application: add SWD to JTAG sequence
This commit is contained in:
parent
e8d1a728d1
commit
563f8b604a
|
@ -389,6 +389,9 @@ static void command_jtag_scan(void* argument)
|
|||
gpio_set(channel_ports[tms], channel_pins[tms]); // start high (to go to reset state)
|
||||
gpio_mode_setup(channel_ports[tms], GPIO_MODE_OUTPUT, GPIO_PUPD_NONE, channel_pins[tms]); // set channel for TMS back to input
|
||||
jtag_tms_ch = tms; // remember which channel we use for TMS for the transaction
|
||||
jtag_transaction(0xffffffff, 0, 26); // ensure we are is reset state, even on SWD devices (needs 50 TMS hig);
|
||||
jtag_transaction(0xffffffff, 0, 26); // continuation
|
||||
jtag_transaction(0xE73C, 0, 16); // send sequence to switch any SWD device back to JTAG (this constant magic value)
|
||||
// all other channel should already be inputs
|
||||
jtag_transaction(0x3f | (0 << 6) | (1 << 7) | (0 << 8) | (0 << 9), 0, 6 + 1 + 1 + 1 + 1); // go back to JTAG TEST-LOGIC_RESET (5 bits should be enough to go from any state to RESET, but we a one just to be sure) -> RUN-TEST/IDLE -> SELECT-DR-SCAN -> CAPTURE-DR -> SHIFT-DR states
|
||||
// initialize array
|
||||
|
|
Loading…
Reference in New Issue