# Talking to a Flask Webserver from a Commandline

Have a bunch of work in setting up a flask webserver to control a robot from an app, and I'm not too pleased with the results for driving. Touch sensitivity issues are driving me nuts, and looking to maybe try a slightly different route instead.

The flask server has a bunch of empty page web requests(my term) where it has a page for http://192.168.10.1/Forward and some python code to control the motor controller. When you go to that URL the code executes in the background and the car goes forward. Have all the URL's mapped to buttons in an app and it works till the screen thinks you let go which is constant and pretty aggrevating.

I've now setup a python script with EVDEV to find and search for joystick events which works. I thought I could use something like this on the event:

webbrowser.get('lynx').open('http://192.168.10.1/Forward')


And it would goto the url with Lynx...but sadly Lynx then wants you to hit Q to Quit then you can send another Joystick command. I guess there's a way to kill the process after each hit but that seems messy.

If there another way I might be able to do something like that without installing the GUI and does not involve having to figure out how to make two scripts talk to one another a different way all together?

Regards, Matt