I assumed this would not be possible, but after reading this post thought that perhaps it might be:
How can I send data from a web page to a serial port?
So I added my code for serial
as below and just hoped some sort of magic would occur:
import serial
ser = serial.Serial('/dev/ttyACM0', 9600)
As expected though, I got an error:
[Mon Aug 01 07:01:44.513340 2016] [wsgi:error] [pid 16:tid 140515737831488] raise SerialException(msg.errno, "could not open port %s: %s" % (self._port, msg))
[Mon Aug 01 07:01:44.513367 2016] [wsgi:error] [pid 16:tid 140515737831488] SerialException: [Errno 2] could not open port /dev/ttyACM0: [Errno 2] No such file or directory: '/dev/ttyACM0'
The code is working fine locally and the online environment mimics the modules available locally through requirements.txt
.