Unicore GPS Setup-UART
Step-by step guide to setup UM9XX module.
Prerequisites:
- Modified mower with replaced mainboard
- Installed RPI with
openmower
service running.
Step 1. Solder headers on WM9XX and note which UART line you choosen
-
WM9XX
You only need 4 middle pins from 6 available: gnd, vcc, tx, rx.
Remaining 2 not needed:
- EN - can be used to shut down the module temporarily
- PPS is a pulse once per second, in case you want to time something
Step 2. Wire WM9XX to the mainboard
Alternative to manual wiring: adapter board
MainBoard | UM9XX |
---|---|
TXD | TXD |
RXD | RXD |
5V_IN | VCC |
GND | GND |
-
UM9XX wiring sample
-
Mainboard wiring sample
Step 3. Configure UM9XX over UART
- Install miniterm (part of python3-serial)
sudo apt-get install python3-serial
- Stop openmower service (otherwise your UART bus is already occupied)
sudo systemctl stop openmower
- Connect to the CAN bus with miniterm (because we wired directly to mainboard, CAN will be available on
/dev/ttyAMA1
, default baud rate is 115200 )
python -m serial.tools.miniterm /dev/ttyAMA1 115200 -e
⚠ Next steps depend on which UART-line you wired headers ⚠
Following code samples assume you wired to bottom lane (COM1), if not, replace COM1 -> COM2
- Reset and configure Baud rate
FRESET⏎ Enter
openmower@openmower:~ $ python -m serial.tools.miniterm /dev/ttyAMA1 115200 -e
--- Miniterm on /dev/ttyAMA1 115200,8,N,1 ---
--- Quit: Ctrl+] | Menu: Ctrl+T | Help: Ctrl+T followed by Ctrl+H ---
FRESET
$command,FRESET,response: OK*4D
system is rebooting
..........
$devicename,COM1*67
Execute
CONFIG COM1 460800⏎ Enter
Now exit miniterm via Ctrl + ]
Connect again to UM9x but with new/higher baud rate via:
python -m serial.tools.miniterm /dev/ttyAMA1 460800 -e
Note if you are not receiving responces to your commands, something is wrong with baud-rate or COM port you are using, reconnect with default baud rate, reset (FRESET) and try again.
For next step - with every "GP*" command your sent, you'll get spammed with more messages. At the end it will become hard to recognize the "OK" from "SAVECONFIG", but it's mandatory that you ensure that "SAVECONFIG" got done!
MODE ROVER UAV ⏎ Enter GPGSV COM1 2 ⏎ Enter GPRMC COM1 1 ⏎ Enter GPGSA COM1 1 ⏎ Enter GPVTG COM1 1 ⏎ Enter GPGGA COM1 0.5 ⏎ Enter SAVECONFIG ⏎ Enter
Example of expected execution output
$GNGGA,192705.50,,,,,0,00,9999.0,,,,,,*45 $command,SAVECONFIG,response: OK*55 $GNGGA,192706.00,,,,,0,00,9999.0,,,,,,*43 $GPGSA,,1,,,,,,,,,,,,,,,,*73 $GNRMC,192706.00,V,,,,,,,030625,0.0,E,N,V*7B
exit miniterm via Ctrl + ]
Step 4. Configure openmower
Update your mower_config.txt
export OM_GPS_PROTOCOL="NMEA"
export OM_GPS_BAUDRATE="460800"
Start openmower service
sudo systemctl start openmower
Done!
Assuming you already configured RTK base, you can bring mower outside and check if you are getting GPS FIX.
For support and assistance in troubleshooting join discord.