Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.forth > #135369

Re: Techman is back after a few years away being very busy with embedded Forth

From Terry Porter <techman001@eternal-september.org>
Newsgroups comp.lang.forth
Subject Re: Techman is back after a few years away being very busy with embedded Forth
Date 2026-08-19 04:01 +0000
Organization A noiseless patient Spider
Message-ID <11639rb$2bqra$1@dont-email.me> (permalink)
References <115t48v$eq20$1@dont-email.me> <11622ob$v1c9$2@paganini.bofh.team>

Show all headers | View raw


On 2026-08-18, Waldek Hebisch <antispam@fricas.org> wrote:
> Terry Porter <techman001@eternal-september.org> wrote:
>> 
>> Regmon is a live register monitor for STM32 microcontrollers. It reads
>> the chip's registers over SWD while the target runs -- no stop, no re-
>> flash -- and decodes them against the official CMSIS-SVD files. Works
>> alongside a running Mecrisp Forth kernel on the same debug link, so you
>> can watch RCC/GPIO/timer registers change as your Forth words execute.
>> Registers, bitfields and an AI-assisted analysis pane. Linux, Python.
>> 
>> Three buttons you will not find on any other register tool:
>> 
>> Analyse Reg samples one register about twenty times over ten seconds
>> and the AI tells you what that register is actually doing while the
>> chip runs.
>> 
>> Analyse Prog fingerprints the whole chip -- it reads the RCC clock
>> gates and the dynamic registers, samples the program counter and
>> stack pointer, and the AI gives a verdict on what the program is
>> doing, live, without stopping the core. That is the unusual bit:
>> conventional microprocessor tools freeze the chip at a breakpoint
>> to inspect it, or need a logic analyser strapped to the pins.
>> Analyse Prog works on a running target over the same SWD link the
>> Forth kernel is using -- no halt, no re-flash, no extra hardware.
>
> What target do you mean here?  Arbitrary non-cooperating target
> or Forth extended by your routines?
>
From: antispam@fricas.org (Waldek Hebisch)
Newsgroups: comp.lang.forth
Subject: Re: Techman is back after a few years away being very busy
 with embedded Forth

Terry Porter <techman001@eternal-september.org> wrote:
>
> Regmon is a live register monitor for STM32 microcontrollers. It reads
> the chip's registers over SWD while the target runs -- no stop, no re-
> flash -- and decodes them against the official CMSIS-SVD files. Works
> alongside a running Mecrisp Forth kernel on the same debug link, so you
> can watch RCC/GPIO/timer registers change as your Forth words execute.
> Registers, bitfields and an AI-assisted analysis pane. Linux, Python.
>
> Three buttons you will not find on any other register tool:
>
> Analyse Reg samples one register about twenty times over ten seconds
> and the AI tells you what that register is actually doing while the
> chip runs.
>
> Analyse Prog fingerprints the whole chip -- it reads the RCC clock
> gates and the dynamic registers, samples the program counter and
> stack pointer, and the AI gives a verdict on what the program is
> doing, live, without stopping the core. That is the unusual bit:
> conventional microprocessor tools freeze the chip at a breakpoint
> to inspect it, or need a logic analyser strapped to the pins.
> Analyse Prog works on a running target over the same SWD link the
> Forth kernel is using -- no halt, no re-flash, no extra hardware.

What target do you mean here?

Arbitrary non-cooperating target or Forth extended by your routines?

Re: Techman is back - what target does Regmon actually work on?

Waldek, good question - and the honest answer is: both, depending on
which part of the tool you mean.

The register reads themselves are non-cooperating. Reading
RCC/GPIO/timer registers goes over the ST-Link's SWD debug port - a
mem read is a debug-port read, full stop. It works on any target,
running or halted, whether it's Mecrisp, C, or a bare chip with
nothing flashed. No cooperation needed. There's a C-mode of the swdd
daemon that skips all the Forth machinery and just serves mem/reg
to an arbitrary target.

Where it does depend on the kernel is the no-halt live channel - the
part that makes it interesting. The "watch a register change while
your Forth word runs, no breakpoint, no re-flash" trick is built on
the SWD ring buffer that Mecrisp-Stellaris maintains. The kernel
actively services that ring as part of its inner loop, so swdd can
exchange data with it without halting the core. That's genuine
cooperation - it only works because Mecrisp is designed that way. A C
firmware that doesn't service a ring buffer won't give you that
zero-intrusion live channel.

So the truthful split:

- Low-level register reads (the mem path): any target,
  non-cooperating, via the debug port.
- Analyse Reg / Analyse Prog live sampling (the "watch it run" path):
  needs a Mecrisp kernel servicing the ring buffer - that's the
  cooperating case, and honestly it's the case the tool is built
  around.

On "no halt" specifically: reading PC and SP via the debug port's
core-register access does work while the core runs, but on a
non-cooperating target it can stall the core briefly and it's nowhere
near as clean. The continuous, genuinely zero-intrusion sampling is
the Mecrisp ring-buffer path. I'd rather say that plainly than pretend
it's magic.

It's an STM32-specific tool (CMSIS-SVD register descriptions, roughly
sixty families), Linux, Python, and it shares the debug link with the
running Forth kernel - same ST-Link, no contention.

Back to comp.lang.forth | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread


Thread

Techman is back after a few years away being very busy with embedded Forth Terry Porter <techman001@eternal-september.org> - 2026-08-16 19:49 +0000
  Re: Techman is back after a few years away being very busy with embedded Forth antispam@fricas.org (Waldek Hebisch) - 2026-08-18 16:54 +0000
    Re: Techman is back after a few years away being very busy with embedded Forth Terry Porter <techman001@eternal-september.org> - 2026-08-19 04:01 +0000
  Re: Techman is back after a few years away being very busy with embedded Forth Kragen Javier Sitaker <kragen@canonical.org> - 2026-08-28 18:12 -0300
    Re: Techman is back after a few years away being very busy with embedded Forth Terry Porter <techman001@eternal-september.org> - 2026-08-30 01:47 +0000

csiph-web