bluerobotics / companion

Companion computer startup scripts and examples
https://www.ardusub.com/operators-manual/companion-web.html
GNU General Public License v3.0
48 stars 54 forks source link

Remove dedicated Mavlink2rest endpoint, set default-modules=output #406

Closed Williangalvani closed 3 years ago

Williangalvani commented 3 years ago

This moves Mavlink2rest to a shared endpoint at port 9000. This endpoint is also used by the pingmav driver and Ardusub.py for fetching the running version for the webui at the /system page.

testing locally it seems to work just fine. mavlink2rest shows all the data as expected. pingmav runs and I'm able to see the ardusub version.

Additionally, the ping1d driver got changed to use the pymavlink interface, so we don't have a driver using two different interfaces(That section would need to be changed anyway it was missing a request for "AUTOPILOT_VERSION").

Helps #313

patrickelectric commented 3 years ago

@Williangalvani do you know how much CPU the PR saves ?

Williangalvani commented 3 years ago

With this, I get 50-60% cpu usage. Eliot's Companion reached up to 100% usage in our tests. (without the PR)