Hi Alan
ran the commands suggested the bot then ceases to respond unless I reboot. It works fine then.
I get
- Code: Select all
pi@raspberrypi ~/raspberry_pi_camera_bot $ sudo ./robot_web_server.py
sockjs.tornado will use json module
Starting web server...
Read 0XACED 0.38
Expected 0XACED 0.38
Do I need to stop the webserver before running a script?
I assume the webserver is running. ok
I do not understand how my script communicates with it as the command
bot.set_motor_speeds( 30.0, 0.0 ) has underscores in it.
While in the webserver script
- Code: Select all
elif lineData[ 0 ] == "SetMotorSpeeds" and len( lineData ) >= 3:
leftMotorSpeed = 0.0
rightMotorSpeed = 0.0
there are no underscores in "SetMotorSpeeds"? So how is my script calling the webserver? My scripts run as expected from terminal or local (after a reboot). I am clearly missing something out?
You say run put print statements in webserver script and run from bot command line. How does that test communication from my terminal. It does prove my webserver is running.
If i edit the line
- Code: Select all
elif lineData[ 0 ] == "SetMotorSpeeds" and len( lineData ) >= 3:
to
- Code: Select all
elif lineData[ 0 ] == "####SetMotorSpeeds" and len( lineData ) >= 3:
the command
- Code: Select all
bot.set_motor_speeds( 30.0, 0.0 )
works is that because I need to reboot? and then it would not?
Thanks