Page 1 of 1

xburn: locking device failed

Posted: Fri Feb 19, 2021 6:01 pm
by Redeye
I'm using the AES key option on xburn for secure booting. Out of 20 boards I've got, 19 have programmed and booted with no problems, but this last board just will not program the aes key. I'm using the command :

xburn --id 0 --lock aes.key --target-file board.xn --enable-jtag --disable-master-lock --no-version-check

but all I get back is "xburn: locking device failed". No other clues at all. I can run code from the debugger with no problems at all, so I think power etc is all good on the board.

I'm a bit stuck on this, has anybody got any ideas how to work out what's wrong with this board?

Re: xburn: locking device failed

Posted: Sat Feb 20, 2021 2:59 pm
by CousinItt
Can you try dropping the jtag speed? It may be a marginal timing/signal integrity problem. For example:

Code: Select all

--jtag-speed 2

Re: xburn: locking device failed

Posted: Mon Feb 22, 2021 1:11 pm
by Redeye
CousinItt wrote: Sat Feb 20, 2021 2:59 pm Can you try dropping the jtag speed? It may be a marginal timing/signal integrity problem. For example:

Code: Select all

--jtag-speed 2
Good idea, but same result "locking device failed". It would help if there was a clue in the error message, but even adding --verbose doesnt give any more information.

Re: xburn: locking device failed

Posted: Mon Feb 22, 2021 8:32 pm
by CousinItt
Does xburn -l give a reliable response?

How about xburn --read?

Re: xburn: locking device failed

Posted: Tue Feb 23, 2021 10:24 am
by Redeye
Yes, xburn -l works reliably every time.

xburn --read works fine as well, but I've got no idea how to interpret the output.

Re: xburn: locking device failed

Posted: Tue Feb 23, 2021 12:46 pm
by CousinItt
Could it be failing because it partially succeeded the first time, and now won't let you do any more? I'm not sure how to tell if that's the case, or to force it to continue.

Also is there more than one xmos device per board?

Re: xburn: locking device failed

Posted: Tue Feb 23, 2021 4:23 pm
by Redeye
Yes, possible. Though it's not a great piece of design if it can fail in a way that bricks the board.

Yes, it's a 3 x XL216 design.

I'm fairly resigned to having to replace the XL216 that's booting, as I believe that's the only one that gets it's OTP programmed with the AES key - can anyone confirm this for me?

Re: xburn: locking device failed

Posted: Tue Feb 23, 2021 5:49 pm
by CousinItt
I can't confirm that. Is there any possibility it's a problem with the XN file spec? E.g. a clock value that's just about OK for most boards? Clutching at straws a bit.

Re: xburn: locking device failed

Posted: Tue Feb 23, 2021 6:06 pm
by Redeye
No, I'm pretty confident the XN file is fine. We've built several hundred of these boards and had only a couple like this.

Looks like replacing the XL216 devices, which is fiddly...