From 4a483bb1bf69a0f0a1bf99aaa9bb47c6f79ab990 Mon Sep 17 00:00:00 2001 From: Karl Kurbjun Date: Mon, 8 Jun 2009 00:19:16 +0000 Subject: M:Robe 500: Mostly complete USB driver, supports BULK mode currently and gets about 2 MB/s writes vs 1.1 MB/s on the OF. Mostly tested against Linux, preliminary testing in Windows appears to work. There is currently a bug in the attach process where it only works once per boot that needs to be fixed. There are a few other minor M:Robe 500 changes as well. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@21208 a1c6a512-1295-4272-9138-f99709370657 --- firmware/target/arm/tms320dm320/system-dm320.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'firmware/target/arm/tms320dm320/system-dm320.c') diff --git a/firmware/target/arm/tms320dm320/system-dm320.c b/firmware/target/arm/tms320dm320/system-dm320.c index b8c9eee87f..8742f59691 100644 --- a/firmware/target/arm/tms320dm320/system-dm320.c +++ b/firmware/target/arm/tms320dm320/system-dm320.c @@ -28,6 +28,7 @@ #include "spi.h" #ifdef CREATIVE_ZVx #include "dma-target.h" +#include "usb-mr500.h" #endif #define default_interrupt(name) \ @@ -308,3 +309,14 @@ void set_cpu_frequency(long frequency) } #endif +/* This function is pretty crude. It is not acurate to a usec, but errors on + * longer. + */ +void udelay(int usec) { + volatile int temp=usec*(175000/200); + + while(temp) { + temp--; + } +} + -- cgit v1.2.3