Mercurial > public > ostc4
diff Small_CPU/Inc/uartProtocol_GNSS.h @ 919:c0553dd70608 Evo_2_23
GNSS support for external UART interface:
An ubox gps module may now be connected to the external UART. Per default the functionality is disabled using the compile switch ENABLE_GNSS_SUPPORT
author | Ideenmodellierer |
---|---|
date | Sun, 03 Nov 2024 15:43:04 +0100 |
parents | 2225c467f1e9 |
children |
line wrap: on
line diff
--- a/Small_CPU/Inc/uartProtocol_GNSS.h Sun Nov 03 15:40:55 2024 +0100 +++ b/Small_CPU/Inc/uartProtocol_GNSS.h Sun Nov 03 15:43:04 2024 +0100 @@ -33,23 +33,47 @@ typedef enum { - UART_GNSS_INIT = 0, /* Default Status for every sensor type */ - UART_GNSS_LOAD, /* Load modul configuration */ - UART_GNSS_GET_ID, /* get unique module ID */ - UART_GNSS_IDLE, /* sensor detected and no communication pending */ - UART_GNSS_ERROR, - UART_GNSS_OPERATING, /* normal operation => cyclic request of PVT data */ + UART_GNSS_INIT = 0, /* Default Status for every sensor type */ + UART_GNSS_IDLE, /* sensor detected and no communication pending */ + UART_GNSS_ERROR, /* Error message received from sensor */ + UART_GNSS_WARMUP = 10, + UART_GNSS_LOADCONF_0, + UART_GNSS_LOADCONF_1, + UART_GNSS_LOADCONF_2, + UART_GNSS_GET_PVT, } uartGnssStatus_t; typedef enum { GNSSRX_READY = 0, /* Initial state */ - GNSSRX_RECEIVING, /* Pending data receiption */ + GNSSRX_DETECT_HEADER_0, + GNSSRX_DETECT_HEADER_1, + GNSSRX_DETECT_HEADER_2, + GNSSRX_DETECT_HEADER_3, + GNSSRX_DETECT_ACK_0, + GNSSRX_DETECT_ACK_1, + GNSSRX_DETECT_ACK_2, + GNSSRX_DETECT_ACK_3, + GNSSRX_READ_NAV_DATA, + GNSSRX_READ_PVT_DATA, + GNSSRX_READ_POSLLH_DATA } receiveStateGnss_t; + typedef enum + { + GNSSCMD_LOADCONF_0 = 0, + GNSSCMD_LOADCONF_1, + GNSSCMD_LOADCONF_2, + GNSSCMD_GET_NAV_DATA, + GNSSCMD_GET_PVT_DATA, + GNSSCMD_GET_POSLLH_DATA + } gnssSensorCmd_t; + + void uartGnss_Control(void); -void uartGnss_ProcessData(void); -uint8_t uartSentinel_isSensorConnected(); +void uartGnss_ProcessData(uint8_t data); +uint8_t uartGnss_isSensorConnected(); +void uartGnss_SendCmd(uint8_t GnssCmd); #endif /* UART_PROTOCOL_GNSS_H */