Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #!/usr/bin/python
- from array import array
- import serial, sys
- i = 3
- ser = serial.Serial('/dev/ttyACM0', 9600)
- a=array('i')
- a.append(int(sys.argv[1]))
- a.append(int(sys.argv[2]))
- a.append(int(sys.argv[3]))
- for i in range(0, 3):
- if not all(0 <= argv <= 180 for argv in sys.argv): sys.exit(0)
- else: print(a[i])
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement