From: matt Date: Mon, 25 May 2009 19:32:23 +0000 (+0000) Subject: move i2c init and get_hw_rev before clocks_init because the clock init code needs... X-Git-Url: https://git.gag.com/?a=commitdiff_plain;h=d8be62824c35b2eb07ff502ba879ae0bb7aedb26;p=debian%2Fgnuradio move i2c init and get_hw_rev before clocks_init because the clock init code needs to know our rev git-svn-id: http://gnuradio.org/svn/gnuradio/trunk@11122 221aa14e-8319-0410-a670-987f0aec2ac5 --- diff --git a/usrp2/firmware/lib/u2_init.c b/usrp2/firmware/lib/u2_init.c index 713b2c32..9a1eb165 100644 --- a/usrp2/firmware/lib/u2_init.c +++ b/usrp2/firmware/lib/u2_init.c @@ -65,6 +65,10 @@ u2_init(void) // init spi, so that we can switch over to the high-speed clock spi_init(); + // init i2c so we can read our rev + i2c_init(); + get_hw_rev(); + // set up the default clocks clocks_init(); @@ -97,13 +101,10 @@ u2_init(void) pic_init(); // progammable interrupt controller bp_init(); // buffer pool - i2c_init(); lsadc_init(); // low-speed ADCs lsdac_init(); // low-speed DACs db_init(); // daughterboard init - get_hw_rev(); - hal_enable_ints(); // flash all leds to let us know board is alive