device temeprature set
Some checks failed
EIVE/eive-obsw/pipeline/head There was a failure building this commit

This commit is contained in:
Jakob Meier
2022-06-01 10:48:18 +02:00
parent 87783b01f5
commit 52d94f44d4
4 changed files with 476 additions and 13 deletions

View File

@ -49,22 +49,39 @@ enum PoolIds : lp_id_t {
COMPONENT_RW,
TEMP_Q7S,
TEMP_BATTERY,
TEMP_RW0,
BATTERY_TEMP_1,
BATTERY_TEMP_2,
BATTERY_TEMP_3,
BATTERY_TEMP_4,
TEMP_RW1,
TEMP_RW2,
TEMP_RW3,
TEMP_RW4,
TEMP_STAR_TRACKER,
TEMP_SYRLINKS_POWER_AMPLIFIER,
TEMP_SYRLINKS_BASEBAND_BOARD,
TEMP_MGT,
TEMP_ACU,
TEMP_PDU1,
TEMP_PDU2,
TEMP_1_P60DOCK,
TEMP_2_P60DOCK,
TEMP_GYRO_0_SIDE_A,
TEMP_GYRO_1_SIDE_A,
TEMP_GYRO_2_SIDE_B,
TEMP_GYRO_3_SIDE_B,
TEMP_MGM_0_SIDE_A,
TEMP_MGM_2_SIDE_B,
TEMP_ADC_PAYLOAD_PCDU
};
static const uint8_t ENTRIES_SENSOR_TEMPERATURE_SET = 18;
static const uint8_t ENTRIES_DEVICE_TEMPERATURE_SET = 25;
/**
* @brief This dataset can be used to store the collected temperatures of all temperature sensors
*/
class SensorTemperatures : public StaticLocalDataSet<18> {
class SensorTemperatures : public StaticLocalDataSet<ENTRIES_SENSOR_TEMPERATURE_SET> {
public:
SensorTemperatures(HasLocalDataPoolIF* owner) : StaticLocalDataSet(owner, SENSOR_TEMPERATURES) {}
@ -99,17 +116,43 @@ class SensorTemperatures : public StaticLocalDataSet<18> {
/**
* @brief This dataset can be used to store the collected temperatures of all device temperature
* sensors
* sensors
*/
class DeviceTemperatures : public StaticLocalDataSet<1> {
class DeviceTemperatures : public StaticLocalDataSet<ENTRIES_DEVICE_TEMPERATURE_SET> {
public:
DeviceTemperatures(HasLocalDataPoolIF* owner) : StaticLocalDataSet(owner, SENSOR_TEMPERATURES) {}
DeviceTemperatures(HasLocalDataPoolIF* owner) : StaticLocalDataSet(owner, DEVICE_TEMPERATURES) {}
DeviceTemperatures(object_id_t objectId)
: StaticLocalDataSet(sid_t(objectId, DEVICE_TEMPERATURES)) {}
lp_var_t<float> q7s =
lp_var_t<float>(sid.objectId, PoolIds::SUS_0_N_LOC_XFYFZM_PT_XF, this);
lp_var_t<float> q7s = lp_var_t<float>(sid.objectId, PoolIds::TEMP_Q7S, this);
lp_var_t<float> batteryTemp1 = lp_var_t<float>(sid.objectId, PoolIds::BATTERY_TEMP_1, this);
lp_var_t<float> batteryTemp2 = lp_var_t<float>(sid.objectId, PoolIds::BATTERY_TEMP_2, this);
lp_var_t<float> batteryTemp3 = lp_var_t<float>(sid.objectId, PoolIds::BATTERY_TEMP_3, this);
lp_var_t<float> batteryTemp4 = lp_var_t<float>(sid.objectId, PoolIds::BATTERY_TEMP_4, this);
lp_var_t<int32_t> rw1 = lp_var_t<int32_t>(sid.objectId, PoolIds::TEMP_RW1, this);
lp_var_t<int32_t> rw2 = lp_var_t<int32_t>(sid.objectId, PoolIds::TEMP_RW2, this);
lp_var_t<int32_t> rw3 = lp_var_t<int32_t>(sid.objectId, PoolIds::TEMP_RW3, this);
lp_var_t<int32_t> rw4 = lp_var_t<int32_t>(sid.objectId, PoolIds::TEMP_RW4, this);
lp_var_t<float> startracker = lp_var_t<float>(sid.objectId, PoolIds::TEMP_STAR_TRACKER, this);
lp_var_t<float> syrlinksPowerAmplifier =
lp_var_t<float>(sid.objectId, PoolIds::TEMP_SYRLINKS_POWER_AMPLIFIER, this);
lp_var_t<float> syrlinksBasebandBoard =
lp_var_t<float>(sid.objectId, PoolIds::TEMP_SYRLINKS_BASEBAND_BOARD, this);
lp_var_t<float> mgt = lp_var_t<float>(sid.objectId, PoolIds::TEMP_MGT, this);
lp_vec_t<int16_t, 3> acu = lp_vec_t<int16_t, 3>(sid.objectId, PoolIds::TEMP_ACU, this);
lp_var_t<int16_t> pdu1 = lp_var_t<int16_t>(sid.objectId, PoolIds::TEMP_PDU1, this);
lp_var_t<int16_t> pdu2 = lp_var_t<int16_t>(sid.objectId, PoolIds::TEMP_PDU2, this);
lp_var_t<int16_t> temp1P60dock = lp_var_t<int16_t>(sid.objectId, PoolIds::TEMP_1_P60DOCK, this);
lp_var_t<int16_t> temp2P60dock = lp_var_t<int16_t>(sid.objectId, PoolIds::TEMP_2_P60DOCK, this);
lp_var_t<float> gyro0SideA = lp_var_t<float>(sid.objectId, PoolIds::TEMP_GYRO_0_SIDE_A, this);
lp_var_t<float> gyro1SideA = lp_var_t<float>(sid.objectId, PoolIds::TEMP_GYRO_1_SIDE_A, this);
lp_var_t<float> gyro2SideB = lp_var_t<float>(sid.objectId, PoolIds::TEMP_GYRO_2_SIDE_B, this);
lp_var_t<float> gyro3SideB = lp_var_t<float>(sid.objectId, PoolIds::TEMP_GYRO_3_SIDE_B, this);
lp_var_t<float> mgm0SideA = lp_var_t<float>(sid.objectId, PoolIds::TEMP_MGM_0_SIDE_A, this);
lp_var_t<float> mgm2SideB = lp_var_t<float>(sid.objectId, PoolIds::TEMP_MGM_2_SIDE_B, this);
lp_var_t<float> adcPayloadPcdu =
lp_var_t<float>(sid.objectId, PoolIds::TEMP_ADC_PAYLOAD_PCDU, this);
};
/**
@ -121,7 +164,7 @@ class SusTemperatures : public StaticLocalDataSet<12> {
SusTemperatures(HasLocalDataPoolIF* owner) : StaticLocalDataSet(owner, SUS_TEMPERATURES) {}
SusTemperatures(object_id_t objectId)
: StaticLocalDataSet(sid_t(objectId, DEVICE_TEMPERATURES)) {}
: StaticLocalDataSet(sid_t(objectId, SUS_TEMPERATURES)) {}
lp_var_t<float> sus_0_n_loc_xfyfzm_pt_xf =
lp_var_t<float>(sid.objectId, PoolIds::SUS_0_N_LOC_XFYFZM_PT_XF, this);