Web Interface - hgdeoro/py-arduino-proxy GitHub Wiki

PyArduinoProxy now is py-arduino

PyArduinoProxy now is py-arduino

I've renamed the project to py-arduino, please check it out at:

https://github.com/hgdeoro/py-arduino

I didn't like the 'proxy' word in its name, and made big changes, including:

  • refactored low level code to the new py_arduino package
  • refactores web application stuff to py_arduino_web package
  • add multiprocess support + background tasks, aka: concurrent access (thanks to uWSGI + PyRO)
  • labeling of pins and restricted acces from web (administrable using Django)
  • cleaned up old code (like old examples) and an updated README

Old content

Wiki home | Git repo | How-to-install | Web-Interface | Blog (spanish) | Site (spanish)


Videos: Web interface + emulator + analog pins and Old version of web interface.

Example: using the web interface to test LM335

How to start it? In the Py-Arduino-Proxy directory, run:

~$ ./bin/webserver.py --info

With '--info' you activate the display of logging messages. You'll get something like this:

~$ ./bin/webserver.py --info
INFO:cherrypy.error:[26/May/2011:12:41:18] ENGINE Listening for SIGHUP.
INFO:cherrypy.error:[26/May/2011:12:41:18] ENGINE Listening for SIGTERM.
INFO:cherrypy.error:[26/May/2011:12:41:18] ENGINE Listening for SIGUSR1.
INFO:cherrypy.error:[26/May/2011:12:41:18] ENGINE Bus STARTING
INFO:cherrypy.error:[26/May/2011:12:41:18] ENGINE Started monitor thread '_TimeoutMonitor'.
INFO:cherrypy.error:[26/May/2011:12:41:18] ENGINE Started monitor thread 'Autoreloader'.
INFO:cherrypy.error:[26/May/2011:12:41:18] ENGINE Serving on 127.0.0.1:8080
INFO:cherrypy.error:[26/May/2011:12:41:18] ENGINE Bus STARTED

By now, the server is running and listening on "127.0.0.1:8080".

Now, you are ready to open "http://127.0.0.1:8080":

web-ui-connect.png

Specify the serial port (something like /dev/ttyACM0 on Ubuntu, COM3 in Windows), and press Connect.

web-ui-main.png

There's also a JavaScript Prototyping page. It let you make simple programs to work with the Arduino from JavaScript! You can open this page clicking on the "JS Prototyper" button.

web-ui-javascript-prototyper.png

And for developers: if you want to modify PyArduinoProxy (either the web interface or anything else), you can use the "Arduino Emulator". Every time you use ARDUINO_EMULATOR as serial port, an instance of the Arduino emulator is used (instead of a real serial connection).

This let you develop and test the modifications without needing a real Arduino connected.

web-ui-arduino-emulator.png