NishanthMenon changed the topic of #openocd to: this is the place to discuss all things OpenOCD | Logs: https://libera.irclog.whitequark.org/openocd/
Guest29 has joined #openocd
<Guest29> I am trying to connect to Beagle-Y-AI board using OpenOCD. The debugger I use is Olimex - ARM-USB-OCD-H debugger. I am using this guide to connect to it https://openbeagle.org/beagley-ai/beagley-ai/-/blob/main/test-report/test-procedure/am67_jtag_testing.md . When I use the config file in this guide it shows Error: Unknown target type cortex_r5, I
<Guest29> see in the OpenOCD source code the target supported is only cortex_r4, any idea how to proceed forward?
tsal has joined #openocd
tsal_ has quit [Ping timeout: 240 seconds]
zjason` has quit [Ping timeout: 276 seconds]
Hawk777 has joined #openocd
<NishanthMenon> Guest29: SoC processor startup sequence requires remote proc to be started up first with Linux. the jtag interface (which openOCD controls) cannot start a CPU by itself. there is a bit of handshake required by s/w to start the processor up (involving communication with secure enclave and the device management components in the SoC).
<NishanthMenon> Guest29: see https://www.youtube.com/watch?v=mQLLtudWSpQ if you are curious.. that said, your mentioned unknown target type cortex_r5. I just tested the latest tip on another board (am62p, which has r5f), and I see with gdb-multiarch -ex 'target extended-remote localhost:3338': https://www.irccloud.com/pastebin/FGfwYEfa/
<NishanthMenon> Guest29: tested on "cbc32c3831e3 (HEAD -> master, origin/master, origin/HEAD) flash/nor/stm32l4x: fix permanent write protection on STM32U5"
Hawk777 has quit [Quit: Leaving.]
ALTracer has quit [Quit: Quit]
nerozero has joined #openocd
renrelkha has quit [Quit: bye]
renrelkha has joined #openocd
Guest29 has quit [Quit: Client closed]
Hawk777 has joined #openocd
Hawk777 has quit [Quit: Leaving.]
Haohmaru has joined #openocd
mawk has quit [Quit: ZNC - https://znc.in]
mawk has joined #openocd
james_ has joined #openocd
james_ is now known as james___
<james___> Hi, I asked a while back and nobody seemed to know, for MPC57XX support, but I found this... https://review.openocd.org/c/openocd/+/6148/2
<james___> does anyone know why it was removed?
<james___> or just never merged in the first place?
<PaulFertser> Anyone can pick up unfinished work btw.
<james___> I'm just not really sure what the state is, do you think it was never merged? Someone sent me some unknown copy of openOCD and it has MPC5xxx, 56xx and 57xx in there so I went looking
<Haohmaru> maybe no one accepted it?
<Haohmaru> there's a lot of people poking openocd but in their own personal forks, and not enough volunteers to poke at the original openocd code
<james___> OK sure, if I can get some sort of interface working then I can test/fix for MPC5777C and 5746G and maybe another that I need to work on soon
<Haohmaru> which $vendor is that even?
<james___> I did all the work manually with an arduino mega already and bit banging but it would be nicer to use openocd,
<Haohmaru> nxp?
<james___> the chips are NXP yeah
<james___> One is an existing auto manufacturer - unlocking ECU for tuning, the other two are aftermarket ECUs I need to write the bootloader for from scratch
<james___> the proper debug tools cost thousands
<Haohmaru> huh, this is not Arm core?
<james___> No, they are PowerPC e200 cores
<james___> I would try to use a pi but the IO voltage is 5v on this ECU, which is why I used an arduino mega originally, I guess I need to make a new openocd driver..
<Haohmaru> or level-shifting? ;P~
<james___> I do have some level shift boards handy but wasn't sure if it would cause trouble, sure they will cause a bit of a delay
<james___> or do raw resistors for level shift..
<Haohmaru> JTAG or SWD?
<james___> JTAG
<Haohmaru> that thing didn't have signals that change direction, right?
<Haohmaru> (like SWD has)
<james___> might be OK yeah, it has separate data in/out
<Haohmaru> so level shifting should be simple-ish
<james___> yeah I guess, do you have to run openocd on the pi with that bcm2835gpio driver for the pi?
<Haohmaru> no clue
<Haohmaru> i only use DAPLINKs with SWD
<james___> I'll see how complicated the drivers are, would be nice to have an arduino mega rather than have to work on a pi
<Haohmaru> you wanna use the crapduino board as a debugger?
<Haohmaru> hm, hold on
<Haohmaru> what's your current debugger which you normally use?
<Haohmaru> do i understand right that it's 3.3V while the target you wanna debug is 5V?
<Haohmaru> because then, what if it could almost work? most JTAG signals are probably debugger->target and probably only a few would be the opposite direction
<Haohmaru> maybe a 3.3V logic signal could work into a 5V input pin, then all you'll have to do is level-shift down the opposite direction
<james___> yeah I could try that
<Haohmaru> HEF4050 for example could work for 5->3.3V
<Haohmaru> or a pile of other options
<james___> the only debuggers I have had are maybe a jtagice for AVR, the MPC I have now is on a dev board with a built-in debugger
<Haohmaru> hm.. is the jtagice "limited" to work only with Atmel stuff or is it usable in general?
<james___> yeah I might try a raspberry pi and just drop that returning signal and see if it works, it just adds to potential issues
<james___> that's all
<Haohmaru> still check carefully how many signals go 5->3.3, "data out" from the target certainly will, but there may be others.. (reset?)
<Haohmaru> maybe also wait for someone else here who's more familiar with JTAG to give an opinion
<james___> yeah sure
<Haohmaru> someone who's name begins with P
<Haohmaru> ;P~
<james___> reset definitely, and some of the others might be pulled up to 5v by default so yes I agree
pengi330 has quit [Ping timeout: 276 seconds]
<Haohmaru> otherwise, for a fancy level shifter, i used some fancy translators.. what were they
<Haohmaru> 74ahc2g45 or something like that
<james___> I do have some special level shifter boards with transistors or mofsets or something on, supposedly works in both directions but I'm never sure how they cope with fast comms
<james___> there is still saturation time or whatever it is called with those components before they switch on/off
<Haohmaru> not g but T
<Haohmaru> (page 2 there)
pengi33 has joined #openocd
<borneoa___> james___: there is a fork from St microelectronics in GitHub that has support for some PowerPC device, but I don't know if the one you're looking for is also inside. The code level is not ready for upstream, but it's supposed functional. ST has been a second source for NXP PowerPC devices and has also some of it's own devices. You need to check the branch "automotive" something
<Haohmaru> is that an ST and NXP collab?
<Haohmaru> not openocd but the chips
JoseT has joined #openocd
<james___> ah thanks, I will have a look. ST make fake/copy chips which are cheaper but meant to be equivalent
<james___> I think the ST ones are named like SPC5xxx instead of MPC5xxx
<Haohmaru> ah, huh
<james___> I can see PowerPC and some stuff for xPC56 and 58 but not 57, I will come back to it later and see..
<james___> I have an FT323R USB breakout here, it has all the pins broken out, can I try that with the ft232r driver? I wasn't sure if there was some special FTDI JTAG devices or this is the right thing to use with a raw chip
JoseT has quit [Quit: Client closed]
<Haohmaru> james___, a bunch of those FTDI adapters can be used with openocd as debuggers, but i don't know details
<james___> OK I will try and see, I wasn't sure if it was some specific FTDI based JTAG tool or if a raw FTDI chip works, let's see..
<Haohmaru> particularly i think they have some FTDI chips that support doing bit sequencing in a sorta fast way for "bitbanging" purposes
<Haohmaru> openocd can use those
<james___> yeah some of the FTDI chips have more features than others for sure
gpol has quit [Ping timeout: 276 seconds]
gpol has joined #openocd
Haohmaru has quit [Quit: saionara]
zjason has joined #openocd
<borneoa___> For Haohmaru. No, are not fake NXP devices. Car makers forced NXP to license the PowerPC devices to another company to guarantee having a second source in case e.g. of NXP changing business or products. I don't know how, but ST was choose for becoming second source of compatible devices. Then, later, there was some ST PowerPC device, but I never used them and I don't have all the details.
nerozero has quit [Ping timeout: 240 seconds]
jfsimon has quit [Ping timeout: 276 seconds]
jfsimon has joined #openocd
jfsimon has quit [Remote host closed the connection]
jfsimon has joined #openocd
tlwoerner has quit [Ping timeout: 245 seconds]
tlwoerner has joined #openocd
dacav has quit [Quit: ZNC 1.9.1 - https://znc.in]