Index: dialin/hd/valves.py =================================================================== diff -u -r04e1842a8e7f64bcc223373cc96db443b9238225 -r7fa5f37e738a58e4e6a784bcd3e638c06a6d0b9e --- dialin/hd/valves.py (.../valves.py) (revision 04e1842a8e7f64bcc223373cc96db443b9238225) +++ dialin/hd/valves.py (.../valves.py) (revision 7fa5f37e738a58e4e6a784bcd3e638c06a6d0b9e) @@ -35,7 +35,6 @@ @unique class ValvesPositions(DialinEnum): - VALVE_POSITION_NOT_IN_POSITION = 0 VALVE_POSITION_A_INSERT_EJECT = 1 VALVE_POSITION_B_OPEN = 2 VALVE_POSITION_C_CLOSE = 3 Index: tests/dg_heat_and_chemical_disinfect_test.py =================================================================== diff -u -rf0c77deb1d6f38f6bedb5ced326cdc85715fe15f -r7fa5f37e738a58e4e6a784bcd3e638c06a6d0b9e --- tests/dg_heat_and_chemical_disinfect_test.py (.../dg_heat_and_chemical_disinfect_test.py) (revision f0c77deb1d6f38f6bedb5ced326cdc85715fe15f) +++ tests/dg_heat_and_chemical_disinfect_test.py (.../dg_heat_and_chemical_disinfect_test.py) (revision 7fa5f37e738a58e4e6a784bcd3e638c06a6d0b9e) @@ -149,10 +149,18 @@ counter = 1 f = open("/home/fw/projects/dialin/tests/run_dg.log", "w") + + dg.valves.cmd_valve_broadcast_interval_override(50) + sleep(0.25) + dg.pressures.cmd_pressure_broadcast_interval_override(50) + sleep(0.25) + dg.drain_pump.cmd_drain_pump_data_broadcast_interval_override(50) + sleep(0.25) + dg.hd_proxy.cmd_start_stop_dg() sleep(0.1) - dg.hd_proxy.cmd_switch_reservoirs(reservoirID=0) - sleep(0.1) + #dg.hd_proxy.cmd_switch_reservoirs(reservoirID=0) + #sleep(0.1) try: while True: @@ -169,38 +177,28 @@ f.write(var) if DGOperationModes(dg.dg_operation_mode).name == DGOperationModes.DG_OP_MODE_RECIRCULATE.name and\ - dg.dg_operation_sub_mode == 2: - - if counter == 1: - dg.valves.cmd_valve_override(VDrVRcStates.VALVE_STATE_RECIRC_C_TO_NC.value, dg.valves.VALVE_DRAIN) - - if counter == 5: - dg.valves.cmd_valve_override(VDrVRcStates.VALVE_STATE_DRAIN_C_TO_NO.value, dg.valves.VALVE_DRAIN) - dg.valves.cmd_valve_override(VPiVSPVBfVRD1VRD2States.VALVE_STATE_OPEN.value, - dg.valves.VALVE_RESERVOIR_DRAIN_1) - - if counter == 6: - - dg.drain_pump.cmd_drain_pump_speed_set_point_override(2100) - + dg.dg_operation_sub_mode == 2 and counter == 1: + dg.hd_proxy.cmd_switch_reservoirs(reservoirID=0) + sleep(2) counter += 1 - """" if DGOperationModes(dg.dg_operation_mode).name == DGOperationModes.DG_OP_MODE_RECIRCULATE.name and\ dg.dg_operation_sub_mode == 2 and counter == 2: - dg.hd_proxy.cmd_fill(volume=1700) + dg.hd_proxy.cmd_drain(tare_load_cell=True) counter += 1 sleep(0.15) if DGOperationModes(dg.dg_operation_mode).name == DGOperationModes.DG_OP_MODE_RECIRCULATE.name and\ dg.dg_operation_sub_mode == 2 and counter == 3: + dg.hd_proxy.cmd_fill(volume=1900) #dg.hd_proxy.cmd_switch_reservoirs(reservoirID=0) - dg.hd_proxy.cmd_drain(volume=50) + #sleep(10) + #dg.hd_proxy.cmd_drain() counter += 1 - sleep(0.15) - """ - sleep(1) + #sleep(0.15) + sleep(0.05) + except KeyboardInterrupt: dg.hd_proxy.cmd_start_stop_dg(start=False) f.close() @@ -275,11 +273,9 @@ # If the mode came back to standby or standby solo if dg.dg_operation_mode == 3 or dg.dg_operation_mode == 4: - # If it is the first call, stop heat disinfect - if complete_counter == 1: - dg.hd_proxy.cmd_start_stop_dg_chemical_disinfect(start=False) + # Write a few more complete states to make sure the complete state items are recorded - elif complete_counter == 3: + if complete_counter == 3: #pass f.close() break Index: tests/test_flush.py =================================================================== diff -u -r1261e3824e07dc805e6bf3d73c5ee340bb88fc15 -r7fa5f37e738a58e4e6a784bcd3e638c06a6d0b9e --- tests/test_flush.py (.../test_flush.py) (revision 1261e3824e07dc805e6bf3d73c5ee340bb88fc15) +++ tests/test_flush.py (.../test_flush.py) (revision 7fa5f37e738a58e4e6a784bcd3e638c06a6d0b9e) @@ -36,9 +36,9 @@ def get_drain_states_info(): - info = ('Drain, {}, DAC, {}, RPM, {}, PRd, {:5.3f}, PDr, {:5.3f}, '. - format(DrainPumpStates(dg.drain_pump.drain_pump_state).name, - dg.drain_pump.dac_value, dg.drain_pump.current_drain_pump_rpm, + info = ('Drain, {}, DAC, {}, Tgt_RPM, {}, Curr_RPM, {}, PRd, {:5.3f}, PDr, {:5.3f}, '. + format(DrainPumpStates(dg.drain_pump.drain_pump_state).name, dg.drain_pump.dac_value, + dg.drain_pump.target_drain_pump_rpm, dg.drain_pump.current_drain_pump_rpm, dg.pressures.drain_pump_inlet_pressure, dg.pressures.drain_pump_outlet_pressure)) return info