p5js Webserial to Arduino
Working example using the WebSerial lirary by Tom Igoe.
--> build and tested with arduino IDE v2.1 and Processing IDE v4.2 (processing Mode: p5.js v1.6)
Things to Note
- keep in mind that only once program can use a Serial port at a time. This means that you can't open the Arduino Serial monitor when connected to web-serial.
- Webserial currently only works in Chrome.
- Sometimes, the browser cache ignores changes to your script.To avoid this, use incognito mode.
Further information
- A helpful introduction to WebSerial - https://developer.chrome.com/articles/serial/