How can I see this debug message in this way any idea anyone?

void SysWriteDebugConsole(const char* s) {
asm("mov r0, #0x04\n" // SYS_WRITE0
"mov r1, %[str]\n"
"bkpt #0xAB\n"
:
: [str] "r"(s)
: "r0", "r1");
}
void SysWriteDebugConsole(const char* s) {
asm("mov r0, #0x04\n" // SYS_WRITE0
"mov r1, %[str]\n"
"bkpt #0xAB\n"
:
: [str] "r"(s)
: "r0", "r1");
}
3 Replies
undefined2001
undefined2001•7d ago
Syswrite0 is mostly on semihosting debugging. Get debug tools Thanks man. I also found it now time to check if I can make it work You can use advance debugging tools like Ozone debugger that will allow you to do instruction tracing. Just note that you need J-Link debugger to use these tools. We'll cover such debugging topics in upcoming EH events jlink is expensive 🤧 i know, but do not buy the cheap chinese version, you'll waste your money. I tried many of them and they never really work, negative reliability.. if you don't have access to jlink but use an stm32 you could try stlink, they are cheaper and good for stm comes built in with nucleo board but saw there are some firmware to turn stlink into jlink Haven’t tried that that should be enough.. i wouldn't recommend to reflash a tool unless you have some spare time to debug it or for learning purposes.. a tool should be something you can trust, and hacking it is a miss and hit miss or hit
undefined2001
undefined2001•7d ago
ST-LINK On-Board
SEGGER offers a firmware upgrading the ST-LINK on-board on the Nucleo and Discovery Boards. All you need to know. Learn more at SEGGER.
undefined2001
undefined2001•7d ago
I think you're talking about jlink-ob firmware to be used with stlink relash utility to convert on board stlink to jlink it sound great. try it, if you want 😉 have you tried it before? yes does it work like a jlink? It's the same as official jlink and works the same, compatible with all their advance debugging s/w it’s flashing time almost all aspects are the same incl. flashing time. The only thing is when it's on-board jlink it'll not be used with other micro's apart from the one on the official board. We can break it of from nucleo board or is it limited by the particular MCU of that board ? yes, if you break it then you'll use as a normal stlink only can’t use jlink firmware after breaking? unfortunately no but connections are all same yes seger protecting their product :salute: @Umesh Lokhande ozone is really good it manages peripherals with good details debugging is really wonderful In a situation where basic debugging can't help I found s/w like ozone very effective it’s fast and responsive I'd like to add a few more advantages, such as helping to locate dead code and identifying code hotspots in a larger codebase I converted back into stlink I saw JLink education which seems affordable to me

Did you find this page helpful?