Commit Graph

397 Commits

Author SHA1 Message Date
Peter Barker
3c46db5261 AP_Periph: rename ins locals to avoid conflict with ins member variable 2023-08-01 11:37:14 +10:00
Andrew Tridgell
7e91de33a4 AP_Periph: update release notes for 1.5.1 2023-07-23 09:02:13 +10:00
Andrew Tridgell
1696464bac AP_Periph: make uCenter ublox fw update more reliable
ensure we have a big enough UART buffer and do locking
2023-07-18 11:38:27 +10:00
Andrew Tridgell
946840cc99 AP_Periph: added targetted tunnel message for CAN serial passthru
this allows for remote control of serial devices over DroneCAN
2023-07-12 17:06:02 +10:00
bugobliterator
b6605f5877 AP_Periph: add CAN and Protocol statistics send 2023-07-10 12:56:37 +10:00
Peter Barker
30dea46cc5 AP_Periph: make canard_broadcast non-static
so it can be used from other files in AP_Periph
2023-07-05 14:37:51 +10:00
Peter Barker
0f1de63d7c AP_Periph: move ADSB CAN handling into adsb.cpp 2023-07-05 14:37:51 +10:00
Andrew Tridgell
a7d51898da AP_Periph: raise CAN priorty of MovingBaseline data
and raise CAN buffer size for lots of movingbaseline data
2023-06-27 10:32:43 +10:00
Peter Barker
e8ada7f4ee Tools: add and use AP_AHRS_ENABLED 2023-06-21 22:28:48 +10:00
Peter Barker
77da6cf2b7 AP_Periph: supply buffer for decoding ADSB messages 2023-06-21 17:50:31 +10:00
bugobliterator
f391445eaf AP_Periph: move sysid_my_gcs to be public 2023-06-17 14:49:22 +10:00
Peter Barker
5a33f870c0 Tools: use HAL_PROXIMITY_ENABLED in place of HAL_PERIPH_ENABLE_PRX
boolean truth rather than defines, and simplifies code
2023-06-08 11:53:01 +10:00
Michael du Breuil
3fd2865857 Tools: AP_Periph: fix building of hwesc telem
This was broken by the APD support
2023-05-31 15:08:01 +10:00
Michael du Breuil
e2d0cc55d0 AP_Periph: Support APD ESC telemetry 2023-05-25 17:35:27 -07:00
Michael du Breuil
584a1f8c49 Tools: AP_Periph: Reduce the priority of outdoing ADS-B messages
We consume these at line rate from the transciever, don't allow this to
cause unnecessary congestion on the bus, as it may be used for flight
critical functions. A more proper solution would be to behave more like
the actual AP_ADSB library, and simple rate limit how often we send any
updates out to the host device, as well as filtering for distance, but
that requires more information then is currently readily available.
2023-05-25 16:59:32 -07:00
Peter Barker
274379ea8a AP_Periph: include AP_ESC_Telem header
... since we insantiate one of these we should include its header
2023-05-09 10:56:13 +10:00
Peter Barker
6c29079a76 AP_Periph: correct includes
we instantiate SerialManager - best include its header!
2023-05-09 10:56:13 +10:00
Peter Barker
ddcfe5e734 Tools: move and rename CAN Driver_Type enumeration 2023-04-20 08:53:46 +10:00
Peter Barker
95d8719465 Tools: remove CANTester 2023-04-18 11:43:58 +10:00
Peter Barker
eb2a4a68c5 AP_Periph: use CopyFieldsFrom in CAN parameters 2023-04-18 11:43:58 +10:00
Tom Pittenger
34a990d2ff AP_Periph: add AP_KDECAN support 2023-04-17 11:52:52 +10:00
Andrew Tridgell
c7231240c8 Tools: rename more variables, types and defines 2023-04-11 10:31:31 +10:00
Andrew Tridgell
7b4e4889c7 AP_Periph: use generated decoder for FW update and actuators 2023-04-10 14:46:54 +10:00
Andrew Tridgell
119b0b15f1 AP_Periph: cope with mixed bxCAN and CANFD packets
this allows for runtime switching of CANFD enable, while supporting
incoming bxCAN packets in CANFD mode
2023-04-10 14:46:54 +10:00
Andrew Tridgell
e6d6848fb1 AP_Periph: prepare for 1.5.0 release 2023-03-27 07:36:19 +11:00
Andrew Tridgell
7f66e35459 AP_Periph: release notes for 1.5.0 2023-03-27 07:35:41 +11:00
Peter Barker
ba3aa0c158 AP_Periph: add and use a "bool read(c)" method to AP_HAL
this is much less likely to not work vs the int16_t equivalent
2023-03-22 17:59:11 +11:00
Iampete1
8b36fde0c1 AP_Periph: fix proximity parameter path 2023-03-21 11:41:18 +11:00
Peter Barker
7995bc5175 Tools: add and use option to compile SLCAN support out of code 2023-03-15 19:08:09 +11:00
Andrew Tridgell
2781f65d56 AP_Periph: limit peripheral mag to 25Hz by default
we only read mag on the vehicles at 10Hz. Some magnetometers were
reporting data at 500Hz (see MMC5xx3 driver)

by sampling more slowly the data is accumulated and averaged on the
node which saves a lot of bandwidth
2023-03-06 17:24:29 -08:00
Andrew Tridgell
a4a52c3e8c AP_Periph: cope with peripherals with i2c only rangefinders
if no uart then still check for non-uart sensors
2023-03-06 19:48:07 +11:00
Andrew Tridgell
d3bf7fc946 AP_Periph: rename CAN_PROBE_CONTINUOUS to AP_PERIPH_PROBE_CONTINUOUS 2023-03-06 19:48:07 +11:00
Tom Pittenger
223b91f6b4 Periph: fix sending GPS Heading packet at correct interval 2023-02-25 03:23:07 -08:00
Henry Wurzburg
59a5babc06 AP_Periph:Add SLCAN feature note 2023-02-24 09:22:34 +11:00
rishabsingh3003
32a0c8935e AP_Periph: Fix hwesc telem temp units 2023-02-22 07:12:47 +11:00
Pierre Kancir
b7b08c3487 AP_Periph: add patch rev into firmware version 2023-02-08 12:47:49 +11:00
Tom Pittenger
95b4ded3e8 AP_Periph: add AP_NMEA_Output to Periph 2023-02-07 21:12:07 +11:00
rishabsingh3003
59bc3cff93 AP_Periph: Allow user to change serial port for HW Telem 2023-01-25 18:15:28 +11:00
Iampete1
43e5ea43b7 Tools: AP_Periph: use shared Param info defines 2023-01-11 18:41:34 +11:00
Peter Barker
65915441b6 Tools: make check_var_info void
Given all the callers die anyway, make it void
2023-01-10 10:48:15 +11:00
Iampete1
bba1d0b9d9 AP_Periph: rename airspeed param group to match vehicles 2023-01-03 10:17:56 +11:00
Iampete1
cb6891821e AP_Periph: always call airspeed init to allow param conversion 2023-01-03 10:17:56 +11:00
Andrew Tridgell
69cb6796f3 AP_Periph: send GNSS Heading message
if not sending RelPosHeading then send Heading message if we have yaw
2022-12-20 10:23:58 +11:00
Andrew Tridgell
dcab2d2f2a AP_Periph: cope with GPS without yaw accuracy 2022-12-20 10:23:58 +11:00
Peter Barker
d438c8e127 AP_Periph: code-generate chan-fetching methods
A recent PR had to change every single one of these methods, which was kind of unfortunate.

So generate the methods using a #define so the duplication happens at preprocessor-time.
2022-12-15 08:31:54 +11:00
rishabsingh3003
27f55ae626 AP_Periph: Add proximity support 2022-12-15 07:20:05 +11:00
James O'Shannessy
11ab5e3f3d AP_Periph: Adds a parameter to allow for user configurable timeout
Timeout defaults to 200ms. Timeout can be disabled by setting parameter to 0. Timeout should be configured to be able to handle at small number of missed packets.
2022-12-03 13:55:01 +11:00
James O'Shannessy
4679cb4265 AP_Periph: Add timeout to ESC driving when CAN packets are lost
Fixes a periph continuing to drive an ESC to an output when the esc_rawcommand packets are lost
2022-12-03 13:55:01 +11:00
bugobliterator
3ec938fae6 waf: add dynamic source option to ap_stlib 2022-11-16 18:05:59 +11:00
bugobliterator
e4ada09fc3 waf: use bld for dronecangen export headers for including 2022-11-16 18:05:59 +11:00
Tom Pittenger
4e94046a4a AP_Periph: can_printf() to send longer strings using multiple packets 2022-10-23 21:47:42 -07:00
Tom Pittenger
3f4755ea7b AP_Periph: add support for AP_TemperatureSensor 2022-10-18 10:05:31 +11:00
Tom Pittenger
53e0c4175e AP_Periph: add support for SLCAN 2022-10-11 11:26:40 +11:00
Tom Pittenger
0767640372 AP_Periph: fix periph-heavy build, wscript 2022-10-11 11:20:50 +11:00
Peter Barker
3cbd018877 AP_Periph: correct build for EFI can
no longer an array
2022-10-05 18:03:59 +11:00
Andrew Tridgell
aa757501f4 AP_Periph: removed the old DroneCAN Fix message
only send/process Fix2 message, saving bus bandwidth and flash space
2022-09-28 17:27:32 +10:00
Andrew Tridgell
304d7472ff AP_Periph: update release notes for 1.4.1 2022-09-28 07:24:27 +10:00
Andy Piper
8ee5c8735d AP_Periph: delegate dshot configuration to BLHeli. Make esc telemetry output rate configurable
correct SRV_Channel initialization order to get ESC masks correct
2022-09-20 09:45:03 +10:00
Peter Barker
25c3665277 Tools: populate sysid/compid in reboot ACK 2022-09-14 20:16:38 +10:00
Andrew Tridgell
31cac4395f AP_Periph: support actuator type with PWM
this makes debugging much easier in CAN analyser
2022-09-13 16:23:44 +10:00
bugobliterator
939bd94796 AP_Periph: make constants used in bitshift unisigned 2022-09-08 13:37:55 +10:00
bugobliterator
3e8355638b AP_Periph: add support for redundant CAN bus 2022-09-08 13:37:55 +10:00
Andrew Tridgell
1fab01951a AP_Periph: build fix 2022-09-05 12:35:37 +10:00
Andrew Tridgell
a92cb1017e AP_Periph: report unsigned bootloader flash attempt 2022-09-05 12:35:37 +10:00
Andrew Tridgell
4bed47cbb0 AP_Periph: raise master version to 1.5 dev 2022-09-04 15:15:22 +10:00
Andrew Tridgell
c5fb666b0f AP_Periph: release notes for 1.4.0 2022-09-04 15:14:27 +10:00
Andrew Tridgell
a4fa99c96c AP_Periph: fixed undulation in Fix2 pkt 2022-08-28 11:43:01 +10:00
Andrew Tridgell
2637f87409 AP_Periph: ensure we don't send inf in Fix and Fix2 for GPS 2022-08-28 11:43:01 +10:00
Andrew Tridgell
5fd9891880 AP_Periph: release notes for 1.4.0beta1 2022-08-27 15:55:55 +10:00
Andrew Tridgell
2f3fe19aca AP_Periph: use AP_CheckFirmware 2022-08-15 09:18:34 +10:00
Andrew Tridgell
cc2589777f AP_Periph: pass correct WGS84 height on GPS peripherals 2022-08-10 05:04:18 +10:00
bugobliterator
c4b182978a AP_Periph: add support for starting sitl periph in maintenance mode 2022-07-27 18:18:03 +10:00
bugobliterator
cdb14bd75d AP_Periph: enlarge CANARD pool for CANFD messages 2022-07-27 18:18:03 +10:00
Iampete1
18351186db AP_Periph: set defualt format version 2022-07-20 17:59:59 +10:00
Peter Barker
4561e78dd5 AP_Periph: include GCS_MAVLink.h for firmware version type define 2022-07-16 17:15:52 +10:00
Andrew Tridgell
5a36d7cf0a AP_Periph: fixed non-contiguous mask for ESC telem output
this fixes the case where a peripheral node has an ESCs that are not
starting at the first channel. Reported here:

https://discuss.ardupilot.org/t/using-matekl431-adapters-for-pwm-and-dshot/85781/22

tested on MatekL431-Periph
2022-06-15 18:16:22 +10:00
Randy Mackay
b9f4998fd8 AP_Periph: remove ToshibaCAN from param descriptions 2022-06-10 12:08:05 +09:00
Andrew Tridgell
f728894eec AP_Periph: added EFI support 2022-06-09 21:10:37 +10:00
Andrew Tridgell
25d231187f AP_Periph: added RNGFND_MAX_RATE parameter
prevent duplicate samples and allow setting of maximum rate we sample
rangefinder
2022-06-09 16:51:56 +10:00
Pradeep
80e2533cf0 AP_Periph: node stats
- Added new config parameter object - STAT
 - init and update statistics
2022-06-07 09:57:32 +10:00
Pradeep
183352cdfe AP_Periph: choose node stats - build files
Added - AP_Stat library and AP_STATS_ENABLED build options
2022-06-07 09:57:32 +10:00
Andrew Tridgell
5e184e167c AP_Periph: allow peripherals to handle servos beyond 16 2022-05-22 12:07:37 +10:00
Andrew Tridgell
10d7a559d2 AP_Periph: 32 servo conversion 2022-05-22 12:07:37 +10:00
Andrew Tridgell
406de11fe9 AP_Periph: mark ESC DShot channels as digital
this allows them to get the right default MIN and MAX values on the
channels
2022-04-28 13:56:41 +10:00
Andrew Tridgell
227e82053a AP_Periph: fixed GPS dropout on F4 and L4 GPS nodes
we need more time for other threads on these nodes or we will end up dropping GPS frames
2022-04-18 14:40:53 +10:00
Andrew Tridgell
fbc9b771d1 AP_Periph: updated release nodes for 1.3.1 2022-04-15 13:48:31 +10:00
bugobliterator
7f5dc33e7e AP_Periph: allow can_printf as periph member method as well 2022-03-23 18:59:43 +11:00
Andrew Tridgell
994e1e0c0a AP_Periph: mark version as 1.4.0dev 2022-03-18 21:16:13 +11:00
Andrew Tridgell
59456b4f82 AP_Periph: updated release notes for 1.3.0 2022-03-18 21:14:07 +11:00
Andrew Tridgell
116c692e2b AP_Periph: rename ReleaseNotes.txt
be consistent with plane and copter
2022-03-18 21:14:04 +11:00
bugobliterator
29673de4f3 AP_Periph: add parameters for setting up FD Bitrates 2022-03-11 18:13:54 +11:00
Siddharth Purohit
8a8de73d89 AP_Periph: add support for CANFD trx 2022-03-11 18:13:54 +11:00
bugobliterator
068208e4d7 AP_Periph: add debug option for hold in bootloader after 15s 2022-03-11 18:13:54 +11:00
Andrew Tridgell
0853accea1 AP_Periph: fixed moving baseline yaw for single CAN peripherals
the AP_GPS_UAVCAN driver requires this param for auto-config of MB yaw
on DroneCAN GPS
2022-03-09 07:52:42 +11:00
Andrew Tridgell
335ab3aac1 AP_Periph: fixed build 2022-02-22 12:13:19 +11:00
Andrew Tridgell
94d02faf37 AP_Periph: fixed build for include changes 2022-02-22 12:13:19 +11:00
Nathan Costa
a867e04116 AP_Periph: airspeed add support for CAN/I2C switch and LED 2022-02-16 13:25:58 +11:00
Peter Barker
a81a1fb19f Tools: build ArduPilot against all.xml not ardupilotmega.xml 2022-02-08 11:00:41 +11:00
Peter Barker
b7df2bce5f Tools: provide default implemenation of handle_change_alt_request
The TODO items to actually implement these are almost 6 years old.
Since then these methods have been burning space.

This doesn't even make sense for several vehicles, so a default
implementation which does nothing seems OK.
2022-02-08 10:59:13 +11:00
Joshua Henderson
2ea33324a0 AP_Periph: add define for BARO_ENABLE 2022-02-08 10:41:02 +11:00
Joshua Henderson
0339f09b07 AP_Periph: use AP_PERIPH_RANGEFINDER_PORT_DEFAULT 2022-02-02 18:45:59 +11:00
Andrew Tridgell
c2dd7f4c9e AP_Periph: fixed LED setup call 2022-01-27 08:26:47 +11:00
bugobliterator
9469817e03 AP_Periph: send epoch time for both message and GNSS timestamp 2022-01-20 17:26:35 +11:00
Joshua Henderson
92aff3bded AP_Periph: use airspeed.set_log_bit() 2022-01-19 18:21:32 +11:00
Peter Barker
ef11400e13 Tools: make C_TO_KELVIN a function macro; create KELVIN_TO_C
These are in celsius
2022-01-13 18:31:46 +11:00
Andrew Tridgell
d62e946d48 AP_Periph: fixed temperature reporting
more common to have ESC temp than motor temp, so report ESC
temperature
2021-12-28 16:30:14 +11:00
Shiv Tyagi
d1eedcb4c3 AP_Periph: remove PacketDitial from AP_CANManager parameter description
We have removed the class AP_BattMonitor_MPPT_PacketDigital, we should also remove these
2021-12-17 20:24:25 +09:00
Peter Barker
1d4b13af08 AP_Periph: correct compilation when both periph-adsb and GCS enabled
Get lots of these otherwise:

/home/pbarker/gcc/gcc-arm-none-eabi-10.3-2021.07/bin/../lib/gcc/arm-none-eabi/10.3.1/../../../../arm-none-eabi/bin/ld: lib/libAP_Periph_libs.a(GCS_MAVLink.cpp.0.o): in function `mavlink_parse_char':
GCS_MAVLink.cpp:(.text.mavlink_parse_char+0x0): multiple definition of `mavlink_parse_char'; Tools/AP_Periph/adsb.cpp.41.o:adsb.cpp:(.text.mavlink_parse_char+0x0): first defined here
/home/pbarker/gcc/gcc-arm-none-eabi-10.3-2021.07/bin/../lib/gcc/arm-none-eabi/10.3.1/../../../../arm-none-eabi/bin/ld: lib/libAP_Periph_libs.a(GCS_MAVLink.cpp.0.o): in function `put_bitfield_n_by_index':
GCS_MAVLink.cpp:(.text.put_bitfield_n_by_index+0x0): multiple definition of `put_bitfield_n_by_index'; Tools/AP_Periph/adsb.cpp.41.o:adsb.cpp:(.text.put_bitfield_n_by_index+0x0): first defined here
2021-12-14 10:35:06 +11:00
Andrew Tridgell
75959450ca AP_Periph: cope with GCS enabled for ESC telem
thanks Tom!
2021-12-10 08:11:24 -08:00
Andrew Tridgell
d239bf99bd AP_Periph: enable use of AP_ESC_Telem in peripheral nodes
give ESC status packets back for RPM, voltage, current etc
2021-12-10 08:11:24 -08:00
Andrew Tridgell
91424c1f03 AP_Periph: enable DShot ESC telemetry 2021-12-10 08:11:24 -08:00
Andrew Tridgell
d34579c275 AP_Periph: allow build with ESC telemetry and BLHeli support 2021-12-10 08:11:24 -08:00
Andrew Tridgell
62b03bd1f1 AP_Periph: removed PWM count check for servos
actuator IDs are tied to OUTn_FUNCTION, not to physical output IDs, so
it is perfectly possible for an actuator ID to be larger than the
number of PWM outputs on the board
2021-12-07 10:23:54 +11:00
Andrew Tridgell
b916e8cceb AP_Periph: fixed param docs for ESC_PWM_TYPE 2021-12-07 10:23:54 +11:00
Andrew Tridgell
9ee140cbbf Tools: revert compass parameter changes 2021-12-04 16:51:53 +11:00
Iampete1
7c116c84c6 Periph: remove compass params underscore 2021-11-30 08:14:43 +09:00
bugobliterator
f74690af49 AP_Periph:libcanard moved to modules/DroneCAN 2021-11-24 18:30:47 +11:00
bugobliterator
4e067a68e2 AP_Periph: move to using dronecan instead of uavcan 2021-11-24 18:30:47 +11:00
Peter Barker
8ae1a58eae Tools: move from ENABLE_SCRIPTING to AP_SCRIPTING_ENABLED 2021-11-15 20:27:40 +11:00
Peter Barker
32374d1614 Tools: ensure ENABLE_SCRIPTING is always defined 2021-11-15 20:27:40 +11:00
Andrew Tridgell
bebb722d02 waf: improve error messages for lack of dsdlc and empy 2021-10-20 19:05:01 +11:00
bugobliterator
f74550bce5 AP_Periph: update notify state decode to use current dsdlc code 2021-10-14 20:13:06 +11:00
bugobliterator
6b44bc3e4c AP_Periph: use methods from new canard dsdl generator 2021-10-14 20:13:06 +11:00
Tom Pittenger
a7686de92b AP_Periph: fix GCS/mavlink for additional serialports 2021-09-30 14:55:01 +10:00
bugobliterator
8a4b9c2b36 AP_Periph: add support for handling Notify State message 2021-09-30 08:52:27 +10:00
Pierre Kancir
6e9ea663e5 AP_Periph: temp fix for -Wcast-align until we fix the generator 2021-09-29 17:27:29 +10:00
Peter Barker
76e2db952b Tools: move from HAL_NO_GCS to HAL_GCS_ENABLED 2021-09-22 21:37:00 +10:00
Willian Galvani
901164a317 AP_Periph: update to use capacity_remaining_pct() as a bool 2021-09-08 17:17:41 +10:00
Andrew Tridgell
6e33910c25 AP_Periph: use a longer loop delay on non-H7
the short delay broke the F412 based CUAV_GPS
2021-09-02 21:56:03 +10:00
Andrew Tridgell
4169656176 Tools: added MCU_STATUS message 2021-08-25 07:11:31 +10:00
bugobliterator
90c9fb7804 AP_Periph: manage separate transfer ids for different transfer desc 2021-08-19 14:20:58 +10:00
bugobliterator
bb65ab83be AP_Periph: reduce Rx latency by reading while sitting in delay 2021-08-19 14:20:58 +10:00
bugobliterator
aa9a40acf5 AP_Periph: add a way to transmit MovingBaseline Data on another port 2021-08-19 14:20:58 +10:00
bugobliterator
54f03b9b64 AP_Periph: add support for moving baseline heading 2021-08-19 14:20:58 +10:00
bugobliterator
acab1478a2 AP_Periph: fix build error 2021-08-12 07:57:12 +10:00
bugobliterator
1d81eb5c47 AP_Periph: fix checking compass available before init 2021-08-11 07:47:56 +10:00
Andrew Tridgell
0ea26b4d3a AP_Periph: fixed float16 conversions for scalars
libcanard does already convert scalars, but doesn't convert arrays. By
calling fix_float16 on scalers we were double converting, which
reduced resolution.
2021-08-05 19:04:41 +10:00
Andrew Tridgell
37935262ff AP_Periph: fixed formatting errors 2021-08-05 09:43:35 +10:00
Andrew Tridgell
751b901ed9 Tools: fixed printf format errors 2021-08-05 09:43:35 +10:00
Peter Barker
d40587062e AP_Periph: use AP::compass().available in place of enabled() 2021-07-30 12:19:42 +10:00
bugobliterator
6f3e3a913a AP_Periph: fix dna wait blink 2021-07-28 17:09:41 +10:00
bugobliterator
35d94b17eb AP_Periph: add support for MAVLink for HerePro 2021-07-26 13:45:43 +10:00
Andrew Tridgell
299b3ef200 AP_Periph: fixed msp gps yaw
build failed with 10.2 compiler, but is a real bug
2021-07-25 21:00:09 +10:00
bugobliterator
ef48d706ed AP_Periph: do not wait for DNA to finish before starting AP_Periph 2021-07-14 15:18:42 +10:00
bugobliterator
a9fda29d42 AP_Periph: remove return res from canard_broadcast 2021-07-14 15:18:42 +10:00
bugobliterator
64c41e51ba AP_Periph: use range for loop instead of indexed for loops 2021-07-14 15:18:42 +10:00
Siddharth Purohit
3ed53c58e9 AP_Periph: provide separate instances of canard objects per iface 2021-07-14 15:18:42 +10:00
Siddharth Purohit
637ccf13df AP_Periph: add MAVLink support for AP_Periph modules 2021-07-02 08:50:16 +10:00
Siddharth Purohit
f9a50e8e47 AP_Periph: allow building InertialSensor and related libraries 2021-06-30 17:06:02 +10:00
Tom Pittenger
4d0f5a1db6 AP_Periph: add support for multiple protocols on AP_Periph 2021-06-09 18:36:18 +10:00