Index: dialin/hd/accelerometer.py =================================================================== diff -u -r3a5030c08d57bddc2c22dca05d1070375e3cb5f7 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/accelerometer.py (.../accelerometer.py) (revision 3a5030c08d57bddc2c22dca05d1070375e3cb5f7) +++ dialin/hd/accelerometer.py (.../accelerometer.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -124,7 +124,7 @@ message['message'][MsgFieldPositions.START_POS_FIELD_9:MsgFieldPositions.END_POS_FIELD_9])) self.tilts = self.AccelerometerVector( x[0], y[0], z[0] ) - def cmd_accel_vector_override(self, mag, axis, reset=NO_RESET): + def cmd_accel_vector_override(self, mag: float, axis: int, reset: int=NO_RESET) -> int: """ Constructs and sends the accelerometer vector override command Constraints: @@ -164,7 +164,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_accel_max_vector_override(self, mag, axis, reset=NO_RESET): + def cmd_accel_max_vector_override(self, mag: float, axis: int, reset: int=NO_RESET) -> int: """ Constructs and sends the accelerometer maximum vector override command Constraints: @@ -204,7 +204,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_accel_broadcast_interval_override(self, ms, reset=NO_RESET): + def cmd_accel_broadcast_interval_override(self, ms: int, reset: int = NO_RESET) -> int: """ Constructs and sends the accelerometer broadcast interval override command Constraints: Index: dialin/hd/air_trap.py =================================================================== diff -u -r045eb4c25850caf5b77a3fabcb0e6eefa7407380 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/air_trap.py (.../air_trap.py) (revision 045eb4c25850caf5b77a3fabcb0e6eefa7407380) +++ dialin/hd/air_trap.py (.../air_trap.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -98,7 +98,7 @@ self.lower_level = lower[0] self.upper_level = upper[0] - def cmd_air_trap_level_sensor_override(self, detected, sensor, reset=NO_RESET): + def cmd_air_trap_level_sensor_override(self, detected: int, sensor: int, reset: int = NO_RESET) -> int: """ Constructs and sends the air trap level sensor override command Constraints: @@ -137,7 +137,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_air_trap_data_broadcast_interval_override(self, ms, reset=NO_RESET): + def cmd_air_trap_data_broadcast_interval_override(self, ms: int, reset: int = NO_RESET) -> int: """ Constructs and sends the air trap data broadcast interval override command Constraints: Index: dialin/hd/alarms.py =================================================================== diff -u -r62df70b019fa433c8f345d2e1699e6c8f204af2c -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/alarms.py (.../alarms.py) (revision 62df70b019fa433c8f345d2e1699e6c8f204af2c) +++ dialin/hd/alarms.py (.../alarms.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -255,7 +255,7 @@ alarm_id = struct.unpack(' int: """ Constructs and sends the clear all active alarms command. This will clear even non-recoverable alarms. @@ -282,7 +282,7 @@ return 1 == received_message['message'][DenaliMessage.PAYLOAD_START_INDEX] return False - def cmd_alarm_state_override(self, state, alarm, reset=NO_RESET): + def cmd_alarm_state_override(self, state: int, alarm: int, reset: int = NO_RESET) -> int: """ Constructs and sends the alarm state override command Constraints: @@ -319,7 +319,7 @@ return 1 == received_message['message'][DenaliMessage.PAYLOAD_START_INDEX] return False - def cmd_alarm_time_override(self, time_ms, alarm, reset=NO_RESET): + def cmd_alarm_time_override(self, time_ms: int, alarm: int, reset: int = NO_RESET) -> int: """ Constructs and sends the alarm time override command Constraints: @@ -361,7 +361,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_alarm_lamp_pattern_override(self, pattern, reset=NO_RESET): + def cmd_alarm_lamp_pattern_override(self, pattern: int, reset: int = NO_RESET) -> int: """ Constructs and sends the alarm lamp pattern override command. Constraints: Index: dialin/hd/blood_flow.py =================================================================== diff -u -r551e0a9620126efd158e93c45e9ed84ee6ec85fb -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/blood_flow.py (.../blood_flow.py) (revision 551e0a9620126efd158e93c45e9ed84ee6ec85fb) +++ dialin/hd/blood_flow.py (.../blood_flow.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -157,7 +157,7 @@ self.pwm_duty_cycle_pct = pwm[0] self.flow_signal_strength = sig[0] - def cmd_blood_flow_set_point_override(self, flow, mode=PUMP_CONTROL_MODE_CLOSED_LOOP, reset=NO_RESET): + def cmd_blood_flow_set_point_override(self, flow: int, mode: int = PUMP_CONTROL_MODE_CLOSED_LOOP, reset: int = NO_RESET) -> int: """ Constructs and sends the blood flow set point override command Constraints: @@ -206,7 +206,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_blood_flow_measured_override(self, flow, reset=NO_RESET): + def cmd_blood_flow_measured_override(self, flow: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured blood flow override command Constraints: @@ -245,7 +245,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_blood_pump_measured_motor_controller_speed_override(self, speed, reset=NO_RESET): + def cmd_blood_pump_measured_motor_controller_speed_override(self, speed: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured blood pump motor controller speed \n override command. @@ -285,7 +285,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_blood_pump_measured_motor_controller_current_override(self, curr, reset=NO_RESET): + def cmd_blood_pump_measured_motor_controller_current_override(self, curr: float, reset: int = NO_RESET) -> int: """ Constructs and sends the measured blood pump motor controller current override command Constraints: @@ -324,7 +324,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_blood_pump_measured_motor_speed_override(self, speed, reset=NO_RESET): + def cmd_blood_pump_measured_motor_speed_override(self, speed: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured blood pump motor speed override \n command. @@ -364,7 +364,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_blood_pump_measured_rotor_speed_override(self, speed, reset=NO_RESET): + def cmd_blood_pump_measured_rotor_speed_override(self, speed: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured blood pump rotor speed override \n command. @@ -404,7 +404,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_blood_flow_signal_strength_override(self, signal_strength, reset=NO_RESET): + def cmd_blood_flow_signal_strength_override(self, signal_strength: float, reset: int =NO_RESET) -> int: """ Constructs and sends the measured blood flow signal strength % override \n command. @@ -444,7 +444,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_blood_flow_broadcast_interval_override(self, ms, reset=NO_RESET): + def cmd_blood_flow_broadcast_interval_override(self, ms: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured blood flow broadcast interval override command Constraints: @@ -484,7 +484,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_home_blood_pump(self): + def cmd_home_blood_pump(self) -> int: """ Constructs and sends a blood pump home request message to the HD. Constraints: Index: dialin/hd/buttons.py =================================================================== diff -u -r20659ffd56482b0596253aa0f1f1a7eda1221945 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/buttons.py (.../buttons.py) (revision 20659ffd56482b0596253aa0f1f1a7eda1221945) +++ dialin/hd/buttons.py (.../buttons.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -88,7 +88,7 @@ if len(mode) > 0: self.poweroff_timeout_expired = bool(mode[0]) - def cmd_off_button_override(self, state, reset=NO_RESET): + def cmd_off_button_override(self, state: int, reset: int = NO_RESET) -> int: """ Constructs and sends the Off button override command See HD/App/Controllers/Buttons.c @@ -129,7 +129,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_stop_button_override(self, state, reset=NO_RESET): + def cmd_stop_button_override(self, state: int, reset: int = NO_RESET) -> int: """ Constructs and sends the Stop button override command See HD/App/Controllers/Buttons.c Index: dialin/hd/calibration_record.py =================================================================== diff -u -r6895b99c133b8d5820df5610c3b12ac55a521998 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/calibration_record.py (.../calibration_record.py) (revision 6895b99c133b8d5820df5610c3b12ac55a521998) +++ dialin/hd/calibration_record.py (.../calibration_record.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -61,7 +61,7 @@ self.can_interface.register_receiving_publication_function(channel_id, msg_id, self._handler_hd_calibration_sync) - def cmd_request_hd_calibration_record(self): + def cmd_request_hd_calibration_record(self) -> int: """ Handles getting HD calibration_record record from firmware. @@ -138,7 +138,7 @@ """ self.logger.debug("Received a complete hd calibration record.") - def cmd_set_hd_calibration_record(self, hd_calibration_record: OrderedDict): + def cmd_set_hd_calibration_record(self, hd_calibration_record: OrderedDict) -> None: """ Handles updating the HD calibration_record record with the newest calibration_record data of a hardware and sends it to FW. Index: dialin/hd/dialysate_inlet_flow.py =================================================================== diff -u -r551e0a9620126efd158e93c45e9ed84ee6ec85fb -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/dialysate_inlet_flow.py (.../dialysate_inlet_flow.py) (revision 551e0a9620126efd158e93c45e9ed84ee6ec85fb) +++ dialin/hd/dialysate_inlet_flow.py (.../dialysate_inlet_flow.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -162,7 +162,10 @@ self.pwm_duty_cycle_pct = pwm[0] self.flow_signal_strength = sig[0] - def cmd_dialysate_inlet_flow_set_point_override(self, flow, mode=PUMP_CONTROL_MODE_CLOSED_LOOP, reset=NO_RESET): + def cmd_dialysate_inlet_flow_set_point_override(self, + flow: int, + mode: int = PUMP_CONTROL_MODE_CLOSED_LOOP, + reset: int = NO_RESET) -> int: """ Constructs and sends the dialysate flow set point override command Constraints: @@ -211,7 +214,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_inlet_flow_measured_override(self, flow, reset=NO_RESET): + def cmd_dialysate_inlet_flow_measured_override(self, flow: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured dialysate flow override command Constraints: @@ -250,7 +253,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_inlet_pump_measured_motor_controller_speed_override(self, speed, reset=NO_RESET): + def cmd_dialysate_inlet_pump_measured_motor_controller_speed_override(self, speed: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured dialysate inlet pump motor controller speed \n override command. @@ -290,7 +293,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_inlet_pump_measured_motor_controller_current_override(self, curr, reset=NO_RESET): + def cmd_dialysate_inlet_pump_measured_motor_controller_current_override(self, curr: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured dialysate inlet pump motor current override command Constraints: @@ -329,7 +332,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_inlet_pump_measured_motor_speed_override(self, speed, reset=NO_RESET): + def cmd_dialysate_inlet_pump_measured_motor_speed_override(self, speed: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured dialysate inlet pump motor speed override \n command. @@ -369,7 +372,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_inlet_pump_measured_rotor_speed_override(self, speed, reset=NO_RESET): + def cmd_dialysate_inlet_pump_measured_rotor_speed_override(self, speed: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured dialysate inlet pump rotor speed override \n command. @@ -409,7 +412,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_flow_signal_strength_override(self, signal_strength, reset=NO_RESET): + def cmd_dialysate_flow_signal_strength_override(self, signal_strength: float, reset: int = NO_RESET) -> int: """ Constructs and sends the measured dialysate flow signal strength % override \n command. @@ -449,7 +452,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_inlet_flow_broadcast_interval_override(self, ms, reset=NO_RESET): + def cmd_dialysate_inlet_flow_broadcast_interval_override(self, ms: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured dialysate inlet flow broadcast interval override command Constraints: @@ -488,7 +491,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_home_dialysate_inlet_pump(self): + def cmd_home_dialysate_inlet_pump(self) -> int: """ Constructs and sends a dialysate inlet pump home request message to the HD. Constraints: Index: dialin/hd/dialysate_outlet_flow.py =================================================================== diff -u -r5ce02d1768b268149d4f69fc1590c87e585f798a -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/dialysate_outlet_flow.py (.../dialysate_outlet_flow.py) (revision 5ce02d1768b268149d4f69fc1590c87e585f798a) +++ dialin/hd/dialysate_outlet_flow.py (.../dialysate_outlet_flow.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -147,7 +147,10 @@ self.measured_dialysate_outlet_pump_mc_current = mccurr[0] self.pwm_duty_cycle_pct = pwm[0] - def cmd_dialysate_outlet_flow_set_point_override(self, flow, mode=PUMP_CONTROL_MODE_CLOSED_LOOP, reset=NO_RESET): + def cmd_dialysate_outlet_flow_set_point_override(self, + flow: int, + mode: int = PUMP_CONTROL_MODE_CLOSED_LOOP, + reset: int =NO_RESET) -> int: """ Constructs and sends the dialysate outlet pump set point override command Constraints: @@ -196,7 +199,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_outlet_reference_uf_volume_override(self, refvol, reset=NO_RESET): + def cmd_dialysate_outlet_reference_uf_volume_override(self, refvol: float, reset: int = NO_RESET) -> int: """ Constructs and sends the UF reference volume override command Constraints: @@ -236,7 +239,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_outlet_measured_uf_volume_override(self, measvol, reset=NO_RESET): + def cmd_dialysate_outlet_measured_uf_volume_override(self, measvol: float, reset: int = NO_RESET) -> int: """ Constructs and sends the measured UF volume override command Constraints: @@ -275,7 +278,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_outlet_pump_measured_motor_controller_speed_override(self, speed, reset=NO_RESET): + def cmd_dialysate_outlet_pump_measured_motor_controller_speed_override(self, speed: float, reset: int = NO_RESET) -> int: """ Constructs and sends the measured dialysate outlet pump motor controller measured speed \n override command. @@ -315,7 +318,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_outlet_pump_measured_motor_controller_current_override(self, curr, reset=NO_RESET): + def cmd_dialysate_outlet_pump_measured_motor_controller_current_override(self, curr: float, reset: int = NO_RESET) -> int: """ Constructs and sends the measured dialysate outlet pump motor current override command Constraints: @@ -354,7 +357,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_outlet_pump_measured_motor_speed_override(self, speed, reset=NO_RESET): + def cmd_dialysate_outlet_pump_measured_motor_speed_override(self, speed: float, reset: int = NO_RESET) -> int: """ Constructs and sends the measured dialysate outlet pump motor speed override \n command. @@ -394,7 +397,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_outlet_pump_measured_rotor_speed_override(self, speed, reset=NO_RESET): + def cmd_dialysate_outlet_pump_measured_rotor_speed_override(self, speed: float, reset: int = NO_RESET) -> int: """ Constructs and sends the measured dialysate outlet pump rotor speed override \n command. @@ -434,7 +437,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_outlet_flow_broadcast_interval_override(self, ms, reset=NO_RESET): + def cmd_dialysate_outlet_flow_broadcast_interval_override(self, ms: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured dialysate outlet flow broadcast interval override command Constraints: @@ -474,7 +477,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_outlet_pump_load_cell_weight_override(self, weight, sensor, reset=NO_RESET): + def cmd_dialysate_outlet_pump_load_cell_weight_override(self, weight: float, sensor: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured load cell weight override command. Constraints: @@ -522,7 +525,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_load_cell_weights(self, r1p, r1b, r2p, r2b): + def cmd_set_load_cell_weights(self, r1p: float, r1b: float, r2p: float, r2b: float) -> int: """ Constructs and sends the set load cell weights command. @@ -550,7 +553,7 @@ return 0 - def cmd_home_dialysate_outlet_pump(self): + def cmd_home_dialysate_outlet_pump(self) -> int: """ Constructs and sends a dialysate outlet pump home request message to the HD. Constraints: Index: dialin/hd/fluid_leak.py =================================================================== diff -u -rba6d26ee1006f3fd215a5c11a078b20006a489d4 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/fluid_leak.py (.../fluid_leak.py) (revision ba6d26ee1006f3fd215a5c11a078b20006a489d4) +++ dialin/hd/fluid_leak.py (.../fluid_leak.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -73,7 +73,7 @@ self.fluid_leak_state = state[0] - def cmd_fluid_leak_detector_override(self, detected, reset=NO_RESET): + def cmd_fluid_leak_detector_override(self, detected: int, reset: int = NO_RESET) -> int: """ Constructs and sends the fluid leak detector state override command Constraints: @@ -106,7 +106,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_fluid_leak_state_broadcast_interval_override(self, ms, reset=NO_RESET): + def cmd_fluid_leak_state_broadcast_interval_override(self, ms: int, reset: int = NO_RESET) -> int: """ Constructs and sends the fluid leak state broadcast interval override command Constraints: Index: dialin/hd/hemodialysis_device.py =================================================================== diff -u -rbe97d97e1ddd765351cdc51cb75aee9e7e63ba58 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/hemodialysis_device.py (.../hemodialysis_device.py) (revision be97d97e1ddd765351cdc51cb75aee9e7e63ba58) +++ dialin/hd/hemodialysis_device.py (.../hemodialysis_device.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -134,7 +134,7 @@ self.hd_operation_mode = mode[0] self.hd_operation_sub_mode = smode[0] - def cmd_log_in_to_hd(self, resend: bool = False): + def cmd_log_in_to_hd(self, resend: bool = False) -> int: """ Constructs and sends a login command via CAN bus. Login required before \n other commands can be sent to the HD. @@ -162,7 +162,7 @@ self.logger.debug("Login Timeout!!!!") return False - def cmd_hd_request_calibration_data(self): + def cmd_hd_request_calibration_data(self) -> int: """ Constructs and sends an HD calibration data request command via CAN bus. Constraints: @@ -191,7 +191,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_hd_set_operation_mode(self, newMode=0): + def cmd_hd_set_operation_mode(self, newMode: int = 0) -> int: """ Constructs and sends a set operation mode request command via CAN bus. Constraints: @@ -233,7 +233,7 @@ self.logger.debug("HD mode change request Timeout!!!!") return False - def cmd_hd_safety_shutdown_override(self, active=True, reset=NO_RESET): + def cmd_hd_safety_shutdown_override(self, active: bool = True, reset: int = NO_RESET) -> int: """ Constructs and sends an HD safety shutdown override command via CAN bus. Constraints: @@ -274,7 +274,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_hd_software_reset_request(self): + def cmd_hd_software_reset_request(self) -> None: """ Constructs and sends an HD software reset request via CAN bus. Constraints: Index: dialin/hd/pressure_occlusion.py =================================================================== diff -u -r8a53de6c3b9d0ef76d2b4f648d2efc2d394cba21 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/pressure_occlusion.py (.../pressure_occlusion.py) (revision 8a53de6c3b9d0ef76d2b4f648d2efc2d394cba21) +++ dialin/hd/pressure_occlusion.py (.../pressure_occlusion.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -121,7 +121,7 @@ self.dialysate_inlet_pump_occlusion = dpi[0] self.dialysate_outlet_pump_occlusion = dpo[0] - def cmd_arterial_pressure_measured_override(self, pres, reset=NO_RESET): + def cmd_arterial_pressure_measured_override(self, pres: float, reset: int = NO_RESET) -> int: """ Constructs and sends the measured arterial pressure override command Constraints: @@ -159,7 +159,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_venous_pressure_measured_override(self, pres, reset=NO_RESET): + def cmd_venous_pressure_measured_override(self, pres: float, reset: int = NO_RESET) -> int: """ Constructs and sends the measured venous pressure \n override command. @@ -198,7 +198,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_blood_pump_measured_occlusion_override(self, occl, reset=NO_RESET): + def cmd_blood_pump_measured_occlusion_override(self, occl: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured blood pump occlusion pressure override command Constraints: @@ -236,7 +236,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_inlet_pump_measured_occlusion_override(self, occl, reset=NO_RESET): + def cmd_dialysate_inlet_pump_measured_occlusion_override(self, occl: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured dialysate inlet pump occlusion pressure override \n command. @@ -275,7 +275,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_dialysate_outlet_pump_measured_occlusion_override(self, occl, reset=NO_RESET): + def cmd_dialysate_outlet_pump_measured_occlusion_override(self, occl: int, reset: int = NO_RESET) -> int: """ Constructs and sends the measured dialysate outlet pump occlusion pressure override \n command. @@ -314,7 +314,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_pressure_occlusion_broadcast_interval_override(self, ms, reset=NO_RESET): + def cmd_pressure_occlusion_broadcast_interval_override(self, ms: int, reset: int = NO_RESET) -> int: """ Constructs and sends the pressure/occlusion broadcast interval override command Constraints: Index: dialin/hd/rtc.py =================================================================== diff -u -rfbe3580dfcda2338d9fa33d09bee85099ea7b801 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/rtc.py (.../rtc.py) (revision fbe3580dfcda2338d9fa33d09bee85099ea7b801) +++ dialin/hd/rtc.py (.../rtc.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -70,7 +70,7 @@ byteorder=DenaliMessage.BYTE_ORDER) self.rtc_epoch = ctypes.c_uint32(epoch) - def cmd_set_rtc_time_and_date(self, second: int, minute: int, hour: int, day: int, month: int, year: int): + def cmd_set_rtc_time_and_date(self, second: int, minute: int, hour: int, day: int, month: int, year: int) -> int: """ Sets the RTC time and date from the provided Index: dialin/hd/service_record.py =================================================================== diff -u -r6895b99c133b8d5820df5610c3b12ac55a521998 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/service_record.py (.../service_record.py) (revision 6895b99c133b8d5820df5610c3b12ac55a521998) +++ dialin/hd/service_record.py (.../service_record.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -60,7 +60,7 @@ self.can_interface.register_receiving_publication_function(channel_id, msg_id, self._handler_hd_service_sync) - def cmd_request_hd_service_record(self): + def cmd_request_hd_service_record(self) -> int: """ Handles getting HD service record from firmware. @@ -136,7 +136,7 @@ """ self.logger.debug("Received a complete hd service record.") - def cmd_set_hd_service_record(self, hd_service_record: OrderedDict): + def cmd_set_hd_service_record(self, hd_service_record: OrderedDict) -> bool: """ Handles updating the HD system and sends it to FW. Index: dialin/hd/syringe_pump.py =================================================================== diff -u -rbe97d97e1ddd765351cdc51cb75aee9e7e63ba58 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/syringe_pump.py (.../syringe_pump.py) (revision be97d97e1ddd765351cdc51cb75aee9e7e63ba58) +++ dialin/hd/syringe_pump.py (.../syringe_pump.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -198,7 +198,9 @@ self.syringe_pump_force_v = frc[0] self.syringe_pump_safety_volume_ml = saf[0] - def cmd_syringe_pump_operation(self, operation=SyringePumpOperations.SYRINGE_PUMP_OP_STOP.value, rate=0.0, volume=0.0): + def cmd_syringe_pump_operation(self, operation: int = SyringePumpOperations.SYRINGE_PUMP_OP_STOP.value, + rate: float = 0.0, + volume: float = 0.0) -> int: """ Constructs and sends the syringe pump operation command Constraints: @@ -244,7 +246,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_syringe_pump_data_broadcast_interval_override(self, ms=1000, reset=NO_RESET): + def cmd_syringe_pump_data_broadcast_interval_override(self, ms: int = 1000, reset: int = NO_RESET) -> int: """ Constructs and sends the syringe pump data broadcast interval override command Constraints: @@ -283,7 +285,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_syringe_pump_meas_position_override(self, position=0, reset=NO_RESET): + def cmd_syringe_pump_meas_position_override(self, position: int = 0, reset: int = NO_RESET) -> int: """ Constructs and sends the syringe pump measured position override command Constraints: @@ -321,7 +323,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_syringe_pump_meas_rate_override(self, rate=0.0, reset=NO_RESET): + def cmd_syringe_pump_meas_rate_override(self, rate: float = 0.0, reset: int = NO_RESET) -> int: """ Constructs and sends the syringe pump measured rate override command Constraints: @@ -359,7 +361,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_syringe_pump_meas_force_override(self, volts=0.0, reset=NO_RESET): + def cmd_syringe_pump_meas_force_override(self, volts: float = 0.0, reset: int = NO_RESET) -> int: """ Constructs and sends the syringe pump measured force override command Constraints: @@ -397,7 +399,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_syringe_pump_meas_detect_override(self, volts=0.0, reset=NO_RESET): + def cmd_syringe_pump_meas_detect_override(self, volts: float = 0.0, reset: int = NO_RESET) -> int: """ Constructs and sends the syringe pump measured syringe detect override command Constraints: @@ -435,7 +437,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_syringe_pump_meas_home_override(self, volts=0.0, reset=NO_RESET): + def cmd_syringe_pump_meas_home_override(self, volts: float = 0.0, reset: int = NO_RESET) -> int: """ Constructs and sends the syringe pump measured home override command Constraints: @@ -473,7 +475,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_syringe_pump_meas_volume_override(self, volume=0.0, reset=NO_RESET): + def cmd_syringe_pump_meas_volume_override(self, volume: float = 0.0, reset: int = NO_RESET) -> int: """ Constructs and sends the syringe pump measured volume override command Constraints: Index: dialin/hd/system_record.py =================================================================== diff -u -r6895b99c133b8d5820df5610c3b12ac55a521998 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/system_record.py (.../system_record.py) (revision 6895b99c133b8d5820df5610c3b12ac55a521998) +++ dialin/hd/system_record.py (.../system_record.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -64,7 +64,7 @@ msg_id = MsgIds.MSG_ID_HD_SEND_SYSTEM_RECORD.value self.can_interface.register_receiving_publication_function(channel_id, msg_id, self._handler_hd_system_sync) - def cmd_request_hd_system_record(self): + def cmd_request_hd_system_record(self) -> int: """ Handles getting HD calibration_record data from firmware. @@ -141,12 +141,12 @@ """ self.logger.debug("Received a complete hd system record.") - def cmd_set_hd_system_record(self, hd_system_record: OrderedDict): + def cmd_set_hd_system_record(self, hd_system_record: OrderedDict) -> bool: """ Handles updating the HD system and sends it to FW. @param hd_system_record: (OrderedDict) the hd system record to be sent - @return: none + @return: True upon success, False otherwise """ record_packets = self._utilities.prepare_record_to_send_to_fw(hd_system_record) Index: dialin/hd/treatment.py =================================================================== diff -u -r045eb4c25850caf5b77a3fabcb0e6eefa7407380 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/treatment.py (.../treatment.py) (revision 045eb4c25850caf5b77a3fabcb0e6eefa7407380) +++ dialin/hd/treatment.py (.../treatment.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -406,7 +406,7 @@ self.recirc_timeout_secs = tmo[0] self.recirc_countdown_secs = cdn[0] - def cmd_set_treatment_param_blood_flow_rate(self, flow): + def cmd_set_treatment_param_blood_flow_rate(self, flow: int) -> int: """ Constructs and sends the set blood flow rate treatment parameter command. This will only set the treatment parameter setting. It will not immediately @@ -443,7 +443,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_treatment_param_dialysate_flow_rate(self, flow): + def cmd_set_treatment_param_dialysate_flow_rate(self, flow: int) -> int: """ Constructs and sends the set dialysate flow rate treatment parameter command. This will only set the treatment parameter setting. It will not immediately @@ -481,7 +481,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_treatment_param_duration(self, duration): + def cmd_set_treatment_param_duration(self, duration: int) -> int: """ Constructs and sends the set treatment duration parameter command. Constraints: @@ -517,7 +517,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_heparin_pre_stop_time(self, pre_stop): + def cmd_set_heparin_pre_stop_time(self, pre_stop: int) -> int: """ Constructs and sends the set Heparin pre-stop time parameter command. Constraints: @@ -553,7 +553,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_saline_bolus_volume(self, volume): + def cmd_set_saline_bolus_volume(self, volume: int) -> int: """ Constructs and sends the set saline bolus volume parameter command. Constraints: @@ -589,7 +589,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_acid_concentrate(self, acid): + def cmd_set_acid_concentrate(self, acid: int) -> int: """ Constructs and sends the set acid concentrate parameter command. Constraints: @@ -628,7 +628,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_bicarb_concentrate(self, bicarb): + def cmd_set_bicarb_concentrate(self, bicarb: int) -> int: """ Constructs and sends the set bicarbonate concentrate parameter command. Constraints: @@ -665,7 +665,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_dialyzer_type(self, dialyzer): + def cmd_set_dialyzer_type(self, dialyzer: int) -> int: """ Constructs and sends the set dialyzer type parameter command. Constraints: @@ -705,7 +705,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_bp_measurement_interval(self, intvl): + def cmd_set_bp_measurement_interval(self, intvl: int) -> int: """ Constructs and sends the set blood pressure measurement interval parameter command. Constraints: @@ -741,7 +741,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_rinseback_flow_rate(self, flow): + def cmd_set_rinseback_flow_rate(self, flow: int) -> int: """ Constructs and sends the set rinseback flow rate parameter command. Constraints: @@ -777,7 +777,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_arterial_pressure_low_alarm_limit(self, pres): + def cmd_set_arterial_pressure_low_alarm_limit(self, pres: int) -> int: """ Constructs and sends the set arterial pressure lower alarm limit parameter command. Constraints: @@ -813,7 +813,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_arterial_pressure_high_alarm_limit(self, pres): + def cmd_set_arterial_pressure_high_alarm_limit(self, pres: int) -> int: """ Constructs and sends the set arterial pressure upper alarm limit parameter command. Constraints: @@ -849,7 +849,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_venous_pressure_low_alarm_limit(self, pres): + def cmd_set_venous_pressure_low_alarm_limit(self, pres: int) -> int: """ Constructs and sends the set venous pressure lower alarm limit parameter command. Constraints: @@ -885,7 +885,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_venous_pressure_high_alarm_limit(self, pres): + def cmd_set_venous_pressure_high_alarm_limit(self, pres: int) -> int: """ Constructs and sends the set venous pressure upper alarm limit parameter command. Constraints: @@ -921,7 +921,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_heparin_dispense_rate(self, rate): + def cmd_set_heparin_dispense_rate(self, rate: float) -> int: """ Constructs and sends the set Heparin dispense rate parameter command. Constraints: @@ -957,7 +957,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_heparin_bolus_volume(self, volume): + def cmd_set_heparin_bolus_volume(self, volume: float) -> int: """ Constructs and sends the set Heparin bolus volume parameter command. Constraints: @@ -993,7 +993,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_dialysate_temperature(self, temp): + def cmd_set_dialysate_temperature(self, temp: float) -> int: """ Constructs and sends the set dialysate temperature parameter command. Constraints: @@ -1029,7 +1029,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_ultrafiltration_volume(self, volume): + def cmd_set_ultrafiltration_volume(self, volume: float) -> int: """ Constructs and sends the set ultrafiltration volume parameter command. Constraints: @@ -1065,7 +1065,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_treatment_time_remaining_override(self, secs_remaining): + def cmd_treatment_time_remaining_override(self, secs_remaining: int) -> int: """ Constructs and sends the treatment time remaining override command Constraints: Index: dialin/hd/ui_proxy.py =================================================================== diff -u -rdf58df8b4e8b8d3f0b0764deda9f15050a071d78 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/ui_proxy.py (.../ui_proxy.py) (revision df58df8b4e8b8d3f0b0764deda9f15050a071d78) +++ dialin/hd/ui_proxy.py (.../ui_proxy.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -1024,7 +1024,7 @@ if RequestRejectReasons.has_value(rea[0]): self.treatment_end_cmd_reject_reason = RequestRejectReasons(rea[0]) - def cmd_ui_checkin_with_hd(self): + def cmd_ui_checkin_with_hd(self) -> int: """ Constructs and sends the ui check-in message @@ -1040,7 +1040,7 @@ return 0 - def cmd_ui_request_hd_version(self): + def cmd_ui_request_hd_version(self) -> None: """ Constructs and sends the ui request for version message @@ -1053,7 +1053,7 @@ self.can_interface.send(message, 0) - def cmd_ui_set_alarm_audio_volume_level(self, volume=MAX_ALARM_VOLUME_LEVEL): + def cmd_ui_set_alarm_audio_volume_level(self, volume: int = MAX_ALARM_VOLUME_LEVEL) -> None: """ Constructs and sends the ui set alarm volume level message @@ -1069,7 +1069,7 @@ self.logger.debug("Sending ui request to set alarm audio volume to level " + str(volume) + " to HD") self.can_interface.send(message, 0) - def cmd_ui_uf_volume_set(self, uf_volume: float): + def cmd_ui_uf_volume_set(self, uf_volume: float) -> None: """ Constructs and sends the ui set ultrafiltration volume parameter message @@ -1085,7 +1085,7 @@ self.logger.debug("Sending ui request to set ultrafiltration volume parameter of " + str(uf_volume) + " to HD") self.can_interface.send(message, 0) - def cmd_ui_uf_pause_resume(self, cmd=UF_CMD_PAUSE): + def cmd_ui_uf_pause_resume(self, cmd: int = UF_CMD_PAUSE) -> None: """ Constructs and sends a ui UF command message @@ -1107,7 +1107,7 @@ self.can_interface.send(message, 0) - def cmd_ui_uf_settings_change_request(self, vol=0.0): + def cmd_ui_uf_settings_change_request(self, vol: float = 0.0) -> None: """ Constructs and sends a ui UF change settings command message @@ -1128,7 +1128,7 @@ self.can_interface.send(message, 0) - def cmd_ui_uf_settings_change_confirm(self, vol=0.0, adj=UF_CMD_CHANGE_TIME_TO_ADJUST): + def cmd_ui_uf_settings_change_confirm(self, vol: float = 0.0, adj: int = UF_CMD_CHANGE_TIME_TO_ADJUST) -> None: """ Constructs and sends a ui UF change settings command message @@ -1153,7 +1153,7 @@ self.can_interface.send(message, 0) - def cmd_ui_treatment_duration_setting_change_request(self, time_min: int = 0): + def cmd_ui_treatment_duration_setting_change_request(self, time_min: int = 0) -> None: """ Constructs and sends a ui UF change settings confirmed by user message @@ -1171,7 +1171,7 @@ # Send message self.can_interface.send(message, 0) - def cmd_ui_blood_and_dialysate_flow_settings_change_request(self, blood_flow, dial_flow): + def cmd_ui_blood_and_dialysate_flow_settings_change_request(self, blood_flow: int, dial_flow: int) -> None: """ Constructs and sends a ui blood & dialysate flow settings change request by user message @@ -1194,7 +1194,7 @@ self.can_interface.send(message, 0) - def cmd_ui_start_treatment_request(self, cmnd=START_TREATMENT_CMD_INITIATE_TREATMENT_WORKFLOW): + def cmd_ui_start_treatment_request(self, cmnd: int = START_TREATMENT_CMD_INITIATE_TREATMENT_WORKFLOW) -> None: """ Constructs and sends a ui start treatment command message @@ -1268,7 +1268,7 @@ ven_low : int = -100, ven_high: int = 100, bp_intvl: int = 15, - rb_flow : int = 50): + rb_flow : int = 50) -> None: """ Constructs and sends a ui set treatment parameters message Constraints: @@ -1339,7 +1339,7 @@ self.can_interface.send(message, 0) - def cmd_ui_confirm_treatment_parameters(self): + def cmd_ui_confirm_treatment_parameters(self) -> None: """ Constructs and sends a ui confirm treatment parameters message @@ -1353,7 +1353,7 @@ self.can_interface.send(message, 0) - def cmd_ui_request_saline_bolus(self, start=False): + def cmd_ui_request_saline_bolus(self, start: bool = False) -> None: """ Constructs and sends a ui request for a saline bolus message Constraints: @@ -1382,7 +1382,7 @@ self.can_interface.send(message, 0) - def cmd_ui_rinseback_user_action(self, action=RinsebackUserActions.REQUESTED_USER_ACTION_RINSEBACK_CONFIRM_START.value): + def cmd_ui_rinseback_user_action(self, action: int = RinsebackUserActions.REQUESTED_USER_ACTION_RINSEBACK_CONFIRM_START.value) -> None: """ Constructs and sends a UI rinseback user action message Constraints: @@ -1414,7 +1414,7 @@ self.can_interface.send(message, 0) - def cmd_ui_recirculate_user_action(self, action=RecircUserActions.REQUESTED_USER_ACTION_TX_RECIRC_RECONNECT.value): + def cmd_ui_recirculate_user_action(self, action: int = RecircUserActions.REQUESTED_USER_ACTION_TX_RECIRC_RECONNECT.value) -> None: """ Constructs and sends a UI recirculate user action message Constraints: @@ -1440,7 +1440,7 @@ self.can_interface.send(message, 0) - def cmd_ui_treatment_end_user_action(self, action=TreatmentEndUserActions.REQUESTED_USER_ACTION_TX_END_RINSEBACK_START.value): + def cmd_ui_treatment_end_user_action(self, action: int = TreatmentEndUserActions.REQUESTED_USER_ACTION_TX_END_RINSEBACK_START.value) -> None: """ Constructs and sends a UI treatment end user action message Constraints: @@ -1463,7 +1463,7 @@ self.can_interface.send(message, 0) - def cmd_ui_user_alarm_response(self, option=AlarmUserOptions.ALARM_USER_ACTION_ACK.value): + def cmd_ui_user_alarm_response(self, option: int = AlarmUserOptions.ALARM_USER_ACTION_ACK.value) -> None: """ Constructs and sends a ui alarm response message. Constraints: @@ -1489,7 +1489,7 @@ self.can_interface.send(message, 0) - def cmd_ui_silence_alarm(self, toggle=1): + def cmd_ui_silence_alarm(self, toggle: int = 1) -> None: """ Constructs and sends a ui alarm response message @@ -1510,7 +1510,7 @@ self.can_interface.send(message, 0) - def cmd_ui_sample_water(self, cmd=0): + def cmd_ui_sample_water(self, cmd: int = 0) -> None: """ Constructs and sends a ui water sample request message @@ -1529,7 +1529,7 @@ self.logger.debug("Sending user sample water command " + str(cmd) + " to HD.") self.can_interface.send(message, 0) - def cmd_ui_send_sample_water_result(self, result=1): + def cmd_ui_send_sample_water_result(self, result: int = 1) -> None: """ Constructs and sends a ui water sample result message @@ -1548,7 +1548,7 @@ self.logger.debug("Sending user sample water result " + str(result) + " to HD.") self.can_interface.send(message, 0) - def cmd_ui_consumable_installation_confirm(self): + def cmd_ui_consumable_installation_confirm(self) -> None: """ Constructs and sends a ui consumable installation confirm message @@ -1561,7 +1561,7 @@ self.logger.debug("Sending user consumable installation confirm to HD.") self.can_interface.send(message, 0) - def cmd_ui_disposable_installation_confirm(self): + def cmd_ui_disposable_installation_confirm(self) -> None: """ Constructs and sends a ui disposable installation confirm message @@ -1574,7 +1574,7 @@ self.logger.debug("Sending user disposable installation confirm to HD.") self.can_interface.send(message, 0) - def cmd_ui_start_prime_request(self): + def cmd_ui_start_prime_request(self) -> None: """ Constructs and sends a ui start prime request message @@ -1587,7 +1587,7 @@ self.logger.debug("Sending user start prime request to HD.") self.can_interface.send(message, 0) - def cmd_ui_continue_to_treatment_request(self): + def cmd_ui_continue_to_treatment_request(self) -> None: """ Constructs and sends a ui continue to treatment request message @@ -1600,7 +1600,7 @@ self.logger.debug("Sending user continue to treatment request to HD.") self.can_interface.send(message, 0) - def cmd_ui_patient_connection_confirm(self): + def cmd_ui_patient_connection_confirm(self) -> None: """ Constructs and sends a ui patient connection confirm message @@ -1613,7 +1613,7 @@ self.logger.debug("Sending user continue to treatment request to HD.") self.can_interface.send(message, 0) - def cmd_ui_start_treatment_request(self): + def cmd_ui_start_treatment_request(self) -> None: """ Constructs and sends a ui start treatment request message @@ -1626,7 +1626,7 @@ self.logger.debug("Sending user start treatment request to HD.") self.can_interface.send(message, 0) - def cmd_ui_disposable_removal_confirm(self): + def cmd_ui_disposable_removal_confirm(self) -> None: """ Constructs and sends a ui disposable removal confirm message Index: dialin/hd/valves.py =================================================================== diff -u -r045eb4c25850caf5b77a3fabcb0e6eefa7407380 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/valves.py (.../valves.py) (revision 045eb4c25850caf5b77a3fabcb0e6eefa7407380) +++ dialin/hd/valves.py (.../valves.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -137,7 +137,7 @@ """ return self.valves_status - def cmd_hd_valves_broadcast_interval_override(self, ms, reset=NO_RESET): + def cmd_hd_valves_broadcast_interval_override(self, ms: int, reset: int = NO_RESET) -> int: """ Constructs and sends broadcast time interval @@ -165,7 +165,7 @@ self.logger.debug("Timeout!!!!") return False - def cmd_set_hd_valve_position(self, valve, position, reset=NO_RESET): + def cmd_set_hd_valve_position(self, valve: int, position: int, reset: int = NO_RESET) -> int: """ Constructs and sends the HD valves set position for a valve @@ -200,7 +200,7 @@ self.logger.debug("HD cmd_valve_override Timeout!!!") return False - def cmd_set_hd_valve_pwm(self, valve, pwm, direction, reset=NO_RESET): + def cmd_set_hd_valve_pwm(self, valve: int, pwm: int, direction: int, reset: int = NO_RESET) -> int: """ Constructs and sends the HD valves PWM command @@ -209,6 +209,7 @@ VDO = 1 VBA = 2 VBV = 3 + @pwm pwm: integer - sets the pwm value @param direction: integer - Direction number: 0 = Clockwise 1 = Counter clockwise @@ -235,7 +236,7 @@ self.logger.debug("HD cmd_valve_override Timeout!!!") return False - def cmd_home_hd_valve(self, valve): + def cmd_home_hd_valve(self, valve: int) -> int: """ Constructs and sends the HD valves home command @@ -262,7 +263,7 @@ self.logger.debug("HD Homing Valve Timeout!!!") return False - def cmd_set_hd_air_trap_valve(self, valve_state=AirTrapState.STATE_CLOSED.name): + def cmd_set_hd_air_trap_valve(self, valve_state: int = AirTrapState.STATE_CLOSED.name) -> int: """ Constructs and sends an open/close command to the HD air trap valve Index: dialin/hd/watchdog.py =================================================================== diff -u -r287af45040e35882e001fb3ea835f304007870c4 -r2e392c92d55178f457a67423ba8c503a86dcf3c8 --- dialin/hd/watchdog.py (.../watchdog.py) (revision 287af45040e35882e001fb3ea835f304007870c4) +++ dialin/hd/watchdog.py (.../watchdog.py) (revision 2e392c92d55178f457a67423ba8c503a86dcf3c8) @@ -38,7 +38,7 @@ self.can_interface = can_interface self.logger = logger - def cmd_watchdog_task_check_in_override(self, state, task, reset=NO_RESET): + def cmd_watchdog_task_check_in_override(self, state: int, task: int, reset: int = NO_RESET) -> int: """ Constructs and sends the watchdog task check-in override command Constraints: