USBDevice with MAX32620HSP platform support

Fork of USBDevice by mbed official

Files at this revision

API Documentation at this revision

Comitter:
mbed_official
Date:
Wed Aug 20 13:15:20 2014 +0100
Parent:
29:b7a0ea455a0c
Child:
31:5bf05f9b3c7b
Commit message:
Synchronized with git revision acf895235e4476b0740a6a55381433645ae03873

Full URL: https://github.com/mbedmicro/mbed/commit/acf895235e4476b0740a6a55381433645ae03873/

[USBDevice] use target group LPC11UXX instead of LPC11U24 or LPC11U35_501

Changed in this revision

USBDevice/USBHAL.h Show annotated file Show diff for this revision Revisions of this file
USBDevice/USBHAL_LPC11U.cpp Show annotated file Show diff for this revision Revisions of this file
--- a/USBDevice/USBHAL.h	Mon Aug 18 13:45:19 2014 +0100
+++ b/USBDevice/USBHAL.h	Wed Aug 20 13:15:20 2014 +0100
@@ -77,7 +77,7 @@
 #if !defined(TARGET_STM32F4)
     virtual bool EP4_OUT_callback(){return false;};
     virtual bool EP4_IN_callback(){return false;};
-#if !defined(TARGET_LPC11U24)
+#if !(defined(TARGET_LPC11UXX) || defined(TARGET_LPC11U6X) || defined(TARGET_LPC1347) || defined(TARGET_LPC1549))
     virtual bool EP5_OUT_callback(){return false;};
     virtual bool EP5_IN_callback(){return false;};
     virtual bool EP6_OUT_callback(){return false;};
@@ -108,7 +108,7 @@
     static void _usbisr(void);
     static USBHAL * instance;
 
-#if defined(TARGET_LPC11U24)
+#if defined(TARGET_LPC11UXX) || defined(TARGET_LPC11U6X) || defined(TARGET_LPC1347) || defined(TARGET_LPC1549)
         bool (USBHAL::*epCallback[10 - 2])(void);
 #elif defined(TARGET_STM32F4XX)
         bool (USBHAL::*epCallback[8 - 2])(void);
--- a/USBDevice/USBHAL_LPC11U.cpp	Mon Aug 18 13:45:19 2014 +0100
+++ b/USBDevice/USBHAL_LPC11U.cpp	Wed Aug 20 13:15:20 2014 +0100
@@ -16,11 +16,11 @@
 * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
 */
 
-#if defined(TARGET_LPC11U24) || defined(TARGET_LPC11U35_401) || defined(TARGET_LPC1347) || defined(TARGET_LPC11U35_501) || defined(TARGET_LPC11U68) || defined(TARGET_LPC1549)
+#if defined(TARGET_LPC11UXX) || defined(TARGET_LPC11U6X) || defined(TARGET_LPC1347) || defined(TARGET_LPC1549)
 
 #if defined(TARGET_LPC1347) || defined(TARGET_LPC1549)
 #define USB_IRQ USB_IRQ_IRQn
-#elif defined(TARGET_LPC11U24) || defined(TARGET_LPC11U35_401) || defined(TARGET_LPC11U35_501) || defined(TARGET_LPC11U68)
+#else
 #define USB_IRQ USB_IRQn
 #endif
 
@@ -167,7 +167,7 @@
        FCCO = FCLKOUT * 2 * P = 48MHz * 2 * 2 = 192MHz (within FCCO range) */
     LPC_SYSCON->USBPLLCTRL = (0x3 | (1UL << 6));
 
-    /* Powerup USB PLL */  
+    /* Powerup USB PLL */
     LPC_SYSCON->PDRUNCFG &= ~(CLK_USB);
 
     /* Wait for PLL to lock */