mbed library sources

Dependents:   Nucleo_blink_led

Fork of mbed-src by mbed official

Revision:
256:76fd9a263045
Parent:
20:4263a77256ae
--- a/targets/hal/TARGET_NXP/TARGET_LPC43XX/PeripheralNames.h	Fri Jul 11 10:00:08 2014 +0100
+++ b/targets/hal/TARGET_NXP/TARGET_LPC43XX/PeripheralNames.h	Tue Jul 15 07:45:08 2014 +0100
@@ -63,15 +63,22 @@
 } I2CName;
 
 typedef enum {
-    PWM0_1 = 1,
-    PWM0_2,
-    PWM0_3,
-    PWM1_1,
-    PWM1_2,
-    PWM1_3,
-    PWM2_1,
-    PWM2_2,
-    PWM2_3
+    PWM_0,
+    PWM_1,
+    PWM_2,
+    PWM_3,
+    PWM_4,
+    PWM_5,
+    PWM_6,
+    PWM_7,
+    PWM_8,
+    PWM_9,
+    PWM_10,
+    PWM_11,
+    PWM_12,
+    PWM_13,
+    PWM_14,
+    PWM_15
 } PWMName;
 
 typedef enum {
@@ -79,9 +86,47 @@
      CAN_1 = (int)LPC_C_CAN1_BASE
 } CANName;
 
-#define STDIO_UART_TX     UART0_TX
-#define STDIO_UART_RX     UART0_RX
-#define STDIO_UART        UART_0
+#define STDIO_UART_TX     USBTX
+#define STDIO_UART_RX     USBRX
+#define STDIO_UART        UART_2
+
+// Default peripherals
+#define MBED_SPI0         SPI0_MOSI, SPI0_MISO, SPI0_SCK, SPI0_SSEL
+#define MBED_SPI1         SPI1_MOSI, SPI1_MISO, SPI1_SCK, SPI1_SSEL
+
+#define MBED_UART0        UART0_TX, UART0_RX
+#define MBED_UART1        UART1_TX, UART1_RX
+#define MBED_UART2        UART2_TX, UART2_RX
+#define MBED_UART3        UART3_TX, UART3_RX
+#define MBED_UARTUSB      USBTX, USBRX
+
+#define COM1              MBED_UART0
+#define COM2              MBED_UART1
+#define COM3              MBED_UART2
+#define COM4              MBED_UART3
+
+#define MBED_I2C0         I2C0_SDA, I2C0_SCL
+#define MBED_I2C1         I2C1_SDA, I2C1_SCL
+
+#define MBED_CAN0         p30, p29
+
+#define MBED_ANALOGOUT0   DAC0
+
+#define MBED_ANALOGIN0    ADC0
+#define MBED_ANALOGIN1    ADC1
+#define MBED_ANALOGIN2    ADC2
+#define MBED_ANALOGIN3    ADC3
+#define MBED_ANALOGIN4    ADC4
+#define MBED_ANALOGIN5    ADC5
+#define MBED_ANALOGIN6    ADC6
+#define MBED_ANALOGIN7    ADC7
+
+#define MBED_PWMOUT0      p26
+#define MBED_PWMOUT1      p25
+#define MBED_PWMOUT2      p24
+#define MBED_PWMOUT3      p23
+#define MBED_PWMOUT4      p22
+#define MBED_PWMOUT5      p21
 
 #ifdef __cplusplus
 }