PX4 / PX4-Autopilot

PX4 Autopilot Software
https://px4.io
BSD 3-Clause "New" or "Revised" License
8.26k stars 13.42k forks source link

RPi3: high cpu utilisation when auto start #5887

Closed lhc610github closed 7 years ago

lhc610github commented 7 years ago

Hi I have successfully running PX4 with Navio2 on RPi3. Now i have issues with auto starting this program as soon as the RPi3 has booted.: added the binary execution to rc.local cd /home/pi && ./px4 px4.config > startup.log It can successfully start the px4 program, but cpu utilisation is much higher than just start this program from shell or ssh. I couldn’t figure out . Could this be a linux distro problem (emlid RT kernel raspbian) or anything didn’t taken care of in PX4 code. Thanks in advance. fig 1 fig 1 is auto start PX4 by rc.local fig 2 this fig is start PX4 from shell or ssh

bkueng commented 7 years ago

I was able to reproduce, use the following line to fix it:

cd /home/pi && ./px4 -d px4.config > px4.log

Note the -d which starts px4 in daemon mode.

I added instructions to the DevGuide in https://github.com/PX4/Devguide/pull/68