Python "Hello World" example for the Astronode S module.
- python v2.7+
- python v3.4+
- Make sure you meet the system requirements.
- Check the
SerialPort
device variable in main.py script:- Use
COMx
devices for Windows hosts. - Use
/dev/ttyUSBx
for Linux hosts.
- Use
- Run the main.py script.
- Make sure you meet the system requirements.
- Using raspi-config, disable login shell over serial and enable serial interface.
- Use
/dev/ttyS0
in main.py script.
RASP 40-PIN ASTRONODE FTDI TTL
-------------------------------------------
PIN1 3V3 <----> 3V3
PIN9 GND <----> GND
PIN14 UART_TX <----> RX
PIN15 UART_RX <----> TX
- Build the docker image:
docker build -t astronode-python-hello-world .
- Run the docker image, attaching the appropiate serial device file:
docker run -t -i --device=/dev/ttyUSB0 astronode-python-hello-world