Index: leahi_dialin/td/modules/treatment.py =================================================================== diff -u -r0ca34ba27790b8aeb6c368190cc770ca3f345184 -r956757fac807b52aec078e84127089db5dff069f --- leahi_dialin/td/modules/treatment.py (.../treatment.py) (revision 0ca34ba27790b8aeb6c368190cc770ca3f345184) +++ leahi_dialin/td/modules/treatment.py (.../treatment.py) (revision 956757fac807b52aec078e84127089db5dff069f) @@ -15,40 +15,16 @@ ############################################################################ import struct from logging import Logger -from enum import unique from .constants import RESET, NO_RESET from leahi_dialin.common.msg_defs import MsgIds, MsgFieldPositions +from leahi_dialin.common.td_defs import TDTreatmentParameters from leahi_dialin.protocols.CAN import DenaliMessage, DenaliChannels from leahi_dialin.utils.base import AbstractSubSystem, publish, DialinEnum from leahi_dialin.utils.checks import check_broadcast_interval_override_ms from leahi_dialin.utils.conversions import integer_to_bytearray, float_to_bytearray -@unique -class TDTreatmentParameters(DialinEnum): - TREATMENT_PARAM_BLOOD_FLOW = 0 # Blood flow rate (in mL/min) - TREATMENT_PARAM_DIALYSATE_FLOW = 1 # Dialysate flow rate (in mL/min) - TREATMENT_PARAM_TREATMENT_DURATION = 2 # Treatment duration (in minutes) - TREATMENT_PARAM_SALINE_BOLUS_VOLUME = 3 # Saline bolus volume (in mL) - TREATMENT_PARAM_HEPARIN_STOP_TIME = 4 # Heparin stop time (in minutes) - TREATMENT_PARAM_HEPARIN_TYPE = 5 # Heparin type (enum) - TREATMENT_PARAM_ACID_CONCENTRATE = 6 # Acid concentrate type (enum) - TREATMENT_PARAM_BICARB_CONCENTRATE = 7 # Bicarbonate concentrate type (enum) - TREATMENT_PARAM_DIALYZER_TYPE = 8 # Dialysate type (enum) - TREATMENT_PARAM_BP_MEAS_INTERVAL = 9 # Blood pressure measurement interval (in minutes) - TREATMENT_PARAM_RINSEBACK_FLOW_RATE = 10 # Rinseback flow rate (in mL/min) - TREATMENT_PARAM_RINSEBACK_VOLUME = 11 # Rinseback volume (in mL) - TREATMENT_PARAM_ART_PRES_LIMIT_WINDOW = 12 # Arterial pressure alarm limit window (in mmHg) - TREATMENT_PARAM_VEN_PRES_LIMIT_WINDOW = 13 # Venous pressure alarm limit window (in mmHg) - TREATMENT_PARAM_VEN_PRES_LIMIT_ASYMMETRIC = 14 # Venous pressure alarm limit asymmetric (in mmHg) - TREATMENT_PARAM_TMP_PRES_LIMIT_WINDOW = 15 # TMP alarm limit window (in mmHg) - TREATMENT_PARAM_DIALYSATE_TEMPERATURE = 16 # Dialysate temperature (in degC) - TREATMENT_PARAM_HEPARIN_DISPENSE_RATE = 17 # Heparin dispense rate (in mL/hr) - TREATMENT_PARAM_HEPARIN_BOLUS_VOLUME = 18 # Heparin bolus volume (in mL) - TREATMENT_PARAM_UF_VOLUME = 19 # Ultrafiltration volume (in liters) - provided separately by UI - NUM_OF_TREATMENT_PARAMS = 20 # Total number of treatment parameters - class TDTreatment(AbstractSubSystem): """ Treatment Delivery (TD) Dialin API sub-class for treatment related commands.