repo time

Dependencies:   mbed MAX14720 MAX30205 USBDevice

Revision:
20:6d2af70c92ab
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/HspGuiSourceV301/Script/hsp_intassignment.py	Tue Apr 06 06:41:40 2021 +0000
@@ -0,0 +1,28 @@
+import serial
+import io
+import time
+
+ser = serial.Serial(port='com16', baudrate=9600, timeout=1)
+
+ser.isOpen()
+
+ser.write("/MAX30001/WriteReg 2 3\r\n".encode())
+print(ser.readline())
+ser.write("/MAX30001/WriteReg 3 3\r\n".encode())
+print(ser.readline())
+
+
+#time.sleep(5)
+#for x in range (0, 100):
+ser.write("/MAX30001/INT_assignment 1 0 0 2 1 0 2 2 0 1 0 0 2 1 0 3 3\r\n".encode())
+print(ser.readline())
+
+ser.write("/MAX30001/WriteReg 10 080004\r\n".encode())
+print(ser.readline())
+
+ser.write("/MAX30001/ReadReg 2\r\n".encode())
+print(ser.readline())
+ser.write("/MAX30001/ReadReg 3\r\n".encode())
+print(ser.readline())
+
+ser.close()