Hi,
I have never used RTT, but looking at the code it looks like it is for
Cortex-M only!
With your SOC you are trying to use it on aarch64 CPUs. No idea if it is a
valid setup for RTT.

A set of commands "rtt server XXX" are registered in src/server/rtt_server.c
All other RTT commands, like "rtt setup XXX" used in your command line, are
registered through data in src/rtt/tcl.c, referenced in Cortex-M and HLA
code only.
The issue is not MacOS related, but a general use case.

Added in copy the original developer, for further comments.

Antonio



On Mon, Apr 1, 2024 at 5:04 AM G <ggs...@gmail.com> wrote:

> Both brew installed 0.12.0 and current git master built openocd fails
> setting up rtt. Debug -d3 output does not reveal more details. MacOS was at
> 12.7.4 on amd64. Identical behaviour on latest macOS on M3.
>
> src/openocd -s
> /usr/local/Cellar/open-ocd/0.12.0_1/bin/../share/openocd/scripts -f
> interface/jlink.cfg -f target/bcm2837.cfg  -c init -c targets  -c "rtt
> setup 0x20000 1000 \"SEGGER RTT\”"
>
>
> Open On-Chip Debugger 0.12.0+dev-01556-ga35e254c5 (2024-03-31-19:20)
> Licensed under GNU GPL v2
> For bug reports, read
>         http://openocd.org/doc/doxygen/bugs.html
> Info : auto-selecting first available session transport "jtag". To
> override use 'transport select <transport>'.
> Info : J-Link V11 compiled Mar 14 2024 13:16:08
> Info : Hardware version: 11.00
> Info : VTarget = 3.297 V
> Info : clock speed 4000 kHz
> Info : JTAG tap: bcm2837.cpu tap/device found: 0x4ba00477 (mfg: 0x23b (ARM
> Ltd), part: 0xba00, ver: 0x4)
> Info : [bcm2837.ap] Examination succeed
> Info : bcm2837.cpu0: hardware has 6 breakpoints, 4 watchpoints
> Info : [bcm2837.cpu0] Examination succeed
> Info : bcm2837.cpu1: hardware has 6 breakpoints, 4 watchpoints
> Info : [bcm2837.cpu1] Examination succeed
> Info : bcm2837.cpu2: hardware has 6 breakpoints, 4 watchpoints
> Info : [bcm2837.cpu2] Examination succeed
> Info : bcm2837.cpu3: hardware has 6 breakpoints, 4 watchpoints
> Info : [bcm2837.cpu3] Examination succeed
> Info : gdb port disabled
> Info : starting gdb server for bcm2837.cpu0 on 3333
> Info : Listening on port 3333 for gdb connections
> Info : starting gdb server for bcm2837.cpu1 on 3334
> Info : Listening on port 3334 for gdb connections
> Info : starting gdb server for bcm2837.cpu2 on 3335
> Info : Listening on port 3335 for gdb connections
> Info : starting gdb server for bcm2837.cpu3 on 3336
> Info : Listening on port 3336 for gdb connections
>     TargetName         Type       Endian TapName            State
> --  ------------------ ---------- ------ ------------------ ------------
>  0  bcm2837.ap         mem_ap     little bcm2837.cpu        unknown
>  1* bcm2837.cpu0       aarch64    little bcm2837.cpu        running
>  2  bcm2837.cpu1       aarch64    little bcm2837.cpu        running
>  3  bcm2837.cpu2       aarch64    little bcm2837.cpu        running
>  4  bcm2837.cpu3       aarch64    little bcm2837.cpu        running
> rtt
>   rtt server
>     rtt server start <port> <channel> [message]
>     rtt server stop <port>
>


Reply via email to