|
@ -196,7 +196,7 @@ static bool cmd_jtag_scan(target *t, int argc, char **argv) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
if(connect_assert_srst) |
|
|
if(connect_assert_srst) |
|
|
platform_srst_set_val(true); /* will be deasserted after attach */ |
|
|
platform_nrst_set_val(true); /* will be deasserted after attach */ |
|
|
|
|
|
|
|
|
int devs = -1; |
|
|
int devs = -1; |
|
|
volatile struct exception e; |
|
|
volatile struct exception e; |
|
@ -217,7 +217,7 @@ static bool cmd_jtag_scan(target *t, int argc, char **argv) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
if(devs <= 0) { |
|
|
if(devs <= 0) { |
|
|
platform_srst_set_val(false); |
|
|
platform_nrst_set_val(false); |
|
|
gdb_out("JTAG device scan failed!\n"); |
|
|
gdb_out("JTAG device scan failed!\n"); |
|
|
return false; |
|
|
return false; |
|
|
} |
|
|
} |
|
@ -237,7 +237,7 @@ bool cmd_swdp_scan(target *t, int argc, char **argv) |
|
|
gdb_outf("Target voltage: %s\n", platform_target_voltage()); |
|
|
gdb_outf("Target voltage: %s\n", platform_target_voltage()); |
|
|
|
|
|
|
|
|
if(connect_assert_srst) |
|
|
if(connect_assert_srst) |
|
|
platform_srst_set_val(true); /* will be deasserted after attach */ |
|
|
platform_nrst_set_val(true); /* will be deasserted after attach */ |
|
|
|
|
|
|
|
|
int devs = -1; |
|
|
int devs = -1; |
|
|
volatile struct exception e; |
|
|
volatile struct exception e; |
|
@ -258,7 +258,7 @@ bool cmd_swdp_scan(target *t, int argc, char **argv) |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
if(devs <= 0) { |
|
|
if(devs <= 0) { |
|
|
platform_srst_set_val(false); |
|
|
platform_nrst_set_val(false); |
|
|
gdb_out("SW-DP scan failed!\n"); |
|
|
gdb_out("SW-DP scan failed!\n"); |
|
|
return false; |
|
|
return false; |
|
|
} |
|
|
} |
|
@ -277,7 +277,7 @@ bool cmd_auto_scan(target *t, int argc, char **argv) |
|
|
if (platform_target_voltage()) |
|
|
if (platform_target_voltage()) |
|
|
gdb_outf("Target voltage: %s\n", platform_target_voltage()); |
|
|
gdb_outf("Target voltage: %s\n", platform_target_voltage()); |
|
|
if (connect_assert_srst) |
|
|
if (connect_assert_srst) |
|
|
platform_srst_set_val(true); /* will be deasserted after attach */ |
|
|
platform_nrst_set_val(true); /* will be deasserted after attach */ |
|
|
|
|
|
|
|
|
int devs = -1; |
|
|
int devs = -1; |
|
|
volatile struct exception e; |
|
|
volatile struct exception e; |
|
@ -299,7 +299,7 @@ bool cmd_auto_scan(target *t, int argc, char **argv) |
|
|
if (devs > 0) |
|
|
if (devs > 0) |
|
|
break; |
|
|
break; |
|
|
|
|
|
|
|
|
platform_srst_set_val(false); |
|
|
platform_nrst_set_val(false); |
|
|
gdb_out("SW-DP scan failed!\n"); |
|
|
gdb_out("SW-DP scan failed!\n"); |
|
|
return false; |
|
|
return false; |
|
|
} |
|
|
} |
|
@ -312,7 +312,7 @@ bool cmd_auto_scan(target *t, int argc, char **argv) |
|
|
break; |
|
|
break; |
|
|
} |
|
|
} |
|
|
if (devs <= 0) { |
|
|
if (devs <= 0) { |
|
|
platform_srst_set_val(false); |
|
|
platform_nrst_set_val(false); |
|
|
gdb_out("auto scan failed!\n"); |
|
|
gdb_out("auto scan failed!\n"); |
|
|
return false; |
|
|
return false; |
|
|
} |
|
|
} |
|
@ -444,8 +444,8 @@ static bool cmd_hard_srst(target *t, int argc, const char **argv) |
|
|
(void)argc; |
|
|
(void)argc; |
|
|
(void)argv; |
|
|
(void)argv; |
|
|
target_list_free(); |
|
|
target_list_free(); |
|
|
platform_srst_set_val(true); |
|
|
platform_nrst_set_val(true); |
|
|
platform_srst_set_val(false); |
|
|
platform_nrst_set_val(false); |
|
|
return true; |
|
|
return true; |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|