jtag/drivers/ftdi: Use adapter_khz value for initial clock speed (was default 1kHz) 23/2223/3
authorAngus Gratton <gus@projectgus.com>
Sat, 19 Jul 2014 08:50:55 +0000 (18:50 +1000)
committerAndreas Fritiofson <andreas.fritiofson@gmail.com>
Tue, 19 Aug 2014 20:26:26 +0000 (20:26 +0000)
nrf51822 doesn't like a 1kHz initial clock rate, puts the DAP into a bad state.

Mailing list discussion thread: http://sourceforge.net/p/openocd/mailman/openocd-devel/thread/20140718081528.GA5554%40ex2.lan/#msg32621853

Change-Id: I71aa75505cc1b41ee80c7b9db415f6ac738c2916
Signed-off-by: Angus Gratton <gus@projectgus.com>
Reviewed-on: http://openocd.zylin.com/2223
Tested-by: jenkins
Reviewed-by: Andreas Fritiofson <andreas.fritiofson@gmail.com>
src/jtag/drivers/ftdi.c

index 0debc2dcfd3b23c88dbdd012aac7de0c9eb810f2..6406406aa093061223edc3502dc083726cb7d56e 100644 (file)
@@ -653,8 +653,7 @@ static int ftdi_initialize(void)
 
        mpsse_loopback_config(mpsse_ctx, false);
 
-       /* Set a low default */
-       freq = mpsse_set_frequency(mpsse_ctx, 1000);
+       freq = mpsse_set_frequency(mpsse_ctx, jtag_get_speed_khz() * 1000);
 
        if (swd_mode)
                ftdi_swd_switch_seq(NULL, JTAG_TO_SWD);

Linking to existing account procedure

If you already have an account and want to add another login method you MUST first sign in with your existing account and then change URL to read https://review.openocd.org/login/?link to get to this page again but this time it'll work for linking. Thank you.

SSH host keys fingerprints

1024 SHA256:YKx8b7u5ZWdcbp7/4AeXNaqElP49m6QrwfXaqQGJAOk gerrit-code-review@openocd.zylin.com (DSA)
384 SHA256:jHIbSQa4REvwCFG4cq5LBlBLxmxSqelQPem/EXIrxjk gerrit-code-review@openocd.org (ECDSA)
521 SHA256:UAOPYkU9Fjtcao0Ul/Rrlnj/OsQvt+pgdYSZ4jOYdgs gerrit-code-review@openocd.org (ECDSA)
256 SHA256:A13M5QlnozFOvTllybRZH6vm7iSt0XLxbA48yfc2yfY gerrit-code-review@openocd.org (ECDSA)
256 SHA256:spYMBqEYoAOtK7yZBrcwE8ZpYt6b68Cfh9yEVetvbXg gerrit-code-review@openocd.org (ED25519)
+--[ED25519 256]--+
|=..              |
|+o..   .         |
|*.o   . .        |
|+B . . .         |
|Bo. = o S        |
|Oo.+ + =         |
|oB=.* = . o      |
| =+=.+   + E     |
|. .=o   . o      |
+----[SHA256]-----+
2048 SHA256:0Onrb7/PHjpo6iVZ7xQX2riKN83FJ3KGU0TvI0TaFG4 gerrit-code-review@openocd.zylin.com (RSA)