From 9e1d00c9fb99494ecd67cc2eb06ef0537a7f18b4 Mon Sep 17 00:00:00 2001 From: Karl Kurbjun Date: Thu, 26 Feb 2009 21:24:40 +0000 Subject: Get the M:Robe 500 main build booting again, fix a bug and commit the rest of Cat's work to get sound working. The code is messy right now, but it plays a file (test.raw) in a normal build when you go into the debug ports screen. Take 1. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@20118 a1c6a512-1295-4272-9138-f99709370657 --- bootloader/mrobe500.c | 31 +++++++++++++++++++++---------- 1 file changed, 21 insertions(+), 10 deletions(-) (limited to 'bootloader/mrobe500.c') diff --git a/bootloader/mrobe500.c b/bootloader/mrobe500.c index f92ff4b..e503baa 100644 --- a/bootloader/mrobe500.c +++ b/bootloader/mrobe500.c @@ -46,7 +46,7 @@ #include "time.h" #include "system-arm.h" -#define MRDEBUG +//#define MRDEBUG #if defined(MRDEBUG) @@ -194,19 +194,28 @@ void main(void) int rc; int(*kernel_entry)(void); - power_init(); - lcd_init(); + /* Make sure interrupts are disabled */ + set_irq_level(IRQ_DISABLED); + set_fiq_status(FIQ_DISABLED); system_init(); kernel_init(); - enable_irq(); - enable_fiq(); + /* Now enable interrupts */ + set_irq_level(IRQ_ENABLED); + set_fiq_status(FIQ_ENABLED); - adc_init(); - button_init(); backlight_init(); - + lcd_init(); font_init(); + button_init(); + usb_init(); + + + power_init(); +// enable_irq(); +// enable_fiq(); + + adc_init(); lcd_setfont(FONT_SYSFIXED); @@ -217,8 +226,6 @@ void main(void) printf("Rockbox boot loader"); printf("Version %s", APPSVERSION); - usb_init(); - /* Enter USB mode without USB thread */ if(usb_detect() == USB_INSERTED) { @@ -244,9 +251,13 @@ void main(void) reset_screen(); lcd_update(); } + #if defined(MRDEBUG) mrdebug(); #endif + + sleep(50); + printf("ATA"); rc = storage_init(); if(rc) -- cgit v1.1