aboutsummaryrefslogtreecommitdiffstats
path: root/Software/Embedded_SW/Embedded/Communication/CommunicationTask.h
blob: d3d4a292c450c54ede87090d5fa8369a80725ee5 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
pre { line-height: 125%; }
td.linenos .normal { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
span.linenos { color: inherit; background-color: transparent; padding-left: 5px; padding-right: 5px; }
td.linenos .special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
span.linenos.special { color: #000000; background-color: #ffffc0; padding-left: 5px; padding-right: 5px; }
.highlight .hll { background-color: #ffffcc }
.highlight .c { color: #888888 } /* Comment */
.highlight .err { color: #a61717; background-color: #e3d2d2 } /* Error *
/*
 * CommunicationTask.h
 *
 *  Created on: 8 ����� 2018
 *      Author: shlomo
 */

#ifndef COMMUNICATION_COMMUNICATIONTASK_H_
#define COMMUNICATION_COMMUNICATIONTASK_H_


void RegisterReceiveCallback(void (*callback_ptr)(char* buffer, size_t length));

uint32_t initArray( size_t initialSize);

bool insertArray(uint32_t buffer, char element);

void freeArray(uint32_t buffer);

extern uint32_t CommunicationTaskInit(void);

extern uint32_t CommunicationTaskMessageReceived(uint32_t buffer,uint16_t msgSize);

extern bool CommunicationTaskSendMessage(char* buffer,size_t length);

void CommunicationMailboxFlush(void);


#define isUART true
#define isUSB false

extern int32_t SetCommunicationPath(bool UARTorUSB);
#endif /* COMMUNICATION_COMMUNICATIONTASK_H_ */