Commit Graph

66562 Commits

Author SHA1 Message Date
Peter Barker
7ce9ec2c61 AP_HAL: add and use linux_hwdef.py
like chibios_hwdef.py - but for Linux
2025-02-19 15:42:52 +11:00
Peter Barker
d31889854c chibios_hwdef.py: prune out unused hal.i2c_mgr parsing code
we have GET_I2C_DEVICE now-adays
2025-02-19 15:42:52 +11:00
Henry Wurzburg
20fe36a8c3 ArduPlane: add AUTOLAND AUX Function
fix
2025-02-19 10:51:25 +11:00
Henry Wurzburg
984409ca82 RC_Channel: add AUTOLAND AUX Function 2025-02-19 10:51:25 +11:00
Leonard Hall
ab59a00ae1 Tools: Add Jervis_Bay to locations 2025-02-18 19:15:15 +11:00
Randy Mackay
fc479fdd7a Tools: NanoRadar MR72 and Hexsoon Radar build options 2025-02-18 16:38:12 +09:00
Randy Mackay
ebbf3998b6 AP_Proximity: add Hexsoon radar support 2025-02-18 16:38:12 +09:00
Randy Mackay
7fbad0bea3 AP_Arming: integrate NanoRadar to RadarCAN rename 2025-02-18 16:38:12 +09:00
Randy Mackay
0abb0a70f0 AP_RangeFinder: integrate RadarCAN rename 2025-02-18 16:38:12 +09:00
Randy Mackay
4f3981ce27 AP_CANManager: rename NanoRadar to RadarCAN 2025-02-18 16:38:12 +09:00
Iampete1
9da6be2ef8 RC_Channel: Document EKF lane switch and yaw reset aux functions. 2025-02-18 14:19:51 +09:00
Thomas Watson
7a6861e28d AP_Filesystem: FATFS: drop tty check logic
In Standard C, the first three file descriptors are usually standard in,
out, and error. However, ArduPilot doesn't have a concept of this and
other backends (such as LittleFS) don't bother to reject them.

Remove this logic to simplify implementation and allow use of more open
files.
2025-02-18 12:33:37 +11:00
Iampete1
9fccccbb3d Tools: AP_Periph: SIM: servo telem move to one indexed 2025-02-18 11:51:34 +11:00
Peter Barker
5fcac2b304 SITL: add instructions for testing MaxSonarI2CXL in SITL 2025-02-18 11:34:10 +11:00
Peter Barker
fd1ade76ca SITL: clamp rangefinder distance to 0m
our starting positions are often underground
2025-02-18 11:34:10 +11:00
Peter Barker
e348c6e7a3 AP_Rangefinder: avoid OwnPtr for MaxSonarI2CXL I2CDevice 2025-02-18 11:34:10 +11:00
Peter Barker
97df89c9fe Tools: tidy build_autotest.sh script
uses pushd rather than multiple cd calls

indents for clarity

removes unused oldhash assignment

create and make use of intermediate variables
2025-02-18 11:20:31 +11:00
abaghiyan
9893017f3c AP_TECS: Corrected formula for _TASmin according to fix in formula for the load factor
To connect loadFactor to airspeed we can use formula of balancing between lift force and gravity force:
liftForce = loadFactor * gravityForce; on the other hand lift force can be expressed as
liftForce = 0.5 * lifCoefficient * airDensity * sq(airspeed) * referenceArea; minimum airseepd is at loadFactor = 1
and lift force only balances the gravit force, so gravity force (which is same as lift force at minimum airspeed) with minimum airspeed can be expressed as
gravityForce = 0.5 * lifCoefficient * airDensity * sq(airspeed_min) * referenceArea; substituting gravit force in previous formula gives us
0.5 * lifCoefficient * airDensity * sq(airspeed) * referenceArea = loadFactor * 0.5 * lifCoefficient * airDensity * sq(airspeed_min) * referenceArea;
from where we get:
loadFactor = sq(airspeed / airspeed_min); and_TASmin should be
_TASmin *= safe_sqrt(_load_factor);
2025-02-18 10:53:06 +11:00
abaghiyan
26cbdd9a4c Plane: Fixed formula for load factor
In general when there the pitch and roll exist the formula for the aerodynamic load factor should be as follows:
aerodynamic_load_factor = cosf(radians(_ahrs.pitch))/cosf(radians(demanded_roll));
which in case of turns (in the horizontal plane) becomes
aerodynamic_load_factor = 1.0f/cosf(radians(demanded_roll));
formulas can be obtained from equations of balanced spiral:
liftForce * cos(roll) = gravityForce * cos(pitch);
liftForce * sin(roll) = gravityForce * lateralAcceleration / gravityAcceleration; // as mass = gravityForce/gravityAcceleration
see issue #24320 [#24320].
To connect loadFactor to airspeed we can use formula of balancing between lift force and gravity force:
liftForce = loadFactor * gravityForce; on the other hand lift force can be expressed as
liftForce = 0.5 * lifCoefficient * airDensity * sq(airspeed) * referenceArea; minimum airseepd is at loadFactor = 1
and lift force only balances the gravit force, so gravity force (which is same as lift force at minimum airspeed) with minimum airspeed can be expressed as
gravityForce = 0.5 * lifCoefficient * airDensity * sq(airspeed_min) * referenceArea; substituting gravit force in previous formula gives us
0.5 * lifCoefficient * airDensity * sq(airspeed) * referenceArea = loadFactor * 0.5 * lifCoefficient * airDensity * sq(airspeed_min) * referenceArea;
from where we get:
loadFactor = sq(airspeed / airspeed_min);
These changes also require changes in ardupilot/libraries/AP_TECS/AP_TECS.cpp
Line 418 (according to the comments by Peter Hall): _TASmin *= _load_factor; should be changed to _TASmin *= safe_sqrt(_load_factor);

See details here: #24320
2025-02-18 10:53:06 +11:00
Randy Mackay
1f3279c1bd Plane: 4.6.0-beta4 release notes 2025-02-17 20:40:13 +09:00
Randy Mackay
775a0fabf2 Copter: 4.6.0-beta4 release notes 2025-02-17 20:40:12 +09:00
Randy Mackay
a06d318ce8 Rover: 4.6.0-beta4 release notes 2025-02-17 20:40:09 +09:00
Randy Mackay
16f2628ba8 Tracker: 4.6.0-beta4 release notes 2025-02-17 20:40:07 +09:00
Peter Barker
b65892448b Tools: build_autotest.sh: allow use of more modern timelimit command
command-line has changed (if indeed this is the same command!)

Regardless, autotest server has some grandfathered binary in place in $HOME/bin/timelimit and we do want to move past it at some stage
2025-02-17 20:19:03 +11:00
Peter Barker
f4122811f8 Vagrant: add autotest server VM 2025-02-17 20:19:03 +11:00
SULILG
59e0f5cc84 AP_HAL_ChibiOS : add SULILGH7 board 2025-02-17 19:50:16 +11:00
Wdiy
cdd6622dfb Tools: add SULILGH7 board 2025-02-17 19:50:16 +11:00
Iampete1
9427b81366 Tools: move from MAV_MODE enum to uint8_t 2025-02-17 17:20:24 +11:00
Iampete1
2730777785 Rover: move from MAV_MODE enum to uint8_t 2025-02-17 17:20:24 +11:00
Iampete1
c07863f6cd Blimp: move from MAV_MODE enum to uint8_t 2025-02-17 17:20:24 +11:00
Iampete1
77b8d90226 ArduSub: move from MAV_MODE enum to uint8_t 2025-02-17 17:20:24 +11:00
Iampete1
aef376f1c7 ArduPlane: move from MAV_MODE enum to uint8_t 2025-02-17 17:20:24 +11:00
Iampete1
57555bb815 ArduCopter: move from MAV_MODE enum to uint8_t 2025-02-17 17:20:24 +11:00
Iampete1
4ea719e017 AntennaTracker: move from MAV_MODE enum to uint8_t 2025-02-17 17:20:24 +11:00
Iampete1
494af643b5 GCS_MAVLink: move from MAV_MODE enum to uint8_t 2025-02-17 17:20:24 +11:00
Iampete1
a74f0b35c7 RC_Channel: add docs for copter inflight trim 2025-02-17 17:15:10 +11:00
Thomas Watson
ec7ece3a4d AP_Filesystem: littlefs: drop singleton 2025-02-17 16:33:51 +11:00
Thomas Watson
ca3c2c7c72 AP_Logger: File: take advantage of new optimal fsync API
Now FATFS will always sync on 4K boundaries even if it gets misaligned
due to a short or forced write.

LittleFS behavior is verified identical.
2025-02-17 16:33:51 +11:00
Thomas Watson
ed2c42ede2 AP_Filesystem: new API for performing optimal fsyncs 2025-02-17 16:33:51 +11:00
Thomas Watson
182646a7e4 AP_Filesystem: littlefs: debug warn of misaligned fsyncs 2025-02-17 16:33:51 +11:00
Randy Mackay
a6c2c1527b AP_Mount: CADDX RC rate control fix 2025-02-17 13:39:44 +09:00
Shiv Tyagi
3d96c7e419 AP_HAL_ChibiOS: create and use AP_PERIPH_NETWORKING_ENABLED 2025-02-17 09:55:51 +11:00
Shiv Tyagi
222f3ceefd Tools: use AP_PERIPH_NETWORKING_ENABLED for HAL_PERIPH_ENABLE_NETWORKING 2025-02-17 09:55:51 +11:00
Shiv Tyagi
15376a4908 AP_HAL_ChibiOS: replace AP_PERIPH_AIRSPEED_ENABLED with HAL_PERIPH_ENABLE_AIRSPEED 2025-02-16 10:11:10 +11:00
Shiv Tyagi
0248f0d5d8 Tools: replace HAL_PERIPH_ENABLE_AIRSPEED with AP_PERIPH_AIRSPEED_ENABLED 2025-02-16 10:11:10 +11:00
Thomas Watson
fb8f3488d5 AP_Filesystem: littlefs: fix lseek
lseek must return the current file position. Previously, the littlefs
version always returned 0, which broke terrain I/O as it checks that the
position returned is the one it seeked to. Fix to return the current
position, which is correctly returned from littlefs.

This problem was originally and incorrectly diagnosed as an issue with
littlefs seeking past the end of the file, but this functionality works
fine and fixing the incorrect return completely fixes terrain.

Terrain functionality was verified using `TERRAIN_DEBUG` on
KakuteH7Mini-Nand running sim on HW. Terrain data is correctly
downloaded from the GCS and loaded from the filesystem after reboot.
2025-02-14 13:29:12 +01:00
Andy Piper
a23f9cd754 AP_Bootloader: SpeedyBee board ids 2025-02-13 11:25:33 +01:00
Andrew Tridgell
f1a7abb31b AP_BLHeli: fixed documentation for SERVO_BLH_3DMASK and SERVO_BLH_RVMASK
they can be combined on both BLHeli32 and AM32
2025-02-13 11:22:50 +01:00
Shiv Tyagi
8655d013c6 AP_RPM: use AP_PERIPH_RPM_ENABLED and AP_PERIPH_RPM_STREAM_ENABLED 2025-02-13 20:29:06 +11:00
Shiv Tyagi
abc605c7e4 Tools: u AP_PERIPH_RPM_ENABLED and AP_PERIPH_RPM_STREAM_ENABLED 2025-02-13 20:29:06 +11:00