The official Mbed 2 C/C++ SDK provides the software platform and libraries to build your applications.
Dependents: hello SerialTestv11 SerialTestv12 Sierpinski ... more
mbed 2
This is the mbed 2 library. If you'd like to learn about Mbed OS please see the mbed-os docs.
TARGET_KL25Z/PinNames.h@65:5798e58a58b1, 2013-08-12 (annotated)
- Committer:
- bogdanm
- Date:
- Mon Aug 12 13:17:46 2013 +0300
- Revision:
- 65:5798e58a58b1
- Parent:
- 64:e3affc9e7238
- Child:
- 66:9c8f0e3462fb
New target (LPC4088), new features (interrupt chaining), bug fixes (KL25Z I2C).
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
bogdanm | 65:5798e58a58b1 | 1 | /* mbed Microcontroller Library |
bogdanm | 65:5798e58a58b1 | 2 | * Copyright (c) 2006-2013 ARM Limited |
bogdanm | 65:5798e58a58b1 | 3 | * |
bogdanm | 65:5798e58a58b1 | 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
bogdanm | 65:5798e58a58b1 | 5 | * you may not use this file except in compliance with the License. |
bogdanm | 65:5798e58a58b1 | 6 | * You may obtain a copy of the License at |
bogdanm | 65:5798e58a58b1 | 7 | * |
bogdanm | 65:5798e58a58b1 | 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
bogdanm | 65:5798e58a58b1 | 9 | * |
bogdanm | 65:5798e58a58b1 | 10 | * Unless required by applicable law or agreed to in writing, software |
bogdanm | 65:5798e58a58b1 | 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
bogdanm | 65:5798e58a58b1 | 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
bogdanm | 65:5798e58a58b1 | 13 | * See the License for the specific language governing permissions and |
bogdanm | 65:5798e58a58b1 | 14 | * limitations under the License. |
bogdanm | 65:5798e58a58b1 | 15 | */ |
bogdanm | 65:5798e58a58b1 | 16 | #ifndef MBED_PINNAMES_H |
bogdanm | 65:5798e58a58b1 | 17 | #define MBED_PINNAMES_H |
bogdanm | 65:5798e58a58b1 | 18 | |
bogdanm | 65:5798e58a58b1 | 19 | #include "cmsis.h" |
bogdanm | 65:5798e58a58b1 | 20 | |
bogdanm | 65:5798e58a58b1 | 21 | #ifdef __cplusplus |
bogdanm | 65:5798e58a58b1 | 22 | extern "C" { |
bogdanm | 65:5798e58a58b1 | 23 | #endif |
bogdanm | 65:5798e58a58b1 | 24 | |
bogdanm | 65:5798e58a58b1 | 25 | typedef enum { |
bogdanm | 65:5798e58a58b1 | 26 | PIN_INPUT, |
bogdanm | 65:5798e58a58b1 | 27 | PIN_OUTPUT |
bogdanm | 65:5798e58a58b1 | 28 | } PinDirection; |
bogdanm | 65:5798e58a58b1 | 29 | |
bogdanm | 65:5798e58a58b1 | 30 | #define PORT_SHIFT 12 |
bogdanm | 65:5798e58a58b1 | 31 | |
bogdanm | 65:5798e58a58b1 | 32 | typedef enum { |
bogdanm | 65:5798e58a58b1 | 33 | PTA0 = 0x0, |
bogdanm | 65:5798e58a58b1 | 34 | PTA1 = 0x4, |
bogdanm | 65:5798e58a58b1 | 35 | PTA2 = 0x8, |
bogdanm | 65:5798e58a58b1 | 36 | PTA3 = 0xc, |
bogdanm | 65:5798e58a58b1 | 37 | PTA4 = 0x10, |
bogdanm | 65:5798e58a58b1 | 38 | PTA5 = 0x14, |
bogdanm | 65:5798e58a58b1 | 39 | PTA6 = 0x18, |
bogdanm | 65:5798e58a58b1 | 40 | PTA7 = 0x1c, |
bogdanm | 65:5798e58a58b1 | 41 | PTA8 = 0x20, |
bogdanm | 65:5798e58a58b1 | 42 | PTA9 = 0x24, |
bogdanm | 65:5798e58a58b1 | 43 | PTA10 = 0x28, |
bogdanm | 65:5798e58a58b1 | 44 | PTA11 = 0x2c, |
bogdanm | 65:5798e58a58b1 | 45 | PTA12 = 0x30, |
bogdanm | 65:5798e58a58b1 | 46 | PTA13 = 0x34, |
bogdanm | 65:5798e58a58b1 | 47 | PTA14 = 0x38, |
bogdanm | 65:5798e58a58b1 | 48 | PTA15 = 0x3c, |
bogdanm | 65:5798e58a58b1 | 49 | PTA16 = 0x40, |
bogdanm | 65:5798e58a58b1 | 50 | PTA17 = 0x44, |
bogdanm | 65:5798e58a58b1 | 51 | PTA18 = 0x48, |
bogdanm | 65:5798e58a58b1 | 52 | PTA19 = 0x4c, |
bogdanm | 65:5798e58a58b1 | 53 | PTA20 = 0x50, |
bogdanm | 65:5798e58a58b1 | 54 | PTA21 = 0x54, |
bogdanm | 65:5798e58a58b1 | 55 | PTA22 = 0x58, |
bogdanm | 65:5798e58a58b1 | 56 | PTA23 = 0x5c, |
bogdanm | 65:5798e58a58b1 | 57 | PTA24 = 0x60, |
bogdanm | 65:5798e58a58b1 | 58 | PTA25 = 0x64, |
bogdanm | 65:5798e58a58b1 | 59 | PTA26 = 0x68, |
bogdanm | 65:5798e58a58b1 | 60 | PTA27 = 0x6c, |
bogdanm | 65:5798e58a58b1 | 61 | PTA28 = 0x70, |
bogdanm | 65:5798e58a58b1 | 62 | PTA29 = 0x74, |
bogdanm | 65:5798e58a58b1 | 63 | PTA30 = 0x78, |
bogdanm | 65:5798e58a58b1 | 64 | PTA31 = 0x7c, |
bogdanm | 65:5798e58a58b1 | 65 | PTB0 = 0x1000, |
bogdanm | 65:5798e58a58b1 | 66 | PTB1 = 0x1004, |
bogdanm | 65:5798e58a58b1 | 67 | PTB2 = 0x1008, |
bogdanm | 65:5798e58a58b1 | 68 | PTB3 = 0x100c, |
bogdanm | 65:5798e58a58b1 | 69 | PTB4 = 0x1010, |
bogdanm | 65:5798e58a58b1 | 70 | PTB5 = 0x1014, |
bogdanm | 65:5798e58a58b1 | 71 | PTB6 = 0x1018, |
bogdanm | 65:5798e58a58b1 | 72 | PTB7 = 0x101c, |
bogdanm | 65:5798e58a58b1 | 73 | PTB8 = 0x1020, |
bogdanm | 65:5798e58a58b1 | 74 | PTB9 = 0x1024, |
bogdanm | 65:5798e58a58b1 | 75 | PTB10 = 0x1028, |
bogdanm | 65:5798e58a58b1 | 76 | PTB11 = 0x102c, |
bogdanm | 65:5798e58a58b1 | 77 | PTB12 = 0x1030, |
bogdanm | 65:5798e58a58b1 | 78 | PTB13 = 0x1034, |
bogdanm | 65:5798e58a58b1 | 79 | PTB14 = 0x1038, |
bogdanm | 65:5798e58a58b1 | 80 | PTB15 = 0x103c, |
bogdanm | 65:5798e58a58b1 | 81 | PTB16 = 0x1040, |
bogdanm | 65:5798e58a58b1 | 82 | PTB17 = 0x1044, |
bogdanm | 65:5798e58a58b1 | 83 | PTB18 = 0x1048, |
bogdanm | 65:5798e58a58b1 | 84 | PTB19 = 0x104c, |
bogdanm | 65:5798e58a58b1 | 85 | PTB20 = 0x1050, |
bogdanm | 65:5798e58a58b1 | 86 | PTB21 = 0x1054, |
bogdanm | 65:5798e58a58b1 | 87 | PTB22 = 0x1058, |
bogdanm | 65:5798e58a58b1 | 88 | PTB23 = 0x105c, |
bogdanm | 65:5798e58a58b1 | 89 | PTB24 = 0x1060, |
bogdanm | 65:5798e58a58b1 | 90 | PTB25 = 0x1064, |
bogdanm | 65:5798e58a58b1 | 91 | PTB26 = 0x1068, |
bogdanm | 65:5798e58a58b1 | 92 | PTB27 = 0x106c, |
bogdanm | 65:5798e58a58b1 | 93 | PTB28 = 0x1070, |
bogdanm | 65:5798e58a58b1 | 94 | PTB29 = 0x1074, |
bogdanm | 65:5798e58a58b1 | 95 | PTB30 = 0x1078, |
bogdanm | 65:5798e58a58b1 | 96 | PTB31 = 0x107c, |
bogdanm | 65:5798e58a58b1 | 97 | PTC0 = 0x2000, |
bogdanm | 65:5798e58a58b1 | 98 | PTC1 = 0x2004, |
bogdanm | 65:5798e58a58b1 | 99 | PTC2 = 0x2008, |
bogdanm | 65:5798e58a58b1 | 100 | PTC3 = 0x200c, |
bogdanm | 65:5798e58a58b1 | 101 | PTC4 = 0x2010, |
bogdanm | 65:5798e58a58b1 | 102 | PTC5 = 0x2014, |
bogdanm | 65:5798e58a58b1 | 103 | PTC6 = 0x2018, |
bogdanm | 65:5798e58a58b1 | 104 | PTC7 = 0x201c, |
bogdanm | 65:5798e58a58b1 | 105 | PTC8 = 0x2020, |
bogdanm | 65:5798e58a58b1 | 106 | PTC9 = 0x2024, |
bogdanm | 65:5798e58a58b1 | 107 | PTC10 = 0x2028, |
bogdanm | 65:5798e58a58b1 | 108 | PTC11 = 0x202c, |
bogdanm | 65:5798e58a58b1 | 109 | PTC12 = 0x2030, |
bogdanm | 65:5798e58a58b1 | 110 | PTC13 = 0x2034, |
bogdanm | 65:5798e58a58b1 | 111 | PTC14 = 0x2038, |
bogdanm | 65:5798e58a58b1 | 112 | PTC15 = 0x203c, |
bogdanm | 65:5798e58a58b1 | 113 | PTC16 = 0x2040, |
bogdanm | 65:5798e58a58b1 | 114 | PTC17 = 0x2044, |
bogdanm | 65:5798e58a58b1 | 115 | PTC18 = 0x2048, |
bogdanm | 65:5798e58a58b1 | 116 | PTC19 = 0x204c, |
bogdanm | 65:5798e58a58b1 | 117 | PTC20 = 0x2050, |
bogdanm | 65:5798e58a58b1 | 118 | PTC21 = 0x2054, |
bogdanm | 65:5798e58a58b1 | 119 | PTC22 = 0x2058, |
bogdanm | 65:5798e58a58b1 | 120 | PTC23 = 0x205c, |
bogdanm | 65:5798e58a58b1 | 121 | PTC24 = 0x2060, |
bogdanm | 65:5798e58a58b1 | 122 | PTC25 = 0x2064, |
bogdanm | 65:5798e58a58b1 | 123 | PTC26 = 0x2068, |
bogdanm | 65:5798e58a58b1 | 124 | PTC27 = 0x206c, |
bogdanm | 65:5798e58a58b1 | 125 | PTC28 = 0x2070, |
bogdanm | 65:5798e58a58b1 | 126 | PTC29 = 0x2074, |
bogdanm | 65:5798e58a58b1 | 127 | PTC30 = 0x2078, |
bogdanm | 65:5798e58a58b1 | 128 | PTC31 = 0x207c, |
bogdanm | 65:5798e58a58b1 | 129 | PTD0 = 0x3000, |
bogdanm | 65:5798e58a58b1 | 130 | PTD1 = 0x3004, |
bogdanm | 65:5798e58a58b1 | 131 | PTD2 = 0x3008, |
bogdanm | 65:5798e58a58b1 | 132 | PTD3 = 0x300c, |
bogdanm | 65:5798e58a58b1 | 133 | PTD4 = 0x3010, |
bogdanm | 65:5798e58a58b1 | 134 | PTD5 = 0x3014, |
bogdanm | 65:5798e58a58b1 | 135 | PTD6 = 0x3018, |
bogdanm | 65:5798e58a58b1 | 136 | PTD7 = 0x301c, |
bogdanm | 65:5798e58a58b1 | 137 | PTD8 = 0x3020, |
bogdanm | 65:5798e58a58b1 | 138 | PTD9 = 0x3024, |
bogdanm | 65:5798e58a58b1 | 139 | PTD10 = 0x3028, |
bogdanm | 65:5798e58a58b1 | 140 | PTD11 = 0x302c, |
bogdanm | 65:5798e58a58b1 | 141 | PTD12 = 0x3030, |
bogdanm | 65:5798e58a58b1 | 142 | PTD13 = 0x3034, |
bogdanm | 65:5798e58a58b1 | 143 | PTD14 = 0x3038, |
bogdanm | 65:5798e58a58b1 | 144 | PTD15 = 0x303c, |
bogdanm | 65:5798e58a58b1 | 145 | PTD16 = 0x3040, |
bogdanm | 65:5798e58a58b1 | 146 | PTD17 = 0x3044, |
bogdanm | 65:5798e58a58b1 | 147 | PTD18 = 0x3048, |
bogdanm | 65:5798e58a58b1 | 148 | PTD19 = 0x304c, |
bogdanm | 65:5798e58a58b1 | 149 | PTD20 = 0x3050, |
bogdanm | 65:5798e58a58b1 | 150 | PTD21 = 0x3054, |
bogdanm | 65:5798e58a58b1 | 151 | PTD22 = 0x3058, |
bogdanm | 65:5798e58a58b1 | 152 | PTD23 = 0x305c, |
bogdanm | 65:5798e58a58b1 | 153 | PTD24 = 0x3060, |
bogdanm | 65:5798e58a58b1 | 154 | PTD25 = 0x3064, |
bogdanm | 65:5798e58a58b1 | 155 | PTD26 = 0x3068, |
bogdanm | 65:5798e58a58b1 | 156 | PTD27 = 0x306c, |
bogdanm | 65:5798e58a58b1 | 157 | PTD28 = 0x3070, |
bogdanm | 65:5798e58a58b1 | 158 | PTD29 = 0x3074, |
bogdanm | 65:5798e58a58b1 | 159 | PTD30 = 0x3078, |
bogdanm | 65:5798e58a58b1 | 160 | PTD31 = 0x307c, |
bogdanm | 65:5798e58a58b1 | 161 | PTE0 = 0x4000, |
bogdanm | 65:5798e58a58b1 | 162 | PTE1 = 0x4004, |
bogdanm | 65:5798e58a58b1 | 163 | PTE2 = 0x4008, |
bogdanm | 65:5798e58a58b1 | 164 | PTE3 = 0x400c, |
bogdanm | 65:5798e58a58b1 | 165 | PTE4 = 0x4010, |
bogdanm | 65:5798e58a58b1 | 166 | PTE5 = 0x4014, |
bogdanm | 65:5798e58a58b1 | 167 | PTE6 = 0x4018, |
bogdanm | 65:5798e58a58b1 | 168 | PTE7 = 0x401c, |
bogdanm | 65:5798e58a58b1 | 169 | PTE8 = 0x4020, |
bogdanm | 65:5798e58a58b1 | 170 | PTE9 = 0x4024, |
bogdanm | 65:5798e58a58b1 | 171 | PTE10 = 0x4028, |
bogdanm | 65:5798e58a58b1 | 172 | PTE11 = 0x402c, |
bogdanm | 65:5798e58a58b1 | 173 | PTE12 = 0x4030, |
bogdanm | 65:5798e58a58b1 | 174 | PTE13 = 0x4034, |
bogdanm | 65:5798e58a58b1 | 175 | PTE14 = 0x4038, |
bogdanm | 65:5798e58a58b1 | 176 | PTE15 = 0x403c, |
bogdanm | 65:5798e58a58b1 | 177 | PTE16 = 0x4040, |
bogdanm | 65:5798e58a58b1 | 178 | PTE17 = 0x4044, |
bogdanm | 65:5798e58a58b1 | 179 | PTE18 = 0x4048, |
bogdanm | 65:5798e58a58b1 | 180 | PTE19 = 0x404c, |
bogdanm | 65:5798e58a58b1 | 181 | PTE20 = 0x4050, |
bogdanm | 65:5798e58a58b1 | 182 | PTE21 = 0x4054, |
bogdanm | 65:5798e58a58b1 | 183 | PTE22 = 0x4058, |
bogdanm | 65:5798e58a58b1 | 184 | PTE23 = 0x405c, |
bogdanm | 65:5798e58a58b1 | 185 | PTE24 = 0x4060, |
bogdanm | 65:5798e58a58b1 | 186 | PTE25 = 0x4064, |
bogdanm | 65:5798e58a58b1 | 187 | PTE26 = 0x4068, |
bogdanm | 65:5798e58a58b1 | 188 | PTE27 = 0x406c, |
bogdanm | 65:5798e58a58b1 | 189 | PTE28 = 0x4070, |
bogdanm | 65:5798e58a58b1 | 190 | PTE29 = 0x4074, |
bogdanm | 65:5798e58a58b1 | 191 | PTE30 = 0x4078, |
bogdanm | 65:5798e58a58b1 | 192 | PTE31 = 0x407c, |
bogdanm | 65:5798e58a58b1 | 193 | |
bogdanm | 65:5798e58a58b1 | 194 | LED_RED = PTB18, |
bogdanm | 65:5798e58a58b1 | 195 | LED_GREEN = PTB19, |
bogdanm | 65:5798e58a58b1 | 196 | LED_BLUE = PTD1, |
bogdanm | 65:5798e58a58b1 | 197 | |
bogdanm | 65:5798e58a58b1 | 198 | // mbed original LED naming |
bogdanm | 65:5798e58a58b1 | 199 | LED1 = LED_BLUE, |
bogdanm | 65:5798e58a58b1 | 200 | LED2 = LED_GREEN, |
bogdanm | 65:5798e58a58b1 | 201 | LED3 = LED_RED, |
bogdanm | 65:5798e58a58b1 | 202 | LED4 = LED_RED, |
bogdanm | 65:5798e58a58b1 | 203 | |
bogdanm | 65:5798e58a58b1 | 204 | // USB Pins |
bogdanm | 65:5798e58a58b1 | 205 | USBTX = PTA2, |
bogdanm | 65:5798e58a58b1 | 206 | USBRX = PTA1, |
bogdanm | 65:5798e58a58b1 | 207 | |
bogdanm | 65:5798e58a58b1 | 208 | // Arduino Headers |
bogdanm | 65:5798e58a58b1 | 209 | D0 = PTA1, |
bogdanm | 65:5798e58a58b1 | 210 | D1 = PTA2, |
bogdanm | 65:5798e58a58b1 | 211 | D2 = PTD4, |
bogdanm | 65:5798e58a58b1 | 212 | D3 = PTA12, |
bogdanm | 65:5798e58a58b1 | 213 | D4 = PTA4, |
bogdanm | 65:5798e58a58b1 | 214 | D5 = PTA5, |
bogdanm | 65:5798e58a58b1 | 215 | D6 = PTC8, |
bogdanm | 65:5798e58a58b1 | 216 | D7 = PTC9, |
bogdanm | 65:5798e58a58b1 | 217 | D8 = PTA13, |
bogdanm | 65:5798e58a58b1 | 218 | D9 = PTD5, |
bogdanm | 65:5798e58a58b1 | 219 | D10 = PTD0, |
bogdanm | 65:5798e58a58b1 | 220 | D11 = PTD2, |
bogdanm | 65:5798e58a58b1 | 221 | D12 = PTD3, |
bogdanm | 65:5798e58a58b1 | 222 | D13 = PTD1, |
bogdanm | 65:5798e58a58b1 | 223 | D14 = PTE0, |
bogdanm | 65:5798e58a58b1 | 224 | D15 = PTE1, |
bogdanm | 65:5798e58a58b1 | 225 | |
bogdanm | 65:5798e58a58b1 | 226 | A0 = PTB0, |
bogdanm | 65:5798e58a58b1 | 227 | A1 = PTB1, |
bogdanm | 65:5798e58a58b1 | 228 | A2 = PTB2, |
bogdanm | 65:5798e58a58b1 | 229 | A3 = PTB3, |
bogdanm | 65:5798e58a58b1 | 230 | A4 = PTC2, |
bogdanm | 65:5798e58a58b1 | 231 | A5 = PTC1, |
bogdanm | 65:5798e58a58b1 | 232 | |
bogdanm | 65:5798e58a58b1 | 233 | // Not connected |
bogdanm | 65:5798e58a58b1 | 234 | NC = (int)0xFFFFFFFF |
bogdanm | 65:5798e58a58b1 | 235 | } PinName; |
bogdanm | 65:5798e58a58b1 | 236 | |
bogdanm | 65:5798e58a58b1 | 237 | /* PullDown not available for KL25 */ |
bogdanm | 65:5798e58a58b1 | 238 | typedef enum { |
bogdanm | 65:5798e58a58b1 | 239 | PullNone = 0, |
bogdanm | 65:5798e58a58b1 | 240 | PullUp = 2, |
bogdanm | 65:5798e58a58b1 | 241 | } PinMode; |
bogdanm | 65:5798e58a58b1 | 242 | |
bogdanm | 65:5798e58a58b1 | 243 | #ifdef __cplusplus |
bogdanm | 65:5798e58a58b1 | 244 | } |
bogdanm | 65:5798e58a58b1 | 245 | #endif |
bogdanm | 65:5798e58a58b1 | 246 | |
bogdanm | 65:5798e58a58b1 | 247 | #endif |