oocd or texane for a stm32f4 ?

Hi Guyzz (spen)

I’m using st-util aith a stm32F4-disc board ,and CodeBlocks.

It seems to work fine.

Should i change to OOCD ?

What wonders am i missing ?

I have a few Versaloon’s , a BusBlasterV2 & a few FT2232 also , and suppose they need OOCD.

I also have 4 TI-Stellaris , doesn’t they need some LM4?? (spence magic) ?

I guess the advantage of oocd would ve a consistent interface across all jtag-dongles or ??

Any tips/hints are velcome

/Bingo

Add …

My BusBlaster can emulate a KT-Jtag dongle (doing swd)

Is swd included in oocd-6.1 git or do i have to use : git://repo.or.cz/openocd/libswd.git

/Bingo

Regarding the OpenOCD or texane question.

From my tests OpenOCD is much faster, due to the async flash algo we use.

OpenOCD also does more things then texane, tcl scripting, semi hosting and supports other adapters. To name but a few.

Not sure on your question with regards to the ti-icdi.

For swd support the best way at the moment is stlink or versaloon. The swd patches you mention are still wip and to slow as a daily driver.

I suppose another possibility would be to reflash your stlink as a BMP - https://github.com/gsmcmullin/blackmagic

Cheers

Spen

Thanx Spen

I read about the SWD lib yesterday @oocd mailinglist , and it seems like one is a bit alone with the lib right now.

I’ll prob go back to my old STM8S versaloon hack , and use the little STM8S board , to play around.

I did build oocd from a git clone from yesterday , and did build another oocd with the versaooon “stuff” as described @versaloon.

I’ll try the versaloon oocd , to see if it’ll work with all the dongles i have …

Versaloon , FT2232H (DLP’s) , Busblaster & ST-Link v1 & v2’s

Will oocd support the Launchpas “out of the box” ?

Ohh i wonder if i pushed my luck here with all the enables :slight_smile:

./configure --enable-maintainer-mode --enable-ftdi --enable-ft2232_libftdi --enable-jlink --enable-stlink --enable-ti-icdi

Thanx

/Bingo

The new to icdi is now supported in master, so no patches are required.

Spen

ntfreak:
For swd support the best way at the moment is stlink or versaloon. The swd patches you mention are still wip and to slow as a daily driver.

I suppose another possibility would be to reflash your stlink as a BMP - https://github.com/gsmcmullin/blackmagic

Cheers

Spen

Spen … Nice advice.

I had a chat with Uwe B , and mailed the schematic of the STM8S-Discovery Programmer-part (also a st-linkv1 variant)

Uwe just happened to have a STM8S-Discovery in the drawer …

And just did a port (new platform) of Blackmagic Probe (BMP) to the programming dongle on a STM8S-Discovery, and named it swlink.

The reason to include the extra port was that, the STM8S programmer has the F103 jtag pins accesible by a 0.1" header. This makes uploading a new firmware to the board with a “Normal Arm Jtag” (i used at ftdi 2232 variant) , very simple.

Due to the easy access to the the F103 jtag pins , this one can also do normal Jtag.

So when using it as a BMP, this is the only “Discovery ST-Link” version that can be used as both a swd, and a Jtag.

This means that the STM8S dongle can do Uart/JTAG and SWD.

It is pre-cut and easily breakable from the STM8 targetboard , and it is cheap.

Uwe guided me through building the dfu-loader and the BMP firmware

Uwe wrote

********** Snip ************

Check out https://github.com/UweBonnes/blackmagic

compile like make PROBE_HOST=swlink (in the blackmagic dir)

load resulting blackmagic_dfu(|.bin|.hex) file to 0x08000000 , and load blackmagic(|.bin|.hex) file to 0x08002000

or use dfu-util -s 0x08002000:leave -D blackmagic.bin after loading of the bootloader.

dfu-util is located at from git://gitorious.org/dfu-util/dfu-util.git

TRACESWO is not yet adapted, but should be doable.

********** Snip ************

See https://github.com/UweBonnes/blackmagic … ink/Readme + platform.c/h , for pinout info & bootloader info

CN5          	   CN7
JTAG/OUT     	   UART
SWD+TRACESWO       UART
JTAG/IN      	   Pin 3/4 shorted when started: Force Bootloader

SWD


TCK gets SWCLK

TMS gets SDDIO

https://github.com/UweBonnes/blackmagic

https://github.com/UweBonnes/blackmagic … rms/swlink

I used the launchpad arm-gcc - gcc-arm-none-eabi-4_7-2012q4 , and it’s a tight fit …

I had to modify the -O2 to -Os in the src/Makefile before being able to link it.

I haven’t had the time to test the dongle (have on-call duty this weekend) , but it dfu-loaded ok , and reports back as a BMP.

This is a nice addition to the toolbox , as my biggest problem with Versaloon & OOCD was that one of them always was out of sync :cry: … As in oocd comitted new patches and Simon didn’t tell witch oocd revision his versaloon pathch was made against.

Black Magic Probe has the OOCD part onboard the “Probe” so all you need is a working arm-none-eabi-gdb , the you have a working jtag/swd dongle.

It might not be as general or versatile as oocd , but you’ll always have the ability to flash your arm , if it’s known to BMP.

This is going to be my “rescue dongle” :slight_smile:

Edit: A bit more ino http://embdev.net/articles/STM_Discover … agic_Probe

                          CN5 JTAG Conn
                          --------------
 
                    JRST  -  o  o  - GND
                    JTDI  -  o  o  - JTMS/SWDIO
              JTCK/SWCLK  -  o  o  - JTDO
                                o  - +3v3

/Bingo