<gamiee>
btw, just as info, I guess I managed to do the best reset mechanism as it is possible to do for the Bouffalo chips.
<gamiee>
I just wanted to say that doing this was magnificient experience for me, both writing the reset mechanism and scripts in TCL, but also doing flash bank driver.
<gamiee>
Now, I just hope it is all good and will be suitable for upstream :P
<Haohmaru>
"QC PASSED"
Hawk777 has quit [Quit: Leaving.]
JakeSays has joined #openocd
JakeSayss has quit [Ping timeout: 260 seconds]
Guest99 has joined #openocd
<Guest99>
I use openocd like this: openocd -f interface/jlink.cfg -c "adapter serial 11223344"....
<Guest99>
However, I get "Error: invalid subcommand "serial 11223344"
<Guest99>
anyidea ?
<Haohmaru>
was that intended to set the adapter speed?
<Guest99>
I have several JLink connected to this host
<Guest99>
I want to select one using its serial number
<PaulFertser>
Guest99: hm, "VTarget = 1.193 V" why is that? It's the jlink measuring VTref input and using that for JTAG/SWD signalling.
<Guest99>
target is 1.2V
<Guest99>
a log of openocd running on this ampere_qs_mq.cfg target would be helpful
Guest99 has quit [Quit: Client closed]
Guest99 has joined #openocd
<PaulFertser>
OK, if it's 1.2 V and your jlink supports that it's correct.
<PaulFertser>
Guest99: but "SWD ack not OK: 2 WAIT" looks wrong, it's as if the target is in wrong state. What is it doing at the moment you're trying to connect?
<Guest99>
yes, the jlink work with Jlink commander
<Guest99>
it's doing nothing, the mcu isn't running
<Guest99>
I don't even need to start the cortex_m, I just want to access the mem-ap
<PaulFertser>
Guest99: you define the CPU target on default AP0, that is, you omit -ap-num , is that right?
<PaulFertser>
Guest99: for that do not define the arm target.
<PaulFertser>
Define a mem_ap target on the appropriate AP number instead.
<Guest99>
mem_ap are on their ap-num target.
<Guest99>
"you define the CPU target on default AP0" -> you mean targets mychip.mcu
<PaulFertser>
Hm, I see now you're defining all of them. And they all fail.
<Guest99>
yes
<Guest99>
I guess I would need to analyze the swd traffic and see what's going on. I don't have enough time for this right now :(
<PaulFertser>
Guest99: for adiv6 AP num looks like 0x00010000
<PaulFertser>
The lowest 3 digits should be zero
<PaulFertser>
Guest99: nope, the problem is above SWD layer.
<PaulFertser>
Use numbers from APAddr there, not just 0, 1, 2.
<PaulFertser>
Guest99: that is mostly likely going to advance your efforts
<Guest99>
that's what I'm trying, my connection to the target just failed, I'll be right back
<PaulFertser>
(I figured that from "Invalid AP#" and checking the source code of the validation function, then it became obvious it's the immediate problem in this setup)
<Guest99>
ok thanks!
Guest99 has quit [Quit: Client closed]
Guest99 has joined #openocd
<PaulFertser>
Guest99: please share new output with correct ap numbers.
<Guest99>
something strange, If I first run the JLink (and a DORMAT-TO-SWD that I need to run manually) and _then_ openocd, it works perfectly
<Guest99>
I'll try to do only the DORMAT-TO-SWD on my side, then run openocd and I'll let you know
<Guest99>
ok, the power init of my test script was not good. It now works. Thanks PaulFertser, using ap-num with addresses was the key.
Guest99 has quit [Quit: Client closed]
Guest99 has joined #openocd
<PaulFertser>
Guest99: yay!
Guest99 has quit [Quit: Client closed]
<PaulFertser>
borneoa___: hm, probably -ap-num parameter and the error "Invalid AP#" is confusing in ADIv6 case where an AP _address_ is expected.
Guest99 has joined #openocd
shoragan has quit [Ping timeout: 252 seconds]
a3f has quit [Ping timeout: 272 seconds]
olerem has quit [Ping timeout: 248 seconds]
Pau has joined #openocd
a3f has joined #openocd
shoragan has joined #openocd
olerem has joined #openocd
Pau has quit [Ping timeout: 240 seconds]
Haohmaru has quit [Quit: saionara]
Guest99 has quit [Ping timeout: 240 seconds]
<borneoa___>
PaulFertser: agree. There is another feature of ADIv6 that we do not support in OpenOCD yet, that is AP behind an AP. We will probably need to specify the whole path, e.g. dap_name:@addr_ap1/@addr_ap2/@addr_ap3... Maybe the parameter should be simply -ap and the messages adapted accordingly.
<PaulFertser>
borneoa___: I do not have any specific suggestion, just an observation that it was the confusing part here for Guest99. Wasn't obvious to me either till I read the code in question.
<PaulFertser>
Probably just more specific error diagnostics for different invalid cases printed by is_ap_num_valid() would be enough?
crabbedhaloablut has quit []
nerozero has quit [Ping timeout: 248 seconds]
zjason`` has quit [Read error: Connection reset by peer]