5 Commits
Author SHA1 Message Date
scottp acd4263a06 0.4.0: builds on Zephyr 4.5 as well as 4.4
Zephyr 4.5 made uart_irq_update() return void, and the receive
interrupt used it as its loop condition, so 0.3.0 does not compile on
4.5. It is now called at the top of each pass, as Zephyr's own samples
do.

From 4.5 the ring buffer is header-only, and CONFIG_RING_BUFFER brings
back the deprecated legacy implementation. CONFIG_RB9704 selects it only
when KERNELVERSION is below 4.5. The rig bridge reads its ring with
ring_buf_peek() and ring_buf_get() in place of the claim API, and gates
the option the same way in a Kconfig of its own.

Tested on v4.4.0 and v4.5.0: 37 pass and 2 skip against the fake on
native_sim, and the sample, rigs and bridges build for every board.

Also in this release, from main since 0.3.0: rbtest in the shell sample,
rb9704_send_fill, and the Stamp-C3 overnight run. The README has a
section on the Zephyr versions; the standalone manifest pins v4.5.0;
the Python tools are 0.4.0.
2026-11-26 16:21:03 +11:00
scottp a70e933b71 0.3.0: provisioning and messages to Cloudloop work, and P_EN is active low
The M5Stamp-C3 under open sky, driven over WiFi from its shell, found
the modem provisioned with topics 244 and 313 to 317 and sent two
messages on topic 244, 16 and 17 bytes. Each was with the network 6 to
10 s after the modem took it, and both arrived in Cloudloop whole.
docs/CLOUDLOOP.md, "What has run", records how Cloudloop shows one: the
same bytes in Base64 and in hex.

P_EN is the RockBLOCK's supercapacitor charge enable, header pin 6, and
it is active low. The sample's overlays had it GPIO_ACTIVE_HIGH, so every
begin switched the charger off: the modem ran down and went silent 2 to
5 minutes later, four times indoors and out. The overlays, the README
and the binding now say GPIO_ACTIVE_LOW. With P_EN wired again on the
new firmware the modem stayed up past every earlier drop and sent the
second message.

The control pins follow Ground Control's start-up and shutdown
sequence. I_EN starts and stops the modem and is what makes the pins
present (CONFIG_RB9704_POWER follows iridium-enable-gpios); P_EN and
I_BTD are optional beside it. Shutdown drives I_EN low and waits for
I_BTD to go low before anything else, as start-up waits for it to go
high, so I_EN never moves back before I_BTD has followed. P_EN is driven
only while the modem runs and released to an input while it is off.

docs/boards/stamp_c3.md has the header's pin numbers, V_IN+ against
V_BATT, and P_EN as the cause of the drops. The module, the sample and
the Python tools are 0.3.0.
2026-10-25 22:48:11 +11:00
scottp 509b9b5b6d Power pins on by default, and a request slot that came back
CONFIG_RB9704_POWER's default read a DT_COMPAT_ variable nothing defined,
so it was never y on its own and the pins went undriven; define it.

A request that ended in -ETIMEDOUT of its own accord, a begin whose
modem never signalled booted, looked to the caller like one it had
abandoned, so neither side gave the slot back and every later call got
-EAGAIN. submit() now reports abandonment apart from the result.

On that boot timeout the supply and enable pins are dropped again, so the
next attempt starts from off. The CLI's messages named paths from the
tree it was carried over from.

Checked on native_sim: the suite against the fake, and begin twice with
the pins on the GPIO emulator, where the second begin now times out
instead of returning EAGAIN.
2026-10-21 22:38:00 +11:00
scottp 97affae86c Who made it, and why: author, credits, licence and support
The README says who wrote it and the two projects it was built for, WII6
and OGLAS, with their sites; credits Ground Control for the modem and
the library that does the protocol work; and gives the licence with
contact details, where to report issues and what helps in a report, and
that it is not a Ground Control product. The licence, every source file
and the Python package's metadata carry the copyright and email; the
package lists its homepage, repository, issues and changelog.
2026-10-09 13:16:30 +11:00
scottp c0e92a7f02 The module: Ground Control's library on Zephyr, with one worker thread
Ground Control's RockBLOCK 9704 library is pinned untouched in west.yml
and compiled here for any board with a UART: a serial port on the bus of
the rock7,rockblock-9704 devicetree node, the library's timing calls on
the kernel, and one worker thread that owns every call into it, since the
library has no locking and shares static buffers.

The worker sleeps until a request or a byte from the modem arrives.
Requests (begin, end, power, send, info, signal) wait as long as the
caller says; a send with K_NO_WAIT queues and reports through mo_done.
Callbacks for a sent message, a received one, the signal and the
provisioning; a status snapshot that never touches the modem.

The library asks for provisioning once and keeps a miss for good; the
worker clears its cache before a send whose topic is missing and after
the modem refuses one, so a modem provisioned later is seen.

The serial port and worker began in the OGLAS satellite bench and were
carried through WII6's lib/wii6-sat.
2026-10-09 12:48:16 +11:00