10 Commits
Author SHA1 Message Date
scottp 04554deaeb v0.7.2: battery monitor not-available values as NAN
Version bump for the release of 560ea24.
2026-11-11 13:23:28 +11:00
scottp 560ea24f60 Battery monitor: "not available" values decode as NAN
Each battery monitor field has a reserved "not available" raw value:
voltage 0x7FFF, aux 0xFFFF, current 0x3FFFFF, consumed Ah 0xFFFFF and
SOC 0x3FF. The parser decoded them as readings, so an unsynchronised
shunt reported SOC 102.3 % and an unavailable current came out as
-0.001 A after sign extension. They are now NAN in the C core.
Time-to-go stays an integer, with 0xFFFF named VICTRONBLE_TTG_NA. The
Arduino wrapper maps the new NANs to 0, as it already did for aux.

Adds a host test vector with every field not available, and notes in
the README that a battery monitor has now been decoded live on Zephyr
(ESP32-S3, Heltec WiFi LoRa 32 V3).
2026-11-11 13:13:57 +11:00
scottp 318e221170 v0.7.1: rename C core header to victronble_core.h (fixes #2)
src/ held both VictronBLE.h and victronble.h. On case-insensitive
filesystems (Windows, macOS) extracting the library ZIP overwrote one
with the other and the Arduino build failed.

The core header is now victronble_core.h in include/ and src/, and every
include is updated. include/victronble.h stays as a deprecated forwarder
so 0.7.0 Zephyr and host code still builds; it is never in src/.

check_version.sh now fails if two tracked paths differ only in case.
2026-10-09 12:54:06 +11:00
scottp 22af47854d Examples and samples ready for Zephyr release 2026-08-26 00:58:57 +10:00
scottp b390c0d579 v0.7.0: pure C core + Zephyr module
- Extract all decode/decrypt into a dependency-free C99 core
 (include/victronble.h, src/victronble_core.c): victronble_decode(),
 is_product_adv/key_matches pre-filters, NAN sentinels, LE accessors.
- AES-128-CTR behind a hook: weak-symbol bundled tiny-AES default,
 runtime override (victronble_set_aes_ctr) for PSA/mbedTLS/hardware.
- Arduino VictronBLE class becomes a thin wrapper over the core
 (registry + nonce dedup + rate limit); public C++ API unchanged,
 NAN converted back to the legacy 0 convention.
- Host test vectors (tests/vectors): openssl-generated ciphertext,
 independent of the bundled AES; all five payload shapes + negatives.
- Zephyr module: zephyr/module.yml + Kconfig (CONFIG_VICTRONBLE) +
 observer backend (victronble_zephyr.{h,c}) — scan cb pre-filters and
 queues, dedicated decode thread, listener callbacks, slow passive
 scan defaults, stats counters. docs/ZEPHYR_PORT.md records the plan.
- library.properties: fix URL (gitea, not the nonexistent GitHub).
2026-08-21 11:59:19 +10:00
scottp 6c30e0d01d Branch version ready for testing with nRF52 2026-06-04 23:47:55 +10:00
scottp 0791fd8cec Bug fixes for reported issues 2026-06-04 21:21:18 +10:00
scottp 3a0adfab82 Versions v0.4 ready for release 2026-02-28 14:38:30 +11:00
scottp 4aa386a5da Keep v0.3.1 2026-02-12 18:10:35 +11:00
scottp d760e7d8dc Initial version only 2025-12-18 17:53:39 +11:00