DockStar JTAG

This forum is for Marvell Kirkwood devices such as the GoFlex Home/Net, PogoPlug v1/v2, SheevaPlug, and ZyXEL devices.

Re: DockStar JTAG

Postby jtagfun » Sun Aug 29, 2010 4:21 pm

Yes, this is the one I meant.

BTW, I just made an un-buffered "wiggler" with only 100 ohm resistors,
I changed "sheevaplug_int" to "dockstar_int" in "dockstar.cfg" with inverted SRST* bit:

proc dockstar_init { } {

# We need to assert DBGRQ while holding nSRST down.
# However DBGACK will be set only when nSRST is released.
# Furthermore, the JTAG interface doesn't respond at all when
# the CPU is in the WFI (wait for interrupts) state, so it is
# possible that initial tap examination failed. So let's
# re-examine the target again here when nSRST is asserted which
# should then succeed.
# jtag_reset 0 1 # open collector
jtag_reset 0 0 # non-inverter
feroceon.cpu arp_examine
halt 0
# jtag_reset 0 0 # open collector
jtag_reset 0 1 # non-inverter
wait_halt

It worked without pushing the reset button and I got the following:

Open On-Chip Debugger
> init
> dockstar_init
target state: halted
target halted in ARM state due to debug-request, current mode: Supervisor
cpsr: 0x000000d3 pc: 0xffff0000
MMU: disabled, D-Cache: disabled, I-Cache: disabled
> nand probe 0
NAND flash device 'NAND 256MiB 3,3V 8-bit' found
>
jtagfun
 
Posts: 24
Joined: Sun Aug 29, 2010 11:37 am

Re: DockStar JTAG

Postby candlejack » Sun Aug 29, 2010 4:45 pm

So i tried a modification.
This should be easy for someone trying a DIY for himself.
Attachments
wiggler.png
wiggler.png (12.6 KiB) Viewed 8107 times
candlejack
 
Posts: 6
Joined: Sat Aug 28, 2010 3:50 pm

Re: DockStar JTAG

Postby bzboi » Sun Aug 29, 2010 4:47 pm

@candlejack & jtagfun Cool, both the simpler circuit and the elimination of the workaround would make this a lot more accessible for everyone. Do you still have to install the R166 pull-up? Please feel free to update the Wiki as you deem fit.
bzboi
 
Posts: 55
Joined: Sun Jul 11, 2010 5:39 pm

Re: DockStar JTAG

Postby candlejack » Sun Aug 29, 2010 5:03 pm

with the pin2 connected to TRST this shouldn't be necessary, but i have not checked this.

As to installing R166 if it is still necessary ,i recommend to do it externally
candlejack
 
Posts: 6
Joined: Sat Aug 28, 2010 3:50 pm

Re: DockStar JTAG

Postby jtagfun » Sun Aug 29, 2010 8:06 pm

I did not install any resistors on Dockstar. The pull-push circuit of parallel port + 100 ohm did the trick.
For totally un-buffered "wiggler", I have cable length of 2" and connected it directly from parallel port of a laptop to the Dockstar.
I'm impressed by the modifications candlejack made for the Dockstar wiggler.
jtagfun
 
Posts: 24
Joined: Sun Aug 29, 2010 11:37 am

Re: DockStar JTAG

Postby jtagfun » Sun Aug 29, 2010 8:23 pm

bzboi, I'm wandering if you can add an nand backup step before nand erase. I'm new to Openocd and haven't tried any backup and write to nand.
I did backups of my Dockstar using "dd", but feel backup by JTAG may be more reliable, especially for the Uboot.
jtagfun
 
Posts: 24
Joined: Sun Aug 29, 2010 11:37 am

Re: DockStar JTAG

Postby bzboi » Sun Aug 29, 2010 8:57 pm

jtagfun, I'm not so sure if that belongs in the wiki. This method is really meant to be a last resort and shouldn't be used for stuff like backup of an operational Dockstar since there are less risky alternatives. You basically need to be at a point where your uBoot is hosed and a NAND backup doesn't make sense before you whip out the JTAG cable. In my specific case, I'm trying to restore to the factory software in a blank 1GB NAND chip, so I really didn't dig into NAND backup too much.

Take a look at http://openocd.berlios.de/doc/html/NAND ... mands.html if you really want to dig into this. I think you're much better served running Jeff Doozan's scripts since many more people will go that route and any issues will be ironed out more quickly.
bzboi
 
Posts: 55
Joined: Sun Jul 11, 2010 5:39 pm

Re: DockStar JTAG

Postby jtagfun » Sun Aug 29, 2010 9:43 pm

I tried the following in "dockstar.cfg" to backup the first page (2KB) of nand:

proc backup {} {
init
dockstar_init # replaced "sheevaplug_init"
nand probe 0
nand list
nand dump 0 "nand00000.bin" 0 0x800
}

And got:

Open On-Chip Debugger
> backup
target state: halted
target halted in ARM state due to debug-request, current mode: Supervisor
cpsr: 0x000000d3 pc: 0xffff0000
MMU: disabled, D-Cache: disabled, I-Cache: disabled
NAND flash device 'NAND 256MiB 3,3V 8-bit' found
#0: NAND 256MiB 3,3V 8-bit (Micron) pagesize: 2048, buswidth: 8,
blocksize: 131072, blocks: 2048
dumped 2048 bytes in 20.421875s (0.098 kb/s)

I have verified the dump with the first 2KB of mtd0.
It took 1.5 hours to backup the first 512KB (Uboot) using un-buffered jtag cable.

I also used the following to backup OOB data for Uboot:

nand dump 0 "nand00000.bin" 0 0x800 oob_only
jtagfun
 
Posts: 24
Joined: Sun Aug 29, 2010 11:37 am

Re: DockStar JTAG

Postby bzboi » Mon Aug 30, 2010 1:24 pm

$this->bbcode_second_pass_quote('jtagfun', 'I') also used the following to backup OOB data for Uboot:

nand dump 0 "nand00000.bin" 0 0x800 oob_only


Good work jtagfun. That's a good point that I forgot about. I take that back about this not belonging in the Wiki. Would you be willing to write something up on how to backup the uboot environment bootloader parameters? Specifically documenting address ranges to be careful of stepping on.
bzboi
 
Posts: 55
Joined: Sun Jul 11, 2010 5:39 pm

Re: DockStar JTAG

Postby jtagfun » Mon Aug 30, 2010 3:33 pm

I only learned the concept of OOB and the differences between NAND and other types of memory yesterday. I need to verify ways of secure NAND backups, e.g., compare backups using JTAG and Jeff's NAND dump.
I'm using Windows PC and have not used Jeff's NAND dump yet, I only did "dd" backup of all mtd's.
I'll do env backups tonight. I did quite few TI ARM unlocks/debricks, but they use different type of flash memory.
I'm still in the process of learning NANDs and not ready to edit your Wiki yet.
jtagfun
 
Posts: 24
Joined: Sun Aug 29, 2010 11:37 am

PreviousNext

Return to Marvell Kirkwood

Who is online

Users browsing this forum: No registered users and 5 guests