Mercurial > public > ostc4
comparison Discovery/Inc/tComm.h @ 970:3123aa8723fd Evo_2_23
Old / new BT module communication:
The old / new BT module do have a sligthly different command set. To keep them compatible a function has been added which returns, based on the HW identification, the command string which matches to the module. In case a command is not supported the value 0 is returned and the calling function may react. E.g. with skipping of configuration steps like it is done now for the new module.
| author | Ideenmodellierer |
|---|---|
| date | Sun, 19 Jan 2025 20:55:30 +0100 |
| parents | fe955104901c |
| children | f1b78bc8de10 1d7c7a36df15 |
comparison
equal
deleted
inserted
replaced
| 969:81049905d829 | 970:3123aa8723fd |
|---|---|
| 41 BM_CONFIG_SIGNAL_POLL, | 41 BM_CONFIG_SIGNAL_POLL, |
| 42 BM_CONFIG_BAUD, | 42 BM_CONFIG_BAUD, |
| 43 BM_CONFIG_SILENCE, | 43 BM_CONFIG_SILENCE, |
| 44 BM_CONFIG_DONE, | 44 BM_CONFIG_DONE, |
| 45 BM_CONFIG_RETRY, | 45 BM_CONFIG_RETRY, |
| 46 #ifdef BOOTLOADER_STANDALONE | |
| 47 BM_INIT_TRIGGER_ON = 100, | 46 BM_INIT_TRIGGER_ON = 100, |
| 48 BM_INIT_TRIGGER_OFF, | 47 BM_INIT_TRIGGER_OFF, |
| 49 BM_INIT_ECHO, | 48 BM_INIT_ECHO, |
| 50 BM_INIT_FACTORY, | 49 BM_INIT_FACTORY, |
| 51 BM_INIT_MODE, | 50 BM_INIT_MODE, |
| 56 BM_INIT_SSP_ID1_OFF, | 55 BM_INIT_SSP_ID1_OFF, |
| 57 BM_INIT_SSP_ID1_ON, | 56 BM_INIT_SSP_ID1_ON, |
| 58 BM_INIT_STORE, | 57 BM_INIT_STORE, |
| 59 BM_INIT_RESTART, | 58 BM_INIT_RESTART, |
| 60 BM_INIT_DONE | 59 BM_INIT_DONE |
| 61 #endif | |
| 62 } BlueModTmpConfig_t; | 60 } BlueModTmpConfig_t; |
| 63 | 61 |
| 62 | |
| 63 typedef enum | |
| 64 { | |
| 65 BT_CMD_ECHO, | |
| 66 BT_CMD_ESCAPE_DELAY, | |
| 67 BT_CMD_SIGNAL_POLL, | |
| 68 BT_CMD_BAUDRATE_115, | |
| 69 BT_CMD_BAUDRATE_460, | |
| 70 BT_CMD_SILENCE, | |
| 71 BT_CMD_NAME, | |
| 72 BT_CMD_EXIT_CMD | |
| 73 } BTCmd; | |
| 64 /* Exported functions --------------------------------------------------------*/ | 74 /* Exported functions --------------------------------------------------------*/ |
| 65 | 75 |
| 66 void tComm_init(void); | 76 void tComm_init(void); |
| 67 uint8_t tComm_control(void); | 77 uint8_t tComm_control(void); |
| 68 void tComm_refresh(void); | 78 void tComm_refresh(void); |
