TI BLE5-Stack API Documentation  2.01.03.00
rtls_host.h
Go to the documentation of this file.
1 /******************************************************************************
2 
3  @file rtls_host.h
4 
5  @brief This file contains the host abstraction layer for a RTLS Host
6  Group: WCS, BTS
7  $Target Device: DEVICES $
8 
9  ******************************************************************************
10  $License: BSD3 2018 $
11  ******************************************************************************
12  $Release Name: PACKAGE NAME $
13  $Release Date: PACKAGE RELEASE DATE $
14  *****************************************************************************/
15 
25 #ifndef RTLS_HOST_H_
26 #define RTLS_HOST_H_
27 
28 #ifdef __cplusplus
29 extern "C"
30 {
31 #endif
32 
33 /*********************************************************************
34  * INCLUDES
35  */
36 
37 /*********************************************************************
38 * EXTERNAL VARIABLES
39 */
40 
41 /*********************************************************************
42  * CONSTANTS
43  */
44 
45 /*********************************************************************
46  * MACROS
47  */
48 
49 /*********************************************************************
50  * TYPEDEFS
51  */
52 
57 typedef enum
59 {
60  HOST_ASYNC_REQ,
61  HOST_ASYNC_RSP,
62  HOST_SYNC_REQ,
63  HOST_SYNC_RSP
65 
66 // RTLS Host message structure
67 typedef struct
68 {
69  uint16_t cmdId;
70  rtlsHostMsgType_e cmdType;
71  uint16_t dataLen;
72  uint8_t *pData;
73 } rtlsHostMsg_t;
74 
76 typedef void (*pfnRtlsCtrlProcessMsgCb)(rtlsHostMsg_t *pMsg);
79 /*********************************************************************
80  * API FUNCTIONS
81  */
82 
92 
103 uint8_t RTLSHost_sendMsg(uint8_t cmdId, uint8_t cmdType, uint8_t *pData, uint16_t dataLen);
104 
105 /*********************************************************************
106 *********************************************************************/
107 
108 #ifdef __cplusplus
109 }
110 #endif
111 
112 #endif /* RTLS_HOST_H_ */
113 
rtlsHostMsgType_e
Enumeration for Host Message types.
Definition: rtls_host.h:58
uint8_t RTLSHost_sendMsg(uint8_t cmdId, uint8_t cmdType, uint8_t *pData, uint16_t dataLen)
This function is an abstraction of sending messages to a RTLS Host.
void(* pfnRtlsCtrlProcessMsgCb)(rtlsHostMsg_t *pMsg)
RTLS Host application callback.
Definition: rtls_host.h:76
void RTLSHost_openHostIf(pfnRtlsCtrlProcessMsgCb rtlsHostMsgCb)
This function opens the host interface and registers the application callback.
© Copyright 1995-2020, Texas Instruments Incorporated. All rights reserved.
Trademarks | Privacy policy | Terms of use | Terms of sale