Wykres commitów

15 Commity (master)

Autor SHA1 Wiadomość Data
jgromes cb9cb87556 [HAL] Make ArduinoHal constructor explicit 2024-05-01 15:41:24 +01:00
Elizabeth Myers 205031550b
Use RadioLibTime_t (aka unsigned long) when dealing with millis() and micros() (#1075)
* Use unsigned long when dealing with millis() and micros().

Although sizeof(uint32_t) == sizeof(unsigned long) on Arduino, this is
not the case on 64-bit Linux, where sizeof(unsigned long) ==
sizeof(uint64_t).

Most timestamp arithmetic and comparisons have been left alone, to
reduce code churn. This is fine, as uint32_t is perfectly wide to store
most timestamp deltas this library will deal with, and C will promote
the integer rather than do a narrowing conversion. The real problem
arises with narrowing conversions being done by assuming timestamps are
32-bit.

No functional changes intended for platforms where sizeof(uint32_t) ==
sizeof(unsigned long) (so most 8/16/32-bit platforms).

Signed-off-by: Elizabeth Myers <elizabeth.jennifer.myers@gmail.com>

* Change most timestamps to use RadioLibTime_t.

This makes it obvious what is and isn't a timestamp.

Not everything has been converted; anything dealing with protocol and
chip-level timestamps has been left alone on purpose, to make it clear
that these functions do require 32-bit timestamps.

No functional changes intended on platforms where sizeof(uint32_t) ==
sizeof(unsigned long).

Signed-off-by: Elizabeth Myers <elizabeth.jennifer.myers@gmail.com>

* Use uint32_t internally in getTimeOnAir.

We need to not overflow the integers with the shifts and
multiplications, so this is correct behaviour.

Signed-off-by: Elizabeth Myers <elizabeth.jennifer.myers@gmail.com>

---------

Signed-off-by: Elizabeth Myers <elizabeth.jennifer.myers@gmail.com>
2024-04-25 21:50:58 +02:00
Jonathan Bennett e5493618a4
Update ArduinoHal.h to make spi and friends protected (#1044)
Most of the "override" functions here can't actually be overridden in a useful way when spi, spiSettings, and everything else is marked private. If everything is override, then nothing should be private.
2024-03-31 21:43:30 +02:00
StevenCellist ca2a3073b9
[LoRaWAN] Change and upgrade persistence handling (#1017)
* [LoRaWAN] Change and upgrade persistence handling

* [BuildOpt] Patch to upstream

* [LoRaWAN] Fix #1018

* [LoRaWAN] Remove outdated parts

* [LoRaWAN] Resolve feedback

Warning: untested - am not at my desk

* [LoRaWAN] Small bugfixes
2024-03-18 08:51:38 +01:00
jgromes a2e2003001 Reworked macro configuration system 2023-11-27 19:38:10 +01:00
jgromes 414e338505 Fixed ESP32 platform detection 2023-08-29 21:57:51 +02:00
jgromes e486829b8f [HAL] Implemented basic persistent storage 2023-07-06 11:19:18 +02:00
jgromes a01b02fae2 [MOD] Rework for buffered SPI (#776) 2023-06-26 19:36:45 +02:00
jgromes 7a99aa0ef4 [HAL] Use compact Doxygen and stop using reserved format 2023-04-22 18:53:30 +02:00
jgromes 876081958b [HAL] Doxygen comments fix 2023-04-22 18:22:46 +02:00
jgromes 09c3ac4f6b [HAL] Formatting cleanup, added doxygen comments 2023-04-22 18:11:00 +02:00
jgromes 37bb8af768 [HAL] Fixed formatting 2023-04-22 18:08:08 +02:00
Mestery 9a68a3c901 use uint32 instead of uint8 for pin type 2023-04-16 21:39:00 +02:00
Mestery 6695133576 fix documentation 2023-04-16 21:10:57 +02:00
Mestery ec3d4eaf20 Improve hardware abstraction layer 2023-04-12 23:16:18 +02:00