Skip to content

Conversation

cbrune
Copy link

@cbrune cbrune commented Aug 14, 2025

This patch strips leading '0x' from hex numbers (if present) returned by openocd for commands like mem2array and mrw.

Fixes: #560

With this patch, the issue described by #560 does not happen:

$ cargo xtask humility app/demo-stm32h7-nucleo/app-h753.toml -- tasks
    Finished `dev` profile [optimized + debuginfo] target(s) in 0.18s
     Running `target/debug/xtask humility app/demo-stm32h7-nucleo/app-h753.toml -- tasks`
humility: attached via OpenOCD
system time = 6695667
ID TASK                       GEN PRI STATE    
 0 jefe                         0   0 recv, notif: fault timer(T+33)
 1 sys                          0   1 recv, notif: exti-wildcard-irq(irq6/irq7/irq8/irq9/irq10/irq23/irq40)
 2 i2c_driver                   0   2 recv
 3 packrat                      0   2 recv
 4 spi_driver                   0   2 recv
 5 net                          0   2 recv, notif: eth-irq(irq61) wake-timer
 6 user_leds                    0   2 recv, notif: timer(T+334)
 7 user_button                  0   3 notif: button
 8 udpecho                      0   3 notif: socket
 9 udpbroadcast                 0   3 notif: bit31(T+1026)
10 udprpc                       0   3 notif: socket
11 hiffy                        0   5 notif: bit31(T+512)
12 hf                           0   4 notif: bit31(T+1037)
13 hash_driver                  0   3 recv
14 idle                         0   7 RUNNING
15 rng_driver                   0   3 recv
16 dump_agent                   0   4 recv

This patch strips leading '0x' from hex numbers (if present) returned
by openocd for commands like `mem2array` and `mrw`.

Fixes: oxidecomputer#560

Signed-off-by: Curt Brune <[email protected]>
@cbrune
Copy link
Author

cbrune commented Aug 14, 2025

lol, this is trying to solve the same issue as PR #500, which I didn't see before now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

humility does not expect 0x prefix on hex numbers from openocd

1 participant