Sending Arduino signals through python to svelte web app
Might be particularly useful for:
Change the port in arduino.py to your arduino port.
Change the websocket port (default here is 8765) in arduino.py and app/src/lib/App.svelte
Finally, change the route to App.svelte to your local route in app/src/routes/+page.svelte. You can copy path of App.svelte on your local machine from app/lib/App.svelte and paste it in app/src/routes/+page.svelte.
` python3 -m venv env source env/bin/activate
pip3 install pyserial pip3 install websockets `
In first terminal, run:
python3 arduino.py
In second terminal, run:
cd app npm run dev