Commit Graph

36823 Commits

Author SHA1 Message Date
Peter Barker 8c6a427107 AP_Vehicle: correct compilation when network port registering disabled
the ports member doesn't exist in this case
2024-08-13 10:46:45 +10:00
Peter Barker f32f3beceb AP_Networking: correct compilation when network port registering disabled
ports doesn't exist if this condition is false
2024-08-13 10:46:45 +10:00
Peter Barker 1dc87a0903 AP_OpticalFlow: simplify condition used for building onboard optical flow in
we're not being consistent in the use of defines to protect this feature; fix that
2024-08-13 10:45:31 +10:00
Andy Piper edbe339f48 AP_Logger: correctly read file header for block logger 2024-08-13 10:44:35 +10:00
Peter Barker 3194fa1385 AP_Scripting: correct compilation when AP_SCRIPTING_SERIALDEVICE_ENABLED false 2024-08-13 10:43:29 +10:00
Peter Barker 6c788c6ae0 AP_Math: correct warning on fabsF
2024-08-08T01:51:53.6780446Z ../../libraries/AP_Math/vector3.cpp:432:9: warning: absolute value function 'fabsf' given an argument of type 'const double' but has parameter of type 'float' which may cause truncation of value [-Wabsolute-value]
2024-08-08T01:51:53.6781336Z     if (fabsF(cosv) >= 1) {
2024-08-08T01:51:53.6781583Z         ^
2024-08-08T01:51:53.6781930Z ../../libraries/AP_Math/ftype.h:50:18: note: expanded from macro 'fabsF'
2024-08-08T01:51:53.6782342Z #define fabsF(x) fabsf(x)
2024-08-08T01:51:53.6782572Z                  ^
2024-08-08T01:51:53.6789178Z ../../libraries/AP_Math/vector3.cpp:633:16: note: in instantiation of member function 'Vector3<double>::angle' requested here
2024-08-08T01:51:53.6789800Z template class Vector3<double>;
2024-08-13 10:42:23 +10:00
Andy Piper 08bf7c6163 AP_HAL_ChibiOS: Flywoo H743 Pro 2024-08-13 10:20:15 +10:00
Thomas Watson e12f345bae AP_DroneCAN: DNA_Server: make lower level database tasks private
All the higher level database operations need to be locked for the whole
duration of the operation, so nobody should be using the lower-level
tasks or raw read/write functions. We can also remove the locks from
them.

The database can now safely be used by multiple servers.
2024-08-13 09:58:44 +10:00
Thomas Watson 4097e9fa42 AP_DroneCAN: DNA_Server: move allocation operation to db
Must be locked for the whole operation due to the find free/add
read-modify-write.

Preserves the previous behavior of sending back an ID of 0 in case of
allocation failure, for better or worse.
2024-08-13 09:58:44 +10:00
Thomas Watson f406c62449 AP_DroneCAN: DNA_Server: move node info update operation to db
Must be locked for the whole operation due to the occupied check and
addition read-modify-write.
2024-08-13 09:58:44 +10:00
Thomas Watson e79437d04a AP_DroneCAN: DNA_Server: move init operation into db
Must be locked for the whole operation due to the get/add
read-modify-write.
2024-08-13 09:58:44 +10:00
Thomas Watson 01e285c681 AP_DroneCAN: DNA_Server: move database tasks to db class
The server should not have raw read/write access to the database so the
database needs to take over the tasks.
2024-08-13 09:58:44 +10:00
Thomas Watson a9774d2334 AP_DroneCAN: DNA_Server: move storage read/write to its own class
There is (currently) only one storage area that is used by all servers,
so it needs to be managed by its own class shared among them.

The occupied mask is also moved as it reflects the storage contents and
so can't be stored by each server.
2024-08-13 09:58:44 +10:00
Iampete1 f6da3ce764 AC_AutoTune: add support for testing tune via aux function 2024-08-13 08:57:44 +09:00
Iampete1 94d3e2673a AC_AutoTune: Multi and Heli: only load tuned gains if a axis has completed successfully 2024-08-13 08:57:44 +09:00
Iampete1 9da6f321a0 RC_Channel: add autotune switch 2024-08-13 08:57:44 +09:00
Peter Barker c3b6127b1b AP_ExternalAHRS: correct VectorNAV handling of error term 2024-08-13 08:38:21 +10:00
Peter Barker f389549d5d AP_InertialSensor: correct warnings on static_assert requiring a message 2024-08-13 08:38:00 +10:00
Peter Barker ce03fd3ed9 AC_AutoTune: remove unused variable from heli autotune 2024-08-12 13:30:26 -04:00
Peter Barker 748fe538ea AP_Winch: correct compilation when backends compiled out 2024-08-12 18:28:27 +10:00
Peter Barker 27a7a21805 AP_Compass: correct compilation when logging disabled 2024-08-12 18:28:07 +10:00
Peter Barker 610ba486ad AP_MSP: cut more code out based on defines 2024-08-12 18:07:21 +10:00
Peter Barker 5c3aa91721 AP_RCTelemetry: add missing gate for AP_VIDEOTX_ENABLED
possible nullptr issue?
2024-08-12 17:52:04 +10:00
Peter Barker 92dd71203e AP_VideoTX: correct include to use config.h
need to avoid random headers in these config files!
2024-08-12 17:52:04 +10:00
Peter Barker 53e9fe0805 AP_Mount: correct compilation with HAL_MOUNT_SET_CAMERA_SOURCE_ENABLED off 2024-08-12 17:50:59 +10:00
Tom Pittenger a014bcb5bd AP_RPM: Allow more instances 2024-08-10 22:37:03 +10:00
mikefenghao ff30224079 AP_HAL_ChibiOS:added new hardware PixPilot-V6PRO 2024-08-10 11:06:33 +10:00
Peter Barker e75903d6fa AP_Baro: replace gcs().send_text with GCS_SEND_TEXT 2024-08-09 14:53:55 -07:00
Peter Barker 127e634589 GCS_MAVLink: add and use Battery backend internal-use-only flag
sometimes the information from a backend is very useful for logging, but not via telemetry.

Add an option bit to signify this
2024-08-08 09:12:08 +10:00
Peter Barker 8ee09c299e AP_BattMonitor: add and use Battery backend internal-use-only flag
sometimes the information from a backend is very useful for logging, but not via telemetry.

Add an option bit to signify this
2024-08-08 09:12:08 +10:00
Iampete1 34549cf0cb AP_ESC_Telem: add logging of power percentage 2024-08-07 11:23:35 +01:00
Iampete1 8ec3d0f0a9 AP_DroneCAN: populate ESC power percentage 2024-08-07 11:23:35 +01:00
Andy Piper a974f3fd42 AP_Motors: add access to per-motor thrust values 2024-08-07 18:45:50 +10:00
Andy Piper fd19c3f401 AP_Vehicle: support per-motor throttle based notches 2024-08-07 18:45:50 +10:00
Peter Barker e23e58fc17 SITL: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker 4dac24796d GCS_MAVLink: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker c0b905f6e6 AR_Motors: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker 7c1d37f374 AP_VisualOdom: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker bfd97bf0cd AP_Soaring: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker fd418ca59d AP_RangeFinder: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker cee45a2fc2 AP_Radio: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker 96b5fa6e93 AP_Proximity: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker 496bbde384 AP_Mount: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker 78afaebe55 AP_Logger: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker 52d5b4e684 AP_LandingGear: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker 9a1aece9ab AP_HAL_ESP32: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker 23b7e0f64d AP_HAL_ChibiOS: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker f7767d7fd0 AP_Generator: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker 4d24e7bbf0 AP_Follow: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker fa4e90a3bb AP_Compass: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker ffb2a32144 AP_Camera: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker 4565eed5ad AP_BoardConfig: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker f5e55b9a12 AP_Beacon: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker d205e2e5cf AP_BattMonitor: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker ec5eb88217 AP_Baro: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker edf42f799c AP_AdvancedFailsafe: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker 5db0eecb99 AC_Fence: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Peter Barker bf09835509 AC_AutoTune: use GCS_SEND_TEXT rather than gcs().send_text
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-07 18:33:16 +10:00
Andy Piper b6717e541a AP_MSP: use highest ESC temp rather than motor temp 2024-08-07 18:10:56 +10:00
Andy Piper f6984024c3 AP_ESC_Telem: use highest ESC temp rather than motor temp 2024-08-07 18:10:56 +10:00
Andy Piper 102f483623 AP_OSD: use highest ESC temp rather than motor temp 2024-08-07 18:10:56 +10:00
Andy Piper 189cc9d549 AP_HAL_ChibiOS: correctly uninvert RX/TX on F4 with inverter support 2024-08-07 17:34:34 +10:00
Andy Piper c8989837bc AP_HAL_ChibiOS: KakuteF4-Wing 2024-08-07 17:34:34 +10:00
Andy Piper 30ce705765 AP_HAL_ChibiOS: fix TMotor H743 with BMI270 2024-08-07 17:30:44 +10:00
Bob Long 078a86ad96 AP_Camera: fix altitude units in CAMERA_FOV_STATUS 2024-08-07 17:08:49 +10:00
Peter Barker b6426516b8 AP_HAL_SITL: work around bug in dash
dash doesn't search the path for scripts, so allow user to specify path to ArduPilot scripts
2024-08-07 17:03:52 +10:00
George Zogopoulos 1f01f75036 AP_NavEKF3: Corrected logged units 2024-08-07 17:02:28 +10:00
Nicole Ashley 126d54bc93 AP_Vehicle: Initialise i-BUS telemetry when enabled 2024-08-07 14:01:44 +10:00
Nicole Ashley e2c7b489a1 AP_OSD: Add i-BUS telemetry serial protocol value 2024-08-07 14:01:44 +10:00
Nicole Ashley 6f42acc01f AP_SerialManager: Add serial protocol for i-BUS telemetry 2024-08-07 14:01:44 +10:00
Nicole Ashley 8040e7c502 AP_IBus_Telem: Initial implementation
Allows telemetry data to be sent to receivers that support the
i-BUS protocol (FlySky and Turnigy).
2024-08-07 14:01:44 +10:00
Peter Barker 70b23733ac AR_Motors: make AP_Motors::PWMType enum class
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-06 18:15:35 +10:00
Peter Barker 70a1bc7606 AP_Motors: make AP_Motors::PWMType enum class
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-06 18:15:35 +10:00
Peter Barker a211b66472 AP_BLHeli: make AP_Motors::PWMType enum class
Co-authored-by: muramura <ma2maru@gmail.com>
2024-08-06 18:15:35 +10:00
Leonard Hall a4a9113cde AC_Autotune: Fix bug introduced in #27370 2024-08-06 17:45:04 +10:00
George Zogopoulos 9df4796b70 AP_Scripting: Typo fixes 2024-08-06 14:03:27 +10:00
Peter Barker bc80358e9b AP_Camera: rely on AHRS for position, not GPS
our location may not be coming from a GPS
2024-08-06 12:11:30 +10:00
Peter Barker b65a5a904c AP_SerialManager: tweak error message 2024-08-06 11:36:33 +10:00
Pradeep CK 0e53eb74df AP_ESC_Telem: addition of ESC extended status message
- Conditional compilation definition : AP_EXTENDED_ESC_TELEM_ENABLE
 - ESCX log structure
 - Update functionalities for ESCX status message
 - ESCX DroneCAN callback
2024-08-06 10:57:36 +10:00
Pradeep CK c7216c05b8 AP_DroneCAN: addition of ESC extended status message
- Conditional compilation definition : AP_EXTENDED_ESC_TELEM_ENABLE
 - ESCX log structure
 - Update functionalities for ESCX status message
 - ESCX DroneCAN callback
2024-08-06 10:57:36 +10:00
Peter Barker 516c2a853f hwdef: add named Pixhack-v3 board
allows for building this on the custom build server
2024-08-06 10:29:05 +10:00
Iampete1 c271771a1e AP_ICEngine: stop engine in E-Stop 2024-08-06 09:56:44 +10:00
Peter Barker cbdbbf436c AP_SerialManager: add warning iffrsky already configured 2024-08-06 09:46:56 +10:00
Peter Barker 6151b84c86 AP_LTM_Telem: disable LTM telemetry by default
we have a custom build server if this is required
2024-08-06 09:30:49 +10:00
Peter Barker cb57beaf8f AP_Hott_Telem: disable Hott telemetry by default
we now have a custom build server
2024-08-06 09:30:49 +10:00
YI-BOYANG 559a6e8f65 AP_HAL_ChibiOS: hwdef for GEPRCF745BTHD 2024-08-06 09:12:23 +10:00
Thomas Watson a164abaafb AP_Scripting: add REPL applet
Implements a reasonably comfortable REPL accessible over serial entirely
as a loadable script.

Also accessible over MAVLink using QGroundControl's MAVLink Console and
the new mavport module.
2024-08-06 09:08:04 +10:00
Thomas Watson 87d2b017aa AP_Scripting: add mavport module
Abstracts the MAVLink SERIAL_CONTROL message to be usable as a Lua port,
in particular the DEV_SHELL device supported by QGroundControl's MAVLink
Console.
2024-08-06 09:08:04 +10:00
Thomas Watson 5ec3313c31 AP_HAL: remove never-overridden get_shell_stream function
The only caller is now gone and nobody ever overrode it to do return
more than nullptr.
2024-08-06 09:08:04 +10:00
Thomas Watson abae008250 GCS_MAVLink: remove vestigial SERIAL_CONTROL_DEV_SHELL support
The HAL always returns nullptr so the function always returns, which is
handled already by the default.
2024-08-06 09:08:04 +10:00
Peter Barker 923b5185c6 AP_HAL_ChibiOS: rename OFFBOARD_GUIDED to AP_PLANE_OFFBOARD_GUIDED_SLEW_ENABLED
and remove comparison vs ENABLED
2024-08-05 10:20:14 +10:00
Peter Barker ba2bec07fa AP_HAL_ChibiOS: add env option to omit hwdef.dat from romfs 2024-08-05 10:20:14 +10:00
Andrew Tridgell 9543eecf23 HAL_ChibiOS: fixed AP_FILESYSTEM_ROMFS_ENABLED for peripherals with defaults.parm
now that defaults are in ROMFS we must enable
AP_FILESYSTEM_ROMFS_ENABLED
2024-08-04 17:36:31 +10:00
Andrew Tridgell 7bdb8d770d SRV_Channel: added AM32 to the SERVO_DSHOT_ESC param docs
setting 3 works well with AM32
2024-08-04 07:31:22 +10:00
Andrew Tridgell d48f9ef12c AP_Scripting: added example copter_deploy.lua 2024-08-03 14:29:51 +10:00
Andrew Tridgell ebad1631d7 AP_Scripting: added arm_force() and baro get_altitude_difference() 2024-08-03 14:29:51 +10:00
Andrew Tridgell 6a1d09959b AP_Arming: added arm_force() for scripting 2024-08-03 14:29:51 +10:00
EternAlmox 2ad7177a39 AP_HAL_ChibiOS: added MFT-SEMA100 2024-08-02 18:40:59 +10:00
Peter Barker bc1c305629 AP_HAL: default SITL and Linux to have 4MB of "flash" 2024-08-02 16:29:57 +10:00
Peter Barker 894b99fce5 AP_HAL: remove unused HAL_MINIMIZE_FEATURES define 2024-08-02 16:29:57 +10:00