diff --git a/constants b/constants index b86cac9b0..43ac0649c 100644 --- a/constants +++ b/constants @@ -54,28 +54,28 @@ src/fsw/FCCode/EEPROMController.hpp:60: "eeprom_size" = "4096" src/fsw/FCCode/GomspaceController.hpp:10: "default_pv_cmd" = "4000" src/fsw/FCCode/GomspaceController.hpp:11: "default_ppt_mode" = "1" src/fsw/FCCode/MainControlLoop.cpp:19: "piksi_serial" = "Serial4" -src/fsw/FCCode/MainControlLoop.cpp:63: "i2c_mode_sel" = "I2C_MASTER" -src/fsw/FCCode/MainControlLoop.cpp:64: "i2c_pin_nos" = "I2C_PINS_18_19" -src/fsw/FCCode/MainControlLoop.cpp:65: "i2c_pullups" = "I2C_PULLUP_EXT" -src/fsw/FCCode/MainControlLoop.cpp:66: "i2c_rate" = "400000" -src/fsw/FCCode/MainControlLoop.cpp:67: "i2c_op" = "I2C_OP_MODE_IMM" -src/fsw/FCCode/MainControlLoop.cpp:127: "piksi_duration" = "6400" -src/fsw/FCCode/MainControlLoop.cpp:128: "adcs_monitor_duration" = "28000" -src/fsw/FCCode/MainControlLoop.cpp:129: "debug_duration" = "16400" -src/fsw/FCCode/MainControlLoop.cpp:130: "gomspace_duration" = "15000" -src/fsw/FCCode/MainControlLoop.cpp:131: "uplink_duration" = "10000" -src/fsw/FCCode/MainControlLoop.cpp:132: "attitude_estimator_duration" = "5000" -src/fsw/FCCode/MainControlLoop.cpp:133: "mission_duration" = "1000" -src/fsw/FCCode/MainControlLoop.cpp:134: "dcdc_duration" = "1000" -src/fsw/FCCode/MainControlLoop.cpp:135: "attitude_controller_duration" = "1000" -src/fsw/FCCode/MainControlLoop.cpp:136: "adcs_commander_duration" = "1000" -src/fsw/FCCode/MainControlLoop.cpp:137: "adcs_box_controller_duration" = "10000" -src/fsw/FCCode/MainControlLoop.cpp:138: "orbit_duration" = "5000" -src/fsw/FCCode/MainControlLoop.cpp:139: "prop_duration" = "28000" -src/fsw/FCCode/MainControlLoop.cpp:140: "downlink_duration" = "1000" -src/fsw/FCCode/MainControlLoop.cpp:141: "quake_duration" = "30000" -src/fsw/FCCode/MainControlLoop.cpp:142: "docking_duration" = "10000" -src/fsw/FCCode/MainControlLoop.cpp:143: "eeprom_duration" = "16600" +src/fsw/FCCode/MainControlLoop.cpp:62: "i2c_mode_sel" = "I2C_MASTER" +src/fsw/FCCode/MainControlLoop.cpp:63: "i2c_pin_nos" = "I2C_PINS_18_19" +src/fsw/FCCode/MainControlLoop.cpp:64: "i2c_pullups" = "I2C_PULLUP_EXT" +src/fsw/FCCode/MainControlLoop.cpp:65: "i2c_rate" = "400000" +src/fsw/FCCode/MainControlLoop.cpp:66: "i2c_op" = "I2C_OP_MODE_IMM" +src/fsw/FCCode/MainControlLoop.cpp:126: "piksi_duration" = "6400" +src/fsw/FCCode/MainControlLoop.cpp:127: "adcs_monitor_duration" = "28000" +src/fsw/FCCode/MainControlLoop.cpp:128: "debug_duration" = "16400" +src/fsw/FCCode/MainControlLoop.cpp:129: "gomspace_duration" = "15000" +src/fsw/FCCode/MainControlLoop.cpp:130: "uplink_duration" = "10000" +src/fsw/FCCode/MainControlLoop.cpp:131: "attitude_estimator_duration" = "5000" +src/fsw/FCCode/MainControlLoop.cpp:132: "mission_duration" = "1000" +src/fsw/FCCode/MainControlLoop.cpp:133: "dcdc_duration" = "1000" +src/fsw/FCCode/MainControlLoop.cpp:134: "attitude_controller_duration" = "1000" +src/fsw/FCCode/MainControlLoop.cpp:135: "adcs_commander_duration" = "1000" +src/fsw/FCCode/MainControlLoop.cpp:136: "adcs_box_controller_duration" = "10000" +src/fsw/FCCode/MainControlLoop.cpp:137: "orbit_duration" = "5000" +src/fsw/FCCode/MainControlLoop.cpp:138: "prop_duration" = "28000" +src/fsw/FCCode/MainControlLoop.cpp:139: "downlink_duration" = "1000" +src/fsw/FCCode/MainControlLoop.cpp:140: "quake_duration" = "30000" +src/fsw/FCCode/MainControlLoop.cpp:141: "docking_duration" = "10000" +src/fsw/FCCode/MainControlLoop.cpp:142: "eeprom_duration" = "16600" src/fsw/FCCode/MissionManager.hpp:32: "initial_detumble_safety_factor" = "0.025" src/fsw/FCCode/MissionManager.hpp:33: "initial_close_approach_trigger_dist" = "2000" src/fsw/FCCode/MissionManager.hpp:34: "initial_docking_trigger_dist" = "0.4" diff --git a/src/flow_data.cpp b/src/flow_data.cpp index 85052c678..b351c3c3c 100644 --- a/src/flow_data.cpp +++ b/src/flow_data.cpp @@ -11,7 +11,7 @@ const std::vector PAN::flow_data = { {4, false, {"rel_orbit.pos", "rel_orbit.vel"}}, {5, false, {"rel_orbit.rel_pos", "rel_orbit.rel_vel", "rel_orbit.rel_pos_sigma", "rel_orbit.rel_vel_sigma"}}, {6, false, {"attitude_estimator.w_bias_body", "attitude_estimator.p_body_eci_sigma_f", "attitude_estimator.w_bias_sigma_body", "attitude_estimator.mag_flag", "attitude_estimator.b_valid", "attitude_estimator.b_body"}}, -{7, true, {"adcs_monitor.functional_fault.base", "piksi_fh.dead.base", "adcs_monitor.wheel1_fault.base", "adcs_monitor.wheel2_fault.base", "adcs_monitor.wheel3_fault.base", "adcs_monitor.wheel_pot_fault.base", "prop.overpressured.base", "prop.pressurize_fail.base", "prop.tank2_temp_high.base", "prop.tank1_temp_high.base", "gomspace.low_batt.base", "gomspace.get_hk.base", "attitude_estimator.fault.base"}}, +{7, true, {"adcs_monitor.functional_fault.base", "piksi_fh.dead.base", "adcs_monitor.wheel2_fault.base", "adcs_monitor.wheel3_fault.base", "adcs_monitor.wheel_pot_fault.base", "prop.overpressured.base", "prop.pressurize_fail.base", "prop.tank2_temp_high.base", "prop.tank1_temp_high.base", "gomspace.low_batt.base", "gomspace.get_hk.base", "attitude_estimator.fault.base"}}, {8, true, {"gomspace.vbatt", "gomspace.cursun", "gomspace.cursys", "gomspace.temp.output1", "gomspace.temp.output2", "gomspace.temp.output3", "gomspace.temp.output4"}}, {9, false, {"gomspace.vboost.output1", "gomspace.vboost.output2", "gomspace.vboost.output3", "gomspace.curin.output1", "gomspace.curin.output2", "gomspace.curin.output3"}}, {10, false, {"gomspace.curout.output1", "gomspace.curout.output2", "gomspace.curout.output3", "gomspace.curout.output4", "gomspace.curout.output5", "gomspace.curout.output6", "gomspace.output.output1", "gomspace.output.output2", "gomspace.output.output3", "gomspace.output.output4", "gomspace.output.output5", "gomspace.output.output6"}}, diff --git a/src/flow_data.csv b/src/flow_data.csv index 362653a97..976df99f4 100644 --- a/src/flow_data.csv +++ b/src/flow_data.csv @@ -1,52 +1,55 @@ -When making changes to this file remember to perform the following steps:,,,,,,,,,,,,,,,,,,,, -1. Change the last generator in /test/test_fsw_downlink_producer/packet_gen.py,,,,,,,,,,,,,,,,,,,, -2. Run the file in the previous step and get an output.,,,,,,,,,,,,,,,,,,,, -3. Save the output in the /test/dat/DownlinkParser/downlink* files,,,,,,,,,,,,,,,,,,,, -4. Update /test/dat/DownlinkParser/expected_output.json,,,,,,,,,,,,,,,,,,,, -,,,,,,,,,,,,,,,,,,,, -,,,,,,,,,,,,,,,,,,,, -Flow Description,Flow is Active?,Flow Fields,,,,,,,,,,,,,,,,,, -Core State Information,TRUE,pan.state,pan.deployed,pan.sat_designation,pan.bootcount,pan.deployment.elapsed,pan.cycle_no,,,,,,,,,,,,, -Core Estimator Data,TRUE,time.valid,time.gps,orbit.valid,orbit.pos,orbit.vel,attitude_estimator.valid,attitude_estimator.ignore_sun_vectors,attitude_estimator.q_body_eci,attitude_estimator.L_body,rel_orbit.state,,,,,,,,, -Debug Orbit Estimator Data,FALSE,orbit.pos_sigma,orbit.vel_sigma,,,,,,,,,,,,,,,,, -Debug Relative Orbit Estimator Far Field,FALSE,rel_orbit.pos,rel_orbit.vel,,,,,,,,,,,,,,,,, -Debug Relative Orbit Estimator Near Field,FALSE,rel_orbit.rel_pos,rel_orbit.rel_vel,rel_orbit.rel_pos_sigma,rel_orbit.rel_vel_sigma,,,,,,,,,,,,,,, -Debug Attitude Estimator,FALSE,attitude_estimator.w_bias_body,attitude_estimator.p_body_eci_sigma_f,attitude_estimator.w_bias_sigma_body,attitude_estimator.mag_flag,attitude_estimator.b_valid,attitude_estimator.b_body,,,,,,,,,,,,, -Faults,TRUE,adcs_monitor.functional_fault.base,piksi_fh.dead.base,adcs_monitor.wheel1_fault.base,adcs_monitor.wheel2_fault.base,adcs_monitor.wheel3_fault.base,adcs_monitor.wheel_pot_fault.base,,prop.overpressured.base,prop.pressurize_fail.base,prop.tank2_temp_high.base,prop.tank1_temp_high.base,gomspace.low_batt.base,gomspace.get_hk.base,attitude_estimator.fault.base,,,,, -Gomspace Core,TRUE,gomspace.vbatt,gomspace.cursun,gomspace.cursys,gomspace.temp.output1,gomspace.temp.output2,gomspace.temp.output3,gomspace.temp.output4,,,,,,,,,,,, -Gomspace Input Data,FALSE,gomspace.vboost.output1,gomspace.vboost.output2,gomspace.vboost.output3,gomspace.curin.output1,gomspace.curin.output2,gomspace.curin.output3,,,,,,,,,,,,, -Gomspace Output Data,FALSE,gomspace.curout.output1,gomspace.curout.output2,gomspace.curout.output3,gomspace.curout.output4,gomspace.curout.output5,gomspace.curout.output6,gomspace.output.output1,gomspace.output.output2,gomspace.output.output3,gomspace.output.output4,gomspace.output.output5,gomspace.output.output6,,,,,,, -Gomspace Basic Data,FALSE,gomspace.counter_boot,gomspace.bootcause,gomspace.battmode,gomspace.pptmode,,,,,,,,,,,,,,, -Gomspace Controls,FALSE,gomspace.power_cycle_output1_cmd,gomspace.power_cycle_output2_cmd,gomspace.power_cycle_output3_cmd,gomspace.power_cycle_output4_cmd,gomspace.power_cycle_output5_cmd,gomspace.power_cycle_output6_cmd,gomspace.piksi_off,,,,,,,,,,,, -SubMachine States,TRUE,adcs.state,prop.state,radio.state,piksi.state,qfh.state,,,,,,,,,,,,,, -ADCS HAVT Information,TRUE,adcs_monitor.havt_device0,adcs_monitor.havt_device1,adcs_monitor.havt_device2,adcs_monitor.havt_device3,adcs_monitor.havt_device4,adcs_monitor.havt_device5,adcs_monitor.havt_device6,adcs_monitor.havt_device7,adcs_monitor.havt_device8,adcs_monitor.havt_device9,adcs_monitor.havt_device10,adcs_monitor.havt_device11,adcs_monitor.havt_device12,adcs_monitor.havt_device13,adcs_monitor.havt_device14,adcs_monitor.havt_device15,adcs_monitor.havt_device16,adcs_monitor.havt_device17, -Core ADCS sensor data,TRUE,adcs_monitor.rwa_speed_rd.x,adcs_monitor.rwa_speed_rd.y,adcs_monitor.rwa_speed_rd.z,,adcs_monitor.rwa_torque_rd.x,adcs_monitor.rwa_torque_rd.y,adcs_monitor.rwa_torque_rd.z,adcs_monitor.ssa_mode,,,,,,,,,,, -Prop Sensors,FALSE,prop.tank1.valve_choice,prop.tank2.pressure,prop.tank2.temp,prop.tank1.temp,prop.num_prop_firings,,,,,,,,,,,,,, -ADCS Computation,TRUE,attitude.pointer_vec1_current,attitude.pointer_vec1_desired,attitude.pointer_vec2_current,attitude.pointer_vec2_desired,,,,,,,,,,,,,,, -Radio Data,TRUE,radio.err,radio.last_comms_ccno,,,,,,,,,,,,,,,,, -ADCS Sensor Data,TRUE,adcs_monitor.mag1_vec.x,adcs_monitor.mag1_vec.y,adcs_monitor.mag1_vec.z,adcs_monitor.mag2_vec.x,adcs_monitor.mag2_vec.y,adcs_monitor.mag2_vec.z,adcs_monitor.gyr_vec.x,adcs_monitor.gyr_vec.y,adcs_monitor.gyr_vec.z,adcs_monitor.ssa_vec,,,,,,,,, -ADCS Sensor Bound Flags,FALSE,adcs_monitor.speed_rd_flag,adcs_monitor.torque_rd_flag,adcs_monitor.mag1_vec_flag,adcs_monitor.mag2_vec_flag,adcs_monitor.gyr_vec_flag,adcs_monitor.gyr_temp_flag,,,,,,,,,,,,, -Raw Piksi Data,FALSE,piksi.pos,piksi.vel,piksi.baseline_pos,piksi.fix_error_count,piksi.time,piksi.microdelta,,,,,,,,,,,,, -DCDC Information,FALSE,dcdc.SpikeDock,dcdc.ADCSMotor,,,,,,,,,,,,,,,,, -ADCS Sun Sensor Voltages 1,FALSE,adcs_monitor.ssa_voltage0,adcs_monitor.ssa_voltage1,adcs_monitor.ssa_voltage2,adcs_monitor.ssa_voltage3,adcs_monitor.ssa_voltage4,adcs_monitor.ssa_voltage5,adcs_monitor.ssa_voltage6,adcs_monitor.ssa_voltage7,adcs_monitor.ssa_voltage8,adcs_monitor.ssa_voltage9,,,,,,,,, -ADCS Sun Sensor Voltages 2,FALSE,adcs_monitor.ssa_voltage10,adcs_monitor.ssa_voltage11,adcs_monitor.ssa_voltage12,adcs_monitor.ssa_voltage13,adcs_monitor.ssa_voltage14,adcs_monitor.ssa_voltage15,adcs_monitor.ssa_voltage16,adcs_monitor.ssa_voltage17,adcs_monitor.ssa_voltage18,adcs_monitor.ssa_voltage19,,,,,,,,, -Docking core information,TRUE,docksys.docked,,,,,,,,,,,,,,,,,, -,,,,,,,,,,,,,,,,,,,, -OrbitController,TRUE,orbit.control.valve1,orbit.control.valve2,orbit.control.valve3,orbit.control.valve4,orbit.control.J_ecef,orbit.control.alpha,orbit.control.num_near_field_nodes,,,,,,,,,,,, -Prop Controls,FALSE,prop.cycles_until_firing,prop.sched_intertank1,prop.sched_intertank2,,,,,,,,,,,,,,,, -ADCS Control Vectors,FALSE,adcs_cmd.rwa_speed_cmd,adcs_cmd.rwa_torque_cmd,adcs_cmd.mtr_cmd,,,,,,,,,,,,,,,, -Timing Data 1,FALSE,timing.adcs_commander.avg_wait,timing.adcs_commander.num_lates,timing.adcs_controller.avg_wait,timing.adcs_controller.num_lates,timing.estimators.avg_wait,timing.estimators.num_lates,timing.adcs_monitor.avg_wait,timing.adcs_monitor.num_lates,timing.attitude_controller.avg_wait,timing.attitude_controller.num_lates,timing.clock_ct.avg_wait,timing.clock_ct.num_lates,timing.dcdc_ct.avg_wait,timing.dcdc_ct.num_lates,timing.debug.avg_wait,timing.debug.num_lates,,, -Timing Data 2,FALSE,timing.docking_ct.avg_wait,timing.docking_ct.num_lates,timing.downlink_ct.avg_wait,timing.downlink_ct.num_lates,timing.eeprom_ct.avg_wait,timing.eeprom_ct.num_lates,timing.gomspace_rd.avg_wait,timing.gomspace_rd.num_lates,timing.mission_ct.avg_wait,timing.mission_ct.num_lates,timing.piksi.avg_wait,timing.piksi.num_lates,timing.quake.avg_wait,timing.quake.num_lates,timing.uplink_ct.avg_wait,timing.uplink_ct.num_lates,,, -DCDC Controls,FALSE,dcdc.ADCSMotor_cmd,dcdc.SpikeDock_cmd,dcdc.disable_cmd,dcdc.reset_cmd,,,,,,,,,,,,,,, -ADCS Minor Control Variables,FALSE,adcs_cmd.rwa_mode,adcs_cmd.rwa_speed_filter,adcs_cmd.rwa_ramp_filter,adcs_cmd.mtr_mode,adcs_cmd.mtr_limit,adcs_cmd.ssa_voltage_filter,adcs_cmd.mag1_mode,adcs_cmd.mag2_mode,adcs_cmd.imu_mag_filter,adcs_cmd.imu_gyr_filter,adcs_cmd.imu_gyr_temp_filter,adcs_cmd.imu_gyr_temp_pwm,adcs_cmd.imu_gyr_temp_desired,,,,,, -Mission Manager Controls,FALSE,detumble_safety_factor,docking_timeout_limit,fault_handler.enabled,trigger_dist.close_approach,trigger_dist.docking,,,,,,,,,,,,,, -Downlink Flow Controls,FALSE,downlink.shift_id1,downlink.shift_id2,downlink.toggle_id,,,,,,,,,,,,,,,, -Gomspace Heater,FALSE,gomspace.heater,gomspace.heater_cmd,,,,,,,,,,,,,,,,, -Gomspace WDT Data,FALSE,gomspace.wdt_i2c_time_left,gomspace.counter_wdt_i2c,,,,,,,,,,,,,,,,, -Gomspace Commands,FALSE,gomspace.gs_reboot_cmd,gomspace.gs_reset_cmd,gomspace.heater_cmd,gomspace.pv1_cmd,gomspace.pv2_cmd,gomspace.pv3_cmd,gomspace.pptmode_cmd,gomspace.counter_reset_cmd,,,,,,,,,,, -ADCS HAVT Disable,FALSE,adcs_cmd.havt_disable0,adcs_cmd.havt_disable1,adcs_cmd.havt_disable2,adcs_cmd.havt_disable3,adcs_cmd.havt_disable4,adcs_cmd.havt_disable5,adcs_cmd.havt_disable6,adcs_cmd.havt_disable7,adcs_cmd.havt_disable8,adcs_cmd.havt_disable9,adcs_cmd.havt_disable10,adcs_cmd.havt_disable11,adcs_cmd.havt_disable12,adcs_cmd.havt_disable13,adcs_cmd.havt_disable14,adcs_cmd.havt_disable15,adcs_cmd.havt_disable16,adcs_cmd.havt_disable17,adcs_cmd.havt_disable18 -ADCS HAVT Reset,FALSE,adcs_cmd.havt_reset0,adcs_cmd.havt_reset1,adcs_cmd.havt_reset2,adcs_cmd.havt_reset3,adcs_cmd.havt_reset4,adcs_cmd.havt_reset5,adcs_cmd.havt_reset6,adcs_cmd.havt_reset7,adcs_cmd.havt_reset8,adcs_cmd.havt_reset9,adcs_cmd.havt_reset10,adcs_cmd.havt_reset11,adcs_cmd.havt_reset12,adcs_cmd.havt_reset13,adcs_cmd.havt_reset14,adcs_cmd.havt_reset15,adcs_cmd.havt_reset16,adcs_cmd.havt_reset17,adcs_cmd.havt_reset18 -Radio Configuration,FALSE,radio.max_transceive,radio.max_wait,,,,,,,,,,,,,,,,, -Piksi Fault Handler Configuration,FALSE,piksi_fh.no_cdpgs_max_wait,piksi_fh.cdpgs_delay_max_wait,piksi_fh.enabled,,,,,,,,,,,,,,,, -Prop Config,FALSE,prop.max_venting_cycles,prop.ctrl_cycles_per_closing,prop.max_pressurizing_cycles,prop.threshold_firing_pressure,prop.ctrl_cycles_per_filling,prop.ctrl_cycles_per_cooling,,,,,,,,,,,,, -Docking auxiliary information,FALSE,docksys.is_turning,docksys.config_cmd,docksys.step_angle,docksys.step_delay,docksys.dock_config,,,,,,,,,,,,,, \ No newline at end of file +When making changes to this file remember to perform the following steps:,,,,,,,,,,,,,,,,,,,,,,,,,,, +1. Change the last generator in /test/test_fsw_downlink_producer/packet_gen.py,,,,,,,,,,,,,,,,,,,,,,,,,,, +2. Run the file in the previous step and get an output.,,,,,,,,,,,,,,,,,,,,,,,,,,, +3. Save the output in the /test/dat/DownlinkParser/downlink* files,,,,,,,,,,,,,,,,,,,,,,,,,,, +4. Update /test/dat/DownlinkParser/expected_output.json,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,, +Flow Description,Flow is Active?,Flow Fields,,,,,,,,,,,,,,,,,,,,,,,,, +Core State Information,TRUE,pan.state,pan.deployed,pan.sat_designation,pan.bootcount,pan.deployment.elapsed,pan.cycle_no,,,,,,,,,,,,,,,,,,,, +Core Estimator Data,TRUE,time.valid,time.gps,orbit.valid,orbit.pos,orbit.vel,attitude_estimator.valid,attitude_estimator.ignore_sun_vectors,attitude_estimator.q_body_eci,attitude_estimator.L_body,rel_orbit.state,,,,,,,,,,,,,,,, +Debug Orbit Estimator Data,FALSE,orbit.pos_sigma,orbit.vel_sigma,,,,,,,,,,,,,,,,,,,,,,,, +Debug Relative Orbit Estimator Far Field,FALSE,rel_orbit.pos,rel_orbit.vel,,,,,,,,,,,,,,,,,,,,,,,, +Debug Relative Orbit Estimator Near Field,FALSE,rel_orbit.rel_pos,rel_orbit.rel_vel,rel_orbit.rel_pos_sigma,rel_orbit.rel_vel_sigma,,,,,,,,,,,,,,,,,,,,,, +Debug Attitude Estimator,FALSE,attitude_estimator.w_bias_body,attitude_estimator.p_body_eci_sigma_f,attitude_estimator.w_bias_sigma_body,attitude_estimator.mag_flag,attitude_estimator.b_valid,attitude_estimator.b_body,,,,,,,,,,,,,,,,,,,, +Faults,TRUE,adcs_monitor.functional_fault.base,piksi_fh.dead.base,adcs_monitor.wheel2_fault.base,adcs_monitor.wheel3_fault.base,adcs_monitor.wheel_pot_fault.base,,prop.overpressured.base,prop.pressurize_fail.base,prop.tank2_temp_high.base,prop.tank1_temp_high.base,gomspace.low_batt.base,gomspace.get_hk.base,attitude_estimator.fault.base,,,,,,,,,,,,, +Gomspace Core,TRUE,gomspace.vbatt,gomspace.cursun,gomspace.cursys,gomspace.temp.output1,gomspace.temp.output2,gomspace.temp.output3,gomspace.temp.output4,,,,,,,,,,,,,,,,,,, +Gomspace Input Data,FALSE,gomspace.vboost.output1,gomspace.vboost.output2,gomspace.vboost.output3,gomspace.curin.output1,gomspace.curin.output2,gomspace.curin.output3,,,,,,,,,,,,,,,,,,,, +Gomspace Output Data,FALSE,gomspace.curout.output1,gomspace.curout.output2,gomspace.curout.output3,gomspace.curout.output4,gomspace.curout.output5,gomspace.curout.output6,gomspace.output.output1,gomspace.output.output2,gomspace.output.output3,gomspace.output.output4,gomspace.output.output5,gomspace.output.output6,,,,,,,,,,,,,, +Gomspace Basic Data,FALSE,gomspace.counter_boot,gomspace.bootcause,gomspace.battmode,gomspace.pptmode,,,,,,,,,,,,,,,,,,,,,, +Gomspace Controls,FALSE,gomspace.power_cycle_output1_cmd,gomspace.power_cycle_output2_cmd,gomspace.power_cycle_output3_cmd,gomspace.power_cycle_output4_cmd,gomspace.power_cycle_output5_cmd,gomspace.power_cycle_output6_cmd,gomspace.piksi_off,,,,,,,,,,,,,,,,,,, +SubMachine States,TRUE,adcs.state,prop.state,radio.state,piksi.state,qfh.state,,,,,,,,,,,,,,,,,,,,, +ADCS HAVT Information,TRUE,adcs_monitor.havt_device0,adcs_monitor.havt_device1,adcs_monitor.havt_device2,adcs_monitor.havt_device3,adcs_monitor.havt_device4,adcs_monitor.havt_device5,adcs_monitor.havt_device6,adcs_monitor.havt_device7,adcs_monitor.havt_device8,adcs_monitor.havt_device9,adcs_monitor.havt_device10,adcs_monitor.havt_device11,adcs_monitor.havt_device12,adcs_monitor.havt_device13,adcs_monitor.havt_device14,adcs_monitor.havt_device15,adcs_monitor.havt_device16,adcs_monitor.havt_device17,,,,,,,, +Core ADCS sensor data,TRUE,adcs_monitor.rwa_speed_rd.x,adcs_monitor.rwa_speed_rd.y,adcs_monitor.rwa_speed_rd.z,,adcs_monitor.rwa_torque_rd.x,adcs_monitor.rwa_torque_rd.y,adcs_monitor.rwa_torque_rd.z,adcs_monitor.ssa_mode,,,,,,,,,,,,,,,,,, +Prop Sensors,FALSE,prop.tank1.valve_choice,prop.tank2.pressure,prop.tank2.temp,prop.tank1.temp,prop.num_prop_firings,,,,,,,,,,,,,,,,,,,,, +ADCS Computation,TRUE,attitude.pointer_vec1_current,attitude.pointer_vec1_desired,attitude.pointer_vec2_current,attitude.pointer_vec2_desired,,,,,,,,,,,,,,,,,,,,,, +Radio Data,TRUE,radio.err,radio.last_comms_ccno,,,,,,,,,,,,,,,,,,,,,,,, +ADCS Sensor Data,TRUE,adcs_monitor.mag1_vec.x,adcs_monitor.mag1_vec.y,adcs_monitor.mag1_vec.z,adcs_monitor.mag2_vec.x,adcs_monitor.mag2_vec.y,adcs_monitor.mag2_vec.z,adcs_monitor.gyr_vec.x,adcs_monitor.gyr_vec.y,adcs_monitor.gyr_vec.z,adcs_monitor.ssa_vec,,,,,,,,,,,,,,,, +ADCS Sensor Bound Flags,FALSE,adcs_monitor.speed_rd_flag,adcs_monitor.torque_rd_flag,adcs_monitor.mag1_vec_flag,adcs_monitor.mag2_vec_flag,adcs_monitor.gyr_vec_flag,adcs_monitor.gyr_temp_flag,,,,,,,,,,,,,,,,,,,, +Raw Piksi Data,FALSE,piksi.pos,piksi.vel,piksi.baseline_pos,piksi.fix_error_count,piksi.time,piksi.microdelta,,,,,,,,,,,,,,,,,,,, +DCDC Information,FALSE,dcdc.SpikeDock,dcdc.ADCSMotor,,,,,,,,,,,,,,,,,,,,,,,, +ADCS Sun Sensor Voltages 1,FALSE,adcs_monitor.ssa_voltage0,adcs_monitor.ssa_voltage1,adcs_monitor.ssa_voltage2,adcs_monitor.ssa_voltage3,adcs_monitor.ssa_voltage4,adcs_monitor.ssa_voltage5,adcs_monitor.ssa_voltage6,adcs_monitor.ssa_voltage7,adcs_monitor.ssa_voltage8,adcs_monitor.ssa_voltage9,,,,,,,,,,,,,,,, +ADCS Sun Sensor Voltages 2,FALSE,adcs_monitor.ssa_voltage10,adcs_monitor.ssa_voltage11,adcs_monitor.ssa_voltage12,adcs_monitor.ssa_voltage13,adcs_monitor.ssa_voltage14,adcs_monitor.ssa_voltage15,adcs_monitor.ssa_voltage16,adcs_monitor.ssa_voltage17,adcs_monitor.ssa_voltage18,adcs_monitor.ssa_voltage19,,,,,,,,,,,,,,,, +Docking core information,TRUE,docksys.docked,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,, +OrbitController,TRUE,orbit.control.valve1,orbit.control.valve2,orbit.control.valve3,orbit.control.valve4,orbit.control.J_ecef,orbit.control.alpha,orbit.control.num_near_field_nodes,,,,,,,,,,,,,,,,,,,, +Prop Controls,FALSE,prop.cycles_until_firing,prop.sched_intertank1,prop.sched_intertank2,,,,,,,,,,,,,,,,,,, +ADCS Control Vectors,FALSE,adcs_cmd.rwa_speed_cmd,adcs_cmd.rwa_torque_cmd,adcs_cmd.mtr_cmd,,,,,,,,,,,,,,,,,,,,,,, +Timing Data 1,FALSE,timing.adcs_commander.avg_wait,timing.adcs_commander.num_lates,timing.adcs_controller.avg_wait,timing.adcs_controller.num_lates,timing.estimators.avg_wait,timing.estimators.num_lates,timing.adcs_monitor.avg_wait,timing.adcs_monitor.num_lates,timing.attitude_controller.avg_wait,timing.attitude_controller.num_lates,timing.clock_ct.avg_wait,timing.clock_ct.num_lates,timing.dcdc_ct.avg_wait,timing.dcdc_ct.num_lates,timing.debug.avg_wait,timing.debug.num_lates,,,,,,,,,, +Timing Data 2,FALSE,timing.docking_ct.avg_wait,timing.docking_ct.num_lates,timing.downlink_ct.avg_wait,timing.downlink_ct.num_lates,timing.eeprom_ct.avg_wait,timing.eeprom_ct.num_lates,timing.gomspace_rd.avg_wait,timing.gomspace_rd.num_lates,timing.mission_ct.avg_wait,timing.mission_ct.num_lates,timing.piksi.avg_wait,timing.piksi.num_lates,timing.quake.avg_wait,timing.quake.num_lates,timing.uplink_ct.avg_wait,timing.uplink_ct.num_lates,,,,,,,,,, +DCDC Controls,FALSE,dcdc.ADCSMotor_cmd,dcdc.SpikeDock_cmd,dcdc.disable_cmd,dcdc.reset_cmd,,,,,,,,,,,,,,,,,,,,,, +ADCS Minor Control Variables,FALSE,adcs_cmd.rwa_mode,adcs_cmd.rwa_speed_filter,adcs_cmd.rwa_ramp_filter,adcs_cmd.mtr_mode,adcs_cmd.mtr_limit,adcs_cmd.ssa_voltage_filter,adcs_cmd.mag1_mode,adcs_cmd.mag2_mode,adcs_cmd.imu_mag_filter,adcs_cmd.imu_gyr_filter,adcs_cmd.imu_gyr_temp_filter,adcs_cmd.imu_gyr_temp_pwm,adcs_cmd.imu_gyr_temp_desired,,,,,,,,,,,,, +Mission Manager Controls,FALSE,detumble_safety_factor,docking_timeout_limit,fault_handler.enabled,trigger_dist.close_approach,trigger_dist.docking,,,,,,,,,,,,,,,,,,,,, +Downlink Flow Controls,FALSE,downlink.shift_id1,downlink.shift_id2,downlink.toggle_id,,,,,,,,,,,,,,,,,,,,,,, +Gomspace Heater,FALSE,gomspace.heater,gomspace.heater_cmd,,,,,,,,,,,,,,,,,,,,,,,, +Gomspace WDT Data,FALSE,gomspace.wdt_i2c_time_left,gomspace.counter_wdt_i2c,,,,,,,,,,,,,,,,,,,,,,,, +Gomspace Commands,FALSE,gomspace.gs_reboot_cmd,gomspace.gs_reset_cmd,gomspace.heater_cmd,gomspace.pv1_cmd,gomspace.pv2_cmd,gomspace.pv3_cmd,gomspace.pptmode_cmd,gomspace.counter_reset_cmd,,,,,,,,,,,,,,,,,, +ADCS HAVT Disable,FALSE,adcs_cmd.havt_disable0,adcs_cmd.havt_disable1,adcs_cmd.havt_disable2,adcs_cmd.havt_disable3,adcs_cmd.havt_disable4,adcs_cmd.havt_disable5,adcs_cmd.havt_disable6,adcs_cmd.havt_disable7,adcs_cmd.havt_disable8,adcs_cmd.havt_disable9,adcs_cmd.havt_disable10,adcs_cmd.havt_disable11,adcs_cmd.havt_disable12,adcs_cmd.havt_disable13,adcs_cmd.havt_disable14,adcs_cmd.havt_disable15,adcs_cmd.havt_disable16,adcs_cmd.havt_disable17,adcs_cmd.havt_disable18,,,,,,, +ADCS HAVT Reset,FALSE,adcs_cmd.havt_reset0,adcs_cmd.havt_reset1,adcs_cmd.havt_reset2,adcs_cmd.havt_reset3,adcs_cmd.havt_reset4,adcs_cmd.havt_reset5,adcs_cmd.havt_reset6,adcs_cmd.havt_reset7,adcs_cmd.havt_reset8,adcs_cmd.havt_reset9,adcs_cmd.havt_reset10,adcs_cmd.havt_reset11,adcs_cmd.havt_reset12,adcs_cmd.havt_reset13,adcs_cmd.havt_reset14,adcs_cmd.havt_reset15,adcs_cmd.havt_reset16,adcs_cmd.havt_reset17,adcs_cmd.havt_reset18,,,,,,, +Radio Configuration,FALSE,radio.max_transceive,radio.max_wait,,,,,,,,,,,,,,,,,,,,,,,, +Piksi Fault Handler Configuration,FALSE,piksi_fh.no_cdpgs_max_wait,piksi_fh.cdpgs_delay_max_wait,piksi_fh.enabled,,,,,,,,,,,,,,,,,,,,,,, +Prop Config,FALSE,prop.max_venting_cycles,prop.ctrl_cycles_per_closing,prop.max_pressurizing_cycles,prop.threshold_firing_pressure,prop.ctrl_cycles_per_filling,prop.ctrl_cycles_per_cooling,,,,,,,,,,,,,,,,,,,, +Docking auxiliary information,FALSE,docksys.is_turning,docksys.config_cmd,docksys.step_angle,docksys.step_delay,docksys.dock_config,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,, +,,,,,,,,,,,,,,,,,,,,,,,,,,, \ No newline at end of file diff --git a/src/fsw/FCCode/DownlinkProducer.cpp b/src/fsw/FCCode/DownlinkProducer.cpp index 707885e53..69e036491 100644 --- a/src/fsw/FCCode/DownlinkProducer.cpp +++ b/src/fsw/FCCode/DownlinkProducer.cpp @@ -13,27 +13,6 @@ DownlinkProducer::DownlinkProducer(StateFieldRegistry& r) : TimedControlTask("pan.state", __FILE__, __LINE__); - current_state = mission_state_fp->get(); - - active_faults = { - FIND_FAULT(adcs_monitor.wheel_pot_fault.base), - FIND_FAULT(adcs_monitor.wheel3_fault.base), - FIND_FAULT(adcs_monitor.wheel2_fault.base), - FIND_FAULT(adcs_monitor.wheel1_fault.base), // this one isnt in flow_data.cpp - FIND_FAULT(gomspace.low_batt.base), - FIND_FAULT(prop.tank1_temp_high.base), - FIND_FAULT(prop.tank2_temp_high.base), - FIND_FAULT(attitude_estimator.fault.base), - FIND_FAULT(adcs_monitor.functional_fault.base), - FIND_FAULT(prop.overpressured.base), - FIND_FAULT(prop.pressurize_fail.base), - FIND_FAULT(piksi_fh.dead.base), - FIND_FAULT(gomspace.get_hk.base) - }; -} - void DownlinkProducer::init_flows(const std::vector& flow_data) { toggle_flow_id_fp = std::make_unique>("downlink.toggle_id", Serializer(flow_data.size())); shift_flows_id1_fp = std::make_unique>("downlink.shift_id1", Serializer(flow_data.size())); @@ -66,7 +45,6 @@ void DownlinkProducer::init_flows(const std::vector& flow_data) { snapshot = new char[max_downlink_size]; snapshot_ptr_f.set(snapshot); snapshot_size_bytes_f.set(max_downlink_size); - faults_flow_shifted = false; } size_t DownlinkProducer::compute_downlink_size(const bool compute_max) const { @@ -131,12 +109,6 @@ static void add_bits_to_downlink_frame(const bit_array& field_bits, } void DownlinkProducer::execute() { - check_mission_state_change(); - current_state = mission_state_fp->get(); - - // If a fault is signalled, reorder the flows so that the relevant information is downlinked earlier - check_fault_signalled(); - // Set the snapshot size in order to let the Quake Manager know about // the size of the current downlink. snapshot_size_bytes_f.set(compute_downlink_size()); @@ -207,67 +179,6 @@ void DownlinkProducer::execute() { } } -void DownlinkProducer::check_fault_signalled() { - bool found_fault = find_faults(); - if (found_fault && !faults_flow_shifted){ - shift_flow_priorities_idx(7, 2); - faults_flow_shifted = true; - } - else if (!found_fault && faults_flow_shifted) { - faults_flow_shifted = false; - shift_flow_priorities_idx(7, fault_idx); - } -} - -bool DownlinkProducer::find_faults() { - for (auto *fault : active_faults) - { - if (fault->is_faulted()) { - // Loop through list of flows and get the flow with the related fault info - for(size_t idx = 0; idx < flows.size(); idx++) { - std::vector fields = flows[idx].field_list; - for (size_t i = 0; i < fields.size(); i++) { - std::string field = fields[i]->name(); - - if (!field.compare(fault->name())){ - fault_idx = idx; - return true; - } - } - } - } - } - return false; -} - -void DownlinkProducer::check_mission_state_change() { - if (current_state!=mission_state_fp->get()) { - switch(static_cast(mission_state_fp->get())){ - case mission_state_t::follower: - reset_flows(); - shift_flow_priorities_idx(16, 13); - break; - case mission_state_t::follower_close_approach: - reset_flows(); - shift_flow_priorities_idx(16, 13); - break; - default: - reset_flows(); - break; - } - } -} - -void DownlinkProducer::reset_flows() { - for(size_t idx = 0; idx < flows.size(); idx++) { - unsigned char flow_id; - flows[idx].id_sr.deserialize(&flow_id); - if (flow_id != idx+1) { - shift_flow_priorities_idx(flow_id, flow_id-1); - } - } -} - DownlinkProducer::~DownlinkProducer() { delete[] snapshot; } @@ -349,7 +260,6 @@ void DownlinkProducer::toggle_flow(unsigned char id) { } void DownlinkProducer::shift_flow_priorities(unsigned char id1, unsigned char id2) { - #ifndef FLIGHT if(id1 > flows.size()) { printf(debug_severity::error, "Flow with ID %d was not found when " "trying to shift with flow ID %d.", id1, id2); @@ -360,7 +270,6 @@ void DownlinkProducer::shift_flow_priorities(unsigned char id1, unsigned char id "trying to shift with flow ID %d.", id2, id1); assert(false); } - #endif size_t idx1 = 0, idx2 = 0; for(size_t idx = 0; idx < flows.size(); idx++) { @@ -384,39 +293,4 @@ void DownlinkProducer::shift_flow_priorities(unsigned char id1, unsigned char id std::swap(flows[i],flows[i+1]); } } -} - -void DownlinkProducer::shift_flow_priorities_idx(unsigned char id, size_t idx) { - #ifndef FLIGHT - if(id > flows.size()) { - printf(debug_severity::error, "Flow with ID %d was not found when " - "trying to shift to index %d.", id, idx); - assert(false); - } - if(idx > flows.size()) { - printf(debug_severity::error, "Flow in index %d was not found when " - "trying to shift with flow ID %d.", idx, id); - assert(false); - } - #endif - - size_t current_idx = 0; - for(size_t i = 0; i < flows.size(); i++) { - unsigned char flow_id; - flows[i].id_sr.deserialize(&flow_id); - if (flow_id == id) { - current_idx = i; - } - } - - if (current_idx>idx) { - for (size_t i = current_idx; i > idx; i--) { - std::swap(flows[i], flows[i-1]); - } - } - else if (idx>current_idx) { - for (size_t i = current_idx; i < idx; i++) { - std::swap(flows[i],flows[i+1]); - } - } -} +} \ No newline at end of file diff --git a/src/fsw/FCCode/DownlinkProducer.hpp b/src/fsw/FCCode/DownlinkProducer.hpp index d15601955..7a6504e4d 100644 --- a/src/fsw/FCCode/DownlinkProducer.hpp +++ b/src/fsw/FCCode/DownlinkProducer.hpp @@ -3,7 +3,6 @@ #include "TimedControlTask.hpp" #include -#include "mission_state_t.enum" class DownlinkProducer : public TimedControlTask { public: @@ -38,11 +37,6 @@ class DownlinkProducer : public TimedControlTask { */ DownlinkProducer(StateFieldRegistry& registry); - /** - * @brief initialize active faults - */ - void init(); - /** * @brief Initialize flows for the Downlink Producer. This function * should be called in the main control loop after the instantiation of all @@ -67,21 +61,6 @@ class DownlinkProducer : public TimedControlTask { */ void execute() override; - void check_fault_signalled(); - - /** - * @brief Checks if any faults in active_faults are faulted. If so, it stores - * the index of the flow with all the faults in fault_idx. Returns true if a - * fault is faulted and false if all the faults are unfaulted. - */ - bool find_faults(); - - /** - * Reorder telemetry flows based on the new mission state - */ - void check_mission_state_change(); - - /** * @brief Destructor; clears the memory allocated for the snapshot * buffer. @@ -172,17 +151,6 @@ class DownlinkProducer : public TimedControlTask { */ void shift_flow_priorities(unsigned char id1, unsigned char id2); - /** - * @brief Shift the flow with the given id to the given index in the flow order. - * Does not change the active status. - */ - void shift_flow_priorities_idx(unsigned char id, size_t idx); - - /* - * Restore the original flow order - */ - void reset_flows(); - protected: /** @brief Pointer to cycle count. */ ReadableStateField* cycle_count_fp; @@ -212,23 +180,6 @@ class DownlinkProducer : public TimedControlTask { * @brief Statefield used to toggle flow's active status. Default is 0 (no flow can have an id of 0) */ std::unique_ptr> toggle_flow_id_fp; - - const WritableStateField* mission_state_fp; - - unsigned char current_state; - - /** - * @brief The index of the flow containing all the faults. - */ - unsigned char fault_idx; - - /** - * @brief Checks if the flow with all the faults has been shifted (due to a fault being recently signalled) - */ - bool faults_flow_shifted; - - std::array active_faults; - }; #endif diff --git a/src/fsw/FCCode/MainControlLoop.cpp b/src/fsw/FCCode/MainControlLoop.cpp index ad481828e..41a16be35 100644 --- a/src/fsw/FCCode/MainControlLoop.cpp +++ b/src/fsw/FCCode/MainControlLoop.cpp @@ -56,7 +56,6 @@ MainControlLoop::MainControlLoop(StateFieldRegistry& registry, estimators.init(); docking_controller.init(); orbit_controller.init(); - downlink_producer.init(); //setup I2C bus for Flight Controller #ifndef DESKTOP diff --git a/telemetry b/telemetry index 1285e0492..a366b06f9 100644 --- a/telemetry +++ b/telemetry @@ -909,7 +909,7 @@ }, "adcs_monitor.wheel1_fault.base": { "bitsize": 1, - "flow_id": 7, + "flow_id": "undefined", "type": "bool", "writable": true }, @@ -2976,7 +2976,6 @@ "fields": [ "adcs_monitor.functional_fault.base", "piksi_fh.dead.base", - "adcs_monitor.wheel1_fault.base", "adcs_monitor.wheel2_fault.base", "adcs_monitor.wheel3_fault.base", "adcs_monitor.wheel_pot_fault.base", diff --git a/test/test_fsw_downlink_producer/test_downlink_producer.cpp b/test/test_fsw_downlink_producer/test_downlink_producer.cpp index c4305d8a8..0f26fd6ef 100644 --- a/test/test_fsw_downlink_producer/test_downlink_producer.cpp +++ b/test/test_fsw_downlink_producer/test_downlink_producer.cpp @@ -11,21 +11,7 @@ struct TestFixture { std::unique_ptr downlink_producer; std::shared_ptr> foo1_fp; - std::shared_ptr adcs_wheel1_fault_fp; - std::shared_ptr adcs_wheel2_fault_fp; - std::shared_ptr adcs_wheel3_fault_fp; - std::shared_ptr adcs_wheelpot_fault_fp; - std::shared_ptr adcs_functional_fault_fp; - std::shared_ptr prop_pressurize_fault_fp; - std::shared_ptr attitude_estimator_fault_fp; - std::shared_ptr gs_low_batt_fault_fp; - std::shared_ptr prop_overpressured_fault_fp; - std::shared_ptr tank2_temp_fault_fp; - std::shared_ptr tank1_temp_fault_fp; - std::shared_ptr piksi_dead_fault_fp; - std::shared_ptr gs_hk_fault_fp; std::shared_ptr> cycle_count_fp; - std::shared_ptr> pan_state_fp; InternalStateField* snapshot_ptr_fp; InternalStateField* snapshot_size_bytes_fp; WritableStateField* shift_flows_id1_fp; @@ -37,31 +23,15 @@ struct TestFixture { void init(const std::vector& flow_data) { // Create required field(s) cycle_count_fp = registry.create_readable_field("pan.cycle_no"); - pan_state_fp = registry.create_writable_field("pan.state"); - pan_state_fp->set(static_cast(mission_state_t::startup)); // Create field(s) for serialization and initialize them to // default values foo1_fp = registry.create_readable_field("foo1"); - adcs_wheel1_fault_fp = registry.create_fault("adcs_monitor.wheel1_fault", 1); - adcs_wheel2_fault_fp = registry.create_fault("adcs_monitor.wheel2_fault", 1); - adcs_wheel3_fault_fp = registry.create_fault("adcs_monitor.wheel3_fault", 1); - adcs_wheelpot_fault_fp = registry.create_fault("adcs_monitor.wheel_pot_fault", 1); - adcs_functional_fault_fp = registry.create_fault("adcs_monitor.functional_fault", 1); - prop_pressurize_fault_fp = registry.create_fault("prop.pressurize_fail", 1); - attitude_estimator_fault_fp = registry.create_fault("attitude_estimator.fault", 1); - gs_low_batt_fault_fp = registry.create_fault("gomspace.low_batt", 1); - prop_overpressured_fault_fp = registry.create_fault("prop.overpressured", 1); - tank2_temp_fault_fp = registry.create_fault("prop.tank2_temp_high", 1); - tank1_temp_fault_fp = registry.create_fault("prop.tank1_temp_high", 1); - piksi_dead_fault_fp = registry.create_fault("piksi_fh.dead", 1); - gs_hk_fault_fp = registry.create_fault("gomspace.get_hk", 1); cycle_count_fp->set(20); foo1_fp->set(400); downlink_producer = std::make_unique(registry); downlink_producer->init_flows(flow_data); - downlink_producer->init(); snapshot_ptr_fp = registry.find_internal_field_t("downlink.ptr"); snapshot_size_bytes_fp = registry.find_internal_field_t( "downlink.snap_size"); @@ -532,163 +502,6 @@ void test_toggle() { TEST_ASSERT_EQUAL(0, tf.toggle_flow_id_fp->get()); } -void test_fault_reordering() { - TestFixture tf; - - std::vector flow_data = { - { - 1, true, {"foo1"} - }, - { - 2, true, {"foo1"} - }, - { - 3, true, {"foo1"} - }, - { - 4, true, {"foo1"} - }, - { - 5, true, {"foo1"} - }, - { - 6, true, {"foo1"} - }, - { - 7, true, {"adcs_monitor.wheel1_fault.base"} - } - }; - tf.init(flow_data); - std::vector flows=tf.downlink_producer->get_flows(); - - std::vector desired_ids={1,2,3,4,5,6,7}; - for (size_t i = 0; ioverride(); - tf.downlink_producer->execute(); - - // Get the new flow vector and check that the flows have been reordered as desired - flows=tf.downlink_producer->get_flows(); - desired_ids={1,2,7,3,4,5,6}; - for (size_t i = 0; iun_override(); - tf.adcs_wheel1_fault_fp->suppress(); - tf.downlink_producer->execute(); - - // Get the new flow vector and check that the flows have been reordered as desired - flows=tf.downlink_producer->get_flows(); - desired_ids={1,2,3,4,5,6,7}; - for (size_t i = 0; i flow_data = { - { - 1, true, {"foo1"} - }, - { - 2, true, {"foo1"} - }, - { - 3, true, {"foo1"} - }, - { - 4, true, {"foo1"} - }, - { - 5, true, {"foo1"} - }, - { - 6, true, {"foo1"} - }, - { - 7, true, {"foo1"} - }, - { - 8, true, {"foo1"} - }, - { - 9, true, {"foo1"} - }, - { - 10, true, {"foo1"} - }, - { - 11, true, {"foo1"} - }, - { - 12, true, {"foo1"} - }, - { - 13, true, {"foo1"} - }, - { - 14, true, {"foo1"} - }, - { - 15, true, {"foo1"} - }, - { - 16, true, {"foo1"} - }, - { - 17, true, {"foo1"} - } - }; - tf.init(flow_data); - std::vector flows=tf.downlink_producer->get_flows(); - - std::vector desired_ids={1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17}; - for (size_t i = 0; iset(static_cast(mission_state_t::follower)); - tf.downlink_producer->execute(); - - // Get the new flow vector and check that the flows have been reordered as desired - flows=tf.downlink_producer->get_flows(); - desired_ids={1,2,3,4,5,6,7,8,9,10,11,12,13,16,14,15,17}; - for (size_t i = 0; iset(static_cast(mission_state_t::standby)); - - tf.downlink_producer->execute(); - - // Get the new flow vector and check that the flows have been reordered as desired - flows=tf.downlink_producer->get_flows(); - desired_ids={1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17}; - for (size_t i = 0; i