Mercurial > public > ostc4
comparison Small_CPU/Inc/externalInterface.h @ 779:0b5f45448eb6
Added UART multiplexer support for DiveO2:
The existing autodetect function now includes a UART multiplexer. The datastructures and protocol handling has been adapted to support several DiveO2 sensors connected to the UART.
author | Ideenmodellierer |
---|---|
date | Tue, 23 May 2023 21:45:34 +0200 |
parents | e23fe82cbf8c |
children | 01b3eb9d55c3 |
comparison
equal
deleted
inserted
replaced
778:74253a41cf80 | 779:0b5f45448eb6 |
---|---|
44 DETECTION_OFF = 0, /* no detection requested */ | 44 DETECTION_OFF = 0, /* no detection requested */ |
45 DETECTION_INIT, /* prepare external interface for operation if not already activated */ | 45 DETECTION_INIT, /* prepare external interface for operation if not already activated */ |
46 DETECTION_START, | 46 DETECTION_START, |
47 DETECTION_ANALOG1, /* check ADC channels for connected sensors */ | 47 DETECTION_ANALOG1, /* check ADC channels for connected sensors */ |
48 DETECTION_ANALOG2, | 48 DETECTION_ANALOG2, |
49 DETECTION_DIGO2, /* check UART channel for connected DigO2 sensor */ | 49 DETECTION_UARTMUX, /* check if a uart multiplexer is present */ |
50 DETECTION_DIGO2_0, /* check UART channel for connected DigO2 sensor */ | |
51 DETECTION_DIGO2_1, | |
52 DETECTION_DIGO2_2, | |
50 #ifdef ENABLE_CO2_SUPPORT | 53 #ifdef ENABLE_CO2_SUPPORT |
51 DETECTION_CO2, /* check UART channel for connected CO2 sensor */ | 54 DETECTION_CO2, /* check UART channel for connected CO2 sensor */ |
52 #endif | 55 #endif |
53 #ifdef ENABLE_SENTINEL_MODE | 56 #ifdef ENABLE_SENTINEL_MODE |
54 DETECTION_SENTINEL, /* check UART channel for connected Sentinel */ | 57 DETECTION_SENTINEL, /* check UART channel for connected Sentinel */ |
79 void externalInterface_SetCO2SignalStrength(uint16_t LED_qa); | 82 void externalInterface_SetCO2SignalStrength(uint16_t LED_qa); |
80 uint16_t externalInterface_GetCO2Value(void); | 83 uint16_t externalInterface_GetCO2Value(void); |
81 uint16_t externalInterface_GetCO2SignalStrength(void); | 84 uint16_t externalInterface_GetCO2SignalStrength(void); |
82 void externalInterface_SetCO2State(uint16_t state); | 85 void externalInterface_SetCO2State(uint16_t state); |
83 uint16_t externalInterface_GetCO2State(void); | 86 uint16_t externalInterface_GetCO2State(void); |
84 uint8_t externalInterface_GetSensorData(uint8_t* pDataStruct); | 87 uint8_t externalInterface_GetSensorData(uint8_t sensorId, uint8_t* pDataStruct); |
85 void externalInterface_SetSensorData(uint8_t dataId, uint8_t* pDataStruct); | 88 void externalInterface_SetSensorData(uint8_t dataId, uint8_t* pDataStruct); |
86 void externalInface_SetSensorMap(uint8_t* pMap); | 89 void externalInface_SetSensorMap(uint8_t* pMap); |
87 uint8_t* externalInterface_GetSensorMapPointer(uint8_t finalMap); | 90 uint8_t* externalInterface_GetSensorMapPointer(uint8_t finalMap); |
88 void externalInterface_AutodetectSensor(void); | 91 void externalInterface_AutodetectSensor(void); |
89 void externalInterface_ExecuteCmd(uint16_t Cmd); | 92 void externalInterface_ExecuteCmd(uint16_t Cmd); |