Skip to content

Instantly share code, notes, and snippets.

@csu
Created August 31, 2012 16:06
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save csu/3555152 to your computer and use it in GitHub Desktop.
Save csu/3555152 to your computer and use it in GitHub Desktop.
Write to serial with Python
#!/usr/bin/python
import serial
ser = serial.Serial('/dev/tty.usbmodem621', 9600)
ser.write('1')
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment