Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Fork of mbed-src by
PinNames.h
00001 /* mbed Microcontroller Library 00002 * Copyright (c) 2006-2013 ARM Limited 00003 * 00004 * Licensed under the Apache License, Version 2.0 (the "License"); 00005 * you may not use this file except in compliance with the License. 00006 * You may obtain a copy of the License at 00007 * 00008 * http://www.apache.org/licenses/LICENSE-2.0 00009 * 00010 * Unless required by applicable law or agreed to in writing, software 00011 * distributed under the License is distributed on an "AS IS" BASIS, 00012 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 00013 * See the License for the specific language governing permissions and 00014 * limitations under the License. 00015 */ 00016 #ifndef MBED_PINNAMES_H 00017 #define MBED_PINNAMES_H 00018 00019 #include "cmsis.h" 00020 00021 #ifdef __cplusplus 00022 extern "C" { 00023 #endif 00024 00025 typedef enum { 00026 PIN_INPUT, 00027 PIN_OUTPUT 00028 } PinDirection; 00029 00030 #define PORT_SHIFT 5 00031 00032 typedef enum { 00033 // LPC11U Pin Names 00034 P0_0 = 0, 00035 P0_1 = 1, 00036 P0_2 = 2, 00037 P0_3 = 3, 00038 P0_4 = 4, 00039 P0_5 = 5, 00040 P0_6 = 6, 00041 P0_7 = 7, 00042 P0_8 = 8, 00043 P0_9 = 9, 00044 P0_10 = 10, 00045 P0_11 = 11, 00046 P0_12 = 12, 00047 P0_13 = 13, 00048 P0_14 = 14, 00049 P0_15 = 15, 00050 P0_16 = 16, 00051 P0_17 = 17, 00052 P0_18 = 18, 00053 P0_19 = 19, 00054 P0_20 = 20, 00055 P0_21 = 21, 00056 P0_22 = 22, 00057 P0_23 = 23, 00058 P0_24 = 24, 00059 P0_25 = 25, 00060 P0_26 = 26, 00061 P0_27 = 27, 00062 00063 P1_0 = 32, 00064 P1_1 = 33, 00065 P1_2 = 34, 00066 P1_3 = 35, 00067 P1_4 = 36, 00068 P1_5 = 37, 00069 P1_6 = 38, 00070 P1_7 = 39, 00071 P1_8 = 40, 00072 P1_9 = 41, 00073 P1_10 = 42, 00074 P1_11 = 43, 00075 P1_12 = 44, 00076 P1_13 = 45, 00077 P1_14 = 46, 00078 P1_15 = 47, 00079 P1_16 = 48, 00080 P1_17 = 49, 00081 P1_18 = 50, 00082 P1_19 = 51, 00083 P1_20 = 52, 00084 P1_21 = 53, 00085 P1_22 = 54, 00086 P1_23 = 55, 00087 P1_24 = 56, 00088 P1_25 = 57, 00089 P1_26 = 58, 00090 P1_27 = 59, 00091 P1_28 = 60, 00092 P1_29 = 61, 00093 00094 P1_31 = 63, 00095 00096 // mbed DIP Pin Names 00097 p5 = P0_9, 00098 p6 = P0_8, 00099 p7 = P1_29, 00100 p8 = P0_2, 00101 p9 = P1_27, 00102 p10 = P1_26, 00103 p11 = P1_22, 00104 p12 = P1_21, 00105 p13 = P1_20, 00106 p14 = P1_23, 00107 p15 = P0_11, 00108 p16 = P0_12, 00109 p17 = P0_13, 00110 p18 = P0_14, 00111 p19 = P0_16, 00112 p20 = P0_22, 00113 p21 = P0_7, 00114 p22 = P0_17, 00115 p23 = P1_17, 00116 p24 = P1_18, 00117 p25 = P1_24, 00118 p26 = P1_25, 00119 p27 = P0_4, 00120 p28 = P0_5, 00121 p29 = P1_5, 00122 p30 = P1_2, 00123 00124 p33 = P0_3, 00125 p34 = P1_15, 00126 p35 = P0_20, 00127 p36 = P0_21, 00128 00129 // Other mbed Pin Names 00130 LED1 = P1_8, 00131 LED2 = P1_9, 00132 LED3 = P1_10, 00133 LED4 = P1_11, 00134 00135 USBTX = P0_19, 00136 USBRX = P0_18, 00137 00138 // Not connected 00139 NC = (int)0xFFFFFFFF, 00140 } PinName; 00141 00142 typedef enum { 00143 CHANNEL0 = FLEX_INT0_IRQn , 00144 CHANNEL1 = FLEX_INT1_IRQn, 00145 CHANNEL2 = FLEX_INT2_IRQn, 00146 CHANNEL3 = FLEX_INT3_IRQn, 00147 CHANNEL4 = FLEX_INT4_IRQn, 00148 CHANNEL5 = FLEX_INT5_IRQn, 00149 CHANNEL6 = FLEX_INT6_IRQn, 00150 CHANNEL7 = FLEX_INT7_IRQn 00151 } Channel; 00152 00153 typedef enum { 00154 PullUp = 2, 00155 PullDown = 1, 00156 PullNone = 0, 00157 Repeater = 3, 00158 OpenDrain = 4 00159 } PinMode; 00160 00161 #ifdef __cplusplus 00162 } 00163 #endif 00164 00165 #endif
Generated on Tue Jul 12 2022 13:47:01 by
1.7.2
