Index: dialin/common/msg_defs.py =================================================================== diff -u -r15ac4efc414bb043b7a3d5af0be099389e8a4bd4 -r342405f045e63fafeaee5406be24312498950a28 --- dialin/common/msg_defs.py (.../msg_defs.py) (revision 15ac4efc414bb043b7a3d5af0be099389e8a4bd4) +++ dialin/common/msg_defs.py (.../msg_defs.py) (revision 342405f045e63fafeaee5406be24312498950a28) @@ -101,6 +101,7 @@ MSG_ID_HD_RINSEBACK_CMD_RESPONSE = 0x53 # HD rinseback request response MSG_ID_HD_RECIRC_CMD_RESPONSE = 0x55 # HD re-circ request response MSG_ID_HD_RINSEBACK_PROGRESS = 0x56 # HD broadcast of rinseback progress + MSG_ID_HD_BLOOD_PRIME_PROGRESS = 0x59 # HD broadcast of blood prime progress MSG_ID_CAN_ERROR_COUNT = 0x999 # test code in support of EMC testing Index: dialin/ui/hd_simulator.py =================================================================== diff -u -r15ac4efc414bb043b7a3d5af0be099389e8a4bd4 -r342405f045e63fafeaee5406be24312498950a28 --- dialin/ui/hd_simulator.py (.../hd_simulator.py) (revision 15ac4efc414bb043b7a3d5af0be099389e8a4bd4) +++ dialin/ui/hd_simulator.py (.../hd_simulator.py) (revision 342405f045e63fafeaee5406be24312498950a28) @@ -1579,6 +1579,27 @@ self.can_interface.send(message, 0) + def cmd_send_treatment_blood_prime_data(self, vTarget, vCurrent): + """ + the bloodprime state change Response message method + | MSG | CAN ID | Box | Type | Ack | Src | Dst | Description | #1:(F32) | #2:(F32) | #2:(U32) | + |:----:|:------:|:---:|:------:|:---:|:---:|:---:|:-----------: |:--: |:--: |:--: | + |0x5900| 0x020 | 6 | 1Hz | N | HD | UI | bloodprime progress data | \ref Data::mTarget | \ref Data::mCurrent | \ref Data::mRate | + + :param vTarget : (float) the target volume in mL + :param vCurrent : (float) the current volume in mL + :return: None + """ + + payload = float_to_bytearray(vTarget) + payload += float_to_bytearray(vCurrent) + + message = DenaliMessage.build_message(channel_id=DenaliChannels.hd_to_ui_ch_id, + message_id=MsgIds.MSG_ID_HD_BLOOD_PRIME_PROGRESS.value, + payload=payload) + + self.can_interface.send(message, 0) + def cmd_send_treatment_adjust_recirculate_response(self, vAccepted, vReason): """ the recirculate state change Response message method