File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -42,6 +42,7 @@ extern "C"
4242{
4343#endif
4444
45+ CaveTalk_Error_t CaveTalk_Reset (CaveTalk_LinkHandle_t * const handle );
4546CaveTalk_Error_t CaveTalk_Speak (const CaveTalk_LinkHandle_t * const handle ,
4647 const CaveTalk_Id_t id ,
4748 const void * const data ,
Original file line number Diff line number Diff line change @@ -38,6 +38,23 @@ static inline uint8_t CaveTalk_GetLowerByte(const uint16_t value);
3838static inline uint16_t CaveTalk_GetUpperUint16 (const uint32_t value );
3939static inline uint16_t CaveTalk_GetLowerUint16 (const uint32_t value );
4040
41+ CaveTalk_Error_t CaveTalk_Reset (CaveTalk_LinkHandle_t * const handle )
42+ {
43+ CaveTalk_Error_t error = CAVE_TALK_ERROR_NULL ;
44+
45+ if (NULL != handle )
46+ {
47+ handle -> receive_state = CAVE_TALK_LINK_STATE_RESET ;
48+ handle -> receive_id = CAVE_TALK_ID_NONE ;
49+ handle -> receive_length = 0U ;
50+ handle -> crc = 0U ;
51+ handle -> bytes_received = 0U ;
52+ }
53+
54+ return error ;
55+ }
56+
57+
4158CaveTalk_Error_t CaveTalk_Speak (const CaveTalk_LinkHandle_t * const handle ,
4259 const CaveTalk_Id_t id ,
4360 const void * const data ,
You can’t perform that action at this time.
0 commit comments