HOW2: Repair Pogo E02 with Raspberry PI (1,2 or 3) JTAG and OpenOCD
May 08, 2015 01:59PM
Update! 23.11.2017
- update uboot + uboot-env to the latest version from bodhi.
- (uboot.2017.07-tld-1 and 2016.05-tld-1.environment)
- now with config for all Raspis (RPI3 also including now)
*********************************************************************************************
I startet my new projekt to repair a broken Pogo E02 (damaged bootloader - mtd0)
with a Raspberry PI used as JTAG Interface.
here in german language: How2 Repair POGO E02 with Raspi-JTAG
First i´de written in a german Forum but thought after translation maybe also interesting for some of you here.

I was inspired by this Forum - thanks to all the guys here.

Pictures: from all this stuff: wiring, Raspi-Jtag-Pogo, Raspi-GPIO, Pogo-serial-connection

HOWTO: Repair a defective PogoE02 with a RaspberryPI used as a JTAG and openOCD
(english version - thanks @ gravelrash for translation support)

The story:
Month ago I bought a Buspirate (JTAG) universal serial interface to repair some defective Pogos.
- it works pretty well
- If you have to repair only one Pogo it is to expensive, because Buspirate costs the same like a new Pogo.

But there is an alternative solution (cheaper more easy and 4 times faster):

Nearly everybody has laying around one (or even more) Raspberry Pi's. The Raspberry Pi has the ability to perform JTAG functions from its GPIO's. After researching on the WEB and doing some testing, I have now put all together and can present a final (working) solution.

It is basically a Raspberry Pi (with the current Raspbian installed) and OpenOCD compiled on it plus 6 interconnecting cables. You can repair all your Pogos with destroyed uboot (mtd0) this way.

Since OpenOCD runs on the Raspberry Pi, the whole process can be accomplished without an additional PC, providing that you have plugged a keyboard, mouse and monitor into the Raspi. But I preferred to have the Raspi integrated into my network and opened the terminal in a (Windows) PC by using putty.

In principle, we require 3 terminal sessions:

Terminal 1 : (SSH terminal) here OpenOCD is called and you see the output of the commands from Terminal2
Terminal 2 : (OpenOCD interface by Telnet on port 4444) This is where we will run the commands (e.g. uboot load into RAM and start without touching nand, but you can also write uboot into nand directly from here )
Terminal 3 : USB / TTY Adapter connected to the Pogo, from here we will stop the boot process and flash the new uboot and/or uboot envs into NAND.

Raspberry Pi B, B+, PI2 or the new PI3
- Use simply standard clock Speed of your Raspi - (B,B+700Mhz, RPI2 900Mhz and RPI3 1200Mhz)
6 connecting cables from Raspi (GPIO ) to the Pogo, Max 30cm in length.
1 USB / TTL Adapter for serial console on the Pogo. (nice to have)
Internet connection for Raspberry Pi

Installation on the Raspi:

First we take the Raspi and install the latest Raspbian, after installing a few more dependencies we compile OpenOCD manually, with the matching Settings:
 sudo apt-get update
 sudo apt-get install picocom
 sudo apt-get install -y autoconf automake texinfo libtool libftdi-dev 
 sudo apt-get install libusb-1.0 libusb-dev
 sudo apt-get install mtd-utils u-boot-tools
 git clone --recursive git://git.code.sf.net/p/openocd/code openocd-git && cd openocd-git

After a massive Compile instruction (Please copy and paste the fully code)
You will need to be patient, because the compilation takes some time.
{
 ./bootstrap &&\
 ./configure --enable-bcm2835gpio \
--enable-buspirate \
--enable-maintainer-mode \
--disable-werror \
--enable-openjtag_ftdi \
--prefix=/usr\
 &&\
 make
 } > openocd_build.log 2>&1
install with:
sudo make install
cd ..
when Installation is finished create a file called pogo.cfg
/usr/share/openocd/scripts/board/pogo.cfg
sudo touch /usr/share/openocd/scripts/board/pogo.cfg
sudo nano /usr/share/openocd/scripts/board/pogo.cfg
and fill it with the following content:
 # Pogoplug E02
 # modification joerg_999 14.03.2016
 # use this pogo.cfg taken from sheevaplug to use with Raspi direct or Buspirate jtag adapter
 # use raspberrypi-native mode 
 # we use the Pins from SPI Interface (violett) 19,21,23,26 and 22, + 20 for GND 
 # see GPIO schematic Raspi Raspi GPIO

 # source [find interface/buspirate.cfg] 
 # source [find interface/sysfsgpio-raspberrypi.cfg] 
 source [find interface/raspberrypi123-native.cfg]
 source [find target/feroceon.cfg]
  
$_TARGETNAME configure \
-work-area-phys 0x100000 \
-work-area-size 65536 \
-work-area-backup 0
 #arm7_9 dcc_downloads enable
 # this assumes the hardware default peripherals location before u-Boot moves it
 set _FLASHNAME $_CHIPNAME.flash
 nand device $_FLASHNAME orion 0 0xd8000000
 proc pogo_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
 feroceon.cpu arp_examine
 halt 0
 jtag_reset 0 0
 wait_halt
 arm mcr 15 0 0 1 0 0x00052078
 mww 0xD0001400 0x43000C30 ;# DDR SDRAM Configuration Register
 mww 0xD0001404 0x39543000 ;# Dunit Control Low Register
 mww 0xD0001408 0x22125451 ;# DDR SDRAM Timing (Low) Register
 mww 0xD000140C 0x00000833 ;# DDR SDRAM Timing (High) Register
 mww 0xD0001410 0x000000CC ;# DDR SDRAM Address Control Register
 mww 0xD0001414 0x00000000 ;# DDR SDRAM Open Pages Control Register
 mww 0xD0001418 0x00000000 ;# DDR SDRAM Operation Register
 mww 0xD000141C 0x00000C52 ;# DDR SDRAM Mode Register
 mww 0xD0001420 0x00000042 ;# DDR SDRAM Extended Mode Register
 mww 0xD0001424 0x0000F17F ;# Dunit Control High Register
 mww 0xD0001428 0x00085520 ;# Dunit Control High Register
 mww 0xD000147c 0x00008552 ;# Dunit Control High Register
 mww 0xD0001504 0x0FFFFFF1 ;# CS0n Size Register
 mww 0xD0001508 0x10000000 ;# CS1n Base Register
 mww 0xD000150C 0x0FFFFFF5 ;# CS1n Size Register
 mww 0xD0001514 0x00000000 ;# CS2n Size Register
 mww 0xD000151C 0x00000000 ;# CS3n Size Register
 mww 0xD0001494 0x003C0000 ;# DDR2 SDRAM ODT Control (Low) Register
 mww 0xD0001498 0x00000000 ;# DDR2 SDRAM ODT Control (High) REgister
 mww 0xD000149C 0x0000F80F ;# DDR2 Dunit ODT Control Register
 mww 0xD0001480 0x00000001 ;# DDR SDRAM Initialization Control Register
 mww 0xD0020204 0x00000000 ;# Main IRQ Interrupt Mask Register
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0020204 0x00000000 ;# "
 mww 0xD0010000 0x01111111 ;# MPP 0 to 7
 mww 0xD0010004 0x11113322 ;# MPP 8 to 15
 mww 0xD0010008 0x00001111 ;# MPP 16 to 23
 mww 0xD0010418 0x003E07CF ;# NAND Read Parameters REgister
 mww 0xD001041C 0x000F0F0F ;# NAND Write Parameters Register
 mww 0xD0010470 0x01C7D943 ;# NAND Flash Control Register
 }
 proc pogo_reflash_uboot { } {
 # reflash the u-Boot binary and reboot into it
 pogo_init
 nand probe 0
 nand erase 0 0x0 0xa0000
 nand write 0 uboot.kwb 0 oob_softecc_kw
 resume
 }
 proc pogo_reflash_uboot_env { } {
 # reflash the u-Boot environment variables area
 pogo_init
 nand probe 0
 nand erase 0 0xc0000 0x20000
 nand write 0 uboot-env.bin 0xc0000 oob_softecc_kw
 resume
 }
 proc pogo_load_uboot { } {
 # load u-Boot into RAM and execute it
 pogo_init
 load_image uboot.kwb
 verify_image uboot.kwb
 resume 0x800200
 }
we make a symlink: # ( for convenience )
ln -s /usr/share/openocd/scripts/board/pogo.cfg pogo.cfg

In the next step we will download the latest uboot and uboot ENVS, unpack them and create also symlinks:
## download uboot Pogo E02 and create Symlink:

wget -c dl.dropbox.com/s/vgbshmiq3o14btp/uboot.2017.07-tld-1.pogo_e02.bodhi.tar
tar -xf uboot.2017.07-tld-1.pogo_e02.bodhi.tar
ln -s uboot.2017.07-tld-1.pogo_e02.mtd0.kwb uboot.kwb

## download u-boot envs and create Symlink:

wget -c dl.dropbox.com/s/4smmw2wr4ugayz9/uboot.2016.05-tld-1.environment.bodhi.tar
tar -xf uboot.2016.05-tld-1.environment.bodhi.tar
ln -s uboot.2016.05-tld-1.environment.img uboot-env.bin
at last we create a new file (based on raspberrypi-native.cfg) :
/usr/share/openocd/scripts/interface/raspberrypi-native.cfg
this is necessary for matching the reset pins and the right adapter speed.
sudo nano /usr/share/openocd/scripts/interface/raspberrypi123-native.cfg
and fill / change the following content:

# raspberrypi123-native.cfg   (for all of the Raspis)
# It´s about 4 times faster for writing and 14 times faster for reading
# compared to the generic sysfsgpio driver

# Config for using Raspberry Pi's expansion header
#
# This is best used with a fast enough buffer but also
# is suitable for direct connection if the target voltage
# matches RPi's 3.3V and the cable is short enough.
#
# Do not forget the GND connection, pin 6 of the expansion header.
#
# Please set the right  peripheral_base address and Transition delay 
# depending on which Raspi (1,2 or 3) you use.

interface bcm2835gpio
# Raspi2 and Raspi3  peripheral_base address
bcm2835gpio_peripheral_base 0x3F000000

# Raspi1  peripheral_base address
# bcm2835gpio_peripheral_base 0x20000000

# Transition delay calculation: SPEED_COEFF/khz - SPEED_OFFSET
# These depend on system clock, calibrated for stock 700MHz
# bcm2835gpio_speed SPEED_COEFF SPEED_OFFSET

# Raspi3 BCM2837 (1200Mhz): 
bcm2835gpio_speed_coeffs 194938 48

# Raspi2 BCM2836 (900Mhz):
# bcm2835gpio_speed_coeffs 146203 36

# Raspi1 BCM2835: (700Mhz)
# bcm2835gpio_speed_coeffs 113714 28

# Each of the JTAG lines need a gpio number set: tck tms tdi tdo
# Header pin numbers: 23 22 19 21
bcm2835gpio_jtag_nums 11 25 10 9

# or if you have both connected,
# reset_config trst_and_srst srst_push_pull

# Each of the SWD lines need a gpio number set: swclk swdio
# Header pin numbers: 22 18
bcm2835gpio_swd_nums 25 24

# If you define trst or srst, use appropriate reset_config
# Header pin numbers: TRST - 26, SRST - 18

bcm2835gpio_trst_num 7
reset_config trst_only

# bcm2835gpio_srst_num 18 # should be GPIO 24, (maybe typo in original)
# reset_config srst_only srst_push_pull

# or if you have both connected,
# reset_config trst_and_srst srst_push_pull

# adapter speed in khz
# my Raspi/Pogo combo accepted 2000 khz but safely it should work with
adapter_khz 200

# adapter nsrst delay in ms
# if you try to flash goflexnet or iomega uncomment next line to increase delay from 200ms to 500ms
# adapter_nsrst_delay 500
after you´ve finished save the configuration at raspberrypi123-native.cfg than start openOCD on the Raspi:

start the Show in Terminal 1 (T1):
sudo openocd -f pogo.cfg
In the next spoilers you see the commands / responses and how to use the 3 terminals.
The major inputs are highlighted green the rest you can use for Info if no errors occur.
maybe its not perfect, but it is enough for the repair and the steps are the same as with Buspirate
Open On-Chip Debugger 0.10.0-dev-00247-g73b676c (2016-03-13-14:41)
Licensed under GNU GPL v2
For bug reports, read
        http://openocd.org/doc/doxygen/bugs.html
BCM2835 GPIO config: tck = 11, tms = 25, tdi = 10, tdo = 9
BCM2835 GPIO nums: swclk = 25, swdio = 24
BCM2835 GPIO config: trst = 7
trst_only separate trst_push_pull
adapter speed: 2000 kHz
Info : auto-selecting first available session transport "jtag". To override use 'transport select <transport>'.
trst_and_srst separate srst_gates_jtag trst_push_pull srst_open_drain connect_deassert_srst
adapter_nsrst_delay: 200
jtag_ntrst_delay: 200
Warn : use 'feroceon.cpu' as target identifier, not '0'
pogo_load_uboot
Info : BCM2835 GPIO JTAG/SWD bitbang driver
Info : JTAG and SWD modes enabled
Info : clock speed 2009 kHz
Info : JTAG tap: feroceon.cpu tap/device found: 0x20a023d3 (mfg: 0x1e9 (Marvell Semiconductors), part: 0x0a02, ver: 0x2)
Info : Embedded ICE version 0
Info : feroceon.cpu: hardware has 1 breakpoint/watchpoint unit

 ## open Terminal #2:        # putty (WindowsPC) #
 $ putty <adress of your RASPI> 4444

T1 Info : accepting 'telnet' connection on tcp/4444

T2 Info : Open On-Chip Debugger
          >
 # T2 The processor will be stopped: 
 # -> Run command:
 > pogo_init 
 > soft_reset_halt            # normaly it works without, if it fails, press reset button on Pogo

 # You normally get this event (the important thing is the status "ARM state"):
 # target state: halted
 # target halted in ARM state due to debug-request, current mode: Supervisor ## OK
 # cpsr: 0x000000d3 pc: 0xffff0000
 # MMU: disabled, D-Cache: disabled, I-Cache: disabled

 # If you get the following output, again:
 # target state: halted
 # target halted in Thumb state due to debug-request, current mode: Supervisor ## not OK !
 # cpsr: 0x200000f3 pc: 0xffff0a8a
 # MMU: enabled, D-Cache: enabled, I-Cache: enabled
 # T2 Is initialized with the command:
 > pogo_init

 # T2 We verify that the nand is well recognized:
 > nand probe 0 
 # NAND flash device 'NAND 128MiB 3.3V 8-bit (Hynix)' found ## OK

 # T2 If you see this output, start from the beginning: 
 > nand probe 0
 # unknown NAND flash device found, manufacturer id: 0x00 device id: 0x00 ## not OK!
 # in procedure 'nand'

 # T2 We clear the first 512kB:
 > nand erase 0 0x0 0xa0000
 # erased blocks 0 to 5 on NAND flash device #0 'NAND 128MiB 3.3V 8-bit'

 # T2 Then we write the nand file uboot:
 # Files we use: pogo.cfg, and Symlinks we created before
 # uboot.2017.07-tld-1.pogo_e02.mtd0.kwb ----> uboot.kwb 
 # uboot.2016.05-tld-1.environment.img ----> uboot-env.bin

 > nand write 0 uboot.kwb 0 oob_softecc_kw 

Finished -> shut down and unplug everything - than replug the Pogo to power, 
Pogo should start with new uboot

 After reboot you can see this Output in Terminal 3 (T3) with TTY/USB Adapter connected to Pogos CON3

 ## start Terminal 3 with the matching ttyUSBx (mostly ttyUSB0 if nothing else is connected)
 ## in T3 (USB/TTL Win/Linux Terminal /dev/ttyUSBx) Hit any key to stop autoboot,
 
U-Boot 2017.07-tld-1 (Sep 05 2017 - 00:13:18 -0700)
 Pogo E02
 SoC: Kirkwood 88F6281_A0
 DRAM: 256 MiB
 WARNING: Caches not enabled
 NAND: 128 MiB
 In: serial
 Out: serial
 Err: serial
 Net: egiga0
 Hit any key to stop autoboot: 0
< Hit Enter>
 Pogo E02>
Note:
bodhis new uboot.2016.05-tld-1.environment.img contains the latest universal uboot-envs for all common plugs!
If you need new uboot-envs you can either flash your uboot envs from Terminal 2
or better you try to boot a Linux pendrive from Terminal 3 and
Flash the uboot envs from the booted Linux or rescue system (if you have already installed before).

the wiring from Raspi to Pogo:
please dont forget to switch off power before!
## JTAG connector - Pogo E02 pinout ##

--------------------------------------------------------------------------------
## Pogo ##
 J1: 
 (1) GND ---> next to power plug
 (2) TDI
 (3) SRST (not connected)
 (4) TDO                             # 6 connecting cables from Pogo to Raspi (must have)
 (5) CLK
 (6) TMS
 (7) RES
 (8) 3.3V (not connected) ---> next to serial port

 CON3: 
 (1) GND
 (2) RXD                             # 3 connecting cables from Pogo to TTL/USB Adapter - don´t use the 3,3V!
 (3) TXD
 (4) 3.3V (not connected)                    

--------------------------------------------------------------------------------
## Raspi ##  Note: be careful and don´t mix GPIO and Pin number on Raspi!
## we use the Pins from SPI Interface (violett) 19,21,23,26 and 22 + 20 for GND see GPIO schematic Raspi

 GPIO--------Pin#--color  ------------ JTAG Pogo E02 (Wire colors i used from Buspirate cable-code)

 GND ------- 20 - (Brown) GND ----------- GND (1)
 GPIO 10 --- 19 - (Grey) MOSI ----------- TDI (2)
 GPIO 9 ---- 21 - (Black) MISO ---------- TDO (4)
 GPIO 11 --- 23 - (Violett) CLK --------- CLK (5)
 GPIO 25 --- 22 - (White) CS ------------ TMS (6)
 GPIO 7  --- 26 - (Blue) AUX/TRST ------- RES (7)

--------------------------------------------------------------------------------
## JTAG cable you have to build ##
 Create a JTAG cable with the following pinout:
 Pin Name Raspi(PinHeader)    Pogo E02 (J1)
 TRST ---------- 26 ------------------- 7
 GND ----------- 20 ------------------- 1
 JTAG_TMS ------ 22 ------------------- 6
 JTAG_TDI ------ 19 ------------------- 2
 JTAG_TDO ------ 21 ------------------- 4
 JTAG_TCK ------ 23 ------------------- 5
good luck! - no more dead POGOS !!!

joerg_999



Edited 91 time(s). Last edit at 11/23/2017 08:27AM by joerg_999.
Re: Repair Pogo E02 with Raspberry PI (JTAG)
May 08, 2015 02:35PM
if you could translate and post here entitled "HOWTO ----------"

that would be very helpful
Re: Repair Pogo E02 with Raspberry PI (JTAG)
May 08, 2015 02:41PM
i´ll do my best...
for quick solution you can use Google translator, (not really good - uboot = submarin ;-) but it works.

CU



Edited 1 time(s). Last edit at 05/08/2015 03:05PM by joerg_999.
Re: Repair Pogo E02 with Raspberry PI (JTAG)
May 08, 2015 03:00PM
P.M. sent



Edited 1 time(s). Last edit at 05/08/2015 03:00PM by Gravelrash.
Re: Repair Pogo E02 with Raspberry PI (JTAG)
May 08, 2015 03:35PM
Very interesting project, Joerg. I hope you, or someone, can provide a translation and keep us up to date on your progress. I have a friend who bought a GuruPlug (newer generation SheevaPlug) from me, and it came with an external JTAG widget. I've often wondered if I could employ that on one of my E02s, but thankfully I have never had the need to try (yet). Do keep us informed.
Re: Repair Pogo E02 with Raspberry PI (JTAG)
May 09, 2015 03:52PM
Thanks Jeorg_999

There are quite a few people and viewers on the forum that will find this useful and very helpful.

WELL DONE and Thankyou for sharing
Re: Repair Pogo E02 with Raspberry PI (JTAG)
May 09, 2015 05:49PM
@joerg,

Thanks for sharing! very informative. I'm sure it will help a lot users.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 17, 2015 10:57AM
Thanks for taking the time to translate your work, Joerg (and the same everyone else who helped with the translation). Your post is most definitely a keeper -- it's been bookmarked!

(Trying vainly to alter this message enough to get around being declared an automated bot by the funky forum software.)
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 17, 2015 12:06PM
It gives me pleasure when it is useful for you.
joerg_999
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 20, 2015 06:48PM
joerg,

> It gives me pleasure when it is useful for you.

Thank you for this HowTo and thanks Gravelrash for helping with translation. This is indeed very useful! especially to unbrick plugs such as Pogo E02 and Dockstar.

-bodhi
===========================
Forum Wiki
bodhi's corner (buy bodhi a beer)
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 21, 2015 08:15AM
Hi Joerg nice share! I'm interested in trying your method to unbrick my pogoplug. I already own a rpi and i'm going to buy a usb-ttl adapter, but i'm not sure if i understood what a usb-ttl adapter is. Do you think this could work? It has got only 5 jumper, do i need six right?



Edited 3 time(s). Last edit at 05/21/2015 08:19AM by ueghio.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 21, 2015 08:52AM
This one would fit, you only need 3 Pins RXD, TXD, and GND. - see my schematic for CON3 on the Pogo.
(NC) means not connected. (it is nothing else a serial Connection with Level shifter to 3,3V)

You can also try without (if you didn´t mess up your uboot envs) but you have to flash in Terminal2 as per description .
I prefere always to have a TTL/USB Adapter in reserve if something is going wrong.

see the Picture from connecting all this People:
Raspi-JTAG to POGO E02joerg_999



Edited 6 time(s). Last edit at 05/21/2015 01:02PM by joerg_999.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 21, 2015 11:42AM
Perfect thank you very much. Unfortunately i am new to rpi gpio connections. Can you tell me the name of the cable that starts from pogo and arrives to the gpio white board i see in your picture? is it a buspirate cable right? I need to buy it too or could this be a right one?



Edited 1 time(s). Last edit at 05/21/2015 12:37PM by ueghio.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 21, 2015 12:54PM
For one time repair you don´t really need.
There would fit this cableset: Cableset
I´ve bought an experimental Board for my Odroid C1 but it also fits to the Raspi.
It´s called Tinkering-Kit like this one: Tinkering Kit
The white board you can see is a Breadboard (all included in the Thinkering Kit)

Rem: the layout for the RASPI GPIOs:

Take that one match your choice best.....

joerg_999



Edited 2 time(s). Last edit at 12/18/2019 04:02PM by joerg_999.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 21, 2015 05:01PM
Ok i bought a 10pin female to female jumper, the USB to TTL cable and also this (maybe unuseful) one from the same seller. Considering i already own a bricked pogo and a rpi, everything should be ready. Hope to find you here again when i will receive all these items. Meanwhile i will study your howto to understand the exact position of cables and the step to step guide. Thank you for your help, goodnight!



Edited 1 time(s). Last edit at 05/21/2015 05:03PM by ueghio.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 21, 2015 05:42PM
The (Raspberry Pi GPIO kit) you asked me is also usefull for your repair session and for experimentation later, but not essentially necessary.

For Information: The first 26 PINs are equal on all types of Raspis (B, B+,PI2), but be carefully because your tinkering kit doesn´t have the same pin layout like mine. Check this before!

It´s a good idea to read the How2 twice when you are not so familiary with on-chip Debugging to understand the important steps.
A second good idea is to read bodhis thread about handling uboot and uboot-envs to understand the whole story better.

If you have further questions you can ask here in Forum, there you always will find people who can help you.

good night
joerg_999



Edited 6 time(s). Last edit at 05/22/2015 11:28AM by joerg_999.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 25, 2015 08:04AM
Hi joerg, i was wondering how you would connect the thikering kit i bought to the pogo..i see these pins on it : p0, p1, p2, p3, p4, p5, p6, p7, ScL, SDA, ce0, ce1, sclk, miso, mosi, gnd, txd, rxd.. thanks in advance
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 25, 2015 09:47AM
you have to measure out which Pins equals GPIO 9,10,11,24 and 25.
(I think you got a Raspi B with 26PIN GPIO Port)
This Raspis only have 8 GPIOs (the are called p0 to p7 on your thinkering kit) but that´s ok.
For GND i took PIN20 but you can take every GND.

Note: GPIO number is not PIN number!

-joerg_999



Edited 1 time(s). Last edit at 05/25/2015 09:49AM by joerg_999.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 25, 2015 10:41AM
Thank you! I have the raspi b (cpu 700mhz , 512mb ram) and i am waiting for the last raspi 2 (40 pins, am i right?). It should arrive on friday. Which one is easier to use for this purpose in your opinion? Maybe the first one wich have more documentation online?



Edited 5 time(s). Last edit at 05/25/2015 11:56AM by ueghio.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 25, 2015 12:59PM
For your purpose both the same



Edited 1 time(s). Last edit at 05/26/2015 03:33AM by joerg_999.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 25, 2015 01:56PM
this thinkering is similar to the one i bought, there is the corresponding layout in the link description. In the next days I will post a picture about connections to be sure i understood every point of your guide. Thank you for explanations. Bye
Marco



Edited 3 time(s). Last edit at 05/25/2015 03:52PM by ueghio.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 28, 2015 03:50PM
Hi, i was trying to connect pogo to usb-ttl cables but i noticed that con3 pins are very close all together. What cable could fit to j1 and con3 pins? Could a generic 3pins dupont cable (like this ) work? This is the problem



Edited 2 time(s). Last edit at 05/28/2015 05:07PM by ueghio.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 28, 2015 05:29PM
I´ve used an old audio-cd drive cable like shown in this blog
but you can also solder directly this 3 Pins on the backside of the connector on the Pogo.

For J1 connector i used a 7-pin charging current distributor which i normaly use to charge my Lipo Akkus something like this, but you can also solder them on the backside directly. (cheap one time solution)



Edited 3 time(s). Last edit at 05/29/2015 03:30AM by joerg_999.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 29, 2015 02:21AM
Soldering could be an option, but i should buy all the necessary things to do that and considering that i never did it before, i would probably do a mess. Anyway buying a lipo balance adapter for one time use maybe is not the cheapest solution. Do you think that i could use this cable ? Ebay seller says that distance between pins is 2,54mm.



Edited 2 time(s). Last edit at 05/29/2015 02:24AM by ueghio.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 29, 2015 03:20AM
No, sorry distance between pins is exactly 2,00 mm on J1 and CON3.
Maybe you get only the Connection cable with one end 2,00mm and the other end with 2,54 mm connector.

see: JTAG-1 JTAG-2
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 29, 2015 04:20AM
Unfortunately I don't have old cd-rom drive cables at home.. I found only this at a reasonable price. Could it work in your opinion? It has got a double black connector, how could i manage it? I'm sorry if i'm boring but now i'm decided to repair my pogo, it is a bet. thank you



Edited 4 time(s). Last edit at 05/29/2015 05:55AM by ueghio.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 29, 2015 07:45AM
Yes this should fit, but once again you shouldnt´t spend to much money for the wiring stuff.
My intension was to give you a cheap and simple solution to repair your defectiv Pogo.

If you have to repair more than one, maybe it´s agood idea to buy all the connectors to build a pretty j-tag cable for every day use.

REM: even with bus-pirate you need to build your own j-tag connection cable because of the 2mm connectors on the Pogo.

The best way is to cut some thin 15mm wires and soldere them on the backside than you can connect with the cheap cables you bought before.

-joerg_999



Edited 1 time(s). Last edit at 05/29/2015 07:54AM by joerg_999.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 29, 2015 10:10AM
I thought it was an hard practice for a newbe. What do i need for soldering? Is possible to find an inexpensive kit?
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 29, 2015 10:25AM
Sorry, i didn´t know that you have no soldering tools.- (oh man, how did you do your electronic stuff the last 30 years?)

I think in your case it would be the best to buy the Lipo balancer cable, it´s much more cheaper than a soldering iron set.and you have nothing to solder.

PS: what´s going on with the soft - do you have compiled openOCD like discription?

greetings joerg_999



Edited 1 time(s). Last edit at 06/01/2015 02:02AM by joerg_999.
Re: HOW2: Repair Pogo E02 with Raspberry PI (JTAG) and OpenOCD
May 29, 2015 11:51AM
Ahah i'm sorry i've never done electric stuff, it's the very first time but i like to learn :) i already ordered the lipo balancer and the audio cable i show you in the previous post. I've not compiled openocd yet, i'll do the next days!
Author:

Your Email:


Subject:


Spam prevention:
Please, enter the code that you see below in the input field. This is for blocking bots that try to post this form automatically. If the code is hard to read, then just try to guess it right. If you enter the wrong code, a new image is created and you get another chance to enter it right.
Message: