VOXL2 with IO board, Graupner RC, F9 uBlox GPS, and the FPV ESC 4-in-1
-
I am hoping to get some guidance on initial setup for a custom drone using VOXL2. Our GPS (uBlox ZED-F9P) isn't being published.
px4-listener sensor_gps never published
GPS is set to autodetect
I tried forcing gps start with 115200 and 38400 (from manual) but get the same command failed result.
px4-qshell gps status
returnsINFO [qshell] Send cmd: 'gps status' INFO [qshell] qshell return value timestamp: 482903338, local time: 482904782
we tried the following but the command failed
px4-qshell gps start -b 38400 INFO [qshell] Send cmd: 'gps start' INFO [qshell] cmd returned with: -1 INFO [qshell] qshell return value timestamp: 487577618, local time: 487581068 ERROR [qshell] Command failed
QGC recognizes that the GPS_1_PROTOCOL = u-blox
-
To add a bit more info;
ESC is connected to VOXL2 J18 and J4
VOXLIO is connected to VOXL2 J19 pins 9-12Doodle Labs Dev port is connected to 5G carrier board J12
mRo Zed F9p is connected to 5G carrier board J9If this is just a configuration issue where we need to point voxl or px4 to a different port I'd love to learn how.
-
@Dan-Jennings and @restore ,
if you run commands using px4-qshell, the commands are sent to the DSP. However, since you have connected your GPS to 5G carrier board J9, that uart is mapped to the CPU (Application Processor) : https://docs.modalai.com/voxl2-linux-user-guide/#devttyhs2---hsb2b-connector-uart
On VOXL2, some parts of PX4 run on DSP and some run on the CPU. Sometimes, components can run in either place, depending on the application (for example, the GPS driver)
So you should start your gps driver without qshell and use
/dev/ttyHS2
as the device name.px4-gps start -d /dev/ttyHS2
Please try that
Alex
-
@Alex-Kushleyev thank you very much for you help. That did the trick and the GPS is working now
-
@restore , Excellent! you are welcome.
-
@Alex-Kushleyev if we use the mRo GPS u-Blox Neo-M9N – IST8308 in order to have a compass (but still plugged into the 5G board) how do we start the ist8308 on dev/ttyHS2?
-
@restore ,
/dev/ttyHS2
is a UART only port that is mapped to the CPU. If you use a compass on the same connector of the carrier board J9, that i2c will also be mapped to CPU. However, we currently do not support compass driver running on the CPU side.A workaround could be to wire the I2C connectors (and gnd) to another i2c port, which is connected to the DSP. I am going to paste my response related to a very similar question from another user:
compass driver is started inside the voxl-px4 start-up script : /usr/bin/voxl-px4-start
# Auto detect the magnetometer. If one or both of these devices # are not connected it will fail but not cause any harm. /bin/echo "Looking for qmc5883l magnetometer" qshell qmc5883l start -R 10 -X -b 1 /bin/echo "Looking for ist8310 magnetometer" qshell ist8310 start -R 10 -X -b 1
please note that both of these drivers are expecting the compass to be connected to the DSP i2c ports. We currently don't have compass driver that can run on the cpu side (unlike GPS). However, you could potentially splice the connection for GND, SDA, SCL and connect the i2c bus to J19 on VOXL2, so that you can use the DSP driver for the compass.. Is that an option for you?
-
We have a few different GPS chips here so I went ahead and removed the Zed F9P GPS and plugged the M8N into the J19 connector as shown in the Voxl2 Offboard sensors documentation. I reverted the gps port and baud changes we had previously made in /usr/bin/voxl-px4-start and verified that the magnetometer lines that you provided were already there.
We now have GPS working off the M8N, but no compass still (checking with PX4-listener)
Running journalctl -b -u voxl-px4 the applicable area looks like this:
Apr 16 23:24:58 m0054 voxl-px4[1848]: Looking for ist8310 magnetometer Apr 16 23:24:58 m0054 voxl-px4[1848]: INFO [qshell] Send cmd: 'ist8310 start -R 10 -X -b 1' Apr 16 23:24:58 m0054 voxl-px4[1848]: INFO [qshell] cmd returned with: -1 Apr 16 23:24:58 m0054 voxl-px4[1848]: INFO [qshell] qshell return value timestamp: 12785145, local time: 12786961 Apr 16 23:24:58 m0054 voxl-px4[1848]: ERROR [qshell] Command failed Apr 16 23:24:58 m0054 voxl-px4[1848]: INFO [qshell] Send cmd: 'gps start' Apr 16 23:24:58 m0054 voxl-px4[1848]: INFO [qshell] qshell return value timestamp: 12834740, local time: 12835521
offboard sensors
https://docs.modalai.com/voxl2-guides-onboard-offboard-sensors/M8N
https://store.mrobotics.io/mRo-GPS-u-Blox-Neo-M8N-Dual-Compass-LIS3MDL-IST831-p/m10034-li8303.htm -
@restore After reading older posts, changing the Voxl start script to add the ist8308 magnetometer to the build instead of the ist8310 solved the issue. I can now see the compass through PX4-listener