I’ve got my servo controller and servos rigged up, and I ran a test program in roborealm, which causes the servos to move as expected. However I don’t want to use roborealm for various reasons, and I’ve been trying to get the servos to move using a python script. I am using a serial port monitor to monitor the data sent to and received from the serial port, and I can send whatever data I want from python.
I have made a script which sends exactly the same data as the roborealm program, but it causes no servo movement. With roborealm the green led flashes, with python the yellow led just turns off, and then on again when the program has run.
Because the actual movement data sent are identical, I think it must have something to do with the way the port is opened and the connection initialised. I have the readout of this for the working roborealm program and the failing python script. Can anyone see where I’m going wrong? Because I’m pretty lost.
I’ve attached a .xls (csv wasn’t allowed) of the readouts from the two programs.
roborealmvpython.xls (39.5 KB)
Thanks for your help. I hope this will be an interesting problem to work out. But not too interesting