Mercurial > public > ostc4
comparison Common/Inc/data_exchange.h @ 1078:082825daccb5 Icon_Integration tip
Added control views for HUD:
The HUD implementation may now be activated by the compile switch ENABLE_HUD_SUPPORT. The HUD will become visible onces detected in the CvOpt overview menu. The first implementation is for testing only => The LEDs may be operated by a number field. Positiv values activate the red, negativ the green LEDs. Depending on the value blink sequences will be scheduled.
At the moment no dive specific data is mapped to the LED operation (like e.g. warnings).
| author | Ideenmodellierer |
|---|---|
| date | Mon, 02 Mar 2026 17:30:38 +0100 |
| parents | 4499227a2db8 |
| children |
comparison
equal
deleted
inserted
replaced
| 1077:bd8ab302ef4a | 1078:082825daccb5 |
|---|---|
| 32 #include "stm32f4xx_hal.h" | 32 #include "stm32f4xx_hal.h" |
| 33 | 33 |
| 34 /* Command definitions for control of external interface */ | 34 /* Command definitions for control of external interface */ |
| 35 /* 1st nibble binary on/off states */ | 35 /* 1st nibble binary on/off states */ |
| 36 /* 2nd nibble target sensor ID (if sensor command is active) */ | 36 /* 2nd nibble target sensor ID (if sensor command is active) */ |
| 37 /* 3rd nibble sensor commands */ | 37 /* 3 + 4th nibble control channel */ |
| 38 /* 4th nibble control channel */ | |
| 39 #define EXT_INTERFACE_33V_ON (0x8000u) /* Bit set to enable 3.3V power interface */ | 38 #define EXT_INTERFACE_33V_ON (0x8000u) /* Bit set to enable 3.3V power interface */ |
| 40 #define EXT_INTERFACE_ADC_ON (0x4000u) /* Bit set to enable ADC conversion */ | 39 #define EXT_INTERFACE_ADC_ON (0x4000u) /* Bit set to enable ADC conversion */ |
| 41 #define EXT_INTERFACE_BUZZER_ON (0x2000u) /* Bit set to enable the buzzer */ | 40 #define EXT_INTERFACE_BUZZER_ON (0x2000u) /* Bit set to enable the buzzer */ |
| 42 | 41 |
| 43 /* Command subset */ | 42 /* Command subset */ |
| 44 #define EXT_INTERFACE_AUTODETECT (0x0001u) /* Start auto detection of connected sensors */ | 43 #define EXT_INTERFACE_AUTODETECT (0x0001u) /* Start auto detection of connected sensors */ |
| 45 #define EXT_INTERFACE_COPY_SENSORMAP (0x0002u) /* Use the sensor map provided by master for internal operations */ | 44 #define EXT_INTERFACE_COPY_SENSORMAP (0x0002u) /* Use the sensor map provided by master for internal operations */ |
| 46 #define EXT_INTERFACE_CO2_CALIB (0x0010u) /* Request calibration of CO2Sensor */ | 45 #define EXT_INTERFACE_CO2_CALIB (0x0010u) /* Request calibration of CO2Sensor */ |
| 47 #define EXT_INTERFACE_O2_INDICATE (0x0020u) /* Request LED to blink*/ | 46 #define EXT_INTERFACE_O2_INDICATE (0x0020u) /* Request LED to blink */ |
| 47 #define EXT_INTERFACE_HUD_UPDATE (0x0030u) /* Update status sequence */ | |
| 48 #define EXT_INTERFACE_HUD_ABORT (0x0031u) /* Abort status sequence */ | |
| 48 | 49 |
| 49 #define DATA_BUFFER_ADC (0x01u) | 50 #define DATA_BUFFER_ADC (0x01u) |
| 50 #define DATA_BUFFER_CO2 (0x02u) | 51 #define DATA_BUFFER_CO2 (0x02u) |
| 51 | 52 |
| 52 #define EXTIF_SENSOR_INFO_SIZE (32u) /* size of data array reserved for extended sensor data from external interface */ | 53 #define EXTIF_SENSOR_INFO_SIZE (32u) /* size of data array reserved for extended sensor data from external interface */ |
| 220 | 221 |
| 221 uint16_t externalInterface_Cmd; | 222 uint16_t externalInterface_Cmd; |
| 222 | 223 |
| 223 uint8_t externalInterface_SensorMap[EXT_INTERFACE_SENSOR_CNT]; | 224 uint8_t externalInterface_SensorMap[EXT_INTERFACE_SENSOR_CNT]; |
| 224 | 225 |
| 225 float UNUSED1[16-1];//VPM_adjusted_critical_radius_he[16]; | 226 uint8_t externalInterface_HUD_Update[EXT_INTERFACE_HUD_LED_MAX]; |
| 227 uint8_t externalInterface_HUD_Brightness; | |
| 228 uint8_t UNUSED0[3]; | |
| 229 float UNUSED1[16-6];//VPM_adjusted_critical_radius_he[16]; => Reuse HUD_Update | |
| 226 float UNUSED2[16];//VPM_adjusted_critical_radius_n2[16]; | 230 float UNUSED2[16];//VPM_adjusted_critical_radius_n2[16]; |
| 227 float UNUSED3[16];//VPM_adjusted_crushing_pressure_he[16]; | 231 float UNUSED3[16];//VPM_adjusted_crushing_pressure_he[16]; |
| 228 float UNUSED4[16];//VPM_adjusted_crushing_pressure_n2[16]; | 232 float UNUSED4[16];//VPM_adjusted_crushing_pressure_n2[16]; |
| 229 float UNUSED5[16];//VPM_initial_allowable_gradient_he[16]; | 233 float UNUSED5[16];//VPM_initial_allowable_gradient_he[16]; |
| 230 float UNUSED6[16];//VPM_initial_allowable_gradient_n2[16]; | 234 float UNUSED6[16];//VPM_initial_allowable_gradient_n2[16]; |
