2
0
mirror of git://git.code.sf.net/p/openocd/code synced 2025-07-20 13:48:12 +10:00
openocd/tcl/target
Salvador Arroyo 1d040adb0d pic32mx: 0 wait state option
By default pic32mx starts after any reset with 1 wait state for RAM access/exec.
It can be changed to 0 wait states by clearing the BMXWSDRM bit (bit 6) in BMXCON register.
With 0 wait states near doubles the execution speed. CRC check sum can be done much faster
increasing verify_image speed. Fast data transfer also works with a bit higher scan rate, up to 1500 Khz.
This option can be set at any time with
mww 0xbf882004 0x40
or cleared with
mww 0xbf882008 0x40.
Some numbers for FTDI/HS with current devel code and a elf file:

Core clock / wait states	             verify_image speed
------------------------------------|------------------------------

        4 Mhz    /    1                            21 KiB/s
        4 Mhz    /    0                            36 KiB/s
        8 Mhz    /    1                            37 KiB/s
        8 Mhz    /    0                            57 KiB/s

Change-Id: I4092ad0f3753f72f77108718d0ed3a3ab84e3b23
Signed-off-by: Salvador Arroyo <sarroyofdez@yahoo.es>
Reviewed-on: http://openocd.zylin.com/1141
Tested-by: jenkins
Reviewed-by: Spencer Oliver <spen@spen-soft.co.uk>
Reviewed-by: Xiaofan <xiaofanc@gmail.com>
2013-04-02 15:12:44 +00:00
..
aduc702x.cfg target: remove legacy target events 2012-05-21 16:19:28 +00:00
am335x.cfg
amdm37x.cfg
ar71xx.cfg
at32ap7000.cfg
at91r40008.cfg
at91rm9200.cfg
at91sam3ax_4x.cfg
at91sam3ax_8x.cfg
at91sam3ax_xx.cfg
at91sam3nXX.cfg cfg: update for target's that support cortex_m AIRCR SYSRESETREQ 2012-08-29 06:24:36 +00:00
at91sam3sXX.cfg
at91sam3u1c.cfg
at91sam3u1e.cfg
at91sam3u2c.cfg
at91sam3u2e.cfg
at91sam3u4c.cfg
at91sam3u4e.cfg
at91sam3uxx.cfg
at91sam3XXX.cfg cfg: update for target's that support cortex_m AIRCR SYSRESETREQ 2012-08-29 06:24:36 +00:00
at91sam4sXX.cfg topic: Added support for the SAM4S variants 2012-04-26 10:58:14 +00:00
at91sam4XXX.cfg cfg: update for target's that support cortex_m AIRCR SYSRESETREQ 2012-08-29 06:24:36 +00:00
at91sam7se512.cfg
at91sam7sx.cfg
at91sam7x256.cfg
at91sam7x512.cfg
at91sam9.cfg
at91sam9g10.cfg
at91sam9g20.cfg
at91sam9g45.cfg
at91sam9rl.cfg
at91sam9260_ext_RAM_ext_flash.cfg
at91sam9260.cfg
at91sam9261.cfg
at91sam9263.cfg
atmega128.cfg
avr32.cfg scripts: use adapter_nsrst_delay not deprecated jtag_nsrst_delay 2012-03-30 16:01:51 +00:00
c100.cfg
c100config.tcl
c100helper.tcl
c100regs.tcl
cs351x.cfg
davinci.cfg
dragonite.cfg
dsp56321.cfg
dsp568013.cfg
dsp568037.cfg
efm32_stlink.cfg flash: EFM32 flash implementation 2013-01-14 10:25:55 +00:00
epc9301.cfg
faux.cfg
feroceon.cfg
fm3.cfg scripts: use adapter_nsrst_delay not deprecated jtag_nsrst_delay 2012-03-30 16:01:51 +00:00
hilscher_netx10.cfg
hilscher_netx50.cfg
hilscher_netx500.cfg
icepick.cfg
imx6.cfg cfg: add basic support of Freescale i.MX6 series targets 2013-03-06 19:06:06 +00:00
imx21.cfg
imx25.cfg
imx27.cfg
imx28.cfg
imx31.cfg
imx35.cfg
imx51.cfg
imx53.cfg
imx.cfg
is5114.cfg
ixp42x.cfg
k40.cfg cfg: update for target's that support cortex_m AIRCR SYSRESETREQ 2012-08-29 06:24:36 +00:00
k60.cfg cfg: update for target's that support cortex_m AIRCR SYSRESETREQ 2012-08-29 06:24:36 +00:00
lpc2xxx.cfg
lpc17xx.cfg cfg: update for target's that support cortex_m AIRCR SYSRESETREQ 2012-08-29 06:24:36 +00:00
lpc1751.cfg added target configs for the lpc17xx devices 2012-08-01 21:15:01 +00:00
lpc1752.cfg added target configs for the lpc17xx devices 2012-08-01 21:15:01 +00:00
lpc1754.cfg added target configs for the lpc17xx devices 2012-08-01 21:15:01 +00:00
lpc1756.cfg added target configs for the lpc17xx devices 2012-08-01 21:15:01 +00:00
lpc1758.cfg added target configs for the lpc17xx devices 2012-08-01 21:15:01 +00:00
lpc1759.cfg added target configs for the lpc17xx devices 2012-08-01 21:15:01 +00:00
lpc1763.cfg added target configs for the lpc17xx devices 2012-08-01 21:15:01 +00:00
lpc1764.cfg added target configs for the lpc17xx devices 2012-08-01 21:15:01 +00:00
lpc1765.cfg added target configs for the lpc17xx devices 2012-08-01 21:15:01 +00:00
lpc1766.cfg added target configs for the lpc17xx devices 2012-08-01 21:15:01 +00:00
lpc1767.cfg added target configs for the lpc17xx devices 2012-08-01 21:15:01 +00:00
lpc1768.cfg lpc1768.cfg abstracted and moved to lpc17xx.cfg 2012-07-30 06:18:51 +00:00
lpc1769.cfg added target configs for the lpc17xx devices 2012-08-01 21:15:01 +00:00
lpc1788.cfg LPC1788 target configuration file. 2012-12-11 12:42:32 +00:00
lpc1850.cfg Added support for NXP LPC1850 Microcontroller 2012-11-06 14:34:37 +00:00
lpc2103.cfg
lpc2124.cfg
lpc2129.cfg
lpc2148.cfg
lpc2294.cfg
lpc2378.cfg
lpc2460.cfg
lpc2478.cfg
lpc2900.cfg
lpc3131.cfg scripts: use adapter_nsrst_delay not deprecated jtag_nsrst_delay 2012-03-30 16:01:51 +00:00
lpc3250.cfg
lpc4350.cfg Change reset configuration. 2013-03-05 15:09:23 +00:00
mc13224v.cfg
nuc910.cfg
omap2420.cfg
omap3530.cfg
omap4430.cfg
omap4460.cfg omap4460: add initial TCL support for the omap4460 es1.0 2012-04-18 20:00:27 +00:00
omap5912.cfg
omapl138.cfg
pic32mx.cfg pic32mx: 0 wait state option 2013-04-02 15:12:44 +00:00
pxa3xx.cfg
pxa255.cfg
pxa270.cfg
readme.txt
samsung_s3c2410.cfg
samsung_s3c2440.cfg
samsung_s3c2450.cfg
samsung_s3c4510.cfg
samsung_s3c6410.cfg
sharp_lh79532.cfg
smp8634.cfg
spear3xx.cfg
stellaris_icdi.cfg icdi: add TI icdi interface 2012-12-23 21:46:20 +00:00
stellaris.cfg
stm32_stlink.cfg stlink: rename stlink cmd names 2012-12-23 21:45:42 +00:00
stm32f0x_stlink.cfg cfg: increase stm32f0 default working area 2012-05-08 14:05:11 +00:00
stm32f1x_stlink.cfg cfg: allow stm32discovery parameter override 2012-04-30 13:06:29 +00:00
stm32f1x.cfg
stm32f2x_stlink.cfg cfg: allow stm32discovery parameter override 2012-04-30 13:06:29 +00:00
stm32f2x.cfg scripts: use adapter_nsrst_delay not deprecated jtag_nsrst_delay 2012-03-30 16:01:51 +00:00
stm32f3x_stlink.cfg cfg: fix incorrect stm32f3 TAPID 2012-10-02 09:37:56 +00:00
stm32f3x.cfg flash: add stm32f3x support 2012-07-11 10:32:39 +00:00
stm32f4x_stlink.cfg cfg: allow stm32discovery parameter override 2012-04-30 13:06:29 +00:00
stm32f4x.cfg cfg: add STM32F4x and STM3241G-EVAL config files 2012-03-30 16:02:14 +00:00
stm32l.cfg cfg: stm32l use minimum family ram size for working area 2012-12-30 11:34:46 +00:00
stm32lx_dual_bank.cfg stm32: add support for the STM32Lx 384kb dual bank flash 2013-02-25 11:56:34 +00:00
stm32lx_stlink.cfg stm32: add support for the STM32Lx 384kb dual bank flash 2013-02-25 11:56:34 +00:00
stm32xl.cfg
str710.cfg
str730.cfg
str750.cfg
str912.cfg
swj-dp.tcl
test_reset_syntax_error.cfg
test_syntax_error.cfg
ti_calypso.cfg config: Add TI Calypso CPU configuration 2012-05-25 12:06:22 +00:00
ti_dm355.cfg
ti_dm365.cfg
ti_dm6446.cfg
ti-ar7.cfg cfg: add Netgear DG834v3 configuration 2013-03-06 21:57:29 +00:00
tmpa900.cfg
tmpa910.cfg
u8500.cfg

Prerequisites:
The users of OpenOCD as well as computer programs interacting with OpenOCD are expecting that certain commands
do the same thing across all the targets.

Rules to follow when writing scripts:

1. The configuration script should be defined such as , for example, the following sequences are working:
	reset
	flash info <bank>
and
	reset
	flash erase_address <start> <len>
and
	reset init
	load

In most cases this can be accomplished by specifying the default startup mode as reset_init (target command
in the configuration file).

2. If the target is correctly configured, flash must be writable without any other helper commands. It is
assumed that all write-protect mechanisms should be disabled.

3. The configuration scripts should be defined such as the binary that was written to flash verifies
(turn off remapping, checksums, etc...)

flash write_image [file] <parameters>
verify_image [file] <parameters>

4. adapter_khz sets the maximum speed (or alternatively RCLK). If invoked
multiple times only the last setting is used.

interface/xxx.cfg files are always executed *before* target/xxx.cfg
files, so any adapter_khz in interface/xxx.cfg will be overridden by
target/xxx.cfg. adapter_khz in interface/xxx.cfg would then, effectively,
set the default JTAG speed.

Note that a target/xxx.cfg file can invoke another target/yyy.cfg file,
so one can create target subtype configurations where e.g. only
amount of DRAM, oscillator speeds differ and having a single
config file for the default/common settings.