Index: dialin/dg/calibration_record.py =================================================================== diff -u -rf822b55ab067aba716dc07f7fa3f53ef9cb2c9e3 -r6c9c54b00503ff8124ba864ec846d1866e58b8b7 --- dialin/dg/calibration_record.py (.../calibration_record.py) (revision f822b55ab067aba716dc07f7fa3f53ef9cb2c9e3) +++ dialin/dg/calibration_record.py (.../calibration_record.py) (revision 6c9c54b00503ff8124ba864ec846d1866e58b8b7) @@ -303,8 +303,8 @@ @return: pressure sensors hardware group dictionary and the byte size of this hardware group """ - hardware_names = ['ppi', 'ppo', 'prd', 'pdr', 'reserved_1', 'reserved_2', 'reserved_3', 'reserved_4', - 'reserved_5', 'reserved_6'] + hardware_names = ['ppi', 'ppo', 'prd', 'pdr', 'baro', 'reserved_1', 'reserved_2', 'reserved_3', 'reserved_4', + 'reserved_5'] group_byte_size = 0 group_name = 'pressure_sensors' hardware_group = OrderedDict({group_name: OrderedDict()}) Index: dialin/dg/heaters.py =================================================================== diff -u -r7ea4b936cef531b2cde9053ae58b7119a3bf0e6c -r6c9c54b00503ff8124ba864ec846d1866e58b8b7 --- dialin/dg/heaters.py (.../heaters.py) (revision 7ea4b936cef531b2cde9053ae58b7119a3bf0e6c) +++ dialin/dg/heaters.py (.../heaters.py) (revision 6c9c54b00503ff8124ba864ec846d1866e58b8b7) @@ -144,7 +144,6 @@ self.trimmer_calc_target_temperature = struct.unpack('f', bytearray( message['message'][MsgFieldPositions.START_POS_FIELD_10:MsgFieldPositions.END_POS_FIELD_10]))[0] - def cmd_start_stop_primary_heater(self, state: int = HeatersStartStop.STOP.name) -> None: """ Constructs and sends a start/stop primary heater command Index: tests/dg_nvm_scripts.py =================================================================== diff -u -r4c63e5617400d2246d2e0290a9c63da4defbb2fc -r6c9c54b00503ff8124ba864ec846d1866e58b8b7 --- tests/dg_nvm_scripts.py (.../dg_nvm_scripts.py) (revision 4c63e5617400d2246d2e0290a9c63da4defbb2fc) +++ tests/dg_nvm_scripts.py (.../dg_nvm_scripts.py) (revision 6c9c54b00503ff8124ba864ec846d1866e58b8b7) @@ -32,7 +32,7 @@ # Use cmd_set_dg_sw_config_record() set the changes back to firmware # This function requires an address for the excel report. Use the absolute address of your excel report like the # example below - dg.sw_configs.cmd_update_dg_sw_config_record('/home/fw/projects/DG_NV_Records/2022-07-14-DG-SW-CONFIGS-Record.xlsx') + dg.sw_configs.cmd_update_dg_sw_config_record('/home/fw/projects/DG_NV_Records/2022-07-16-DG-SW-CONFIGS-Record.xlsx') # Use this function to reset the configuration records to all be 0 #dg.sw_configs.cmd_reset_dg_sw_config_record() Index: tests/dg_tests.py =================================================================== diff -u -r4c63e5617400d2246d2e0290a9c63da4defbb2fc -r6c9c54b00503ff8124ba864ec846d1866e58b8b7 --- tests/dg_tests.py (.../dg_tests.py) (revision 4c63e5617400d2246d2e0290a9c63da4defbb2fc) +++ tests/dg_tests.py (.../dg_tests.py) (revision 6c9c54b00503ff8124ba864ec846d1866e58b8b7) @@ -171,11 +171,12 @@ def get_ro_info(): info = ('RO, {}, PPi, {:5.3f}, PPo, {:5.3f}, PWM, {:5.3f}, Flow, {:5.3f}, Tgt_flow, {:5.3f}, Dia_flow, {:5.3f}, ' - 'Feedback_PWM, {:5.3f}, flow_with_conc_pumps, {:5.3f}, ' + 'Feedback_PWM, {:5.3f}, Flow_with_conc_pumps, {:5.3f}, Dialysate_flow, {:5.3f}, ' .format(dg.ro_pump.ro_pump_state, dg.pressures.ro_pump_inlet_pressure, dg.pressures.ro_pump_outlet_pressure, dg.ro_pump.pwm_duty_cycle_pct, dg.ro_pump.measured_flow_rate_lpm, dg.ro_pump.target_flow_lpm, dg.dialysate_flow_sensor.flow_rate, - dg.ro_pump.feedback_duty_cycle_pct, dg.ro_pump.measured_raw_flow_rate_with_conc_pumps_mlp)) + dg.ro_pump.feedback_duty_cycle_pct, dg.ro_pump.measured_raw_flow_rate_with_conc_pumps_mlp, + dg.dialysate_flow_sensor.flow_rate)) return info @@ -191,14 +192,14 @@ def get_heaters_info(): info = ('Pri_main_DC, {:5.3f}, Pri_state, {}, Trimmer_DC, {:5.3f}, Trimmer_state, {}, ' 'Primary_target_temp, {:5.3f}, Trimmer_target_temp, {:5.3f}, Primary_eff, {:5.3f}, ' - 'Primary_calc_temp, {:5.3f}, Trimmer_calc_temp, {:5.3f}, Primary_volt, {:5.3f}, Trimmer_volt, {:5.3f}, '. - format(dg.heaters.main_primary_heater_duty_cycle, dg.heaters.primary_heater_state, - dg.heaters.trimmer_heater_duty_cycle, dg.heaters.trimmer_heater_state, - dg.heaters.primary_heaters_target_temperature, dg.heaters.trimmer_heater_target_temperature, - dg.heaters.primary_efficiency, dg.heaters.primary_heaters_target_temperature, - dg.heaters.trimmer_calc_target_temperature, - dg.voltages.monitored_voltages[DGMonitoredVoltages.MONITORED_LINE_24V_PRIM_HTR_V.value], - dg.voltages.monitored_voltages[DGMonitoredVoltages.MONITORED_LINE_24V_TRIM_HTR_V.value])) + 'Primary_calc_temp, {:5.3f}, Trimmer_calc_temp, {:5.3f}, Primary_volt, {:5.3f}, Trimmer_volt, {:5.3f}, ' + .format(dg.heaters.main_primary_heater_duty_cycle, dg.heaters.primary_heater_state, + dg.heaters.trimmer_heater_duty_cycle, dg.heaters.trimmer_heater_state, + dg.heaters.primary_heaters_target_temperature, dg.heaters.trimmer_heater_target_temperature, + dg.heaters.primary_efficiency, dg.heaters.primary_heaters_target_temperature, + dg.heaters.trimmer_calc_target_temperature, + dg.voltages.monitored_voltages[DGMonitoredVoltages.MONITORED_LINE_24V_PRIM_HTR_V.value], + dg.voltages.monitored_voltages[DGMonitoredVoltages.MONITORED_LINE_24V_TRIM_HTR_V.value])) return info @@ -312,9 +313,9 @@ f = open("/home/fw/projects/dialin/tests/run_dg.log", "w") dg.hd_proxy.cmd_start_stop_dg() - sleep(0.1) + sleep(1) - dg.hd_proxy.cmd_switch_reservoirs(reservoir_id=1) + dg.heaters.cmd_start_stop_primary_heater() sleep(0.1) try: @@ -376,7 +377,12 @@ counter = 1 start = False + sleep_time = 1 + #dg.heaters.cmd_heaters_broadcast_interval_override(50) + #sleep(1) + #dg.voltages.cmd_monitored_voltages_broadcast_interval_override(50) + try: while True: hd_run = get_hd_run_info() @@ -422,7 +428,7 @@ """ print(var) f.write(var) - sleep(1) + sleep(sleep_time) except KeyboardInterrupt: dg.hd_proxy.cmd_start_stop_dg(start=False) f.close() @@ -623,7 +629,7 @@ # run_chemical_disinfect() - # run_dg() + #run_dg() # cmd_set_disinfect_ui_screen() Index: tests/hd_nvm_scripts.py =================================================================== diff -u -r7ea4b936cef531b2cde9053ae58b7119a3bf0e6c -r6c9c54b00503ff8124ba864ec846d1866e58b8b7 --- tests/hd_nvm_scripts.py (.../hd_nvm_scripts.py) (revision 7ea4b936cef531b2cde9053ae58b7119a3bf0e6c) +++ tests/hd_nvm_scripts.py (.../hd_nvm_scripts.py) (revision 6c9c54b00503ff8124ba864ec846d1866e58b8b7) @@ -55,7 +55,7 @@ # Use cmd_set_hd_calibration_excel_to_fw() set the changes back to firmware # This function requires an address for the excel report. Use the absolute address of your excel report like the # example below - hd.calibration_record.cmd_set_hd_calibration_excel_to_fw('/home/fw/projects/HD_NV_Records/2022-05-17-HD-Record.xlsx') + hd.calibration_record.cmd_set_hd_calibration_excel_to_fw('/home/fw/projects/HD_NV_Records/2022-07-19-HD-Record.xlsx') # For resetting the calibration record to benign values, use the function below #hd.calibration_record.cmd_reset_hd_calibration_record()