NishanthMenon changed the topic of #openocd to: this is the place to discuss all things OpenOCD | Logs: https://libera.irclog.whitequark.org/openocd/
cozycactus has quit [Quit: Connection closed for inactivity]
tsal_ has joined #openocd
tsal has quit [Ping timeout: 252 seconds]
Hawk777 has joined #openocd
nerozero has joined #openocd
tsal_ has quit [Ping timeout: 248 seconds]
tsal has joined #openocd
Haohmaru has joined #openocd
Hawk777 has quit [Quit: Leaving.]
joconor has quit [Ping timeout: 252 seconds]
joconor has joined #openocd
slobodan has joined #openocd
Deneb has joined #openocd
Deneb has quit [Quit: Leaving]
renrelkha has quit [Quit: bye]
renrelkha has joined #openocd
slobodan has quit [Remote host closed the connection]
slobodan has joined #openocd
slobodan has quit [Read error: Connection reset by peer]
slobodan has joined #openocd
slobodan has quit [Read error: Connection reset by peer]
slobodan has joined #openocd
slobodan has quit [Read error: Connection reset by peer]
slobodan has joined #openocd
slobodan has quit [Read error: Connection reset by peer]
slobodan has joined #openocd
slobodan has quit [Read error: Connection reset by peer]
slobodan has joined #openocd
slobodan has quit [Read error: Connection reset by peer]
slobodan has joined #openocd
slobodan has quit [Read error: Connection reset by peer]
slobodan has joined #openocd
<sys64738> re: SAML11: looks like using a jlink mini instead of an FT4232 does make connecting to the CPU work, though flashing doesn't work (openocd fails at resetting the CPU, apparently). using the jlink software does make everything work. so in any case, there is *something* not working properly in openocd's support for the SAML11
<sys64738> (same result again across 0.11.0, 0.12.0, and git commit edf2c82cf)
<Haohmaru> i think afaik jlink has some fancy software inside which is aware of different kinds of target chips and probably does some things
<sys64738> yeah that sounds likely
<Haohmaru> there were some segger debuggers which include everything up to a complete gdb server
<Haohmaru> for that to work, they'd have to deal with the chip-specific crap in the debugger itself
<sys64738> yeah, I'm aware (blackmagic debugger is the name of that one)
<sys64738> (and forks of it like farpatch)
<sys64738> but that one doesn't have any SAML1x support at all so doesn't help me atm
<Haohmaru> iirc the blackmagic thing wasn't from segger
cozycactus has joined #openocd
<sys64738> ah yeah that's correct
Haohmaru has quit [Quit: saionara]
dliviu has quit [Ping timeout: 260 seconds]
<PaulFertser> sys64738: no, jlink is used in exactly the same way as ftdi mpsse with OpenOCD, nothing fancy.
<PaulFertser> I mean jlink with OpenOCD of course.
<zapb__> sys64738, there is a "high-level interface" for J-Link probes but that's not used by OpenOCD
slobodan has quit [Read error: Connection reset by peer]
nerozero has quit [Ping timeout: 260 seconds]
slobodan has joined #openocd
dliviu has joined #openocd
<sys64738> well in any case, this is what I'm observing
<zapb__> sys64738, are you using a dev board? I assume JLinkCommander uses a different reset strategy or something like that
<sys64738> I'm using https://rtfm.newae.com/Targets/UFO%20Targets/CW308T-ATSAML11/ , which isn't *quite* a devboard as you have to bring your own debugger thingy
<sys64738> (see also the scrollback from last thursday? friday?)
<sys64738> ah wait no, tue 08 oct even
PlasmaHH has joined #openocd
<zapb__> sys64738, okay... 404 but I'm quite familiar with this HW ;)
HelloShitty has joined #openocd
<sys64738> 404 what? that link works for me
<PlasmaHH> Hi, anyone familiar with swo/itm output of stm32u5 ? I don't quite get what the -formatter parameter is for in the tpiu command for enabling swo data...
<PaulFertser> PlasmaHH: hi.
<PlasmaHH> my problem is that with "on" the data over the wire is broken but with "off" while it is right, I dont get anything at the output tcp port
<PaulFertser> PlasmaHH: the thing is that ITM data goes through TPIU where it can be mixed (or not) with tracing data from ETM. And unless you need that tracing you should disable formatter because it doesn't help.
<PlasmaHH> PaulFertser: ah I see... while that doesnt explain why in that case the data is broken ( I dont have anything tracing enabled I think ) there is now still the problem of openocd not forwarding that data to me
<PaulFertser> PlasmaHH: so how do you configure that tcp port then?
<zapb__> sys64738, I get an error 404 here, anyway ... maybe I find some time to test the target
<PlasmaHH> PaulFertser: the important config line is: stm32u5x.tpiu configure -protocol uart -pin-freq 20000000 -traceclk 160000000 -output :22888 -formatter off
<PaulFertser> PlasmaHH: how do you check brokenness? Probably the tool just doesn't expect formatted data?
<PaulFertser> PlasmaHH: and btw what are you capturing with?
<PlasmaHH> PaulFertser: I looked at the data with a logic analyzer with -formatter on and I could see that it was often not sending what I put into ITM_SendChar
<PlasmaHH> PaulFertser: I am using an stm32u5a5 nucleo board with the onboard stlink
<PlasmaHH> so -formatter off it is, now I just need to get openocd to output me some data
<PaulFertser> PlasmaHH: can that stlink capture at 20 MHz?
<PlasmaHH> PaulFertser: now that is a good question, lets see
<PlasmaHH> (only so far confirmed with the logic analyzer that the data is correct on the pin )
<PaulFertser> PlasmaHH: I think you should just omit -pin-freq altogether if you're using stlink to capture.
<PlasmaHH> PaulFertser: unfortunately that gives me Error: SWO frequency is not suitable. Please choose a different frequency. ... probably because it tries to use a default frequency of 24mhz or so?
<PlasmaHH> using 2mhz works so it most likely is that it cannot capture at 20mhz
<PlasmaHH> hm, openocd says it doesnt support higher than 24mhz but already at 20mhz it stops outputting stuff... 16mhz works fine so I guess I settle for that now
<PlasmaHH> finally I can start writing my swo plugin ^^
<PlasmaHH> thanks a lot that was bugging me for weeks
<zapb__> PlasmaHH, what kind of plugin?
<PaulFertser> PlasmaHH: probably it's a signal integrity issue in your case.
<PaulFertser> PlasmaHH: stlinkv3 should be able to capture up to 24 MHz, yes. Probably you need to add some kind of termination there or more ground connections between the target and adapter?
<PlasmaHH> zapb__: for gdb, all kinds of functionality I need
<PlasmaHH> PaulFertser: its built into the nucleo board, I would hope for them to have the best connection possible. Also my logic analyzer with flimsy wiring can capture it just fine at those speeds... doesn't matter right now, 16mhz is fine
<zapb__> PlasmaHH, like a decoder or what functionality?
<PlasmaHH> zapb__: yes for swo I plan on writing a decoder that is aware of the different streams so within gdb I can output them to different targets if necessary ( my gdb plugin provides the ability to redirect output to other ttys or tcp ports or so ). plus I want to send it through rich for colouor support ;)
<zapb__> PlasmaHH, you should consider to use one of the already existing libraries
<PlasmaHH> zapb__: well maybe, do you know any good swo decoding one?
<zapb__> PlasmaHH, https://github.com/orbcode
<zapb__> there are probably more
<PlasmaHH> zapb__: I would prefer a pure python solution
<zapb__> PlasmaHH, I see, then I don't know but probably there is already one :D
<PlasmaHH> zapb__: when I had a quick look all I could find was a simple script that decodes and outputs...
<PlasmaHH> the protocol isn't too hard to decode though
<PlasmaHH> FirstI think I need to implement me some advanced register blacklisting feature, its not a good idea to try reading the tpiu registers when no tpiu stuff is enabled...
PlasmaHH has quit [Ping timeout: 264 seconds]
slobodan has quit [Ping timeout: 265 seconds]
diddly has quit [Read error: Connection reset by peer]
diddly has joined #openocd