Mercurial > public > ostc4
diff Small_CPU/Src/scheduler.c @ 714:045ff7800501
Added customizable data area for specific sensor data:
In future smart sensors will be connected via UART interface. These sensor provide additional data like diagnostics or id numbers which may vary from sensor to sensor. That's why a byte array has been added which stores up to 32 bytes. The layout of this array may be specific to sensor needs. As first example temperature and id number of the DiveO2 sensor are provided.
author | Ideenmodellierer |
---|---|
date | Sun, 20 Nov 2022 20:42:08 +0100 |
parents | f1b40364b0af |
children | 621265ec3d23 |
line wrap: on
line diff
--- a/Small_CPU/Src/scheduler.c Sun Nov 20 20:37:44 2022 +0100 +++ b/Small_CPU/Src/scheduler.c Sun Nov 20 20:42:08 2022 +0100 @@ -1733,6 +1733,7 @@ value = getExternalInterfaceChannel(channel); global.dataSendToMaster.data[boolADCBuffer && DATA_BUFFER_ADC].extADC_voltage[channel] = value; } + global.dataSendToMaster.data[boolADCBuffer && DATA_BUFFER_ADC].externalInterface_SensorID = externalInterface_GetSensorData((uint8_t*)&global.dataSendToMaster.data[boolADCBuffer && DATA_BUFFER_ADC].sensor_data); global.dataSendToMaster.boolADCO2Data |= boolADCBuffer; }