Raspberry Pi + Pololu Maestro + Python3 + Tornado + Servo Control Part 3

So we have all the backbone software ready as discussed in Part 2, now we want to create the interface. We basically need JQuery to handle the button interaction. Once a button is clicked, it will send a command to the server via WebSocket. The server needs to relay the…

Raspberry Pi + Pololu Maestro + Python3 + Tornado + Servo Control Part 2

In Part 1 we discussed ways to connect all the hardware together. For there software component, there are 4 different technologies involved: Device.py, which provides byte commands to Pololu Maestro discussed previously. DeviceController.py, which provides servo control via function calls on the Device Driver object. TornadoServer.py, which serves the web…

slide

Run NodeJS server on boot with forever on Raspberry Pi

LEGO Shop at Home: The World’s Biggest LEGO Shop Raspberry Pi is capable to host a NodeJS server. We want to use node’s forever module to keep our node server running, even when system restarts. Install forever Install forever and use the node app as root: sudo -i npm install forever -g Test run your nodeJS server app:…

HTML script to listen and send commands to Arduino via Serial Port

This is the source code for the web page interface to control your robot. For this to work you need the corresponding¬†NodeJS script behind it. ¬† <html> <head> <title>Rasinro – Rasberry Internet Rover</title> </head> <body onmousemove=””> <h1>Rasinro – Raspberry Internet Rover</h1> <p>Status: <span id=”status”>Waiting…</span></p> <table border=’1′> <tr align=”center”><td><button id=’fl’ type=”button”>Forward…

nodeJS on Raspberry Pi

NodeJS Script to listen and send command to Arduino Robot

var SerialPort,fs, http, io, server, net, serial, port; fs = require(‘fs’); http = require(‘http’); net = require(‘net’); var light1 = true; var light2 = true; SerialPort = require(‘serialport’).SerialPort; port = ‘/dev/ttyACM0’; server = http.createServer(function(req, res) { return fs.readFile(“” + __dirname + “/mobil2an.html”, function(err, data) { res.writeHead(200, { ‘Content-Type’: ‘text/html’ });…

Next Page »