Mouse code for the MacroRat
mbed-dev/targets/TARGET_STM/TARGET_STM32F4/TARGET_MTS_DRAGONFLY_F411RE/PinNames.h@18:6a4db94011d3, 2017-05-14 (annotated)
- Committer:
- sahilmgandhi
- Date:
- Sun May 14 23:18:57 2017 +0000
- Revision:
- 18:6a4db94011d3
Publishing again
Who changed what in which revision?
User | Revision | Line number | New contents of line |
---|---|---|---|
sahilmgandhi | 18:6a4db94011d3 | 1 | /* mbed Microcontroller Library |
sahilmgandhi | 18:6a4db94011d3 | 2 | ******************************************************************************* |
sahilmgandhi | 18:6a4db94011d3 | 3 | * Copyright (c) 2014, STMicroelectronics |
sahilmgandhi | 18:6a4db94011d3 | 4 | * All rights reserved. |
sahilmgandhi | 18:6a4db94011d3 | 5 | * |
sahilmgandhi | 18:6a4db94011d3 | 6 | * Redistribution and use in source and binary forms, with or without |
sahilmgandhi | 18:6a4db94011d3 | 7 | * modification, are permitted provided that the following conditions are met: |
sahilmgandhi | 18:6a4db94011d3 | 8 | * |
sahilmgandhi | 18:6a4db94011d3 | 9 | * 1. Redistributions of source code must retain the above copyright notice, |
sahilmgandhi | 18:6a4db94011d3 | 10 | * this list of conditions and the following disclaimer. |
sahilmgandhi | 18:6a4db94011d3 | 11 | * 2. Redistributions in binary form must reproduce the above copyright notice, |
sahilmgandhi | 18:6a4db94011d3 | 12 | * this list of conditions and the following disclaimer in the documentation |
sahilmgandhi | 18:6a4db94011d3 | 13 | * and/or other materials provided with the distribution. |
sahilmgandhi | 18:6a4db94011d3 | 14 | * 3. Neither the name of STMicroelectronics nor the names of its contributors |
sahilmgandhi | 18:6a4db94011d3 | 15 | * may be used to endorse or promote products derived from this software |
sahilmgandhi | 18:6a4db94011d3 | 16 | * without specific prior written permission. |
sahilmgandhi | 18:6a4db94011d3 | 17 | * |
sahilmgandhi | 18:6a4db94011d3 | 18 | * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" |
sahilmgandhi | 18:6a4db94011d3 | 19 | * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE |
sahilmgandhi | 18:6a4db94011d3 | 20 | * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE |
sahilmgandhi | 18:6a4db94011d3 | 21 | * DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE |
sahilmgandhi | 18:6a4db94011d3 | 22 | * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL |
sahilmgandhi | 18:6a4db94011d3 | 23 | * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR |
sahilmgandhi | 18:6a4db94011d3 | 24 | * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER |
sahilmgandhi | 18:6a4db94011d3 | 25 | * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, |
sahilmgandhi | 18:6a4db94011d3 | 26 | * OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE |
sahilmgandhi | 18:6a4db94011d3 | 27 | * OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. |
sahilmgandhi | 18:6a4db94011d3 | 28 | ******************************************************************************* |
sahilmgandhi | 18:6a4db94011d3 | 29 | */ |
sahilmgandhi | 18:6a4db94011d3 | 30 | #ifndef MBED_PINNAMES_H |
sahilmgandhi | 18:6a4db94011d3 | 31 | #define MBED_PINNAMES_H |
sahilmgandhi | 18:6a4db94011d3 | 32 | |
sahilmgandhi | 18:6a4db94011d3 | 33 | #include "cmsis.h" |
sahilmgandhi | 18:6a4db94011d3 | 34 | #include "PinNamesTypes.h" |
sahilmgandhi | 18:6a4db94011d3 | 35 | |
sahilmgandhi | 18:6a4db94011d3 | 36 | #ifdef __cplusplus |
sahilmgandhi | 18:6a4db94011d3 | 37 | extern "C" { |
sahilmgandhi | 18:6a4db94011d3 | 38 | #endif |
sahilmgandhi | 18:6a4db94011d3 | 39 | |
sahilmgandhi | 18:6a4db94011d3 | 40 | typedef enum { |
sahilmgandhi | 18:6a4db94011d3 | 41 | PA_0 = 0x00, |
sahilmgandhi | 18:6a4db94011d3 | 42 | PA_1 = 0x01, |
sahilmgandhi | 18:6a4db94011d3 | 43 | PA_2 = 0x02, |
sahilmgandhi | 18:6a4db94011d3 | 44 | PA_3 = 0x03, |
sahilmgandhi | 18:6a4db94011d3 | 45 | PA_4 = 0x04, |
sahilmgandhi | 18:6a4db94011d3 | 46 | PA_5 = 0x05, |
sahilmgandhi | 18:6a4db94011d3 | 47 | PA_6 = 0x06, |
sahilmgandhi | 18:6a4db94011d3 | 48 | PA_7 = 0x07, |
sahilmgandhi | 18:6a4db94011d3 | 49 | PA_8 = 0x08, |
sahilmgandhi | 18:6a4db94011d3 | 50 | PA_9 = 0x09, |
sahilmgandhi | 18:6a4db94011d3 | 51 | PA_10 = 0x0A, |
sahilmgandhi | 18:6a4db94011d3 | 52 | PA_11 = 0x0B, |
sahilmgandhi | 18:6a4db94011d3 | 53 | PA_12 = 0x0C, |
sahilmgandhi | 18:6a4db94011d3 | 54 | PA_13 = 0x0D, |
sahilmgandhi | 18:6a4db94011d3 | 55 | PA_14 = 0x0E, |
sahilmgandhi | 18:6a4db94011d3 | 56 | PA_15 = 0x0F, |
sahilmgandhi | 18:6a4db94011d3 | 57 | |
sahilmgandhi | 18:6a4db94011d3 | 58 | PB_0 = 0x10, |
sahilmgandhi | 18:6a4db94011d3 | 59 | PB_1 = 0x11, |
sahilmgandhi | 18:6a4db94011d3 | 60 | PB_2 = 0x12, |
sahilmgandhi | 18:6a4db94011d3 | 61 | PB_3 = 0x13, |
sahilmgandhi | 18:6a4db94011d3 | 62 | PB_4 = 0x14, |
sahilmgandhi | 18:6a4db94011d3 | 63 | PB_5 = 0x15, |
sahilmgandhi | 18:6a4db94011d3 | 64 | PB_6 = 0x16, |
sahilmgandhi | 18:6a4db94011d3 | 65 | PB_7 = 0x17, |
sahilmgandhi | 18:6a4db94011d3 | 66 | PB_8 = 0x18, |
sahilmgandhi | 18:6a4db94011d3 | 67 | PB_9 = 0x19, |
sahilmgandhi | 18:6a4db94011d3 | 68 | PB_10 = 0x1A, |
sahilmgandhi | 18:6a4db94011d3 | 69 | PB_12 = 0x1C, |
sahilmgandhi | 18:6a4db94011d3 | 70 | PB_13 = 0x1D, |
sahilmgandhi | 18:6a4db94011d3 | 71 | PB_14 = 0x1E, |
sahilmgandhi | 18:6a4db94011d3 | 72 | PB_15 = 0x1F, |
sahilmgandhi | 18:6a4db94011d3 | 73 | |
sahilmgandhi | 18:6a4db94011d3 | 74 | PC_0 = 0x20, |
sahilmgandhi | 18:6a4db94011d3 | 75 | PC_1 = 0x21, |
sahilmgandhi | 18:6a4db94011d3 | 76 | PC_2 = 0x22, |
sahilmgandhi | 18:6a4db94011d3 | 77 | PC_3 = 0x23, |
sahilmgandhi | 18:6a4db94011d3 | 78 | PC_4 = 0x24, |
sahilmgandhi | 18:6a4db94011d3 | 79 | PC_5 = 0x25, |
sahilmgandhi | 18:6a4db94011d3 | 80 | PC_6 = 0x26, |
sahilmgandhi | 18:6a4db94011d3 | 81 | PC_7 = 0x27, |
sahilmgandhi | 18:6a4db94011d3 | 82 | PC_8 = 0x28, |
sahilmgandhi | 18:6a4db94011d3 | 83 | PC_9 = 0x29, |
sahilmgandhi | 18:6a4db94011d3 | 84 | PC_10 = 0x2A, |
sahilmgandhi | 18:6a4db94011d3 | 85 | PC_11 = 0x2B, |
sahilmgandhi | 18:6a4db94011d3 | 86 | PC_12 = 0x2C, |
sahilmgandhi | 18:6a4db94011d3 | 87 | PC_13 = 0x2D, |
sahilmgandhi | 18:6a4db94011d3 | 88 | PC_14 = 0x2E, |
sahilmgandhi | 18:6a4db94011d3 | 89 | PC_15 = 0x2F, |
sahilmgandhi | 18:6a4db94011d3 | 90 | |
sahilmgandhi | 18:6a4db94011d3 | 91 | PD_2 = 0x32, |
sahilmgandhi | 18:6a4db94011d3 | 92 | |
sahilmgandhi | 18:6a4db94011d3 | 93 | PH_0 = 0x70, |
sahilmgandhi | 18:6a4db94011d3 | 94 | PH_1 = 0x71, |
sahilmgandhi | 18:6a4db94011d3 | 95 | |
sahilmgandhi | 18:6a4db94011d3 | 96 | // ADC internal channels |
sahilmgandhi | 18:6a4db94011d3 | 97 | ADC_TEMP = 0xF0, |
sahilmgandhi | 18:6a4db94011d3 | 98 | ADC_VREF = 0xF1, |
sahilmgandhi | 18:6a4db94011d3 | 99 | ADC_VBAT = 0xF2, |
sahilmgandhi | 18:6a4db94011d3 | 100 | |
sahilmgandhi | 18:6a4db94011d3 | 101 | // Arduino connector namings |
sahilmgandhi | 18:6a4db94011d3 | 102 | A0 = PC_2, |
sahilmgandhi | 18:6a4db94011d3 | 103 | A1 = PC_0, |
sahilmgandhi | 18:6a4db94011d3 | 104 | A2 = PC_4, |
sahilmgandhi | 18:6a4db94011d3 | 105 | A3 = PB_0, |
sahilmgandhi | 18:6a4db94011d3 | 106 | A4 = PC_1, |
sahilmgandhi | 18:6a4db94011d3 | 107 | A5 = PC_9, |
sahilmgandhi | 18:6a4db94011d3 | 108 | D0 = PA_3, |
sahilmgandhi | 18:6a4db94011d3 | 109 | D1 = PA_2, |
sahilmgandhi | 18:6a4db94011d3 | 110 | D2 = PB_15, |
sahilmgandhi | 18:6a4db94011d3 | 111 | D3 = PA_0, |
sahilmgandhi | 18:6a4db94011d3 | 112 | D4 = PA_7, |
sahilmgandhi | 18:6a4db94011d3 | 113 | D5 = PA_9, |
sahilmgandhi | 18:6a4db94011d3 | 114 | D6 = PA_1, |
sahilmgandhi | 18:6a4db94011d3 | 115 | D7 = PA_8, |
sahilmgandhi | 18:6a4db94011d3 | 116 | D8 = PB_1, |
sahilmgandhi | 18:6a4db94011d3 | 117 | D9 = PB_13, |
sahilmgandhi | 18:6a4db94011d3 | 118 | D10 = PC_8, |
sahilmgandhi | 18:6a4db94011d3 | 119 | D11 = PB_5, |
sahilmgandhi | 18:6a4db94011d3 | 120 | D12 = PA_6, |
sahilmgandhi | 18:6a4db94011d3 | 121 | D13 = PA_5, |
sahilmgandhi | 18:6a4db94011d3 | 122 | D14 = PB_9, |
sahilmgandhi | 18:6a4db94011d3 | 123 | D15 = PB_8, |
sahilmgandhi | 18:6a4db94011d3 | 124 | |
sahilmgandhi | 18:6a4db94011d3 | 125 | // Generic signals namings |
sahilmgandhi | 18:6a4db94011d3 | 126 | LED1 = D3, |
sahilmgandhi | 18:6a4db94011d3 | 127 | LED2 = D3, |
sahilmgandhi | 18:6a4db94011d3 | 128 | LED3 = D3, |
sahilmgandhi | 18:6a4db94011d3 | 129 | LED4 = D3, |
sahilmgandhi | 18:6a4db94011d3 | 130 | SERIAL_TX = D1, |
sahilmgandhi | 18:6a4db94011d3 | 131 | SERIAL_RX = D0, |
sahilmgandhi | 18:6a4db94011d3 | 132 | SERIAL_RTS = D3, |
sahilmgandhi | 18:6a4db94011d3 | 133 | SERIAL_CTS = D6, |
sahilmgandhi | 18:6a4db94011d3 | 134 | SERIAL_DCD = D4, |
sahilmgandhi | 18:6a4db94011d3 | 135 | SERIAL_DSR = D5, |
sahilmgandhi | 18:6a4db94011d3 | 136 | SERIAL_DTR = D7, |
sahilmgandhi | 18:6a4db94011d3 | 137 | SERIAL_RI = D8, |
sahilmgandhi | 18:6a4db94011d3 | 138 | USBTX = PB_6, |
sahilmgandhi | 18:6a4db94011d3 | 139 | USBRX = PB_7, |
sahilmgandhi | 18:6a4db94011d3 | 140 | RADIO_TX = PC_7, |
sahilmgandhi | 18:6a4db94011d3 | 141 | RADIO_RX = PC_6, |
sahilmgandhi | 18:6a4db94011d3 | 142 | RADIO_RTS = PB_10, |
sahilmgandhi | 18:6a4db94011d3 | 143 | RADIO_CTS = PB_12, |
sahilmgandhi | 18:6a4db94011d3 | 144 | RADIO_DCD = D5, |
sahilmgandhi | 18:6a4db94011d3 | 145 | RADIO_DSR = D8, |
sahilmgandhi | 18:6a4db94011d3 | 146 | RADIO_DTR = D4, |
sahilmgandhi | 18:6a4db94011d3 | 147 | RADIO_RI = D9, |
sahilmgandhi | 18:6a4db94011d3 | 148 | WAKEUP = D3, |
sahilmgandhi | 18:6a4db94011d3 | 149 | |
sahilmgandhi | 18:6a4db94011d3 | 150 | // I2C1 and I2C3 are available on Arduino pins |
sahilmgandhi | 18:6a4db94011d3 | 151 | I2C1_SCL = D15, |
sahilmgandhi | 18:6a4db94011d3 | 152 | I2C1_SDA = D14, |
sahilmgandhi | 18:6a4db94011d3 | 153 | I2C3_SCL = D7, |
sahilmgandhi | 18:6a4db94011d3 | 154 | I2C3_SDA = A5, |
sahilmgandhi | 18:6a4db94011d3 | 155 | |
sahilmgandhi | 18:6a4db94011d3 | 156 | // legacy definitions |
sahilmgandhi | 18:6a4db94011d3 | 157 | I2C_SCL = I2C1_SCL, |
sahilmgandhi | 18:6a4db94011d3 | 158 | I2C_SDA = I2C1_SDA, |
sahilmgandhi | 18:6a4db94011d3 | 159 | |
sahilmgandhi | 18:6a4db94011d3 | 160 | // SPI1 and SPI2 are available on Arduino pins |
sahilmgandhi | 18:6a4db94011d3 | 161 | SPI1_MOSI = D11, |
sahilmgandhi | 18:6a4db94011d3 | 162 | SPI1_MISO = D12, |
sahilmgandhi | 18:6a4db94011d3 | 163 | SPI1_SCK = D13, |
sahilmgandhi | 18:6a4db94011d3 | 164 | SPI2_MOSI = D2, |
sahilmgandhi | 18:6a4db94011d3 | 165 | SPI2_MISO = A0, |
sahilmgandhi | 18:6a4db94011d3 | 166 | SPI2_SCK = D9, |
sahilmgandhi | 18:6a4db94011d3 | 167 | |
sahilmgandhi | 18:6a4db94011d3 | 168 | // SPI3 connects to flash part |
sahilmgandhi | 18:6a4db94011d3 | 169 | SPI3_MOSI = PC_12, |
sahilmgandhi | 18:6a4db94011d3 | 170 | SPI3_MISO = PC_11, |
sahilmgandhi | 18:6a4db94011d3 | 171 | SPI3_SCK = PC_10, |
sahilmgandhi | 18:6a4db94011d3 | 172 | |
sahilmgandhi | 18:6a4db94011d3 | 173 | // legacy definitions |
sahilmgandhi | 18:6a4db94011d3 | 174 | SPI_MOSI = SPI3_MOSI, |
sahilmgandhi | 18:6a4db94011d3 | 175 | SPI_MISO = SPI3_MISO, |
sahilmgandhi | 18:6a4db94011d3 | 176 | SPI_SCK = SPI3_SCK, |
sahilmgandhi | 18:6a4db94011d3 | 177 | SPI_CS1 = PA_4, |
sahilmgandhi | 18:6a4db94011d3 | 178 | SPI_CS2 = PB_14, |
sahilmgandhi | 18:6a4db94011d3 | 179 | |
sahilmgandhi | 18:6a4db94011d3 | 180 | // Not connected |
sahilmgandhi | 18:6a4db94011d3 | 181 | NC = (int)0xFFFFFFFF |
sahilmgandhi | 18:6a4db94011d3 | 182 | } PinName; |
sahilmgandhi | 18:6a4db94011d3 | 183 | |
sahilmgandhi | 18:6a4db94011d3 | 184 | #ifdef __cplusplus |
sahilmgandhi | 18:6a4db94011d3 | 185 | } |
sahilmgandhi | 18:6a4db94011d3 | 186 | #endif |
sahilmgandhi | 18:6a4db94011d3 | 187 | |
sahilmgandhi | 18:6a4db94011d3 | 188 | #endif |