HTML Oscilloscope for Arduino.
Powered by Ruby/EventMachine, WebSocket and HTML5 Canvas.
gem install em-websocket gem install em-serialport
Start the server
The script will start watching serial port. When the first WebSocket client appears, Arduino is reseted and start streaming.
If you want to stop the server, please type Ctrl-C.
After starting the server, open graph.html. You need to use the browser available WebSocket and Canvas.
Buffering of SerialServer.rb is poor a little. Therefore, a part of graph line will be broken because some WebSocket packets contain large value. Someday I'll be fix.
The baudrate is set 9600bps. If you set the baudrate more faster, the time between each point is shorter a little. I think that it's enough to set 9600bps.
Serial-Communication extention for EventMachine.
WebSocket support extention for EventMachine.