HomeAut
communication.h
1 /*
2  * communication.h
3  *
4  * Created on: 2016. dec. 3.
5  * Author: Vizi Gábor
6  * E-mail: vizi.gabor90@gmail.com
7  * Function: -
8  * Target: STM32Fx
9  * Version: -
10  * Last modified: 2016. dec. 3.
11  */
12 
13 #ifndef COMMUNICATION_H_
14 #define COMMUNICATION_H_
15 
16 
17 
18 /*------------------------------------------------------------------------------
19  * Type definitions
20  *----------------------------------------------------------------------------*/
21 
22 typedef enum
23 {
24  CommProt_Unknown = 0,
25  CommProt_DebugUart = (1 << 0),
26  CommProt_SWO = (1 << 1),
27 
28  CommProt_Disable = (1 << 2)
29 } CommProtocol_t;
30 
31 
32 
33 /*------------------------------------------------------------------------------
34  * Global function declarations
35  *----------------------------------------------------------------------------*/
36 
37 uint8_t COMMUNICATION_SendMessage(CommProtocol_t protocol, const char *message);
38 uint8_t COMMUNICATION_SendChar(CommProtocol_t protocol, char c);
39 uint8_t COMMUNICATION_Printf(CommProtocol_t protocol, const char *format, ...);
40 
41 
42 
43 #endif /* COMMUNICATION_H_ */