Position mode works, but offboard mode don't
-
@Dawid-Mościcki how are you connecting to the system instance - over udp on port 14550? I would recommend swapping to mavSDK instead of mavros as ros1 is depracated. Please check out the documentation here:
-
@Zachary-Lowell-0 i'm not sending commands in offboard mode via voxl2. voxl2 is connected over wifi to our PC, PC is running ros noetic with mavros instance and sending commands over wifi-telemetry
-
Got it - what on the voxl2 side is ingesting these commands and pushing them into the PX4 instance? As for the horizontal drift, I would recommend seeing if you were to do a simple takeoff and land in offboard mode via MAVSDK if the same issue persists (which can be programmed onboard the voxl2). Can you show your initial code that swaps it into offboard mode? Are you sending initial 0's for the setpoint then starting offboard mode, then consistently sending in setpoints post start?
-
Also can you try your code in HITL to see if you get the same reactions?
-
"Got it - what on the voxl2 side is ingesting these commands and pushing them into the PX4 instance? "
Sorry, but i assumed that i could just send it via wifi telemetry directly to px4 via mavros and it should work. I will try again with using voxl2 instead. Could You link me any tutorial how to do it ? it's my first time using this product ... This will be good ? https://docs.modalai.com/mavros/
Thanks and best regards -
Sorry I think I misunderstood your architecture. You should be able to probe PX4 from a traditional mavros packet over the wifi telemetry. I am assuming you are connecting over something like "/dev/ttyUSB0" or something like that? If not, then I am guessing you are connecting over a port like 14550 and not using QGC?
Would you mind posting some of your code so I could see what you are relaying to the PX4 instance - Are you sending in an initial 0's setpoint prior to starting the offboard mode?
-
Are you using QGC - and if so, can you turn it off and then test offboard? There could be conflicting packets or interaction between the px4 instance and qgc. If not, please make sure the initial setup for offboard mode is set points of 0's and if you can run voxl-mavlink-server in debug mode from the command line interface.
Can you takeoff in position mode and swap to offboard mode mid flight and hold position or something of that nature as well?
The thing that is most likely the issue I believe is voxl-vision-hub. There is a program in vision-hub that will automatically do a figure 8 in offboard when it gets kicked off programatically and this is most likely conflicting with your takeoff. The parameters you needs to disable in
/etc/modalai/voxl-vision-hub.conf
are:offboard_mode: off
Hopefully this works - keep us posted!
-
@Zachary-Lowell-0
Thanks for help ! i set offboard_mode: off.
Steps i took :- create simple ros noetic mavros publisher that will set offboard, arm drone, and publish on local_position (0,0,1.5) and orientation (w:1,0,0,0).
- Drone armed, spinned motors and after 1s go back to position mode when armed that causes drone to lift off and crash I broke one of landing gear so i hope i can 3D print it and it will be fine.
We have some problems now with VOXL ESC For some reason when i inspect mavlink via QGC (command voxl_esc status) its returning failure (-1). After restarting it via battery few times sometimes it starts working again and sometimes dont
What could be reason for that ? Do You have any more tips or stepps for debbuging this ?
Thanks again
I will post code and steps later this day hopefully
-
Dang! @Dawid-Mościcki to stay in offboard mode you need to consistently be feeding into the PX4 instance setpoint commands or else it will fall back to position mode. Once you changed the offboard_Mode to off, did you restart voxl-vision-hub and or reboot the voxl2?
@Alex-Kushleyev looks like they are having some ESC trouble - any recommendations?
-
Let's do a quick check of ESCs. Please follow this procedure:
#stop px4 which will conflict with ESC tools systemctl stop voxl-px4 #udpate voxl-esc tools to get the latest (if you have internet connection) apt-get update apt-get install voxl-esc #run ESC scan cd /usr/share/modalai/voxl-esc-tools/ ./voxl-esc-scan.py
This should detect the modalai ESCs without using PX4. Hopefully there is no issue in doing that, please let us know.
-
@Alex-Kushleyev
I tried to update voxl-esc, but its already newest version ...
I 3d printed drone's skid and fly tested. Drone was having trouble with managing constant altitude, and when trying to land (it was on the ground) somehow flew up to 1.5m and made rapid descend to ground and crashed. Could You help me review this issue ? This is link to logs, params, and esc output on gdrive : linkIt was very strange ... I'm almost certain that we got a bug in params at this point.
Best regards
-
@Dawid-Mościcki , i took a look at the log, the ESC performance looks good. I do see the jump at the end, which you described, but it is not clear to my why this happened.
@Zachary-Lowell-0 , any suggestions how to diagnose further? Position and offboard mode use VIO, for x-y-z control, right? (sorry if I am off, not entirely familiar). Can we log and look at VIO quality?
-
@Alex-Kushleyev Any updates on reviewing this issue ? TBH i'm scared to take off this drone from ground again without finding cause of that strange behavior ...
-
@Alex-Kushleyev said in Position mode works, but offboard mode don't:
for
@Dawid-Mościcki I would say it is safe for now to just fly via position mode or mannual mode and have a kill switch linked to the rC controller. Then you can try swapping over to positio mode. Then try your offboard code.
If the esc chimes when booted then it is getting the right data to control the motors.
-
@Zachary-Lowell-0 that crash happened in position mode .......
-
Got it - if you are certain this is an issue in the parameters of PX4, you can reconfigure the MPA to match that of the m500 - just run
voxl-configure-mpa
and it will then ask for the drone you are using. Then it will parse through all the config files for the m500 and setup the MPA and px4. Then reboot and everything should be back to factory defaults. -
@Zachary-Lowell-0
I did it, and configured drone accordingly to https://docs.modalai.com/flying-with-vio/ so that drone could fly without GPS.
Drone can't fly at all, doesnt respond to stick inputs, logs : https://review.px4.io/plot_app?log=f4e0abee-f370-4932-91c4-2e19aa6e66cf
Vibration metrics is too high, what can we do ?
Please help -
@Dawid-Mościcki Any 3D files for this drone are available for download ? For example landing skid ?
-
@Dawid-Mościcki i don't even know how's that possible https://review.px4.io/plot_app?log=973783b8-6262-46e3-8214-602dce495131
look at actuator FFT -
@Dawid-Mościcki said in Position mode works, but offboard mode don't:
Please help
2 Replies Last reply about 24 hours ago Reply
Hi David - can you reflash your voxl with the most recent SDK and reconfigure the SKU - we need to start from baseline. Let me know.
Zach