diff --git a/jtag/ChangeLog b/jtag/ChangeLog index df2f8cc5..714d8e25 100644 --- a/jtag/ChangeLog +++ b/jtag/ChangeLog @@ -1,5 +1,8 @@ 2008-09-06 Arnim Laeuger + * src/tap/cable/usbblaster.c: set fixed frequency and print warning + if a different frequency is requested + * src/tap/cable/generic.c: fixed calibration loop * src/svf/svf.c: require frequency setting from cable for diff --git a/jtag/src/tap/cable/usbblaster.c b/jtag/src/tap/cable/usbblaster.c index 1cc73af3..ecda841c 100644 --- a/jtag/src/tap/cable/usbblaster.c +++ b/jtag/src/tap/cable/usbblaster.c @@ -50,6 +50,8 @@ #define TDO 0 +#define FIXED_FREQUENCY 12000000L + /* The default driver if not specified otherwise during connect */ #ifdef ENABLE_LOWLEVEL_FTD2XX #define DEFAULT_DRIVER "ftd2xx" @@ -93,6 +95,16 @@ usbblaster_connect( char *params[], cable_t *cable ) return 0; } +void +usbblaster_set_frequency( cable_t *cable, uint32_t new_frequency ) +{ + if (new_frequency != FIXED_FREQUENCY) + printf( _("Warning: USB-Blaster frequency is fixed to %ld Hz\n"), + FIXED_FREQUENCY ); + + cable->frequency = FIXED_FREQUENCY; +} + static int usbblaster_init( cable_t *cable ) { @@ -108,6 +120,8 @@ usbblaster_init( cable_t *cable ) cx_xfer( cmd_root, NULL, cable, COMPLETELY ); + usbblaster_set_frequency( cable, FIXED_FREQUENCY ); + return 0; } @@ -421,12 +435,6 @@ usbblaster_flush( cable_t *cable, cable_flush_amount_t how_much ) } } -void -usbblaster_set_frequency( cable_t *cable, uint32_t new_frequency ) -{ - cable->frequency = new_frequency; -} - void usbblaster_help( const char *cablename ) {