Comment flasher bootloader sur dropix v1 sous openocd/linux?

Bonjour,

Bravo pour la dropix v1, mais en voulant jouer avec 1 an après l’avoir achetée…

Comme l’upload de firmware ne fonctionnait pas avec qgc sous linux (du moins je n’ai pas réussi à le faire fonctionner)
J’ai commencer à vouloir m’assurer que les bootloaders étaient à jour et c’est là que j’ai fait une fausse manip et uploadé le firmware de la pxio dans la pxfmu (Oups!)
Du coup la carte ne fonctionne plus du tout, mais qu’à cela ne tienne, je me dis que je vais faire comme les grands et utiliser le connecteur JTAG/SWD.
C’est là qu’arrive le souci, j’ai un message d’erreur dont j’ignore la source et que je n’arrive pas à traiter

L’instruction qui pose problème:

openocd -s /home/olivier/openocd-0.9.0/tcl/interface/ftdi -s /home/olivier/openocd-0.9.0/tcl/target -f olimex-arm-usb-tiny-h.cfg -f olimex-arm-jtag-swd.cfg -f stm32f4x.cfg

olimex-arm-usb-tiny-h.cfg

Olimex ARM-USB-TINY-H

olimex.com/dev/arm-usb-tiny-h.html

interface ftdi
ftdi_device_desc "Olimex OpenOCD JTAG ARM-USB-TINY-H"
ftdi_vid_pid 0x15ba 0x002a
ftdi_serial OLYXFG2L

ftdi_layout_init 0x0808 0x0a1b
ftdi_layout_signal nSRST -oe 0x0200
ftdi_layout_signal nTRST -data 0x0100 -oe 0x0100
ftdi_layout_signal LED -data 0x0800

olimex-arm-jtag-swd.cfg

Olimex ARM JTAG SWD adapter

olimex.com/Products/ARM/JTAG/ARM-JTAG-SWD/

transport select swd
ftdi_layout_signal SWD_EN -nalias nTRST
ftdi_layout_signal SWDIO_OE -alias TMS

stm32f4x.cfg

script for stm32f4x family

stm32 devices support both JTAG and SWD transports.

source [find target/swj-dp.tcl]
source [find mem_helper.tcl]

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

set _ENDIAN little

Work-area is a space in RAM used for flash programming

By default use 64kB

if { [info exists WORKAREASIZE] } {
set _WORKAREASIZE $WORKAREASIZE
} else {
set _WORKAREASIZE 0x10000
}

#jtag scan chain
if { [info exists CPUTAPID] } {
set _CPUTAPID $CPUTAPID
} else {
if { [using_jtag] } {
# See STM Document RM0090
# Section 38.6.3 - corresponds to Cortex-M4 r0p1
set _CPUTAPID 0x4ba00477
} {
set _CPUTAPID 0x2ba01477
}
}

swj_newdap $_CHIPNAME cpu -irlen 4 -ircapture 0x1 -irmask 0xf -expected-id $_CPUTAPID

if { [info exists BSTAPID] } {
set _BSTAPID $BSTAPID
} else {

See STM Document RM0090

Section 38.6.2

STM32F405xx/07xx and STM32F415xx/17xx

set _BSTAPID1 0x06413041

STM32F42xxx and STM32F43xxx

set _BSTAPID2 0x06419041

See STM Document RM0368 (Rev. 3)

STM32F401B/C

set _BSTAPID3 0x06423041

STM32F401D/E

set _BSTAPID4 0x06433041

See STM Document RM0383 (Rev 2)

STM32F411

set _BSTAPID5 0x06431041
}

if {[using_jtag]} {
swj_newdap $_CHIPNAME bs -irlen 5 -expected-id $_BSTAPID1
-expected-id $_BSTAPID2 -expected-id $_BSTAPID3
-expected-id $_BSTAPID4 -expected-id $_BSTAPID5
}

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

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

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

JTAG speed should be <= F_CPU/6. F_CPU after reset is 16MHz, so use F_JTAG = 2MHz

Since we may be running of an RC oscilator, we crank down the speed a

bit more to be on the safe side. Perhaps superstition, but if are

running off a crystal, we can run closer to the limit. Note

that there can be a pretty wide band where things are more or less stable.

adapter_khz 2000
#adapter_khz 100

adapter_nsrst_delay 100
if {[using_jtag]} {
jtag_ntrst_delay 100
}

reset_config srst_nogate

if {![using_hla]} {

if srst is not fitted use SYSRESETREQ to

perform a soft reset

cortex_m reset_config sysresetreq
}

$_TARGETNAME configure -event examine-end {
# DBGMCU_CR |= DBG_STANDBY | DBG_STOP | DBG_SLEEP
mmw 0xE0042004 0x00000007 0

# Stop watchdog counters during halt
# DBGMCU_APB1_FZ = DBG_IWDG_STOP | DBG_WWDG_STOP
mww 0xE0042008 0x00001800

}

$_TARGETNAME configure -event trace-config {
# Set TRACE_IOEN; TRACE_MODE is set to async; when using sync
# change this value accordingly to configure trace pins
# assignment
mmw 0xE0042004 0x00000020 0
}

Le log d’erreurs:

Open On-Chip Debugger 0.9.0 (2015-08-18-20:59)
Licensed under GNU GPL v2
For bug reports, read
openocd.org/doc/doxygen/bugs.html
User : 13 1 command.c:546 command_print(): debug_level: 3
Debug: 14 1 configuration.c:44 add_script_search_dir(): adding /home/olivier/openocd-0.9.0/tcl/interface/ftdi
Debug: 15 1 configuration.c:44 add_script_search_dir(): adding /home/olivier/openocd-0.9.0/tcl/target
Debug: 16 1 options.c:98 add_default_dirs(): bindir=/usr/local/bin
Debug: 17 1 options.c:99 add_default_dirs(): pkgdatadir=/usr/local/share/openocd
Debug: 18 1 options.c:100 add_default_dirs(): run_prefix=
Debug: 19 2 configuration.c:44 add_script_search_dir(): adding /home/olivier/.openocd
Debug: 20 2 configuration.c:44 add_script_search_dir(): adding /usr/local/share/openocd/site
Debug: 21 2 configuration.c:44 add_script_search_dir(): adding /usr/local/share/openocd/scripts
Debug: 22 2 configuration.c:84 find_file(): found /home/olivier/openocd-0.9.0/tcl/interface/ftdi/olimex-arm-usb-tiny-h.cfg
Debug: 23 2 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_interface ftdi
Debug: 24 2 command.c:145 script_debug(): command - interface ocd_interface ftdi
Debug: 26 2 command.c:366 register_command_handler(): registering ‘ocd_ftdi_device_desc’…
Debug: 27 2 command.c:366 register_command_handler(): registering ‘ocd_ftdi_serial’…
Debug: 28 2 command.c:366 register_command_handler(): registering ‘ocd_ftdi_channel’…
Debug: 29 2 command.c:366 register_command_handler(): registering ‘ocd_ftdi_layout_init’…
Debug: 30 3 command.c:366 register_command_handler(): registering ‘ocd_ftdi_layout_signal’…
Debug: 31 3 command.c:366 register_command_handler(): registering ‘ocd_ftdi_set_signal’…
Debug: 32 3 command.c:366 register_command_handler(): registering ‘ocd_ftdi_vid_pid’…
Debug: 33 3 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_ftdi_device_desc Olimex OpenOCD JTAG ARM-USB-TINY-H
Debug: 34 3 command.c:145 script_debug(): command - ftdi_device_desc ocd_ftdi_device_desc Olimex OpenOCD JTAG ARM-USB-TINY-H
Debug: 36 3 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_ftdi_vid_pid 0x15ba 0x002a
Debug: 37 3 command.c:145 script_debug(): command - ftdi_vid_pid ocd_ftdi_vid_pid 0x15ba 0x002a
Debug: 39 3 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_ftdi_serial OLYXFG2L
Debug: 40 3 command.c:145 script_debug(): command - ftdi_serial ocd_ftdi_serial OLYXFG2L
Debug: 42 3 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_ftdi_layout_init 0x0808 0x0a1b
Debug: 43 3 command.c:145 script_debug(): command - ftdi_layout_init ocd_ftdi_layout_init 0x0808 0x0a1b
Debug: 45 4 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_ftdi_layout_signal nSRST -oe 0x0200
Debug: 46 4 command.c:145 script_debug(): command - ftdi_layout_signal ocd_ftdi_layout_signal nSRST -oe 0x0200
Debug: 48 4 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_ftdi_layout_signal nTRST -data 0x0100 -oe 0x0100
Debug: 49 4 command.c:145 script_debug(): command - ftdi_layout_signal ocd_ftdi_layout_signal nTRST -data 0x0100 -oe 0x0100
Debug: 51 4 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_ftdi_layout_signal LED -data 0x0800
Debug: 52 4 command.c:145 script_debug(): command - ftdi_layout_signal ocd_ftdi_layout_signal LED -data 0x0800
Debug: 54 4 configuration.c:84 find_file(): found /home/olivier/openocd-0.9.0/tcl/interface/ftdi/olimex-arm-jtag-swd.cfg
Debug: 55 4 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_transport select swd
Debug: 56 4 command.c:145 script_debug(): command - ocd_transport ocd_transport select swd
Debug: 57 4 command.c:325 command_new(): BUG: command ‘swd’ does not have the ‘.usage’ field filled out
Debug: 58 5 command.c:366 register_command_handler(): registering ‘ocd_swd’…
Debug: 59 5 command.c:366 register_command_handler(): registering ‘ocd_swd’…
Info : 60 5 ftdi.c:920 ftdi_swd_init(): FTDI SWD mode enabled
Debug: 61 5 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_ftdi_layout_signal SWD_EN -nalias nTRST
Debug: 62 5 command.c:145 script_debug(): command - ftdi_layout_signal ocd_ftdi_layout_signal SWD_EN -nalias nTRST
Debug: 64 5 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_ftdi_layout_signal SWDIO_OE -alias TMS
Debug: 65 5 command.c:145 script_debug(): command - ftdi_layout_signal ocd_ftdi_layout_signal SWDIO_OE -alias TMS
Debug: 67 5 configuration.c:84 find_file(): found /home/olivier/openocd-0.9.0/tcl/target/stm32f4x.cfg
Debug: 68 5 configuration.c:84 find_file(): found /usr/local/share/openocd/scripts/target/swj-dp.tcl
Debug: 69 5 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_transport select
Debug: 70 6 command.c:145 script_debug(): command - ocd_transport ocd_transport select
Debug: 71 6 configuration.c:84 find_file(): found /usr/local/share/openocd/scripts/mem_helper.tcl
Debug: 72 6 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_add_usage_text mrw address
Debug: 73 6 command.c:145 script_debug(): command - add_usage_text ocd_add_usage_text mrw address
Debug: 75 6 command.c:1100 help_add_command(): added ‘mrw’ help text
Debug: 76 6 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_add_help_text mrw Returns value of word in memory.
Debug: 77 6 command.c:145 script_debug(): command - add_help_text ocd_add_help_text mrw Returns value of word in memory.
Debug: 79 6 command.c:1113 help_add_command(): added ‘mrw’ help text
Debug: 80 7 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_add_usage_text mmw address setbits clearbits
Debug: 81 7 command.c:145 script_debug(): command - add_usage_text ocd_add_usage_text mmw address setbits clearbits
Debug: 83 7 command.c:1100 help_add_command(): added ‘mmw’ help text
Debug: 84 7 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_add_help_text mmw Modify word in memory. new_val = (old_val & ~clearbits) | setbits;
Debug: 85 7 command.c:145 script_debug(): command - add_help_text ocd_add_help_text mmw Modify word in memory. new_val = (old_val & ~clearbits) | setbits;
Debug: 87 7 command.c:1113 help_add_command(): added ‘mmw’ help text
Debug: 88 7 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_transport select
Debug: 89 7 command.c:145 script_debug(): command - ocd_transport ocd_transport select
Debug: 90 7 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_transport select
Debug: 91 8 command.c:145 script_debug(): command - ocd_transport ocd_transport select
Debug: 92 8 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_transport select
Debug: 93 8 command.c:145 script_debug(): command - ocd_transport ocd_transport select
Debug: 94 8 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_transport select
Debug: 95 8 command.c:145 script_debug(): command - ocd_transport ocd_transport select
Debug: 96 8 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_swd newdap stm32f4x cpu -irlen 4 -ircapture 0x1 -irmask 0xf -expected-id 0x2ba01477
Debug: 97 8 command.c:145 script_debug(): command - ocd_swd ocd_swd newdap stm32f4x cpu -irlen 4 -ircapture 0x1 -irmask 0xf -expected-id 0x2ba01477
Debug: 98 10 tcl.c:549 jim_newtap_cmd(): Creating New Tap, Chip: stm32f4x, Tap: cpu, Dotted: stm32f4x.cpu, 8 params
Debug: 99 10 core.c:1302 jtag_tap_init(): Created Tap: stm32f4x.cpu @ abs position 0, irlen 0, capture: 0x0 mask: 0x0
Debug: 100 10 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_transport select
Debug: 101 10 command.c:145 script_debug(): command - ocd_transport ocd_transport select
Debug: 102 10 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_target create stm32f4x.cpu cortex_m -endian little -chain-position stm32f4x.cpu
Debug: 103 10 command.c:145 script_debug(): command - ocd_target ocd_target create stm32f4x.cpu cortex_m -endian little -chain-position stm32f4x.cpu
Debug: 104 10 target.c:1837 target_free_all_working_areas_restore(): freeing all working areas
Debug: 105 10 command.c:366 register_command_handler(): registering ‘ocd_arm’…
Debug: 106 11 command.c:366 register_command_handler(): registering ‘ocd_arm’…
Debug: 107 11 command.c:366 register_command_handler(): registering ‘ocd_arm’…
Debug: 108 11 command.c:366 register_command_handler(): registering ‘ocd_arm’…
Debug: 109 11 command.c:366 register_command_handler(): registering ‘ocd_arm’…
Debug: 110 11 command.c:366 register_command_handler(): registering ‘ocd_arm’…
Debug: 111 11 command.c:366 register_command_handler(): registering ‘ocd_dap’…
Debug: 112 11 command.c:366 register_command_handler(): registering ‘ocd_dap’…
Debug: 113 11 command.c:366 register_command_handler(): registering ‘ocd_dap’…
Debug: 114 11 command.c:366 register_command_handler(): registering ‘ocd_dap’…
Debug: 115 11 command.c:366 register_command_handler(): registering ‘ocd_dap’…
Debug: 116 11 command.c:366 register_command_handler(): registering ‘ocd_dap’…
Debug: 117 12 command.c:366 register_command_handler(): registering ‘ocd_dap’…
Debug: 118 12 command.c:366 register_command_handler(): registering ‘ocd_tpiu’…
Debug: 119 12 command.c:366 register_command_handler(): registering ‘ocd_itm’…
Debug: 120 12 command.c:366 register_command_handler(): registering ‘ocd_itm’…
Debug: 121 12 command.c:366 register_command_handler(): registering ‘ocd_cortex_m’…
Debug: 122 12 command.c:366 register_command_handler(): registering ‘ocd_cortex_m’…
Debug: 123 12 command.c:366 register_command_handler(): registering ‘ocd_cortex_m’…
Debug: 124 12 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 125 12 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 126 12 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 127 12 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 128 13 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 129 13 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 130 13 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 131 13 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 132 13 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 133 13 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 134 13 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 135 13 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 136 13 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 137 13 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 138 13 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 139 14 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 140 14 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 141 14 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 142 14 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 143 14 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 144 14 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 145 14 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 146 14 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 147 14 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 148 14 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 149 15 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 150 15 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 151 15 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 152 15 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 153 15 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 154 15 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 155 15 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 156 15 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 157 15 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 158 15 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 159 15 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 160 16 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 161 16 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 162 16 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 163 16 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 164 16 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 165 16 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 166 16 command.c:366 register_command_handler(): registering ‘ocd_stm32f4x.cpu’…
Debug: 167 16 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_stm32f4x.cpu configure -work-area-phys 0x20000000 -work-area-size 0x10000 -work-area-backup 0
Debug: 168 16 command.c:145 script_debug(): command - ocd_stm32f4x.cpu ocd_stm32f4x.cpu configure -work-area-phys 0x20000000 -work-area-size 0x10000 -work-area-backup 0
Debug: 169 16 target.c:1837 target_free_all_working_areas_restore(): freeing all working areas
Debug: 170 16 target.c:1837 target_free_all_working_areas_restore(): freeing all working areas
Debug: 171 16 target.c:1837 target_free_all_working_areas_restore(): freeing all working areas
Debug: 172 16 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_flash bank stm32f4x.flash stm32f2x 0 0 0 0 stm32f4x.cpu
Debug: 173 16 command.c:145 script_debug(): command - ocd_flash ocd_flash bank stm32f4x.flash stm32f2x 0 0 0 0 stm32f4x.cpu
Debug: 175 16 command.c:366 register_command_handler(): registering ‘ocd_stm32f2x’…
Debug: 176 16 command.c:366 register_command_handler(): registering ‘ocd_stm32f2x’…
Debug: 177 17 command.c:366 register_command_handler(): registering ‘ocd_stm32f2x’…
Debug: 178 17 tcl.c:824 handle_flash_bank_command(): ‘stm32f2x’ driver usage field missing
Debug: 179 17 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_adapter_khz 2000
Debug: 180 17 command.c:145 script_debug(): command - adapter_khz ocd_adapter_khz 2000
Debug: 182 17 core.c:1629 jtag_config_khz(): handle jtag khz
Debug: 183 17 core.c:1596 adapter_khz_to_speed(): convert khz to interface specific speed value
Debug: 184 17 core.c:1596 adapter_khz_to_speed(): convert khz to interface specific speed value
User : 185 17 command.c:546 command_print(): adapter speed: 2000 kHz
Debug: 186 17 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_adapter_nsrst_delay 100
Debug: 187 17 command.c:145 script_debug(): command - adapter_nsrst_delay ocd_adapter_nsrst_delay 100
User : 189 17 command.c:546 command_print(): adapter_nsrst_delay: 100
Debug: 190 17 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_transport select
Debug: 191 17 command.c:145 script_debug(): command - ocd_transport ocd_transport select
Debug: 192 17 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_reset_config srst_nogate
Debug: 193 17 command.c:145 script_debug(): command - reset_config ocd_reset_config srst_nogate
User : 195 17 command.c:546 command_print(): none separate
Debug: 196 17 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_transport select
Debug: 197 17 command.c:145 script_debug(): command - ocd_transport ocd_transport select
Debug: 198 17 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_cortex_m reset_config sysresetreq
Debug: 199 17 command.c:145 script_debug(): command - ocd_cortex_m ocd_cortex_m reset_config sysresetreq
User : 201 17 command.c:546 command_print(): cortex_m reset_config sysresetreq
Debug: 202 18 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_stm32f4x.cpu configure -event examine-end
# DBGMCU_CR |= DBG_STANDBY | DBG_STOP | DBG_SLEEP
mmw 0xE0042004 0x00000007 0

# Stop watchdog counters during halt
# DBGMCU_APB1_FZ = DBG_IWDG_STOP | DBG_WWDG_STOP
mww 0xE0042008 0x00001800

Debug: 203 18 command.c:145 script_debug(): command - ocd_stm32f4x.cpu ocd_stm32f4x.cpu configure -event examine-end
# DBGMCU_CR |= DBG_STANDBY | DBG_STOP | DBG_SLEEP
mmw 0xE0042004 0x00000007 0

# Stop watchdog counters during halt
# DBGMCU_APB1_FZ = DBG_IWDG_STOP | DBG_WWDG_STOP
mww 0xE0042008 0x00001800

Debug: 204 18 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_stm32f4x.cpu configure -event trace-config
# Set TRACE_IOEN; TRACE_MODE is set to async; when using sync
# change this value accordingly to configure trace pins
# assignment
mmw 0xE0042004 0x00000020 0

Debug: 205 18 command.c:145 script_debug(): command - ocd_stm32f4x.cpu ocd_stm32f4x.cpu configure -event trace-config
# Set TRACE_IOEN; TRACE_MODE is set to async; when using sync
# change this value accordingly to configure trace pins
# assignment
mmw 0xE0042004 0x00000020 0

Debug: 206 18 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_init
Debug: 207 18 command.c:145 script_debug(): command - init ocd_init
Debug: 209 19 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_target init
Debug: 210 19 command.c:145 script_debug(): command - ocd_target ocd_target init
Debug: 212 19 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_target names
Debug: 213 19 command.c:145 script_debug(): command - ocd_target ocd_target names
Debug: 214 19 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_stm32f4x.cpu cget -event gdb-flash-erase-start
Debug: 215 19 command.c:145 script_debug(): command - ocd_stm32f4x.cpu ocd_stm32f4x.cpu cget -event gdb-flash-erase-start
Debug: 216 19 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_stm32f4x.cpu configure -event gdb-flash-erase-start reset init
Debug: 217 19 command.c:145 script_debug(): command - ocd_stm32f4x.cpu ocd_stm32f4x.cpu configure -event gdb-flash-erase-start reset init
Debug: 218 19 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_stm32f4x.cpu cget -event gdb-flash-write-end
Debug: 219 19 command.c:145 script_debug(): command - ocd_stm32f4x.cpu ocd_stm32f4x.cpu cget -event gdb-flash-write-end
Debug: 220 19 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_stm32f4x.cpu configure -event gdb-flash-write-end reset halt
Debug: 221 19 command.c:145 script_debug(): command - ocd_stm32f4x.cpu ocd_stm32f4x.cpu configure -event gdb-flash-write-end reset halt
Debug: 222 19 target.c:1313 handle_target_init_command(): Initializing targets…
Debug: 223 19 command.c:366 register_command_handler(): registering ‘ocd_target_request’…
Debug: 224 19 command.c:366 register_command_handler(): registering ‘ocd_trace’…
Debug: 225 19 command.c:366 register_command_handler(): registering ‘ocd_trace’…
Debug: 226 19 command.c:366 register_command_handler(): registering ‘ocd_fast_load_image’…
Debug: 227 20 command.c:366 register_command_handler(): registering ‘ocd_fast_load’…
Debug: 228 20 command.c:366 register_command_handler(): registering ‘ocd_profile’…
Debug: 229 20 command.c:366 register_command_handler(): registering ‘ocd_virt2phys’…
Debug: 230 20 command.c:366 register_command_handler(): registering ‘ocd_reg’…
Debug: 231 20 command.c:366 register_command_handler(): registering ‘ocd_poll’…
Debug: 232 20 command.c:366 register_command_handler(): registering ‘ocd_wait_halt’…
Debug: 233 20 command.c:366 register_command_handler(): registering ‘ocd_halt’…
Debug: 234 20 command.c:366 register_command_handler(): registering ‘ocd_resume’…
Debug: 235 20 command.c:366 register_command_handler(): registering ‘ocd_reset’…
Debug: 236 20 command.c:366 register_command_handler(): registering ‘ocd_soft_reset_halt’…
Debug: 237 20 command.c:366 register_command_handler(): registering ‘ocd_step’…
Debug: 238 20 command.c:366 register_command_handler(): registering ‘ocd_mdw’…
Debug: 239 20 command.c:366 register_command_handler(): registering ‘ocd_mdh’…
Debug: 240 20 command.c:366 register_command_handler(): registering ‘ocd_mdb’…
Debug: 241 20 command.c:366 register_command_handler(): registering ‘ocd_mww’…
Debug: 242 20 command.c:366 register_command_handler(): registering ‘ocd_mwh’…
Debug: 243 20 command.c:366 register_command_handler(): registering ‘ocd_mwb’…
Debug: 244 20 command.c:366 register_command_handler(): registering ‘ocd_bp’…
Debug: 245 20 command.c:366 register_command_handler(): registering ‘ocd_rbp’…
Debug: 246 20 command.c:366 register_command_handler(): registering ‘ocd_wp’…
Debug: 247 20 command.c:366 register_command_handler(): registering ‘ocd_rwp’…
Debug: 248 20 command.c:366 register_command_handler(): registering ‘ocd_load_image’…
Debug: 249 20 command.c:366 register_command_handler(): registering ‘ocd_dump_image’…
Debug: 250 20 command.c:366 register_command_handler(): registering ‘ocd_verify_image’…
Debug: 251 20 command.c:366 register_command_handler(): registering ‘ocd_test_image’…
Debug: 252 21 command.c:366 register_command_handler(): registering ‘ocd_reset_nag’…
Debug: 253 21 command.c:366 register_command_handler(): registering ‘ocd_ps’…
Debug: 254 21 command.c:366 register_command_handler(): registering ‘ocd_test_mem_access’…
Debug: 255 21 ftdi.c:625 ftdi_initialize(): ftdi interface using shortest path jtag state transitions
Debug: 256 71 mpsse.c:363 mpsse_purge(): -
Debug: 257 79 mpsse.c:644 mpsse_loopback_config(): off
Debug: 258 79 mpsse.c:689 mpsse_set_frequency(): target 2000000 Hz
Debug: 259 79 mpsse.c:681 mpsse_rtck_config(): off
Debug: 260 80 mpsse.c:670 mpsse_divide_by_5_config(): off
Debug: 261 80 mpsse.c:650 mpsse_set_divisor(): 14
Debug: 262 80 mpsse.c:713 mpsse_set_frequency(): actually 2000000 Hz
Debug: 263 84 core.c:1596 adapter_khz_to_speed(): convert khz to interface specific speed value
Debug: 264 84 core.c:1599 adapter_khz_to_speed(): have interface set up
Debug: 265 84 mpsse.c:689 mpsse_set_frequency(): target 2000000 Hz
Debug: 266 84 mpsse.c:681 mpsse_rtck_config(): off
Debug: 267 84 mpsse.c:670 mpsse_divide_by_5_config(): off
Debug: 268 84 mpsse.c:650 mpsse_set_divisor(): 14
Debug: 269 84 mpsse.c:713 mpsse_set_frequency(): actually 2000000 Hz
Debug: 270 84 core.c:1596 adapter_khz_to_speed(): convert khz to interface specific speed value
Debug: 271 84 core.c:1599 adapter_khz_to_speed(): have interface set up
Info : 272 84 core.c:1384 adapter_init(): clock speed 2000 kHz
Debug: 273 84 openocd.c:137 handle_init_command(): Debug Adapter init complete
Debug: 274 84 command.c:145 script_debug(): command - ocd_command ocd_command type ocd_transport init
Debug: 275 84 command.c:145 script_debug(): command - ocd_transport ocd_transport init
Debug: 277 84 transport.c:240 handle_transport_init(): handle_transport_init
Debug: 278 84 ftdi.c:1092 ftdi_swd_switch_seq(): JTAG-to-SWD
Debug: 279 84 ftdi.c:946 ftdi_swd_run_queue(): Executing 2 queued transactions
Debug: 280 87 ftdi.c:978 ftdi_swd_run_queue(): JUNK DP read reg 0 = ffffffff
Debug: 281 87 command.c:628 run_command(): Command failed with error code -4
User : 282 88 command.c:689 command_run_line(): in procedure 'init’
in procedure 'ocd_bouncer’
Debug: 283 88 command.c:628 run_command(): Command failed with error code -4
User : 284 88 command.c:689 command_run_line():

La panoplie:

openocd 0.9.0
un debugger jtag/swd (ARM-USB-TINY-H de Olimex) 
un adaptateur ARM-JTAG-20-10 de Olimex
JTAG_1 de la dropix V1

Connectique:

sur la dropix le fil rouge est sur la pin 1 au bord de la carte côté connecteur USB (Si je me trompe pas)
sur ARM-JTAG-20-10 le sens est facile à trouver, la pin 7 est coupée

SOS:

La longueur de ce message est à l’image de mon désespoir
Merci par avance pour une solution ou un indice qui me permettrait d’avancer!

olivier

Le plus simple est de nous renvoyer la carte et on vous fera la manip.

Merci pour votre réponse et pour le service après-vente

Sans vouloir abuser de votre temps,
j’ai déjà passé plusieurs jours à essayer de régler ce problème
et idéalement j’aimerais comprendre pour pouvoir être autonome en cas de nouvelle fausse manip.

Y aurait-il des pins à court-circuiter (pont)? Des résistances à ajouter pour mettre en pull-up des signaux?
Je n’ai pas trouvé le design de la carte. Y-a-t-il des pads boot0 et vdd pour passer en mode bootloader STM?

Si c’est simplement un souci de configuration openocd, je me débrouillerai et finirai par trouver

Merci pour votre aide
olivier

Non il n’y a rien pour modifier le boot0. Nous passons par le connecteur JTAG avec un STLINK32 pour reflasher la carte.

Merci pour l’info,
Je vais essayer avec un ST-LINK