Re: [Openocd-development] Flashing STM32 F2

2011-12-15 Thread Laurent Charpentier
 I tried to flash STM32 F2 in the same way like i do on F1
 devices and hit some issues:
 
 My 1st try was with stm32f2x mass_erase 0 but seems that
 there is no subcommands registered.

You can use the following command instead:
monitor flash erase_sector 0 0 11

Laurent

___
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development


Re: [Openocd-development] rename st32 flash drivers

2011-07-28 Thread Laurent Charpentier
Hi Spencer,

 Idea is to bring the stm32 flash drivers inline with their
 actual names, eg.
 stm32x to stm32f1x
 stm32f2xxx to stm32f2x

This is a good idea to clean that up.
I think you can go one step further by dropping the 'x' (which has no meaning) 
in order to rename:
 - stm32x to stm32f1
 - stm32f2xxx to stm32f2

Laurent
___
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development


Re: [Openocd-development] Configuration file for stm32f2xxx

2011-06-07 Thread Laurent Charpentier
Hi Øyvind,Here are the patches attached.
Laurent
--- On Tue, 6/7/11, Øyvind Harboe oyvind.har...@zylin.com wrote:

From: Øyvind Harboe oyvind.har...@zylin.com
Subject: Re: [Openocd-development] Configuration file for stm32f2xxx
To: Laurent Charpentier laurent_p...@yahoo.com
Cc: openocd-development@lists.berlios.de
Date: Tuesday, June 7, 2011, 12:13 AM

Please provide a git patch. That way I don't have to piece together the
story from the email thread.

Thanks!




-- 
Øyvind Harboe

Can Zylin Consulting help on your project?


US toll free 1-866-980-3434 / International +47 51 87 40 27

http://www.zylin.com/zy1000.html
ARM7 ARM9 ARM11 XScale Cortex
JTAG debugger and flash programmer





0001-Configuration-file-for-stm32f2xxx.patch
Description: Binary data


0002-Added-configuration-file-for-STM3220G-EVAL-board.patch
Description: Binary data


0003-Added-STM32F2-configuration-file.patch
Description: Binary data
___
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development


Re: [Openocd-development] Configuration file for stm32f2xxx

2011-06-07 Thread Laurent Charpentier
Here are the configuration files for STM32F2xxx to review:

0001-Added-configuration-file-for-stm32f2xxx.patch
Description: Binary data


0002-Added-configuration-file-for-STM3220G-EVAL-board.patch
Description: Binary data
___
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development


[Openocd-development] Configuration file for stm32f2xxx

2011-06-06 Thread Laurent Charpentier
Hi,
We would like to add the configuration file for the stm32f2xxx to the GIT 
repository.
Here is the file (should be named openocd/tcl/target/stm32f2xxx.cfg )
Thanks for adding this file.
Laurent

--
# script for stm32f2xxx

if { [info exists CHIPNAME] } {
   set  _CHIPNAME $CHIPNAME
} else {
   set  _CHIPNAME stm32f2xxx
}

if { [info exists ENDIAN] } {
   set  _ENDIAN $ENDIAN
} else {
   set  _ENDIAN little
}

# Work-area is a space in RAM used for flash programming
# By default use 128kB
if { [info exists WORKAREASIZE] } {
   set  _WORKAREASIZE $WORKAREASIZE
} else {
   set  _WORKAREASIZE 0x2
}

# JTAG speed should be = F_CPU/6. F_CPU after reset is 8MHz, so use F_JTAG = 
1MHz
jtag_khz 1000

jtag_nsrst_delay 100
jtag_ntrst_delay 100

#jtag scan chain
if { [info exists CPUTAPID ] } {
   set _CPUTAPID $CPUTAPID
} else {
  # See STM Document RM0033
  # Section 32.6.3 - corresponds to Cortex-M3 r2p0
   set _CPUTAPID 0x4ba00477
}
jtag newtap $_CHIPNAME cpu -irlen 4 -ircapture 0x1 -irmask 0xf -expected-id 
$_CPUTAPID

if { [info exists BSTAPID ] } {
   set _BSTAPID $BSTAPID
} else {
  # See STM Document RM0033
  # Section 32.6.2
  # 
  set _BSTAPID 0x06411041
}
jtag newtap $_CHIPNAME bs -irlen 5 -expected-id $_BSTAPID

set _TARGETNAME $_CHIPNAME.cpu
target create $_TARGETNAME cortex_m3 -endian $_ENDIAN -chain-position 
$_TARGETNAME

$_TARGETNAME configure -work-area-phys 0x2000 -work-area-size 
$_WORKAREASIZE -work-area-backup 0

set _FLASHNAME $_CHIPNAME.flash
flash bank $_FLASHNAME stm32f2xxx 0 0 0 0 $_TARGETNAME

# For more information about the configuration files, take a look at:
# openocd.texi
___
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development


Re: [Openocd-development] Configuration file for stm32f2xxx

2011-06-06 Thread Laurent Charpentier
Andreas,STM32F2 is referenced as stm32f2xxx (3 Xs) in the openocd project 
(don't ask me why :).
for example:./src/flash/nor/stm32f2xxx.c./contrib/loaders/flash/stm32f2xxx.S
To make it consistent I kept the 3 Xs.Laurent

--- On Mon, 6/6/11, Andreas Fritiofson andreas.fritiof...@gmail.com wrote:

From: Andreas Fritiofson andreas.fritiof...@gmail.com
Subject: Re: [Openocd-development] Configuration file for stm32f2xxx
To: Øyvind Harboe oyvind.har...@zylin.com
Cc: Laurent Charpentier laurent_p...@yahoo.com, 
openocd-development@lists.berlios.de
Date: Monday, June 6, 2011, 2:40 AM



On Mon, Jun 6, 2011 at 11:23 AM, Øyvind Harboe oyvind.har...@zylin.com wrote:

To create a patch:



git add tcl/tcl/target/stm32f2xxx.cfg
 Another minor thing I noticed now, why three x in the file name? And in the 
flash driver too it seems? Shouldn't it be stm32f2xx?

(also, to avoid confusion, I'll just point out that the above git snippet has 
tcl/ duplicated in the path)
/Andreas

___
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development


Re: [Openocd-development] Configuration file for stm32f2xxx

2011-06-06 Thread Laurent Charpentier
I added the tcl/target/stm32f2xxx.cfg file.
I changed the 128KB RAM size to 64KB according to Andreas' note.

L.

___
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development


Re: [Openocd-development] Configuration file for stm32f2xxx

2011-06-06 Thread Laurent Charpentier
I also added the STM3220G-EVAL configuration file to 
tcl/board/stm3220g_eval.cfg



# STM3220G-EVAL: This is an STM32F2 eval board with a single STM32F207IGT6
# (128KB) chip.
# http://www.st.com/internet/evalboard/product/250374.jsp

# increase working area to 128KB
set WORKAREASIZE 0x2

# chip name
set CHIPNAME STM32F207IGT6

source [find target/stm32f2xxx.cfg]


___
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development


[Openocd-development] bootstrap: patch proposal

2011-05-31 Thread Laurent Charpentier
Hi Everyone,

I would like to propose a (minor) patch for the bootstrap file.

Code at line 30: 
if [ -n $1 ] || [ $1 != nosubmodule ]

This condition is always TRUE:
 - TRUE if string is non-zero
 - TRUE if string is zero (since empty string is different from nosubmodule)

This issue prevents from running bootstrap with nosubmodule.

I attached a proposed patch.

Laurent

bootstrap.patch
Description: Binary data
___
Openocd-development mailing list
Openocd-development@lists.berlios.de
https://lists.berlios.de/mailman/listinfo/openocd-development