Ardupilot2/libraries
Michael du Breuil 5b961891ee AP_BattMonitor: Handle allocating too many analog channels
If you over allocate the number of analog channels this results in a
crash. It's easy to trigger this if you have voltage only monitors as we
still eat up a current input channel, regarless of if we use it. There
are only 16 channels at this time on ChibiOS, so if you have 9 voltage
only battery monitors you are out.

This PR improves that situation by only allocating channels when needed,
and in the case where we run out we now set a ConfigError, which on a
flight controller is much more friendly then a instant segfault the
moment we read a battery monitor. NOTE: on AP_Periph this takes the
node off the bus, rather then just sitting in the bootloader. This was
consideted acceptable as the current behaviour was to segfault and then
sit in the bootloader, unless you made new firmware that limited the
number of channels allocated it wasn't possible to recover in this
situation anyways.
2024-12-24 09:01:28 +09:00
..
AC_AttitudeControl AC_PosControl: add get_vel_target and get_accel_target 2024-12-18 18:28:12 +11:00
AC_Autorotation AC_Autorotation: Add RSC_Autorotation class 2024-10-11 09:54:26 +11:00
AC_AutoTune AC_AutoTune: fix tracking of maximum angular acceleration 2024-12-05 09:18:56 +09:00
AC_Avoidance AC_Avoidance: add missing include 2024-12-15 12:46:22 +11:00
AC_CustomControl AC_CustomControl: re-order initialiser lines so -Werror=reorder will work 2024-09-24 22:50:28 +10:00
AC_Fence AC_Fence: remember manual disable of fence for min-alt 2024-12-11 18:58:00 +11:00
AC_InputManager
AC_PID AC_PID: AC_P_2D comment fix 2024-10-04 09:25:56 +09:00
AC_PrecLand AC_PrecLand: remove assumption about how precland update method is called 2024-09-24 10:56:57 +09:00
AC_Sprayer AC_Sprayer: create and use an AP_Sprayer_config.h 2024-07-05 14:27:45 +10:00
AC_WPNav AC_Loiter: updates to offset handling 2024-10-04 09:25:56 +09:00
AP_AccelCal
AP_ADC AP_ADC: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
AP_ADSB AP_ADSB: add option to force Mode3AC Only 2024-12-14 22:51:11 -08:00
AP_AdvancedFailsafe AP_AdvancedFailsafe: fix singleton panic message 2024-12-15 23:38:24 +11:00
AP_AHRS AP_AHRS: return EAS from get_unconstrained_airspeed_EAS 2024-12-18 19:10:15 +11:00
AP_Airspeed AP_Airspeed: correct compilation when AP_AIRSPEED_AUTO_CAL_ENABLE is false 2024-12-17 11:32:55 +11:00
AP_AIS AP_AIS: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
AP_Arming AP_Arming: HAL_RUNCAM_ENABLED -> AP_CAMERA_RUNCAM_ENABLED 2024-12-13 11:07:09 +00:00
AP_Avoidance AP_Avoidance: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
AP_Baro AP_Baro: optimize DroneCAN subscription process 2024-11-18 10:30:29 +11:00
AP_BattMonitor AP_BattMonitor: Handle allocating too many analog channels 2024-12-24 09:01:28 +09:00
AP_Beacon AP_Beacon: allow hwdefs to override number of beacons 2024-08-26 13:48:02 +10:00
AP_BLHeli AP_BLHeli:correct RVMASK metadata 2024-10-08 20:58:16 +11:00
AP_BoardConfig AP_BoardConfig: add option to use IO safety led switch for ProfiLED 2024-11-20 19:12:44 +11:00
AP_Button
AP_Camera AP_Camera: remove lf from panic 2024-12-13 11:07:09 +00:00
AP_CANManager AP_CANManager: fixed critical race in log_text() 2024-12-14 15:41:38 +11:00
AP_CheckFirmware AP_CheckFirmware: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
AP_Common AP_Common: removed old MultiHeap code 2024-11-20 07:32:03 +11:00
AP_Compass AP_Compass: optimize DroneCAN subscription process 2024-11-18 10:30:29 +11:00
AP_CSVReader
AP_CustomRotations AP_CustomRotations: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
AP_DAL AP_DAL: document more replay messages 2024-10-15 10:46:45 +11:00
AP_DDS AP_DDS: remove superfluous linefeed from panic strings 2024-12-14 10:06:13 +11:00
AP_Declination
AP_Devo_Telem
AP_DroneCAN AP_DroneCAN: document CANS (Can Bus Statistics) log message 2024-12-15 15:17:55 +11:00
AP_EFI AP_EFI: optimize DroneCAN subscription process 2024-11-18 10:30:29 +11:00
AP_ESC_Telem AP_ESC_Telem: ensure that EDTv2 only gets logged when telemetry is available 2024-12-11 18:14:34 +00:00
AP_ExternalAHRS AP_ExternalAHRS: support backends with get_variances() 2024-10-23 06:46:59 +09:00
AP_ExternalControl AP_ExternalControl: arm through external control 2024-11-17 21:05:59 +11:00
AP_FETtecOneWire AP_FETtecOneWire: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
AP_Filesystem AP_Filesystem: Add details of withdefaults query param to README 2024-12-15 08:43:42 +11:00
AP_FlashIface
AP_FlashStorage AP_FlashStorage: remove superfluous linefeed from panic strings 2024-12-14 10:06:13 +11:00
AP_Follow AP_Follow: use set_alt_m when possible 2024-11-08 10:54:39 +11:00
AP_Frsky_Telem Ap_Frsky_Telem: fix for apparent wind passthrough telemetry frame 2024-11-27 13:46:37 +11:00
AP_Generator AP_Generator: apply -Os to all cpp files 2024-12-17 11:11:27 +11:00
AP_GPS AP_GPS: Cast enum to int to fix compiler warning when max enum value is less than the constant being compared to. 2024-12-15 15:16:21 +11:00
AP_Gripper AP_Gripper: correct emitting of grabbed/released messages 2024-06-20 10:59:14 +10:00
AP_GSOF AP_GPS: GSOF: Removed unused private members to fix Qurt compiler warnings 2024-11-19 12:26:55 +11:00
AP_GyroFFT AP_GyroFFT: move to new constant dt low pass filter class 2024-08-20 09:09:41 +10:00
AP_HAL AP_HAL: enable up to 3 CAN callbacks 2024-12-11 08:43:56 +11:00
AP_HAL_ChibiOS hwdef: reduce number of RCOU channels skyviper has 2024-12-24 08:07:10 +09:00
AP_HAL_Empty AP_HAL_Empty: removed run_debug_shell 2024-07-11 07:42:54 +10:00
AP_HAL_ESP32 AP_HAL_ESP32: drop spurious HAL_PARAM_DEFAULTS_PATH definition 2024-12-24 10:50:21 +11:00
AP_HAL_Linux AP_HAL_Linux: remove superfluous linefeed from panic strings 2024-12-14 10:06:13 +11:00
AP_HAL_QURT AP_HAL_QURT: Add support for the ModalAI IO board to support PWM ESCs 2024-12-16 13:03:50 +11:00
AP_HAL_SITL SITL: make SIM_ENGINE_FAIL a mask 2024-12-18 18:06:50 +11:00
AP_Hott_Telem AP_Hott_Telem: disable Hott telemetry by default 2024-08-06 09:30:49 +10:00
AP_IBus_Telem AP_IBus_Telem: Initial implementation 2024-08-07 14:01:44 +10:00
AP_ICEngine AP_ICEngine: fix send_text severities 2024-09-27 16:12:28 +10:00
AP_InertialNav AP_InertialNav: remove use of AP_AHRS from most headers 2024-09-03 10:35:54 +10:00
AP_InertialSensor AP_InertialSensor: do not read FIFO faster than requested rate for ICM45686 2024-12-18 19:05:20 +11:00
AP_InternalError AP_InternalError: remove superfluous linefeed from panic strings 2024-12-14 10:06:13 +11:00
AP_IOMCU IO_Firmware: update IOMCU firmware with profiled LED support over safety pins 2024-11-20 19:12:44 +11:00
AP_IRLock
AP_JSButton
AP_JSON AP_JSON: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
AP_KDECAN AP_KDECAN: standardize on 32 bit microsecond CAN timeouts 2024-10-11 09:51:43 +11:00
AP_L1_Control AP_L1_Control: make reached_loiter_target() more reliable 2024-10-01 07:15:44 +10:00
AP_Landing
AP_LandingGear AP_LandingGear: use GCS_SEND_TEXT rather than gcs().send_text 2024-08-07 18:33:16 +10:00
AP_LeakDetector AP_LeakDetector: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
AP_Logger AP_Logger: remove superfluous linefeed from panic strings 2024-12-14 10:06:13 +11:00
AP_LTM_Telem AP_LTM_Telem: disable LTM telemetry by default 2024-08-06 09:30:49 +10:00
AP_Math AP_Math: move zeroing to header, use memset, reuse in identity 2024-11-05 08:39:25 +09:00
AP_Menu AP_Menu: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
AP_Mission AP_Mission: DO_RETURN_PATH_START limit worst case runtime 2024-11-26 11:17:55 +11:00
AP_Module AP_Module: remove use of AP_AHRS from most headers 2024-09-03 10:35:54 +10:00
AP_Motors AP_Motors: create and use a singleton for SRV_Channels 2024-11-13 19:47:49 +11:00
AP_Mount AP_Mount: rearrange methods and variables per PR review 2024-12-16 19:16:25 +09:00
AP_MSP AP_MSP: MSP_RAW_GPS cog should be decidegrees not centidegrees 2024-09-13 12:45:22 +10:00
AP_MultiHeap AP_MultiHeap: added simple unit test 2024-11-20 07:32:03 +11:00
AP_NavEKF AP_NavEKF: add enumeration to document EKF SolutionStatus 2024-11-05 08:59:42 +09:00
AP_NavEKF2 AP_NavEKF2: apply -O2 to AP_NavEKFx.h 2024-12-17 11:18:54 +11:00
AP_NavEKF3 AP_NavEKF3: apply -O2 to AP_NavEKFx.h 2024-12-17 11:18:54 +11:00
AP_Navigation
AP_Networking AP_Networking: fix memory error generated by CAN mcast driver 2024-12-18 21:48:54 +11:00
AP_NMEA_Output
AP_Notify AP_Notify: add support for controlling ProfiLED via IOMCU safety pins 2024-11-20 19:12:44 +11:00
AP_OLC
AP_ONVIF AP_ONVIF: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
AP_OpenDroneID Copter: Give better error in opendroneid build when DID_ENABLE=0. 2024-09-17 09:17:24 +10:00
AP_OpticalFlow AP_OpticalFlow: optimize DroneCAN subscription process 2024-11-18 10:30:29 +11:00
AP_OSD AP_OSD: don't go via RCMap singleton to get RPTY RC channels 2024-09-17 22:10:53 +10:00
AP_Parachute AP_Parachute: remove AUX_FUNC entries based on feature defines 2024-09-08 00:55:43 +10:00
AP_Param AP_Param: remove superfluous linefeed from panic strings 2024-12-14 10:06:13 +11:00
AP_PiccoloCAN AP_PiccoloCAN: send incomming servo telem data to new AP_Servo_Telem lib 2024-12-03 07:38:17 +11:00
AP_Proximity AP_Proximity: prevent buffer overflow in LD06 driver 2024-12-19 22:58:29 +11:00
AP_Quicktune AP_Quicktune: adjust defaults 2024-11-27 14:07:38 +11:00
AP_Radio AP_Radio: remove superfluous linefeed from panic strings 2024-12-14 10:06:13 +11:00
AP_Rally
AP_RAMTRON
AP_RangeFinder AP_RangeFinder: alphabetise type parm docs 2024-11-25 20:28:18 +11:00
AP_RCMapper
AP_RCProtocol AP_RCProtocol: remove superfluous linefeed from panic strings 2024-12-14 10:06:13 +11:00
AP_RCTelemetry AP_RCTelemetry: add missing CRSF scheduler table entry 2024-12-05 10:03:27 -06:00
AP_Relay AP_Rely: allow RELAYn_DEFAULT values for DroneCAN Periphs 2024-11-15 10:57:31 -08:00
AP_RobotisServo AP_RobotisServo: Send register write values as little-endian 2024-09-27 11:53:06 +10:00
AP_ROMFS AP_ROMFS: clarify usage and null termination 2024-05-04 10:15:44 +10:00
AP_RPM AP_RPM: optimize DroneCAN subscription process 2024-11-18 10:30:29 +11:00
AP_RSSI AP_RSSI: make metadata more consistent 2024-07-02 11:34:29 +10:00
AP_RTC AP_RTC: correct logger documentation 2024-11-22 10:18:31 +11:00
AP_SBusOut
AP_Scheduler AP_Scheduler: log RTC into PM message 2024-11-21 09:19:38 +11:00
AP_Scripting AP_Scripting: added QUIK_ANGLE_MAX for lua quicktune 2024-12-22 07:09:31 +11:00
AP_SerialLED
AP_SerialManager AP_SerialManager: move serial port init of Volz protocol into Volz library 2024-12-17 09:14:08 +11:00
AP_Servo_Telem AP_ServoTelem: added active mask 2024-12-03 07:38:17 +11:00
AP_ServoRelayEvents
AP_SmartRTL AP_SmartRTL: add point made public 2024-07-24 17:22:44 +10:00
AP_Soaring AP_Soaring: Use constexpr instead of define for constants 2024-11-24 12:26:09 +11:00
AP_Stats
AP_SurfaceDistance AP_SurfaceDistance: re-order initialiser lines so -Werror=reorder will work 2024-09-24 22:50:28 +10:00
AP_TECS AP_TECS: Removed an unused variable to get rid of a compiler warning 2024-12-14 15:42:46 +11:00
AP_TempCalibration AP_TempCalibration: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
AP_TemperatureSensor AP_TemperatureSensor: optimize DroneCAN subscription process 2024-11-18 10:30:29 +11:00
AP_Terrain AP_Terrain: Add const to locals 2024-11-26 15:42:04 +11:00
AP_Torqeedo AP_Torqeedo: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
AP_Tuning
AP_Vehicle AP_Vehicle: remove runcam singleton 2024-12-13 11:07:09 +00:00
AP_VideoTX AP_Tramp: Fix _configuration_finished indication 2024-11-13 07:50:05 +11:00
AP_VisualOdom AP_VisualOdom: fix singleton panic message 2024-12-15 23:38:24 +11:00
AP_Volz_Protocol AP_Volz_Protocol: Moved member variable definition within proper #define block to prevent unused variable warning 2024-12-18 21:50:27 +11:00
AP_WheelEncoder AP_WheelEncoder: correct initialisation of WheelRateController objects 2024-09-24 10:46:34 +09:00
AP_Winch AP_Winch: correct compilation when backends compiled out 2024-08-12 18:28:27 +10:00
AP_WindVane AP_WindVane: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
APM_Control APM_Control: Correct use of deceleration 2024-11-04 11:55:28 +09:00
AR_Motors AR_Motors: make SRV_Channels::cork non-static 2024-11-13 19:47:49 +11:00
AR_WPNav AR_WPNav: re-order initialiser lines so -Werror=reorder will work 2024-09-24 22:50:28 +10:00
doc
Filter Filter: enable 4 filters on low-flash boards 2024-12-09 07:40:06 +11:00
GCS_MAVLink GCS_MAVLink: move sending of WATER_DEPTH into Rover code 2024-12-17 20:17:19 +11:00
PID
RC_Channel RC_Channel: add another 8 scripting aux functions 2024-12-14 15:41:57 +11:00
SITL SITL: default SIM_ENGINE_MUL to 0 2024-12-18 18:06:50 +11:00
SRV_Channel SRV_Channel: added get_output_pwm_chan() for scripting 2024-11-28 09:24:03 +11:00
StorageManager StorageManager: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
COLCON_IGNORE