Commit Graph

1030 Commits

Author SHA1 Message Date
Andrew Tridgell f1c6538f34 AP_HAL_Linux: use NEW_NOTHROW for new(std::nothrow) 2024-06-04 09:20:21 +10:00
Patrick José Pereira 34f5579699 AP_HAL_Linux: Remove message about base address
The value is the same as in the match

Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
2024-05-13 10:46:58 -03:00
Patrick José Pereira 6016e411e0 AP_HAL_Linux: Add support to Raspberry Pi 5
The Raspberry Pi 5 has a coprocessor that takes care of the IO over the BCM.
This adds support to the new RP1 processor.

Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
2024-05-13 10:46:58 -03:00
Patrick José Pereira 3f451b9f4c AP_HAL_Linux: Util_RPI: Add message about unknown board
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
2024-05-13 10:46:58 -03:00
Patrick José Pereira 4af6142933 AP_HAL_Linux: Util_RPI: Add support to RPI5 identification
Signed-off-by: Patrick José Pereira <patrickelectric@gmail.com>
2024-05-13 10:46:58 -03:00
Peter Barker 599ff17f34 AP_HAL_Linux: fix SPIUARTDriver to work with GPS autodetection
GPS auto-detection requires get_baud_rate to return non-zero.  The SPIUARTDriver was returning 0.
2024-05-08 17:13:58 +10:00
Peter Barker 7319422d6c AP_HAL_Linux: remove unused RC input methods
these protocols have come from AP_RCProtocol for years
2024-05-07 09:49:48 +10:00
Oleksiy Protas cadd121401 Bounds correctness for AnalogIn_IIO 2024-04-16 09:14:55 +10:00
Oleksiy Protas 364e6f06f3 AP_HAL_Linux: delay signal handlers setup
Allow default signals before full initialization in Linux, this makes sure we don't get an unkillable process if it hangs on initialization

Exit flag marked volatile to counteract possible compiler optimization due to the handler code running in a different context
2024-04-05 11:36:29 +11:00
Andrew Tridgell cfad74ce6b AP_HAL_Linux: fixed get_baud_rate() 2024-02-29 11:00:40 +11:00
Peter Barker df3267c9ba waf: remove SKETCH and SKETCHNAME from build sysmte
... renaming one of them to AP_BUILD_TARGET
2024-02-26 15:42:25 +11:00
Richard Allen bf1d364201 HAL_Linux: reduce delay(ms) jitter
Fix delay(1) rarely returning immediately.
On my RPi4, this once per 5-20k calls that worked.

Reduce the last call to microsleep according to the
remaining time needed in the last loop iteration.
2024-02-26 09:15:52 +11:00
Andrew Tridgell 1f2b9df290 HAL_Linux: fixed float calc of time for onboard flow 2024-02-06 07:31:21 +11:00
Andrew Tridgell 45ca3ad4bb HAL_Linux: fixed time function to use integer maths
avoid floating point rounding errors after long uptimes.

thanks to Richard (RSAXVC) for finding this
2024-02-06 07:31:21 +11:00
Andrew Tridgell 34c737de36 HAL_Linux: use SocketAPM_native 2024-01-03 12:14:47 +11:00
Andrew Tridgell 931bae5b88 AP_HAL_Linux: use SocketAPM_native 2024-01-03 12:14:47 +11:00
Andrew Tridgell ce6adcfe83 AP_HAL_Linux: added PRIORITY_NET 2024-01-03 12:14:47 +11:00
Peter Barker 7e51811a24 AP_HAL_Linux: cope with HAL_WITH_DSP being false 2024-01-03 11:45:31 +11:00
Andrew Tridgell 8f8048e4cd HAL_Linux: reimplement CAN with BinarySemaphore 2024-01-03 07:37:05 +11:00
Andrew Tridgell bdb8a08724 HAL_Linux: implement BinarySemaphore 2024-01-03 07:37:05 +11:00
Thomas Watson e460a19b17 AP_HAL_Linux: deprecate and warn on legacy --uartX option use 2023-12-19 06:53:15 +11:00
Thomas Watson f34034584f AP_HAL_Linux: eliminate internal legacy UART ordering/references
Leave the legacy command line arguments to avoid breaking users.
2023-12-19 06:53:15 +11:00
Thomas Watson 764b469e47 AP_HAL_Linux: pass UARTs to AP_HAL in SERIALn order 2023-12-19 06:53:15 +11:00
Ka Ru ce177a3637 AP_HAL_Linux: add can-zero board 2023-12-05 07:41:06 -06:00
Thomas Watson 8fe95dca81 AP_HAL_Linux: introduce get_HAL_mutable() to complement get_HAL()
Returns a mutable reference to the same HAL for certain purposes where
the HAL needs to be mutated to avoid UB problems with casting away const
and to make the fact that mutation is happening obvious.
2023-11-28 08:24:25 +11:00
Willian Galvani d33facd884 AP_HAL_Linux: add newline and remove stray semicolon 2023-10-31 20:34:24 -03:00
Willian Galvani 60a38a0ab1 AP_HAL_Linux: set bw_in_bytes_per_second default to 10/100Mbps connection 2023-10-31 11:00:28 +11:00
Andrew Tridgell cb62e48164 HAL_Linux: use the AP_RCProtocol sbus decoder for Linux 2023-10-13 09:42:25 +11:00
Richard Allen c8f9d193fb AP_HAL_Linux: make all semaphores priority-inherit 2023-09-06 15:58:58 -05:00
Andrew Tridgell 559e85df11 HAL_Linux: inherit CAN stats structure
this allows for the last_transmit_us field
2023-09-05 06:56:51 +10:00
Andrew Tridgell aaa2746bff AP_HAL_Linux: added last_transmit_us to CAN stats 2023-09-05 06:56:51 +10:00
Willian Galvani e82949d241 AP_HAL_Linux: update Navigator available GPIOs
The comment was wrong. gpio 26 is actually used for the PCA Output Enable signal.
This also adds GPIO18, which is the one broken out to the PWM0 pin
2023-09-04 18:06:37 +10:00
Andrew Tridgell 51af21f6d9 HAL_Linux: removed ESC scaling, moved to AP_HAL 2023-08-24 13:06:40 +10:00
Andrew Tridgell 8ed289a514 AP_HAL_Linux: removed native_millis/micros 2023-08-24 13:06:40 +10:00
Andrew Tridgell 25761c3a8e AP_HAL_Linux: moved UART port locking up to AP_HAL 2023-07-12 17:06:02 +10:00
Peter Barker 9ee6be8a55 AP_HAL_Linux: fix help ouput from Options to Examples 2023-06-17 17:51:34 +10:00
Neil Bertram dcafaf3ab2 AP_HAL_Linux: Improve the self-documentation and configuration of serial ports for the Linux HAL 2023-06-17 14:46:27 +10:00
Mohammad Hefny 9314163bb0 AP_HAL_Linux: Fix RPI check using enumerations 2023-06-17 14:44:38 +10:00
acxz 7aa8347374 AP_HAL_Linux: remove std:: scope from uint16_t 2023-05-17 11:15:43 +10:00
Andy Piper b5d7d06886 AP_HAL_Linux: QSPI -> WSPI 2023-04-28 08:31:15 +10:00
Andrew Tridgell d5effcdf92 AP_HAL_Linux: change to 16 bit timeout in event interface
prevent issues on 16 bit timers where we can end up with TIME_INFINITE
2023-04-19 17:26:57 +10:00
bugobliterator ee310433e5 AP_HAL_Linux: add option to use vitual CAN in linux 2023-03-29 17:16:39 +11:00
Peter Barker a10f5dbd0a AP_HAL_Linux: 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
Richard Allen 90cbb6ad26 AP_HAL_Linux: Update GPIO and RCInput for pi version change
Update version numbers according to earlier change.

Fixes: 53c1c235b8
2023-02-22 21:10:04 -08:00
Richard Allen 693068e68a AP_HAL_Linux: more rpi initialization checks
Check more mmap() call sites for failure and exit.
Also exit when starting on an unknown board.
2023-02-22 21:10:04 -08:00
Andrew Tridgell deb86be1da AP_HAL_Linux: added old_size to heap_realloc 2023-01-16 09:19:16 +11:00
Andrew Tridgell 03f4ab515d AP_HAL_Linux: check for alloc failure of ObjectBuffer 2023-01-08 15:11:32 +11:00
Mohammad Hefny feece150c6 AP_HAL_Linux: Raspberry 64OS Address fix 2022-12-27 10:03:41 +11:00
Willian Galvani 5ae3f96cbe AP_HAL_Linux: add LEAK probe pin to Navigator gpio whitelist 2022-11-08 09:46:50 -03:00
Willian Galvani c607c38cbf AP_HAL_Linux: add missing header to RCInput_RCProtocol.cpp
This fixes muslhf linux build
2022-09-28 18:38:33 -03:00