Eddie Robot Python cmds
I am trying to make a simple python project to send commands to an eddie platform along these line:
import serial
import ctypes
import sys
import os
import time
ser = serial.Serial("COM3",115200)
print ser.name
cmd="go 20 20"
ser.write(cmd)
ser.close()
I know that the port is open and is working, but the commands that I have been sending do not execute. I have tried using ascii and hex but still nothing. I am guessing that I need a wrapper of some sort but I am at a loss right now. Any info/help would be greatly appreciated.
import serial
import ctypes
import sys
import os
import time
ser = serial.Serial("COM3",115200)
print ser.name
cmd="go 20 20"
ser.write(cmd)
ser.close()
I know that the port is open and is working, but the commands that I have been sending do not execute. I have tried using ascii and hex but still nothing. I am guessing that I need a wrapper of some sort but I am at a loss right now. Any info/help would be greatly appreciated.
Comments
You're missing the tail CR.
import serial
import ctypes
import sys
import os
import time
ser = serial.Serial("COM3",115200)
print ser.name
cmd="go 20 20\r"
ser.write(cmd)
time.sleep(.01)
ser.close()
But if not, I'd suggest swapping it out for FFDS1 from lonesock. I've tested it up to 460800 baud at full half duplex saturation and it does fine.