client (index.html + other js) --> server.js --> Arduino (test.ino)
This test code is set on Arduino uno R3.
Based on the button pressed on the client (port 3000), Builtin LED of Arduino Uno blinks.
Make sure that npm and nodeJS are installed on the device.
npm init -y
npm install express serialport
- Upload the arduino code
- Close the serial monitor
- Initiate server
node server.js