aboutsummaryrefslogtreecommitdiffstats
path: root/firmware/zpu/lib/u2_init.c
diff options
context:
space:
mode:
authorJosh Blum <josh@joshknows.com>2010-12-31 17:29:57 -0800
committerJosh Blum <josh@joshknows.com>2010-12-31 17:29:57 -0800
commit4711829f03ee2fcd1c4e9dc2a353af0e35497180 (patch)
tree342b9379aac344922677fcbbaf74bd9869c6b137 /firmware/zpu/lib/u2_init.c
parent886a1be2f24e74de9244e3103e7a8b89071b8eb4 (diff)
downloaduhd-4711829f03ee2fcd1c4e9dc2a353af0e35497180.tar.gz
uhd-4711829f03ee2fcd1c4e9dc2a353af0e35497180.tar.bz2
uhd-4711829f03ee2fcd1c4e9dc2a353af0e35497180.zip
usrp2: fixed mdelay (used ticks rb register), cool led blink in u2init, removed unused files
Diffstat (limited to 'firmware/zpu/lib/u2_init.c')
-rw-r--r--firmware/zpu/lib/u2_init.c15
1 files changed, 11 insertions, 4 deletions
diff --git a/firmware/zpu/lib/u2_init.c b/firmware/zpu/lib/u2_init.c
index 191a0e816..71bd2c594 100644
--- a/firmware/zpu/lib/u2_init.c
+++ b/firmware/zpu/lib/u2_init.c
@@ -51,10 +51,17 @@ u2_init(void)
hal_enable_ints();
// flash all leds to let us know board is alive
- hal_set_leds(0x0, 0x1f);
- mdelay(100);
- hal_set_leds(0x1f, 0x1f);
- mdelay(100);
+ hal_set_led_src(0x0, 0x1f); /* software ctrl */
+ hal_set_leds(0x0, 0x1f); mdelay(300);
+ hal_set_leds(LED_E, LED_E); mdelay(300);
+ hal_set_leds(LED_C, LED_C); mdelay(300);
+ hal_set_leds(LED_A, LED_A); mdelay(300);
+ for (int i = 0; i < 3; i++){ //blink all
+ static const int blinks = LED_E | LED_C | LED_A;
+ hal_set_leds(0x0, 0x1f); mdelay(100);
+ hal_set_leds(blinks, 0x1f); mdelay(100);
+ }
+ hal_set_led_src(0x1f & ~LED_D, 0x1f); /* hardware ctrl */
hal_set_leds(LED_D, 0x1f); // Leave one on
#if 0