########################################################################### # # Copyright (c) 2019-2020 Diality Inc. - All Rights Reserved. # # THIS CODE MAY NOT BE COPIED OR REPRODUCED IN ANY FORM, IN PART OR IN # WHOLE, WITHOUT THE EXPLICIT PERMISSION OF THE COPYRIGHT OWNER. # # @file test_can_xmit.py # # @author (last) Peter Lucia # @date (last) 06-Aug-2020 # @author (original) Peter Lucia # @date (original) 14-Jul-2020 # ############################################################################ import sys sys.path.append("..") from dialin.hd.hemodialysis_device import HD from time import sleep if __name__ == "__main__": # create an HD object called hd hd = HD() # log into HD if not hd.cmd_log_in_to_hd(): sys.exit() # reset sequence counter x = 0 # send large CAN test messages (6 frames each) every 100ms while True: sleep(0.1) hd.pressure_occlusion.test_can_message(x) x += 6