Video Feed with PS3 Control

I decided I wanted to have PS3 control but also the WebUI video feed, so on a whim, I simply added both the
@reboot /home/pi/metalborg/ps3MetalJoy.sh # PS3 Control
and
@reboot sudo /home/pi/metalborg/metalWeb.py # Web Control
To crontab -e

To my surprise, it worked ... albeit with occasional freezes on the video.

I then thought, it can't be hard to remove all the buttons and controls from the metalWeb.py so that it just feeds the video. I was wrong, again.

I'm comfortable with experimenting with the Main Page part of the code, because if I get it wrong it won't cause any issues, it will just throw up errors on the page, or not work at all ... I guess.
But it it's the controls that concern me, if I get that wrong it could wreck either motors or boards, perhaps.

My plan was to simply trim the WebUi down to just do the video feed to WiFi, and leave all the control to the PS3 controller.

Oh! I'm working on adding some bling too. I'll let you know how that goes.

I've found someone that can supply me with some very small motor cycle starter motors (less than 100mm long) for my mini DoodleBorg project. Just need to flip through the catalogue to see if there are any that have the mount orientation that I would like. But at least it's a step in the right direction :-)

piborg's picture

So you are using the phone as a monitor and controlling with the PS3 controller, sounds like fun :)

If you go to "/stream" you should get just the video stream without any controls, e.g. http://192.168.0.100/stream

In the WebServer class you can remove the control functionality as follows:

  1. Remove the drive off section, starts with
    elif getPath.startswith('/off'):
  2. Remove the motor speed setting section, starts with
    elif getPath.startswith('/set/'):
  3. Remove the main page section, starts with
    elif getPath == '/':
  4. Make the streaming panel the main page, replace the line:
    elif getPath == '/stream':
    with the main page url "/":
    elif getPath == '/':

This will make the main page the same as the current "/stream" page, preventing control of the robot from the web UI.

That's exactly what I wanted to achieve, thank you.

Subscribe to Comments for "Video Feed with PS3 Control"