Using Johnny-Five, Express.js and Socket.io
Node.JS and NPM are required. Get them at https://nodejs.org/en/ and https://www.npmjs.com/
- Clone or the repository:
git clone https://github.com/tlystad24/arduino-socket.git - Navigate to the directory:
cd arduino-socket - Install the dependencies:
npm install
- Connect the arduino to a computer, then compile and upload
StandardFirmata, which can be found inexamples/firmata/StandardFirmata. - Connect two switches with a 10k pullup to
pin 5 and 6.
- Run the server:
node index.js - Navigate to
127.0.0.1:4000to open the app.