summaryrefslogtreecommitdiff
path: root/bootloader/imx233.c
diff options
context:
space:
mode:
authorAmaury Pouly <pamaury@rockbox.org>2011-06-17 22:30:58 +0000
committerAmaury Pouly <pamaury@rockbox.org>2011-06-17 22:30:58 +0000
commit2cf33133820ee17e4b5d2d622db15dedff1a1f6e (patch)
tree60eddf4c3f16d5d274bc111ce53db02cfe75a6e8 /bootloader/imx233.c
parentd4800fa3851d2d89c1be03ec99af81f277892579 (diff)
fuze+: add more clocking code, add dma code, add ssp code, add stub usb code, update storage to SD + MMC, beginning of the driver
git-svn-id: svn://svn.rockbox.org/rockbox/trunk@30010 a1c6a512-1295-4272-9138-f99709370657
Diffstat (limited to 'bootloader/imx233.c')
-rw-r--r--bootloader/imx233.c38
1 files changed, 35 insertions, 3 deletions
diff --git a/bootloader/imx233.c b/bootloader/imx233.c
index 868d6e499f..85a545b523 100644
--- a/bootloader/imx233.c
+++ b/bootloader/imx233.c
@@ -37,6 +37,9 @@
#include "power.h"
#include "pinctrl-imx233.h"
#include "system-target.h"
+#include "ssp-imx233.h"
+
+#include "usb.h"
int show_logo(void);
@@ -60,10 +63,39 @@ void main(void)
button_init_device();
- button_debug_screen();
-
- power_off();
+ //button_debug_screen();
+
+ #if 0
+ usb_init();
+ usb_start_monitoring();
+ extern int usb_status;
+ usb_status = USB_INSERTED;
+ usb_status_event(USB_POWERED);
+
+ printf("USB: Connecting");
+
+ while(1)
+ {
+ int button = button_get_w_tmo(HZ/25);
+ if(button == SYS_USB_CONNECTED)
+ break; /* Hit */
+ if(button_read_device() & BUTTON_POWER)
+ power_off();
+ yield();
+ }
+
+ printf("USB: Connected");
+ while(1)
+ {
+ int button = button_get_w_tmo(HZ/25);
+
+ if(button_read_device() & BUTTON_POWER)
+ power_off();
+ yield();
+ }
+ #endif
+
ret = storage_init();
if(ret < 0)
error(EATA, ret, true);