mbed library sources
Dependents: frdm_kl05z_gpio_test
Fork of mbed-src by
targets/hal/TARGET_NXP/TARGET_LPC81X/TARGET_LPC812/PinNames.h@179:fdae7a0cf091, 2014-05-07 (annotated)
- Committer:
- mbed_official
- Date:
- Wed May 07 11:30:07 2014 +0100
- Revision:
- 179:fdae7a0cf091
- Parent:
- 113:65a335a675de
Synchronized with git revision 0cd322f5c38141218f5724ee0a71e0788610b022
Full URL: https://github.com/mbedmicro/mbed/commit/0cd322f5c38141218f5724ee0a71e0788610b022/
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
bogdanm | 20:4263a77256ae | 1 | /* mbed Microcontroller Library |
bogdanm | 20:4263a77256ae | 2 | * Copyright (c) 2006-2013 ARM Limited |
bogdanm | 20:4263a77256ae | 3 | * |
bogdanm | 20:4263a77256ae | 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
bogdanm | 20:4263a77256ae | 5 | * you may not use this file except in compliance with the License. |
bogdanm | 20:4263a77256ae | 6 | * You may obtain a copy of the License at |
bogdanm | 20:4263a77256ae | 7 | * |
bogdanm | 20:4263a77256ae | 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
bogdanm | 20:4263a77256ae | 9 | * |
bogdanm | 20:4263a77256ae | 10 | * Unless required by applicable law or agreed to in writing, software |
bogdanm | 20:4263a77256ae | 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
bogdanm | 20:4263a77256ae | 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
bogdanm | 20:4263a77256ae | 13 | * See the License for the specific language governing permissions and |
bogdanm | 20:4263a77256ae | 14 | * limitations under the License. |
bogdanm | 20:4263a77256ae | 15 | */ |
bogdanm | 20:4263a77256ae | 16 | #ifndef MBED_PINNAMES_H |
bogdanm | 20:4263a77256ae | 17 | #define MBED_PINNAMES_H |
bogdanm | 20:4263a77256ae | 18 | |
bogdanm | 20:4263a77256ae | 19 | #include "cmsis.h" |
bogdanm | 20:4263a77256ae | 20 | |
bogdanm | 20:4263a77256ae | 21 | #ifdef __cplusplus |
bogdanm | 20:4263a77256ae | 22 | extern "C" { |
bogdanm | 20:4263a77256ae | 23 | #endif |
bogdanm | 20:4263a77256ae | 24 | |
bogdanm | 20:4263a77256ae | 25 | typedef enum { |
bogdanm | 20:4263a77256ae | 26 | PIN_INPUT, |
bogdanm | 20:4263a77256ae | 27 | PIN_OUTPUT |
bogdanm | 20:4263a77256ae | 28 | } PinDirection; |
bogdanm | 20:4263a77256ae | 29 | |
bogdanm | 20:4263a77256ae | 30 | typedef enum { |
bogdanm | 20:4263a77256ae | 31 | P0_0 = 0, |
bogdanm | 20:4263a77256ae | 32 | P0_1 = 1, |
bogdanm | 20:4263a77256ae | 33 | P0_2 = 2, |
bogdanm | 20:4263a77256ae | 34 | P0_3 = 3, |
bogdanm | 20:4263a77256ae | 35 | P0_4 = 4, |
bogdanm | 20:4263a77256ae | 36 | P0_5 = 5, |
bogdanm | 20:4263a77256ae | 37 | P0_6 = 6, |
bogdanm | 20:4263a77256ae | 38 | P0_7 = 7, |
bogdanm | 20:4263a77256ae | 39 | P0_8 = 8, |
bogdanm | 20:4263a77256ae | 40 | P0_9 = 9, |
bogdanm | 20:4263a77256ae | 41 | P0_10 = 10, |
bogdanm | 20:4263a77256ae | 42 | P0_11 = 11, |
bogdanm | 20:4263a77256ae | 43 | P0_12 = 12, |
bogdanm | 20:4263a77256ae | 44 | P0_13 = 13, |
bogdanm | 20:4263a77256ae | 45 | P0_14 = 14, |
bogdanm | 20:4263a77256ae | 46 | P0_15 = 15, |
bogdanm | 20:4263a77256ae | 47 | P0_16 = 16, |
bogdanm | 20:4263a77256ae | 48 | P0_17 = 17, |
bogdanm | 20:4263a77256ae | 49 | |
bogdanm | 20:4263a77256ae | 50 | D0 = P0_0, |
bogdanm | 20:4263a77256ae | 51 | D1 = P0_4, |
bogdanm | 20:4263a77256ae | 52 | D2 = P0_6, |
bogdanm | 20:4263a77256ae | 53 | D3 = P0_8, |
bogdanm | 20:4263a77256ae | 54 | D4 = P0_9, |
bogdanm | 20:4263a77256ae | 55 | |
bogdanm | 20:4263a77256ae | 56 | D7 = P0_7, |
bogdanm | 20:4263a77256ae | 57 | D8 = P0_17, |
bogdanm | 20:4263a77256ae | 58 | D9 = P0_16, |
bogdanm | 20:4263a77256ae | 59 | D10 = P0_13, |
bogdanm | 20:4263a77256ae | 60 | D11 = P0_14, |
bogdanm | 20:4263a77256ae | 61 | D12 = P0_15, |
bogdanm | 20:4263a77256ae | 62 | D13 = P0_12, |
mbed_official | 179:fdae7a0cf091 | 63 | D14 = P0_10, |
mbed_official | 179:fdae7a0cf091 | 64 | D15 = P0_11, |
bogdanm | 20:4263a77256ae | 65 | |
bogdanm | 20:4263a77256ae | 66 | A4 = P0_10, |
bogdanm | 20:4263a77256ae | 67 | A5 = P0_11, |
bogdanm | 20:4263a77256ae | 68 | |
bogdanm | 20:4263a77256ae | 69 | // LPC800-MAX board |
bogdanm | 20:4263a77256ae | 70 | LED_RED = P0_7, |
bogdanm | 20:4263a77256ae | 71 | LED_GREEN = P0_17, |
bogdanm | 20:4263a77256ae | 72 | LED_BLUE = P0_16, |
bogdanm | 20:4263a77256ae | 73 | |
bogdanm | 20:4263a77256ae | 74 | // mbed original LED naming |
bogdanm | 20:4263a77256ae | 75 | LED1 = LED_BLUE, |
bogdanm | 20:4263a77256ae | 76 | LED2 = LED_GREEN, |
bogdanm | 20:4263a77256ae | 77 | LED3 = LED_RED, |
bogdanm | 20:4263a77256ae | 78 | LED4 = LED_RED, |
bogdanm | 20:4263a77256ae | 79 | |
bogdanm | 20:4263a77256ae | 80 | // Serial to USB pins |
bogdanm | 20:4263a77256ae | 81 | USBTX = P0_6, |
bogdanm | 20:4263a77256ae | 82 | USBRX = P0_1, |
bogdanm | 20:4263a77256ae | 83 | |
bogdanm | 20:4263a77256ae | 84 | // Not connected |
bogdanm | 20:4263a77256ae | 85 | NC = (int)0xFFFFFFFF, |
bogdanm | 20:4263a77256ae | 86 | } PinName; |
bogdanm | 20:4263a77256ae | 87 | |
bogdanm | 20:4263a77256ae | 88 | typedef enum { |
bogdanm | 20:4263a77256ae | 89 | PullUp = 2, |
bogdanm | 20:4263a77256ae | 90 | PullDown = 1, |
bogdanm | 20:4263a77256ae | 91 | PullNone = 0, |
bogdanm | 20:4263a77256ae | 92 | Repeater = 3, |
mbed_official | 113:65a335a675de | 93 | OpenDrain = 4, |
mbed_official | 113:65a335a675de | 94 | PullDefault = PullDown |
bogdanm | 20:4263a77256ae | 95 | } PinMode; |
bogdanm | 20:4263a77256ae | 96 | |
bogdanm | 20:4263a77256ae | 97 | #define STDIO_UART_TX USBTX |
bogdanm | 20:4263a77256ae | 98 | #define STDIO_UART_RX USBRX |
bogdanm | 20:4263a77256ae | 99 | |
bogdanm | 20:4263a77256ae | 100 | typedef struct { |
bogdanm | 20:4263a77256ae | 101 | unsigned char n; |
bogdanm | 20:4263a77256ae | 102 | unsigned char offset; |
bogdanm | 20:4263a77256ae | 103 | } SWM_Map; |
bogdanm | 20:4263a77256ae | 104 | |
bogdanm | 20:4263a77256ae | 105 | #ifdef __cplusplus |
bogdanm | 20:4263a77256ae | 106 | } |
bogdanm | 20:4263a77256ae | 107 | #endif |
bogdanm | 20:4263a77256ae | 108 | |
bogdanm | 20:4263a77256ae | 109 | #endif |