dapjs icon indicating copy to clipboard operation
dapjs copied to clipboard

RTT example - allow empty lines too

Open fanoush opened this issue 1 year ago • 1 comments

It is typical to just press enter to see if console input is working, I was very confused that nothing happens so connected to my device via UART to produce some output to RTT, and only after I found it working I had an idea to actually type some text before pressing enter.

BTW I could not test it but hopefully it works, I cloned repo and set up github pages but when trying at https://fanoush.github.io/dapjs/examples/rtt/web.html the page gets 404 on https://fanoush.github.io/dapjs/dist/dap.umd.js Not sure how I should put stuff to "dist"

EDIT: now I tested it by committing directly to my gh-pages branch and it seems to work

fanoush avatar Sep 05 '24 11:09 fanoush

And BTW I have also added some other stuff to the RTT example, not sure if you would be interested in some of them? you may check https://github.com/ARMmbed/dapjs/compare/gh-pages...fanoush:dapjs:gh-pages

  • faster ram searching
  • direct character mode
  • adding VID for Raspberry Pi Pico debugprobe - which is cheap and capable CMSIS-DAP v2 debugger anyone can make from spare RP2040/Pico board
  • avoid CPU halt/reset this should not be needed for RTT at all and it interferes with device that is already running something

I am testing it with Espruino build with interactive console over RTT and it seems to work pretty well. Character mode allows tab completion, ctrl+c break etc

The IRQ button change is not that useful but in case of Espruino it wakes device from sleep when activating the console after first keypress, unfortunately Segger RTT is designed to be polled from both sides instead if triggering interrupt when data comes so there is no way to wake the device otherwise. After first input espruino imlementation starts polling timer so then it works until RTT console is deactivated.

fanoush avatar Sep 08 '24 12:09 fanoush

Thanks for your PR and sorry for the delay...

thegecko avatar Oct 19 '24 17:10 thegecko