mirror of https://github.com/ARMmbed/mbed-os.git
STM32H7: standard pin names
parent
ede1741e55
commit
68b620bdc2
|
|
@ -90,7 +90,6 @@ MBED_WEAK const PinMap PinMap_ADC[] = {
|
||||||
{PC_1_ALT3, ADC_3, STM_PIN_DATA_EXT(STM_MODE_ANALOG, GPIO_NOPULL, 0, 10, 0)}, // ADC3_INN10 // Connected to ETH_MDC
|
{PC_1_ALT3, ADC_3, STM_PIN_DATA_EXT(STM_MODE_ANALOG, GPIO_NOPULL, 0, 10, 0)}, // ADC3_INN10 // Connected to ETH_MDC
|
||||||
{PC_1_ALT4, ADC_3, STM_PIN_DATA_EXT(STM_MODE_ANALOG, GPIO_NOPULL, 0, 11, 0)}, // ADC3_INP11 // Connected to ETH_MDC
|
{PC_1_ALT4, ADC_3, STM_PIN_DATA_EXT(STM_MODE_ANALOG, GPIO_NOPULL, 0, 11, 0)}, // ADC3_INP11 // Connected to ETH_MDC
|
||||||
{PC_2, ADC_3, STM_PIN_DATA_EXT(STM_MODE_ANALOG, GPIO_NOPULL, 0, 0, 0)}, // ADC3_INP0
|
{PC_2, ADC_3, STM_PIN_DATA_EXT(STM_MODE_ANALOG, GPIO_NOPULL, 0, 0, 0)}, // ADC3_INP0
|
||||||
{PC_2_ALT0, ADC_3, STM_PIN_DATA_EXT(STM_MODE_ANALOG, GPIO_NOPULL, 0, 1, 0)}, // ADC3_INN1
|
|
||||||
{PC_3, ADC_3, STM_PIN_DATA_EXT(STM_MODE_ANALOG, GPIO_NOPULL, 0, 1, 0)}, // ADC3_INP1
|
{PC_3, ADC_3, STM_PIN_DATA_EXT(STM_MODE_ANALOG, GPIO_NOPULL, 0, 1, 0)}, // ADC3_INP1
|
||||||
{PC_4, ADC_1, STM_PIN_DATA_EXT(STM_MODE_ANALOG, GPIO_NOPULL, 0, 4, 0)}, // ADC1_INP4 // Connected to ETH_RXD0
|
{PC_4, ADC_1, STM_PIN_DATA_EXT(STM_MODE_ANALOG, GPIO_NOPULL, 0, 4, 0)}, // ADC1_INP4 // Connected to ETH_RXD0
|
||||||
{PC_4_ALT0, ADC_2, STM_PIN_DATA_EXT(STM_MODE_ANALOG, GPIO_NOPULL, 0, 4, 0)}, // ADC2_INP4 // Connected to ETH_RXD0
|
{PC_4_ALT0, ADC_2, STM_PIN_DATA_EXT(STM_MODE_ANALOG, GPIO_NOPULL, 0, 4, 0)}, // ADC2_INP4 // Connected to ETH_RXD0
|
||||||
|
|
|
||||||
|
|
@ -1,31 +1,18 @@
|
||||||
/* mbed Microcontroller Library
|
/* mbed Microcontroller Library
|
||||||
*******************************************************************************
|
* SPDX-License-Identifier: BSD-3-Clause
|
||||||
* Copyright (c) 2018, STMicroelectronics
|
******************************************************************************
|
||||||
|
*
|
||||||
|
* Copyright (c) 2016-2021 STMicroelectronics.
|
||||||
* All rights reserved.
|
* All rights reserved.
|
||||||
*
|
*
|
||||||
* Redistribution and use in source and binary forms, with or without
|
* This software component is licensed by ST under BSD 3-Clause license,
|
||||||
* modification, are permitted provided that the following conditions are met:
|
* the "License"; You may not use this file except in compliance with the
|
||||||
|
* License. You may obtain a copy of the License at:
|
||||||
|
* opensource.org/licenses/BSD-3-Clause
|
||||||
*
|
*
|
||||||
* 1. Redistributions of source code must retain the above copyright notice,
|
******************************************************************************
|
||||||
* this list of conditions and the following disclaimer.
|
|
||||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
|
||||||
* this list of conditions and the following disclaimer in the documentation
|
|
||||||
* and/or other materials provided with the distribution.
|
|
||||||
* 3. Neither the name of STMicroelectronics nor the names of its contributors
|
|
||||||
* may be used to endorse or promote products derived from this software
|
|
||||||
* without specific prior written permission.
|
|
||||||
*
|
*
|
||||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
* Automatically generated from STM32CubeMX/db/mcu/STM32H743ZITx.xml
|
||||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
||||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
|
||||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
|
||||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
||||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
|
||||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
|
||||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
|
||||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
||||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
||||||
*******************************************************************************
|
|
||||||
*/
|
*/
|
||||||
|
|
||||||
/* MBED TARGET LIST: NUCLEO_H743ZI2 */
|
/* MBED TARGET LIST: NUCLEO_H743ZI2 */
|
||||||
|
|
@ -40,213 +27,214 @@
|
||||||
extern "C" {
|
extern "C" {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
#define ALTC 0xF00
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
ALT0 = 0x100,
|
ALT0 = 0x100,
|
||||||
ALT1 = 0x200,
|
ALT1 = 0x200,
|
||||||
ALT2 = 0x300,
|
ALT2 = 0x300,
|
||||||
ALT3 = 0x400,
|
ALT3 = 0x400,
|
||||||
ALT4 = 0x500
|
ALT4 = 0x500,
|
||||||
} ALTx;
|
} ALTx;
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
PA_0 = 0x00,
|
PA_0 = 0x00,
|
||||||
PA_1 = 0x01,
|
PA_0C = PA_0 | ALTC, // dual pad
|
||||||
PA_1_ALT0 = PA_1 | ALT0,
|
PA_1 = 0x01,
|
||||||
PA_2 = 0x02,
|
PA_1C = PA_1 | ALTC, // dual pad
|
||||||
PA_2_ALT0 = PA_2 | ALT0,
|
PA_1_ALT0 = PA_1 | ALT0, // same pin used for alternate HW
|
||||||
PA_3 = 0x03,
|
PA_2 = 0x02,
|
||||||
PA_3_ALT0 = PA_3 | ALT0,
|
PA_2_ALT0 = PA_2 | ALT0, // same pin used for alternate HW
|
||||||
PA_4 = 0x04,
|
PA_3 = 0x03,
|
||||||
PA_4_ALT0 = PA_4 | ALT0,
|
PA_3_ALT0 = PA_3 | ALT0, // same pin used for alternate HW
|
||||||
PA_4_ALT1 = PA_4 | ALT1,
|
PA_4 = 0x04,
|
||||||
PA_5 = 0x05,
|
PA_4_ALT0 = PA_4 | ALT0, // same pin used for alternate HW
|
||||||
PA_5_ALT0 = PA_5 | ALT0,
|
PA_4_ALT1 = PA_4 | ALT1, // same pin used for alternate HW
|
||||||
PA_5_ALT1 = PA_5 | ALT1,
|
PA_5 = 0x05,
|
||||||
PA_5_ALT2 = PA_5 | ALT2,
|
PA_5_ALT0 = PA_5 | ALT0, // same pin used for alternate HW
|
||||||
PA_6 = 0x06,
|
PA_5_ALT1 = PA_5 | ALT1, // same pin used for alternate HW
|
||||||
PA_6_ALT0 = PA_6 | ALT0,
|
PA_5_ALT2 = PA_5 | ALT2, // same pin used for alternate HW
|
||||||
PA_7 = 0x07,
|
PA_6 = 0x06,
|
||||||
PA_7_ALT0 = PA_7 | ALT0,
|
PA_6_ALT0 = PA_6 | ALT0, // same pin used for alternate HW
|
||||||
PA_7_ALT1 = PA_7 | ALT1,
|
PA_7 = 0x07,
|
||||||
PA_7_ALT2 = PA_7 | ALT2,
|
PA_7_ALT0 = PA_7 | ALT0, // same pin used for alternate HW
|
||||||
PA_8 = 0x08,
|
PA_7_ALT1 = PA_7 | ALT1, // same pin used for alternate HW
|
||||||
PA_9 = 0x09,
|
PA_7_ALT2 = PA_7 | ALT2, // same pin used for alternate HW
|
||||||
PA_9_ALT0 = PA_9 | ALT0,
|
PA_8 = 0x08,
|
||||||
PA_10 = 0x0A,
|
PA_9 = 0x09,
|
||||||
PA_10_ALT0 = PA_10 | ALT0,
|
PA_9_ALT0 = PA_9 | ALT0, // same pin used for alternate HW
|
||||||
PA_11 = 0x0B,
|
PA_10 = 0x0A,
|
||||||
PA_11_ALT0 = PA_11 | ALT0,
|
PA_10_ALT0 = PA_10 | ALT0, // same pin used for alternate HW
|
||||||
PA_12 = 0x0C,
|
PA_11 = 0x0B,
|
||||||
PA_12_ALT0 = PA_12 | ALT0,
|
PA_11_ALT0 = PA_11 | ALT0, // same pin used for alternate HW
|
||||||
PA_13 = 0x0D,
|
PA_12 = 0x0C,
|
||||||
PA_14 = 0x0E,
|
PA_12_ALT0 = PA_12 | ALT0, // same pin used for alternate HW
|
||||||
PA_15 = 0x0F,
|
PA_13 = 0x0D,
|
||||||
PA_15_ALT0 = PA_15 | ALT0,
|
PA_14 = 0x0E,
|
||||||
PA_15_ALT1 = PA_15 | ALT1,
|
PA_15 = 0x0F,
|
||||||
|
PA_15_ALT0 = PA_15 | ALT0, // same pin used for alternate HW
|
||||||
|
PA_15_ALT1 = PA_15 | ALT1, // same pin used for alternate HW
|
||||||
|
PB_0 = 0x10,
|
||||||
|
PB_0_ALT0 = PB_0 | ALT0, // same pin used for alternate HW
|
||||||
|
PB_0_ALT1 = PB_0 | ALT1, // same pin used for alternate HW
|
||||||
|
PB_0_ALT2 = PB_0 | ALT2, // same pin used for alternate HW
|
||||||
|
PB_1 = 0x11,
|
||||||
|
PB_1_ALT0 = PB_1 | ALT0, // same pin used for alternate HW
|
||||||
|
PB_1_ALT1 = PB_1 | ALT1, // same pin used for alternate HW
|
||||||
|
PB_2 = 0x12,
|
||||||
|
PB_3 = 0x13,
|
||||||
|
PB_3_ALT0 = PB_3 | ALT0, // same pin used for alternate HW
|
||||||
|
PB_3_ALT1 = PB_3 | ALT1, // same pin used for alternate HW
|
||||||
|
PB_4 = 0x14,
|
||||||
|
PB_4_ALT0 = PB_4 | ALT0, // same pin used for alternate HW
|
||||||
|
PB_4_ALT1 = PB_4 | ALT1, // same pin used for alternate HW
|
||||||
|
PB_5 = 0x15,
|
||||||
|
PB_5_ALT0 = PB_5 | ALT0, // same pin used for alternate HW
|
||||||
|
PB_5_ALT1 = PB_5 | ALT1, // same pin used for alternate HW
|
||||||
|
PB_6 = 0x16,
|
||||||
|
PB_6_ALT0 = PB_6 | ALT0, // same pin used for alternate HW
|
||||||
|
PB_6_ALT1 = PB_6 | ALT1, // same pin used for alternate HW
|
||||||
|
PB_7 = 0x17,
|
||||||
|
PB_7_ALT0 = PB_7 | ALT0, // same pin used for alternate HW
|
||||||
|
PB_8 = 0x18,
|
||||||
|
PB_8_ALT0 = PB_8 | ALT0, // same pin used for alternate HW
|
||||||
|
PB_9 = 0x19,
|
||||||
|
PB_9_ALT0 = PB_9 | ALT0, // same pin used for alternate HW
|
||||||
|
PB_10 = 0x1A,
|
||||||
|
PB_11 = 0x1B,
|
||||||
|
PB_12 = 0x1C,
|
||||||
|
PB_13 = 0x1D,
|
||||||
|
PB_14 = 0x1E,
|
||||||
|
PB_14_ALT0 = PB_14 | ALT0, // same pin used for alternate HW
|
||||||
|
PB_14_ALT1 = PB_14 | ALT1, // same pin used for alternate HW
|
||||||
|
PB_15 = 0x1F,
|
||||||
|
PB_15_ALT0 = PB_15 | ALT0, // same pin used for alternate HW
|
||||||
|
PB_15_ALT1 = PB_15 | ALT1, // same pin used for alternate HW
|
||||||
|
PC_0 = 0x20,
|
||||||
|
PC_0_ALT0 = PC_0 | ALT0, // same pin used for alternate HW
|
||||||
|
PC_0_ALT1 = PC_0 | ALT1, // same pin used for alternate HW
|
||||||
|
PC_1 = 0x21,
|
||||||
|
PC_1_ALT0 = PC_1 | ALT0, // same pin used for alternate HW
|
||||||
|
PC_1_ALT1 = PC_1 | ALT1, // same pin used for alternate HW
|
||||||
|
PC_1_ALT2 = PC_1 | ALT2, // same pin used for alternate HW
|
||||||
|
PC_1_ALT3 = PC_1 | ALT3, // same pin used for alternate HW
|
||||||
|
PC_1_ALT4 = PC_1 | ALT4, // same pin used for alternate HW
|
||||||
|
PC_2 = 0x22,
|
||||||
|
PC_2C = PC_2 | ALTC, // dual pad
|
||||||
|
PC_2C_ALT0 = PC_2C | ALT0, // same pin used for alternate HW
|
||||||
|
PC_3 = 0x23,
|
||||||
|
PC_3C = PC_3 | ALTC, // dual pad
|
||||||
|
PC_4 = 0x24,
|
||||||
|
PC_4_ALT0 = PC_4 | ALT0, // same pin used for alternate HW
|
||||||
|
PC_5 = 0x25,
|
||||||
|
PC_5_ALT0 = PC_5 | ALT0, // same pin used for alternate HW
|
||||||
|
PC_5_ALT1 = PC_5 | ALT1, // same pin used for alternate HW
|
||||||
|
PC_5_ALT2 = PC_5 | ALT2, // same pin used for alternate HW
|
||||||
|
PC_6 = 0x26,
|
||||||
|
PC_6_ALT0 = PC_6 | ALT0, // same pin used for alternate HW
|
||||||
|
PC_7 = 0x27,
|
||||||
|
PC_7_ALT0 = PC_7 | ALT0, // same pin used for alternate HW
|
||||||
|
PC_8 = 0x28,
|
||||||
|
PC_8_ALT0 = PC_8 | ALT0, // same pin used for alternate HW
|
||||||
|
PC_9 = 0x29,
|
||||||
|
PC_9_ALT0 = PC_9 | ALT0, // same pin used for alternate HW
|
||||||
|
PC_10 = 0x2A,
|
||||||
|
PC_10_ALT0 = PC_10 | ALT0, // same pin used for alternate HW
|
||||||
|
PC_11 = 0x2B,
|
||||||
|
PC_11_ALT0 = PC_11 | ALT0, // same pin used for alternate HW
|
||||||
|
PC_12 = 0x2C,
|
||||||
|
PC_13 = 0x2D,
|
||||||
|
PC_14 = 0x2E,
|
||||||
|
PC_15 = 0x2F,
|
||||||
|
PD_0 = 0x30,
|
||||||
|
PD_1 = 0x31,
|
||||||
|
PD_2 = 0x32,
|
||||||
|
PD_3 = 0x33,
|
||||||
|
PD_4 = 0x34,
|
||||||
|
PD_5 = 0x35,
|
||||||
|
PD_6 = 0x36,
|
||||||
|
PD_7 = 0x37,
|
||||||
|
PD_8 = 0x38,
|
||||||
|
PD_9 = 0x39,
|
||||||
|
PD_10 = 0x3A,
|
||||||
|
PD_11 = 0x3B,
|
||||||
|
PD_12 = 0x3C,
|
||||||
|
PD_13 = 0x3D,
|
||||||
|
PD_14 = 0x3E,
|
||||||
|
PD_15 = 0x3F,
|
||||||
|
PE_0 = 0x40,
|
||||||
|
PE_1 = 0x41,
|
||||||
|
PE_2 = 0x42,
|
||||||
|
PE_3 = 0x43,
|
||||||
|
PE_4 = 0x44,
|
||||||
|
PE_5 = 0x45,
|
||||||
|
PE_6 = 0x46,
|
||||||
|
PE_7 = 0x47,
|
||||||
|
PE_8 = 0x48,
|
||||||
|
PE_9 = 0x49,
|
||||||
|
PE_10 = 0x4A,
|
||||||
|
PE_11 = 0x4B,
|
||||||
|
PE_12 = 0x4C,
|
||||||
|
PE_13 = 0x4D,
|
||||||
|
PE_14 = 0x4E,
|
||||||
|
PE_15 = 0x4F,
|
||||||
|
PF_0 = 0x50,
|
||||||
|
PF_1 = 0x51,
|
||||||
|
PF_2 = 0x52,
|
||||||
|
PF_3 = 0x53,
|
||||||
|
PF_4 = 0x54,
|
||||||
|
PF_4_ALT0 = PF_4 | ALT0, // same pin used for alternate HW
|
||||||
|
PF_5 = 0x55,
|
||||||
|
PF_6 = 0x56,
|
||||||
|
PF_6_ALT0 = PF_6 | ALT0, // same pin used for alternate HW
|
||||||
|
PF_7 = 0x57,
|
||||||
|
PF_8 = 0x58,
|
||||||
|
PF_8_ALT0 = PF_8 | ALT0, // same pin used for alternate HW
|
||||||
|
PF_9 = 0x59,
|
||||||
|
PF_9_ALT0 = PF_9 | ALT0, // same pin used for alternate HW
|
||||||
|
PF_10 = 0x5A,
|
||||||
|
PF_10_ALT0 = PF_10 | ALT0, // same pin used for alternate HW
|
||||||
|
PF_11 = 0x5B,
|
||||||
|
PF_12 = 0x5C,
|
||||||
|
PF_12_ALT0 = PF_12 | ALT0, // same pin used for alternate HW
|
||||||
|
PF_13 = 0x5D,
|
||||||
|
PF_14 = 0x5E,
|
||||||
|
PF_14_ALT0 = PF_14 | ALT0, // same pin used for alternate HW
|
||||||
|
PF_15 = 0x5F,
|
||||||
|
PG_0 = 0x60,
|
||||||
|
PG_1 = 0x61,
|
||||||
|
PG_2 = 0x62,
|
||||||
|
PG_3 = 0x63,
|
||||||
|
PG_4 = 0x64,
|
||||||
|
PG_5 = 0x65,
|
||||||
|
PG_6 = 0x66,
|
||||||
|
PG_7 = 0x67,
|
||||||
|
PG_8 = 0x68,
|
||||||
|
PG_9 = 0x69,
|
||||||
|
PG_10 = 0x6A,
|
||||||
|
PG_11 = 0x6B,
|
||||||
|
PG_12 = 0x6C,
|
||||||
|
PG_13 = 0x6D,
|
||||||
|
PG_14 = 0x6E,
|
||||||
|
PG_15 = 0x6F,
|
||||||
|
PH_0 = 0x70,
|
||||||
|
PH_1 = 0x71,
|
||||||
|
|
||||||
PB_0 = 0x10,
|
/**** ADC internal channels ****/
|
||||||
PB_0_ALT0 = PB_0 | ALT0,
|
|
||||||
PB_0_ALT1 = PB_0 | ALT1,
|
|
||||||
PB_0_ALT2 = PB_0 | ALT2,
|
|
||||||
PB_1 = 0x11,
|
|
||||||
PB_1_ALT0 = PB_1 | ALT0,
|
|
||||||
PB_1_ALT1 = PB_1 | ALT1,
|
|
||||||
PB_2 = 0x12,
|
|
||||||
PB_3 = 0x13,
|
|
||||||
PB_3_ALT0 = PB_3 | ALT0,
|
|
||||||
PB_3_ALT1 = PB_3 | ALT1,
|
|
||||||
PB_4 = 0x14,
|
|
||||||
PB_4_ALT0 = PB_4 | ALT0,
|
|
||||||
PB_4_ALT1 = PB_4 | ALT1,
|
|
||||||
PB_5 = 0x15,
|
|
||||||
PB_5_ALT0 = PB_5 | ALT0,
|
|
||||||
PB_5_ALT1 = PB_5 | ALT1,
|
|
||||||
PB_6 = 0x16,
|
|
||||||
PB_6_ALT0 = PB_6 | ALT0,
|
|
||||||
PB_6_ALT1 = PB_6 | ALT1,
|
|
||||||
PB_7 = 0x17,
|
|
||||||
PB_7_ALT0 = PB_7 | ALT0,
|
|
||||||
PB_8 = 0x18,
|
|
||||||
PB_8_ALT0 = PB_8 | ALT0,
|
|
||||||
PB_9 = 0x19,
|
|
||||||
PB_9_ALT0 = PB_9 | ALT0,
|
|
||||||
PB_10 = 0x1A,
|
|
||||||
PB_11 = 0x1B,
|
|
||||||
PB_12 = 0x1C,
|
|
||||||
PB_13 = 0x1D,
|
|
||||||
PB_14 = 0x1E,
|
|
||||||
PB_14_ALT0 = PB_14 | ALT0,
|
|
||||||
PB_14_ALT1 = PB_14 | ALT1,
|
|
||||||
PB_15 = 0x1F,
|
|
||||||
PB_15_ALT0 = PB_15 | ALT0,
|
|
||||||
PB_15_ALT1 = PB_15 | ALT1,
|
|
||||||
|
|
||||||
PC_0 = 0x20,
|
ADC_TEMP = 0xF0, // Internal pin virtual value
|
||||||
PC_0_ALT0 = PC_0 | ALT0,
|
ADC_VREF = 0xF1, // Internal pin virtual value
|
||||||
PC_0_ALT1 = PC_0 | ALT1,
|
ADC_VBAT = 0xF2, // Internal pin virtual value
|
||||||
PC_1 = 0x21,
|
|
||||||
PC_1_ALT0 = PC_1 | ALT0,
|
|
||||||
PC_1_ALT1 = PC_1 | ALT1,
|
|
||||||
PC_1_ALT2 = PC_1 | ALT2,
|
|
||||||
PC_1_ALT3 = PC_1 | ALT3,
|
|
||||||
PC_1_ALT4 = PC_1 | ALT4,
|
|
||||||
PC_2 = 0x22,
|
|
||||||
PC_2_ALT0 = PC_2 | ALT0,
|
|
||||||
PC_3 = 0x23,
|
|
||||||
PC_4 = 0x24,
|
|
||||||
PC_4_ALT0 = PC_4 | ALT0,
|
|
||||||
PC_5 = 0x25,
|
|
||||||
PC_5_ALT0 = PC_5 | ALT0,
|
|
||||||
PC_5_ALT1 = PC_5 | ALT1,
|
|
||||||
PC_5_ALT2 = PC_5 | ALT2,
|
|
||||||
PC_6 = 0x26,
|
|
||||||
PC_6_ALT0 = PC_6 | ALT0,
|
|
||||||
PC_7 = 0x27,
|
|
||||||
PC_7_ALT0 = PC_7 | ALT0,
|
|
||||||
PC_8 = 0x28,
|
|
||||||
PC_8_ALT0 = PC_8 | ALT0,
|
|
||||||
PC_9 = 0x29,
|
|
||||||
PC_9_ALT0 = PC_9 | ALT0,
|
|
||||||
PC_10 = 0x2A,
|
|
||||||
PC_10_ALT0 = PC_10 | ALT0,
|
|
||||||
PC_11 = 0x2B,
|
|
||||||
PC_11_ALT0 = PC_11 | ALT0,
|
|
||||||
PC_12 = 0x2C,
|
|
||||||
PC_13 = 0x2D,
|
|
||||||
PC_14 = 0x2E,
|
|
||||||
PC_15 = 0x2F,
|
|
||||||
|
|
||||||
PD_0 = 0x30,
|
|
||||||
PD_1 = 0x31,
|
|
||||||
PD_2 = 0x32,
|
|
||||||
PD_3 = 0x33,
|
|
||||||
PD_4 = 0x34,
|
|
||||||
PD_5 = 0x35,
|
|
||||||
PD_6 = 0x36,
|
|
||||||
PD_7 = 0x37,
|
|
||||||
PD_8 = 0x38,
|
|
||||||
PD_9 = 0x39,
|
|
||||||
PD_10 = 0x3A,
|
|
||||||
PD_11 = 0x3B,
|
|
||||||
PD_12 = 0x3C,
|
|
||||||
PD_13 = 0x3D,
|
|
||||||
PD_14 = 0x3E,
|
|
||||||
PD_15 = 0x3F,
|
|
||||||
|
|
||||||
PE_0 = 0x40,
|
|
||||||
PE_1 = 0x41,
|
|
||||||
PE_2 = 0x42,
|
|
||||||
PE_3 = 0x43,
|
|
||||||
PE_4 = 0x44,
|
|
||||||
PE_5 = 0x45,
|
|
||||||
PE_6 = 0x46,
|
|
||||||
PE_7 = 0x47,
|
|
||||||
PE_8 = 0x48,
|
|
||||||
PE_9 = 0x49,
|
|
||||||
PE_10 = 0x4A,
|
|
||||||
PE_11 = 0x4B,
|
|
||||||
PE_12 = 0x4C,
|
|
||||||
PE_13 = 0x4D,
|
|
||||||
PE_14 = 0x4E,
|
|
||||||
PE_15 = 0x4F,
|
|
||||||
|
|
||||||
PF_0 = 0x50,
|
|
||||||
PF_1 = 0x51,
|
|
||||||
PF_2 = 0x52,
|
|
||||||
PF_3 = 0x53,
|
|
||||||
PF_4 = 0x54,
|
|
||||||
PF_4_ALT0 = PF_4 | ALT0,
|
|
||||||
PF_5 = 0x55,
|
|
||||||
PF_6 = 0x56,
|
|
||||||
PF_6_ALT0 = PF_6 | ALT0,
|
|
||||||
PF_7 = 0x57,
|
|
||||||
PF_8 = 0x58,
|
|
||||||
PF_8_ALT0 = PF_8 | ALT0,
|
|
||||||
PF_9 = 0x59,
|
|
||||||
PF_9_ALT0 = PF_9 | ALT0,
|
|
||||||
PF_10 = 0x5A,
|
|
||||||
PF_10_ALT0 = PF_10 | ALT0,
|
|
||||||
PF_11 = 0x5B,
|
|
||||||
PF_12 = 0x5C,
|
|
||||||
PF_12_ALT0 = PF_12 | ALT0,
|
|
||||||
PF_13 = 0x5D,
|
|
||||||
PF_14 = 0x5E,
|
|
||||||
PF_14_ALT0 = PF_14 | ALT0,
|
|
||||||
PF_15 = 0x5F,
|
|
||||||
|
|
||||||
PG_0 = 0x60,
|
|
||||||
PG_1 = 0x61,
|
|
||||||
PG_2 = 0x62,
|
|
||||||
PG_3 = 0x63,
|
|
||||||
PG_4 = 0x64,
|
|
||||||
PG_5 = 0x65,
|
|
||||||
PG_6 = 0x66,
|
|
||||||
PG_7 = 0x67,
|
|
||||||
PG_8 = 0x68,
|
|
||||||
PG_9 = 0x69,
|
|
||||||
PG_10 = 0x6A,
|
|
||||||
PG_11 = 0x6B,
|
|
||||||
PG_12 = 0x6C,
|
|
||||||
PG_13 = 0x6D,
|
|
||||||
PG_14 = 0x6E,
|
|
||||||
PG_15 = 0x6F,
|
|
||||||
|
|
||||||
PH_0 = 0x70,
|
|
||||||
PH_1 = 0x71,
|
|
||||||
|
|
||||||
// ADC internal channels
|
|
||||||
ADC_TEMP = 0xF0,
|
|
||||||
ADC_VREF = 0xF1,
|
|
||||||
ADC_VBAT = 0xF2,
|
|
||||||
|
|
||||||
#ifdef TARGET_FF_ARDUINO_UNO
|
#ifdef TARGET_FF_ARDUINO_UNO
|
||||||
// Arduino Uno(Rev3) Header pin connection naming
|
// Arduino Uno (Rev3) pins
|
||||||
ARDUINO_UNO_A0 = PA_3,
|
ARDUINO_UNO_A0 = PA_3,
|
||||||
ARDUINO_UNO_A1 = PC_0,
|
ARDUINO_UNO_A1 = PC_0,
|
||||||
ARDUINO_UNO_A2 = PC_3,
|
ARDUINO_UNO_A2 = PC_3,
|
||||||
ARDUINO_UNO_A3 = PB_1,
|
ARDUINO_UNO_A3 = PB_1,
|
||||||
ARDUINO_UNO_A4 = PC_2,
|
ARDUINO_UNO_A4 = PC_2,
|
||||||
ARDUINO_UNO_A5 = PF_10,
|
ARDUINO_UNO_A5 = PF_10,
|
||||||
|
|
||||||
ARDUINO_UNO_D0 = PB_7,
|
ARDUINO_UNO_D0 = PB_7,
|
||||||
ARDUINO_UNO_D1 = PB_6,
|
ARDUINO_UNO_D1 = PB_6,
|
||||||
ARDUINO_UNO_D2 = PG_14,
|
ARDUINO_UNO_D2 = PG_14,
|
||||||
|
|
@ -266,66 +254,66 @@ typedef enum {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// ST ZIO connector extending Arduino Uno
|
// ST ZIO connector extending Arduino Uno
|
||||||
A6 = PF_4,
|
A6 = PF_4,
|
||||||
A7 = PF_5,
|
A7 = PF_5,
|
||||||
A8 = PF_6,
|
A8 = PF_6,
|
||||||
D16 = PC_6,
|
D16 = PC_6,
|
||||||
D17 = PB_15,
|
D17 = PB_15,
|
||||||
D18 = PB_13,
|
D18 = PB_13,
|
||||||
D19 = PB_12,
|
D19 = PB_12,
|
||||||
D20 = PA_15,
|
D20 = PA_15,
|
||||||
D21 = PC_7,
|
D21 = PC_7,
|
||||||
D22 = PB_5,
|
D22 = PB_5,
|
||||||
D23 = PB_3,
|
D23 = PB_3,
|
||||||
D24 = PA_4,
|
D24 = PA_4,
|
||||||
D25 = PB_4,
|
D25 = PB_4,
|
||||||
D26 = PG_6,
|
D26 = PG_6,
|
||||||
D27 = PB_2,
|
D27 = PB_2,
|
||||||
D28 = PD_13,
|
D28 = PD_13,
|
||||||
D29 = PD_12,
|
D29 = PD_12,
|
||||||
D30 = PD_11,
|
D30 = PD_11,
|
||||||
D31 = PE_2,
|
D31 = PE_2,
|
||||||
D32 = PA_0,
|
D32 = PA_0,
|
||||||
D33 = PB_0,
|
D33 = PB_0,
|
||||||
D34 = PE_0,
|
D34 = PE_0,
|
||||||
D35 = PB_11,
|
D35 = PB_11,
|
||||||
D36 = PB_10,
|
D36 = PB_10,
|
||||||
D37 = PE_15,
|
D37 = PE_15,
|
||||||
D38 = PE_6,
|
D38 = PE_6,
|
||||||
D39 = PE_12,
|
D39 = PE_12,
|
||||||
D40 = PE_10,
|
D40 = PE_10,
|
||||||
D41 = PE_7,
|
D41 = PE_7,
|
||||||
D42 = PE_8,
|
D42 = PE_8,
|
||||||
D43 = PC_8,
|
D43 = PC_8,
|
||||||
D44 = PC_9,
|
D44 = PC_9,
|
||||||
D45 = PC_10,
|
D45 = PC_10,
|
||||||
D46 = PC_11,
|
D46 = PC_11,
|
||||||
D47 = PC_12,
|
D47 = PC_12,
|
||||||
D48 = PD_2,
|
D48 = PD_2,
|
||||||
D49 = PG_2,
|
D49 = PG_2,
|
||||||
D50 = PG_3,
|
D50 = PG_3,
|
||||||
D51 = PD_7,
|
D51 = PD_7,
|
||||||
D52 = PD_6,
|
D52 = PD_6,
|
||||||
D53 = PD_5,
|
D53 = PD_5,
|
||||||
D54 = PD_4,
|
D54 = PD_4,
|
||||||
D55 = PD_3,
|
D55 = PD_3,
|
||||||
D56 = PE_2,
|
D56 = PE_2,
|
||||||
D57 = PE_4,
|
D57 = PE_4,
|
||||||
D58 = PE_5,
|
D58 = PE_5,
|
||||||
D59 = PE_6,
|
D59 = PE_6,
|
||||||
D60 = PE_3,
|
D60 = PE_3,
|
||||||
D61 = PF_8,
|
D61 = PF_8,
|
||||||
D62 = PF_7,
|
D62 = PF_7,
|
||||||
D63 = PF_9,
|
D63 = PF_9,
|
||||||
D64 = PG_1,
|
D64 = PG_1,
|
||||||
D65 = PG_0,
|
D65 = PG_0,
|
||||||
D66 = PD_1,
|
D66 = PD_1,
|
||||||
D67 = PD_0,
|
D67 = PD_0,
|
||||||
D68 = PF_0,
|
D68 = PF_0,
|
||||||
D69 = PF_1,
|
D69 = PF_1,
|
||||||
D70 = PF_2,
|
D70 = PF_2,
|
||||||
D71 = PE_2,
|
D71 = PE_2,
|
||||||
D72 = PB_2,
|
D72 = PB_2,
|
||||||
|
|
||||||
// STDIO for console print
|
// STDIO for console print
|
||||||
#ifdef MBED_CONF_TARGET_STDIO_UART_TX
|
#ifdef MBED_CONF_TARGET_STDIO_UART_TX
|
||||||
|
|
@ -360,8 +348,8 @@ typedef enum {
|
||||||
USB_OTG_HS_ULPI_D5 = PB_12,
|
USB_OTG_HS_ULPI_D5 = PB_12,
|
||||||
USB_OTG_HS_ULPI_D6 = PB_13,
|
USB_OTG_HS_ULPI_D6 = PB_13,
|
||||||
USB_OTG_HS_ULPI_D7 = PB_5,
|
USB_OTG_HS_ULPI_D7 = PB_5,
|
||||||
USB_OTG_HS_ULPI_DIR = PC_2,
|
USB_OTG_HS_ULPI_DIR = PC_2C,
|
||||||
USB_OTG_HS_ULPI_NXT = PC_3,
|
USB_OTG_HS_ULPI_NXT = PC_3C,
|
||||||
USB_OTG_HS_ULPI_STP = PC_0,
|
USB_OTG_HS_ULPI_STP = PC_0,
|
||||||
USB_OTG_HS_VBUS = PB_13,
|
USB_OTG_HS_VBUS = PB_13,
|
||||||
|
|
||||||
|
|
@ -386,10 +374,10 @@ typedef enum {
|
||||||
ETH_TXD1 = PB_13,
|
ETH_TXD1 = PB_13,
|
||||||
ETH_TXD1_ALT0 = PG_12,
|
ETH_TXD1_ALT0 = PG_12,
|
||||||
ETH_TXD1_ALT1 = PG_14,
|
ETH_TXD1_ALT1 = PG_14,
|
||||||
ETH_TXD2 = PC_2,
|
ETH_TXD2 = PC_2C,
|
||||||
ETH_TXD3 = PE_2,
|
ETH_TXD3 = PE_2,
|
||||||
ETH_TXD3_ALT0 = PB_8,
|
ETH_TXD3_ALT0 = PB_8,
|
||||||
ETH_TX_CLK = PC_3,
|
ETH_TX_CLK = PC_3C,
|
||||||
ETH_TX_EN = PB_11,
|
ETH_TX_EN = PB_11,
|
||||||
ETH_TX_EN_ALT0 = PG_11,
|
ETH_TX_EN_ALT0 = PG_11,
|
||||||
|
|
||||||
|
|
@ -430,9 +418,8 @@ typedef enum {
|
||||||
// Standardized LED and button names
|
// Standardized LED and button names
|
||||||
#define LED1 PB_0 // LD1
|
#define LED1 PB_0 // LD1
|
||||||
#define LED2 PE_1 // Yellow
|
#define LED2 PE_1 // Yellow
|
||||||
#define LED3 PB_14 // Red
|
#define LED3 PB_14 // LD3 [Red]
|
||||||
#define BUTTON1 PC_13
|
#define BUTTON1 PC_13 // USER_Btn [B1]
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
* SPDX-License-Identifier: BSD-3-Clause
|
* SPDX-License-Identifier: BSD-3-Clause
|
||||||
******************************************************************************
|
******************************************************************************
|
||||||
*
|
*
|
||||||
* Copyright (c) 2016-2020 STMicroelectronics.
|
* Copyright (c) 2016-2021 STMicroelectronics.
|
||||||
* All rights reserved.
|
* All rights reserved.
|
||||||
*
|
*
|
||||||
* This software component is licensed by ST under BSD 3-Clause license,
|
* This software component is licensed by ST under BSD 3-Clause license,
|
||||||
|
|
@ -38,7 +38,6 @@ typedef enum {
|
||||||
} ALTx;
|
} ALTx;
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
|
|
||||||
PA_0 = 0x00,
|
PA_0 = 0x00,
|
||||||
PA_0C = PA_0 | ALTC, // dual pad
|
PA_0C = PA_0 | ALTC, // dual pad
|
||||||
PA_0C_ALT0 = PA_0C | ALT0, // same pin used for alternate HW
|
PA_0C_ALT0 = PA_0C | ALT0, // same pin used for alternate HW
|
||||||
|
|
@ -47,27 +46,27 @@ typedef enum {
|
||||||
PA_1 = 0x01,
|
PA_1 = 0x01,
|
||||||
PA_1C = PA_1 | ALTC, // dual pad
|
PA_1C = PA_1 | ALTC, // dual pad
|
||||||
PA_1C_ALT0 = PA_1C | ALT0, // same pin used for alternate HW
|
PA_1C_ALT0 = PA_1C | ALT0, // same pin used for alternate HW
|
||||||
PA_1_ALT0 = PA_1 | ALT0, // same pin used for alternate HW
|
PA_1_ALT0 = PA_1 | ALT0, // same pin used for alternate HW
|
||||||
PA_2 = 0x02,
|
PA_2 = 0x02,
|
||||||
PA_2_ALT0 = PA_2 | ALT0, // same pin used for alternate HW
|
PA_2_ALT0 = PA_2 | ALT0, // same pin used for alternate HW
|
||||||
PA_3 = 0x03,
|
PA_3 = 0x03,
|
||||||
PA_3_ALT0 = PA_3 | ALT0, // same pin used for alternate HW
|
PA_3_ALT0 = PA_3 | ALT0, // same pin used for alternate HW
|
||||||
PA_4 = 0x04,
|
PA_4 = 0x04,
|
||||||
PA_4_ALT0 = PA_4 | ALT0, // same pin used for alternate HW
|
PA_4_ALT0 = PA_4 | ALT0, // same pin used for alternate HW
|
||||||
PA_4_ALT1 = PA_4 | ALT1, // same pin used for alternate HW
|
PA_4_ALT1 = PA_4 | ALT1, // same pin used for alternate HW
|
||||||
PA_5 = 0x05,
|
PA_5 = 0x05,
|
||||||
PA_5_ALT0 = PA_5 | ALT0, // same pin used for alternate HW
|
PA_5_ALT0 = PA_5 | ALT0, // same pin used for alternate HW
|
||||||
PA_5_ALT1 = PA_5 | ALT1, // same pin used for alternate HW
|
PA_5_ALT1 = PA_5 | ALT1, // same pin used for alternate HW
|
||||||
PA_5_ALT2 = PA_5 | ALT2, // same pin used for alternate HW
|
PA_5_ALT2 = PA_5 | ALT2, // same pin used for alternate HW
|
||||||
PA_6 = 0x06,
|
PA_6 = 0x06,
|
||||||
PA_6_ALT0 = PA_6 | ALT0, // same pin used for alternate HW
|
PA_6_ALT0 = PA_6 | ALT0, // same pin used for alternate HW
|
||||||
PA_7 = 0x07,
|
PA_7 = 0x07,
|
||||||
PA_7_ALT0 = PA_7 | ALT0, // same pin used for alternate HW
|
PA_7_ALT0 = PA_7 | ALT0, // same pin used for alternate HW
|
||||||
PA_7_ALT1 = PA_7 | ALT1, // same pin used for alternate HW
|
PA_7_ALT1 = PA_7 | ALT1, // same pin used for alternate HW
|
||||||
PA_7_ALT2 = PA_7 | ALT2, // same pin used for alternate HW
|
PA_7_ALT2 = PA_7 | ALT2, // same pin used for alternate HW
|
||||||
PA_8 = 0x08,
|
PA_8 = 0x08,
|
||||||
PA_9 = 0x09,
|
PA_9 = 0x09,
|
||||||
PA_9_ALT0 = PA_9 | ALT0, // same pin used for alternate HW
|
PA_9_ALT0 = PA_9 | ALT0, // same pin used for alternate HW
|
||||||
PA_10 = 0x0A,
|
PA_10 = 0x0A,
|
||||||
PA_10_ALT0 = PA_10 | ALT0, // same pin used for alternate HW
|
PA_10_ALT0 = PA_10 | ALT0, // same pin used for alternate HW
|
||||||
PA_11 = 0x0B,
|
PA_11 = 0x0B,
|
||||||
|
|
@ -80,31 +79,31 @@ typedef enum {
|
||||||
PA_15_ALT0 = PA_15 | ALT0, // same pin used for alternate HW
|
PA_15_ALT0 = PA_15 | ALT0, // same pin used for alternate HW
|
||||||
PA_15_ALT1 = PA_15 | ALT1, // same pin used for alternate HW
|
PA_15_ALT1 = PA_15 | ALT1, // same pin used for alternate HW
|
||||||
PB_0 = 0x10,
|
PB_0 = 0x10,
|
||||||
PB_0_ALT0 = PB_0 | ALT0, // same pin used for alternate HW
|
PB_0_ALT0 = PB_0 | ALT0, // same pin used for alternate HW
|
||||||
PB_0_ALT1 = PB_0 | ALT1, // same pin used for alternate HW
|
PB_0_ALT1 = PB_0 | ALT1, // same pin used for alternate HW
|
||||||
PB_0_ALT2 = PB_0 | ALT2, // same pin used for alternate HW
|
PB_0_ALT2 = PB_0 | ALT2, // same pin used for alternate HW
|
||||||
PB_1 = 0x11,
|
PB_1 = 0x11,
|
||||||
PB_1_ALT0 = PB_1 | ALT0, // same pin used for alternate HW
|
PB_1_ALT0 = PB_1 | ALT0, // same pin used for alternate HW
|
||||||
PB_1_ALT1 = PB_1 | ALT1, // same pin used for alternate HW
|
PB_1_ALT1 = PB_1 | ALT1, // same pin used for alternate HW
|
||||||
PB_2 = 0x12,
|
PB_2 = 0x12,
|
||||||
PB_3 = 0x13,
|
PB_3 = 0x13,
|
||||||
PB_3_ALT0 = PB_3 | ALT0, // same pin used for alternate HW
|
PB_3_ALT0 = PB_3 | ALT0, // same pin used for alternate HW
|
||||||
PB_3_ALT1 = PB_3 | ALT1, // same pin used for alternate HW
|
PB_3_ALT1 = PB_3 | ALT1, // same pin used for alternate HW
|
||||||
PB_4 = 0x14,
|
PB_4 = 0x14,
|
||||||
PB_4_ALT0 = PB_4 | ALT0, // same pin used for alternate HW
|
PB_4_ALT0 = PB_4 | ALT0, // same pin used for alternate HW
|
||||||
PB_4_ALT1 = PB_4 | ALT1, // same pin used for alternate HW
|
PB_4_ALT1 = PB_4 | ALT1, // same pin used for alternate HW
|
||||||
PB_5 = 0x15,
|
PB_5 = 0x15,
|
||||||
PB_5_ALT0 = PB_5 | ALT0, // same pin used for alternate HW
|
PB_5_ALT0 = PB_5 | ALT0, // same pin used for alternate HW
|
||||||
PB_5_ALT1 = PB_5 | ALT1, // same pin used for alternate HW
|
PB_5_ALT1 = PB_5 | ALT1, // same pin used for alternate HW
|
||||||
PB_6 = 0x16,
|
PB_6 = 0x16,
|
||||||
PB_6_ALT0 = PB_6 | ALT0, // same pin used for alternate HW
|
PB_6_ALT0 = PB_6 | ALT0, // same pin used for alternate HW
|
||||||
PB_6_ALT1 = PB_6 | ALT1, // same pin used for alternate HW
|
PB_6_ALT1 = PB_6 | ALT1, // same pin used for alternate HW
|
||||||
PB_7 = 0x17,
|
PB_7 = 0x17,
|
||||||
PB_7_ALT0 = PB_7 | ALT0, // same pin used for alternate HW
|
PB_7_ALT0 = PB_7 | ALT0, // same pin used for alternate HW
|
||||||
PB_8 = 0x18,
|
PB_8 = 0x18,
|
||||||
PB_8_ALT0 = PB_8 | ALT0, // same pin used for alternate HW
|
PB_8_ALT0 = PB_8 | ALT0, // same pin used for alternate HW
|
||||||
PB_9 = 0x19,
|
PB_9 = 0x19,
|
||||||
PB_9_ALT0 = PB_9 | ALT0, // same pin used for alternate HW
|
PB_9_ALT0 = PB_9 | ALT0, // same pin used for alternate HW
|
||||||
PB_10 = 0x1A,
|
PB_10 = 0x1A,
|
||||||
PB_11 = 0x1B,
|
PB_11 = 0x1B,
|
||||||
PB_12 = 0x1C,
|
PB_12 = 0x1C,
|
||||||
|
|
@ -116,41 +115,41 @@ typedef enum {
|
||||||
PB_15_ALT0 = PB_15 | ALT0, // same pin used for alternate HW
|
PB_15_ALT0 = PB_15 | ALT0, // same pin used for alternate HW
|
||||||
PB_15_ALT1 = PB_15 | ALT1, // same pin used for alternate HW
|
PB_15_ALT1 = PB_15 | ALT1, // same pin used for alternate HW
|
||||||
PC_0 = 0x20,
|
PC_0 = 0x20,
|
||||||
PC_0_ALT0 = PC_0 | ALT0, // same pin used for alternate HW
|
PC_0_ALT0 = PC_0 | ALT0, // same pin used for alternate HW
|
||||||
PC_0_ALT1 = PC_0 | ALT1, // same pin used for alternate HW
|
PC_0_ALT1 = PC_0 | ALT1, // same pin used for alternate HW
|
||||||
PC_1 = 0x21,
|
PC_1 = 0x21,
|
||||||
PC_1_ALT0 = PC_1 | ALT0, // same pin used for alternate HW
|
PC_1_ALT0 = PC_1 | ALT0, // same pin used for alternate HW
|
||||||
PC_1_ALT1 = PC_1 | ALT1, // same pin used for alternate HW
|
PC_1_ALT1 = PC_1 | ALT1, // same pin used for alternate HW
|
||||||
PC_1_ALT2 = PC_1 | ALT2, // same pin used for alternate HW
|
PC_1_ALT2 = PC_1 | ALT2, // same pin used for alternate HW
|
||||||
PC_1_ALT3 = PC_1 | ALT3, // same pin used for alternate HW
|
PC_1_ALT3 = PC_1 | ALT3, // same pin used for alternate HW
|
||||||
PC_1_ALT4 = PC_1 | ALT4, // same pin used for alternate HW
|
PC_1_ALT4 = PC_1 | ALT4, // same pin used for alternate HW
|
||||||
PC_2 = 0x22,
|
PC_2 = 0x22,
|
||||||
PC_2C = PC_2 | ALTC, // dual pad
|
PC_2C = PC_2 | ALTC, // dual pad
|
||||||
PC_2C_ALT0 = PC_2C | ALT0, // same pin used for alternate HW
|
PC_2C_ALT0 = PC_2C | ALT0, // same pin used for alternate HW
|
||||||
PC_2_ALT0 = PC_2 | ALT0, // same pin used for alternate HW
|
PC_2_ALT0 = PC_2 | ALT0, // same pin used for alternate HW
|
||||||
PC_2_ALT1 = PC_2 | ALT1, // same pin used for alternate HW
|
PC_2_ALT1 = PC_2 | ALT1, // same pin used for alternate HW
|
||||||
PC_2_ALT2 = PC_2 | ALT2, // same pin used for alternate HW
|
PC_2_ALT2 = PC_2 | ALT2, // same pin used for alternate HW
|
||||||
PC_2_ALT3 = PC_2 | ALT3, // same pin used for alternate HW
|
PC_2_ALT3 = PC_2 | ALT3, // same pin used for alternate HW
|
||||||
PC_2_ALT4 = PC_2 | ALT4, // same pin used for alternate HW
|
PC_2_ALT4 = PC_2 | ALT4, // same pin used for alternate HW
|
||||||
PC_3 = 0x23,
|
PC_3 = 0x23,
|
||||||
PC_3C = PC_3 | ALTC, // dual pad
|
PC_3C = PC_3 | ALTC, // dual pad
|
||||||
PC_3_ALT0 = PC_3 | ALT0, // same pin used for alternate HW
|
PC_3_ALT0 = PC_3 | ALT0, // same pin used for alternate HW
|
||||||
PC_3_ALT1 = PC_3 | ALT1, // same pin used for alternate HW
|
PC_3_ALT1 = PC_3 | ALT1, // same pin used for alternate HW
|
||||||
PC_3_ALT2 = PC_3 | ALT2, // same pin used for alternate HW
|
PC_3_ALT2 = PC_3 | ALT2, // same pin used for alternate HW
|
||||||
PC_4 = 0x24,
|
PC_4 = 0x24,
|
||||||
PC_4_ALT0 = PC_4 | ALT0, // same pin used for alternate HW
|
PC_4_ALT0 = PC_4 | ALT0, // same pin used for alternate HW
|
||||||
PC_5 = 0x25,
|
PC_5 = 0x25,
|
||||||
PC_5_ALT0 = PC_5 | ALT0, // same pin used for alternate HW
|
PC_5_ALT0 = PC_5 | ALT0, // same pin used for alternate HW
|
||||||
PC_5_ALT1 = PC_5 | ALT1, // same pin used for alternate HW
|
PC_5_ALT1 = PC_5 | ALT1, // same pin used for alternate HW
|
||||||
PC_5_ALT2 = PC_5 | ALT2, // same pin used for alternate HW
|
PC_5_ALT2 = PC_5 | ALT2, // same pin used for alternate HW
|
||||||
PC_6 = 0x26,
|
PC_6 = 0x26,
|
||||||
PC_6_ALT0 = PC_6 | ALT0, // same pin used for alternate HW
|
PC_6_ALT0 = PC_6 | ALT0, // same pin used for alternate HW
|
||||||
PC_7 = 0x27,
|
PC_7 = 0x27,
|
||||||
PC_7_ALT0 = PC_7 | ALT0, // same pin used for alternate HW
|
PC_7_ALT0 = PC_7 | ALT0, // same pin used for alternate HW
|
||||||
PC_8 = 0x28,
|
PC_8 = 0x28,
|
||||||
PC_8_ALT0 = PC_8 | ALT0, // same pin used for alternate HW
|
PC_8_ALT0 = PC_8 | ALT0, // same pin used for alternate HW
|
||||||
PC_9 = 0x29,
|
PC_9 = 0x29,
|
||||||
PC_9_ALT0 = PC_9 | ALT0, // same pin used for alternate HW
|
PC_9_ALT0 = PC_9 | ALT0, // same pin used for alternate HW
|
||||||
PC_10 = 0x2A,
|
PC_10 = 0x2A,
|
||||||
PC_10_ALT0 = PC_10 | ALT0, // same pin used for alternate HW
|
PC_10_ALT0 = PC_10 | ALT0, // same pin used for alternate HW
|
||||||
PC_11 = 0x2B,
|
PC_11 = 0x2B,
|
||||||
|
|
@ -196,15 +195,15 @@ typedef enum {
|
||||||
PF_2 = 0x52,
|
PF_2 = 0x52,
|
||||||
PF_3 = 0x53,
|
PF_3 = 0x53,
|
||||||
PF_4 = 0x54,
|
PF_4 = 0x54,
|
||||||
PF_4_ALT0 = PF_4 | ALT0, // same pin used for alternate HW
|
PF_4_ALT0 = PF_4 | ALT0, // same pin used for alternate HW
|
||||||
PF_5 = 0x55,
|
PF_5 = 0x55,
|
||||||
PF_6 = 0x56,
|
PF_6 = 0x56,
|
||||||
PF_6_ALT0 = PF_6 | ALT0, // same pin used for alternate HW
|
PF_6_ALT0 = PF_6 | ALT0, // same pin used for alternate HW
|
||||||
PF_7 = 0x57,
|
PF_7 = 0x57,
|
||||||
PF_8 = 0x58,
|
PF_8 = 0x58,
|
||||||
PF_8_ALT0 = PF_8 | ALT0, // same pin used for alternate HW
|
PF_8_ALT0 = PF_8 | ALT0, // same pin used for alternate HW
|
||||||
PF_9 = 0x59,
|
PF_9 = 0x59,
|
||||||
PF_9_ALT0 = PF_9 | ALT0, // same pin used for alternate HW
|
PF_9_ALT0 = PF_9 | ALT0, // same pin used for alternate HW
|
||||||
PF_10 = 0x5A,
|
PF_10 = 0x5A,
|
||||||
PF_10_ALT0 = PF_10 | ALT0, // same pin used for alternate HW
|
PF_10_ALT0 = PF_10 | ALT0, // same pin used for alternate HW
|
||||||
PF_11 = 0x5B,
|
PF_11 = 0x5B,
|
||||||
|
|
@ -234,11 +233,11 @@ typedef enum {
|
||||||
PH_1 = 0x71,
|
PH_1 = 0x71,
|
||||||
PH_2 = 0x72,
|
PH_2 = 0x72,
|
||||||
PH_3 = 0x73,
|
PH_3 = 0x73,
|
||||||
PH_3_ALT0 = PH_3 | ALT0, // same pin used for alternate HW
|
PH_3_ALT0 = PH_3 | ALT0, // same pin used for alternate HW
|
||||||
PH_4 = 0x74,
|
PH_4 = 0x74,
|
||||||
PH_4_ALT0 = PH_4 | ALT0, // same pin used for alternate HW
|
PH_4_ALT0 = PH_4 | ALT0, // same pin used for alternate HW
|
||||||
PH_5 = 0x75,
|
PH_5 = 0x75,
|
||||||
PH_5_ALT0 = PH_5 | ALT0, // same pin used for alternate HW
|
PH_5_ALT0 = PH_5 | ALT0, // same pin used for alternate HW
|
||||||
PH_6 = 0x76,
|
PH_6 = 0x76,
|
||||||
PH_7 = 0x77,
|
PH_7 = 0x77,
|
||||||
PH_8 = 0x78,
|
PH_8 = 0x78,
|
||||||
|
|
@ -274,9 +273,9 @@ typedef enum {
|
||||||
PJ_6 = 0x96,
|
PJ_6 = 0x96,
|
||||||
PJ_7 = 0x97,
|
PJ_7 = 0x97,
|
||||||
PJ_8 = 0x98,
|
PJ_8 = 0x98,
|
||||||
PJ_8_ALT0 = PJ_8 | ALT0, // same pin used for alternate HW
|
PJ_8_ALT0 = PJ_8 | ALT0, // same pin used for alternate HW
|
||||||
PJ_9 = 0x99,
|
PJ_9 = 0x99,
|
||||||
PJ_9_ALT0 = PJ_9 | ALT0, // same pin used for alternate HW
|
PJ_9_ALT0 = PJ_9 | ALT0, // same pin used for alternate HW
|
||||||
PJ_10 = 0x9A,
|
PJ_10 = 0x9A,
|
||||||
PJ_10_ALT0 = PJ_10 | ALT0, // same pin used for alternate HW
|
PJ_10_ALT0 = PJ_10 | ALT0, // same pin used for alternate HW
|
||||||
PJ_11 = 0x9B,
|
PJ_11 = 0x9B,
|
||||||
|
|
@ -286,9 +285,9 @@ typedef enum {
|
||||||
PJ_14 = 0x9E,
|
PJ_14 = 0x9E,
|
||||||
PJ_15 = 0x9F,
|
PJ_15 = 0x9F,
|
||||||
PK_0 = 0xA0,
|
PK_0 = 0xA0,
|
||||||
PK_0_ALT0 = PK_0 | ALT0, // same pin used for alternate HW
|
PK_0_ALT0 = PK_0 | ALT0, // same pin used for alternate HW
|
||||||
PK_1 = 0xA1,
|
PK_1 = 0xA1,
|
||||||
PK_1_ALT0 = PK_1 | ALT0, // same pin used for alternate HW
|
PK_1_ALT0 = PK_1 | ALT0, // same pin used for alternate HW
|
||||||
PK_2 = 0xA2,
|
PK_2 = 0xA2,
|
||||||
PK_3 = 0xA3,
|
PK_3 = 0xA3,
|
||||||
PK_4 = 0xA4,
|
PK_4 = 0xA4,
|
||||||
|
|
@ -303,12 +302,14 @@ typedef enum {
|
||||||
ADC_VBAT = 0xF2, // Internal pin virtual value
|
ADC_VBAT = 0xF2, // Internal pin virtual value
|
||||||
|
|
||||||
#ifdef TARGET_FF_ARDUINO_UNO
|
#ifdef TARGET_FF_ARDUINO_UNO
|
||||||
|
// Arduino Uno (Rev3) pins
|
||||||
ARDUINO_UNO_A0 = PA_4,
|
ARDUINO_UNO_A0 = PA_4,
|
||||||
ARDUINO_UNO_A1 = PF_10,
|
ARDUINO_UNO_A1 = PF_10,
|
||||||
ARDUINO_UNO_A2 = PA_0C,
|
ARDUINO_UNO_A2 = PA_0C,
|
||||||
ARDUINO_UNO_A3 = PA_1C,
|
ARDUINO_UNO_A3 = PA_1C,
|
||||||
ARDUINO_UNO_A4 = PC_2C,
|
ARDUINO_UNO_A4 = PC_2C,
|
||||||
ARDUINO_UNO_A5 = PC_3C,
|
ARDUINO_UNO_A5 = PC_3C,
|
||||||
|
|
||||||
ARDUINO_UNO_D0 = PJ_9,
|
ARDUINO_UNO_D0 = PJ_9,
|
||||||
ARDUINO_UNO_D1 = PJ_8,
|
ARDUINO_UNO_D1 = PJ_8,
|
||||||
ARDUINO_UNO_D2 = PJ_3,
|
ARDUINO_UNO_D2 = PJ_3,
|
||||||
|
|
@ -494,8 +495,7 @@ typedef enum {
|
||||||
#define LED2 PI_13 // LED2
|
#define LED2 PI_13 // LED2
|
||||||
#define LED3 PI_14 // LED3
|
#define LED3 PI_14 // LED3
|
||||||
#define LED4 PI_15 // LED4
|
#define LED4 PI_15 // LED4
|
||||||
#define BUTTON1 PC_13 // B2
|
#define BUTTON1 PC_13 // B2 [Wakeup Button]
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -54,7 +54,6 @@ typedef enum {
|
||||||
} ALTx;
|
} ALTx;
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
|
|
||||||
PA_0 = 0x00,
|
PA_0 = 0x00,
|
||||||
PA_0C = PA_0 | ALTC, // dual pad
|
PA_0C = PA_0 | ALTC, // dual pad
|
||||||
PA_0C_ALT0 = PA_0C | ALT0, // same pin used for alternate HW
|
PA_0C_ALT0 = PA_0C | ALT0, // same pin used for alternate HW
|
||||||
|
|
@ -63,27 +62,27 @@ typedef enum {
|
||||||
PA_1 = 0x01,
|
PA_1 = 0x01,
|
||||||
PA_1C = PA_1 | ALTC, // dual pad
|
PA_1C = PA_1 | ALTC, // dual pad
|
||||||
PA_1C_ALT0 = PA_1C | ALT0, // same pin used for alternate HW
|
PA_1C_ALT0 = PA_1C | ALT0, // same pin used for alternate HW
|
||||||
PA_1_ALT0 = PA_1 | ALT0, // same pin used for alternate HW
|
PA_1_ALT0 = PA_1 | ALT0, // same pin used for alternate HW
|
||||||
PA_2 = 0x02,
|
PA_2 = 0x02,
|
||||||
PA_2_ALT0 = PA_2 | ALT0, // same pin used for alternate HW
|
PA_2_ALT0 = PA_2 | ALT0, // same pin used for alternate HW
|
||||||
PA_3 = 0x03,
|
PA_3 = 0x03,
|
||||||
PA_3_ALT0 = PA_3 | ALT0, // same pin used for alternate HW
|
PA_3_ALT0 = PA_3 | ALT0, // same pin used for alternate HW
|
||||||
PA_4 = 0x04,
|
PA_4 = 0x04,
|
||||||
PA_4_ALT0 = PA_4 | ALT0, // same pin used for alternate HW
|
PA_4_ALT0 = PA_4 | ALT0, // same pin used for alternate HW
|
||||||
PA_4_ALT1 = PA_4 | ALT1, // same pin used for alternate HW
|
PA_4_ALT1 = PA_4 | ALT1, // same pin used for alternate HW
|
||||||
PA_5 = 0x05,
|
PA_5 = 0x05,
|
||||||
PA_5_ALT0 = PA_5 | ALT0, // same pin used for alternate HW
|
PA_5_ALT0 = PA_5 | ALT0, // same pin used for alternate HW
|
||||||
PA_5_ALT1 = PA_5 | ALT1, // same pin used for alternate HW
|
PA_5_ALT1 = PA_5 | ALT1, // same pin used for alternate HW
|
||||||
PA_5_ALT2 = PA_5 | ALT2, // same pin used for alternate HW
|
PA_5_ALT2 = PA_5 | ALT2, // same pin used for alternate HW
|
||||||
PA_6 = 0x06,
|
PA_6 = 0x06,
|
||||||
PA_6_ALT0 = PA_6 | ALT0, // same pin used for alternate HW
|
PA_6_ALT0 = PA_6 | ALT0, // same pin used for alternate HW
|
||||||
PA_7 = 0x07,
|
PA_7 = 0x07,
|
||||||
PA_7_ALT0 = PA_7 | ALT0, // same pin used for alternate HW
|
PA_7_ALT0 = PA_7 | ALT0, // same pin used for alternate HW
|
||||||
PA_7_ALT1 = PA_7 | ALT1, // same pin used for alternate HW
|
PA_7_ALT1 = PA_7 | ALT1, // same pin used for alternate HW
|
||||||
PA_7_ALT2 = PA_7 | ALT2, // same pin used for alternate HW
|
PA_7_ALT2 = PA_7 | ALT2, // same pin used for alternate HW
|
||||||
PA_8 = 0x08,
|
PA_8 = 0x08,
|
||||||
PA_9 = 0x09,
|
PA_9 = 0x09,
|
||||||
PA_9_ALT0 = PA_9 | ALT0, // same pin used for alternate HW
|
PA_9_ALT0 = PA_9 | ALT0, // same pin used for alternate HW
|
||||||
PA_10 = 0x0A,
|
PA_10 = 0x0A,
|
||||||
PA_10_ALT0 = PA_10 | ALT0, // same pin used for alternate HW
|
PA_10_ALT0 = PA_10 | ALT0, // same pin used for alternate HW
|
||||||
PA_11 = 0x0B,
|
PA_11 = 0x0B,
|
||||||
|
|
@ -96,31 +95,31 @@ typedef enum {
|
||||||
PA_15_ALT0 = PA_15 | ALT0, // same pin used for alternate HW
|
PA_15_ALT0 = PA_15 | ALT0, // same pin used for alternate HW
|
||||||
PA_15_ALT1 = PA_15 | ALT1, // same pin used for alternate HW
|
PA_15_ALT1 = PA_15 | ALT1, // same pin used for alternate HW
|
||||||
PB_0 = 0x10,
|
PB_0 = 0x10,
|
||||||
PB_0_ALT0 = PB_0 | ALT0, // same pin used for alternate HW
|
PB_0_ALT0 = PB_0 | ALT0, // same pin used for alternate HW
|
||||||
PB_0_ALT1 = PB_0 | ALT1, // same pin used for alternate HW
|
PB_0_ALT1 = PB_0 | ALT1, // same pin used for alternate HW
|
||||||
PB_0_ALT2 = PB_0 | ALT2, // same pin used for alternate HW
|
PB_0_ALT2 = PB_0 | ALT2, // same pin used for alternate HW
|
||||||
PB_1 = 0x11,
|
PB_1 = 0x11,
|
||||||
PB_1_ALT0 = PB_1 | ALT0, // same pin used for alternate HW
|
PB_1_ALT0 = PB_1 | ALT0, // same pin used for alternate HW
|
||||||
PB_1_ALT1 = PB_1 | ALT1, // same pin used for alternate HW
|
PB_1_ALT1 = PB_1 | ALT1, // same pin used for alternate HW
|
||||||
PB_2 = 0x12,
|
PB_2 = 0x12,
|
||||||
PB_3 = 0x13,
|
PB_3 = 0x13,
|
||||||
PB_3_ALT0 = PB_3 | ALT0, // same pin used for alternate HW
|
PB_3_ALT0 = PB_3 | ALT0, // same pin used for alternate HW
|
||||||
PB_3_ALT1 = PB_3 | ALT1, // same pin used for alternate HW
|
PB_3_ALT1 = PB_3 | ALT1, // same pin used for alternate HW
|
||||||
PB_4 = 0x14,
|
PB_4 = 0x14,
|
||||||
PB_4_ALT0 = PB_4 | ALT0, // same pin used for alternate HW
|
PB_4_ALT0 = PB_4 | ALT0, // same pin used for alternate HW
|
||||||
PB_4_ALT1 = PB_4 | ALT1, // same pin used for alternate HW
|
PB_4_ALT1 = PB_4 | ALT1, // same pin used for alternate HW
|
||||||
PB_5 = 0x15,
|
PB_5 = 0x15,
|
||||||
PB_5_ALT0 = PB_5 | ALT0, // same pin used for alternate HW
|
PB_5_ALT0 = PB_5 | ALT0, // same pin used for alternate HW
|
||||||
PB_5_ALT1 = PB_5 | ALT1, // same pin used for alternate HW
|
PB_5_ALT1 = PB_5 | ALT1, // same pin used for alternate HW
|
||||||
PB_6 = 0x16,
|
PB_6 = 0x16,
|
||||||
PB_6_ALT0 = PB_6 | ALT0, // same pin used for alternate HW
|
PB_6_ALT0 = PB_6 | ALT0, // same pin used for alternate HW
|
||||||
PB_6_ALT1 = PB_6 | ALT1, // same pin used for alternate HW
|
PB_6_ALT1 = PB_6 | ALT1, // same pin used for alternate HW
|
||||||
PB_7 = 0x17,
|
PB_7 = 0x17,
|
||||||
PB_7_ALT0 = PB_7 | ALT0, // same pin used for alternate HW
|
PB_7_ALT0 = PB_7 | ALT0, // same pin used for alternate HW
|
||||||
PB_8 = 0x18,
|
PB_8 = 0x18,
|
||||||
PB_8_ALT0 = PB_8 | ALT0, // same pin used for alternate HW
|
PB_8_ALT0 = PB_8 | ALT0, // same pin used for alternate HW
|
||||||
PB_9 = 0x19,
|
PB_9 = 0x19,
|
||||||
PB_9_ALT0 = PB_9 | ALT0, // same pin used for alternate HW
|
PB_9_ALT0 = PB_9 | ALT0, // same pin used for alternate HW
|
||||||
PB_10 = 0x1A,
|
PB_10 = 0x1A,
|
||||||
PB_11 = 0x1B,
|
PB_11 = 0x1B,
|
||||||
PB_12 = 0x1C,
|
PB_12 = 0x1C,
|
||||||
|
|
@ -132,41 +131,41 @@ typedef enum {
|
||||||
PB_15_ALT0 = PB_15 | ALT0, // same pin used for alternate HW
|
PB_15_ALT0 = PB_15 | ALT0, // same pin used for alternate HW
|
||||||
PB_15_ALT1 = PB_15 | ALT1, // same pin used for alternate HW
|
PB_15_ALT1 = PB_15 | ALT1, // same pin used for alternate HW
|
||||||
PC_0 = 0x20,
|
PC_0 = 0x20,
|
||||||
PC_0_ALT0 = PC_0 | ALT0, // same pin used for alternate HW
|
PC_0_ALT0 = PC_0 | ALT0, // same pin used for alternate HW
|
||||||
PC_0_ALT1 = PC_0 | ALT1, // same pin used for alternate HW
|
PC_0_ALT1 = PC_0 | ALT1, // same pin used for alternate HW
|
||||||
PC_1 = 0x21,
|
PC_1 = 0x21,
|
||||||
PC_1_ALT0 = PC_1 | ALT0, // same pin used for alternate HW
|
PC_1_ALT0 = PC_1 | ALT0, // same pin used for alternate HW
|
||||||
PC_1_ALT1 = PC_1 | ALT1, // same pin used for alternate HW
|
PC_1_ALT1 = PC_1 | ALT1, // same pin used for alternate HW
|
||||||
PC_1_ALT2 = PC_1 | ALT2, // same pin used for alternate HW
|
PC_1_ALT2 = PC_1 | ALT2, // same pin used for alternate HW
|
||||||
PC_1_ALT3 = PC_1 | ALT3, // same pin used for alternate HW
|
PC_1_ALT3 = PC_1 | ALT3, // same pin used for alternate HW
|
||||||
PC_1_ALT4 = PC_1 | ALT4, // same pin used for alternate HW
|
PC_1_ALT4 = PC_1 | ALT4, // same pin used for alternate HW
|
||||||
PC_2 = 0x22,
|
PC_2 = 0x22,
|
||||||
PC_2C = PC_2 | ALTC, // dual pad
|
PC_2C = PC_2 | ALTC, // dual pad
|
||||||
PC_2C_ALT0 = PC_2C | ALT0, // same pin used for alternate HW
|
PC_2C_ALT0 = PC_2C | ALT0, // same pin used for alternate HW
|
||||||
PC_2_ALT0 = PC_2 | ALT0, // same pin used for alternate HW
|
PC_2_ALT0 = PC_2 | ALT0, // same pin used for alternate HW
|
||||||
PC_2_ALT1 = PC_2 | ALT1, // same pin used for alternate HW
|
PC_2_ALT1 = PC_2 | ALT1, // same pin used for alternate HW
|
||||||
PC_2_ALT2 = PC_2 | ALT2, // same pin used for alternate HW
|
PC_2_ALT2 = PC_2 | ALT2, // same pin used for alternate HW
|
||||||
PC_2_ALT3 = PC_2 | ALT3, // same pin used for alternate HW
|
PC_2_ALT3 = PC_2 | ALT3, // same pin used for alternate HW
|
||||||
PC_2_ALT4 = PC_2 | ALT4, // same pin used for alternate HW
|
PC_2_ALT4 = PC_2 | ALT4, // same pin used for alternate HW
|
||||||
PC_3 = 0x23,
|
PC_3 = 0x23,
|
||||||
PC_3C = PC_3 | ALTC, // dual pad
|
PC_3C = PC_3 | ALTC, // dual pad
|
||||||
PC_3_ALT0 = PC_3 | ALT0, // same pin used for alternate HW
|
PC_3_ALT0 = PC_3 | ALT0, // same pin used for alternate HW
|
||||||
PC_3_ALT1 = PC_3 | ALT1, // same pin used for alternate HW
|
PC_3_ALT1 = PC_3 | ALT1, // same pin used for alternate HW
|
||||||
PC_3_ALT2 = PC_3 | ALT2, // same pin used for alternate HW
|
PC_3_ALT2 = PC_3 | ALT2, // same pin used for alternate HW
|
||||||
PC_4 = 0x24,
|
PC_4 = 0x24,
|
||||||
PC_4_ALT0 = PC_4 | ALT0, // same pin used for alternate HW
|
PC_4_ALT0 = PC_4 | ALT0, // same pin used for alternate HW
|
||||||
PC_5 = 0x25,
|
PC_5 = 0x25,
|
||||||
PC_5_ALT0 = PC_5 | ALT0, // same pin used for alternate HW
|
PC_5_ALT0 = PC_5 | ALT0, // same pin used for alternate HW
|
||||||
PC_5_ALT1 = PC_5 | ALT1, // same pin used for alternate HW
|
PC_5_ALT1 = PC_5 | ALT1, // same pin used for alternate HW
|
||||||
PC_5_ALT2 = PC_5 | ALT2, // same pin used for alternate HW
|
PC_5_ALT2 = PC_5 | ALT2, // same pin used for alternate HW
|
||||||
PC_6 = 0x26,
|
PC_6 = 0x26,
|
||||||
PC_6_ALT0 = PC_6 | ALT0, // same pin used for alternate HW
|
PC_6_ALT0 = PC_6 | ALT0, // same pin used for alternate HW
|
||||||
PC_7 = 0x27,
|
PC_7 = 0x27,
|
||||||
PC_7_ALT0 = PC_7 | ALT0, // same pin used for alternate HW
|
PC_7_ALT0 = PC_7 | ALT0, // same pin used for alternate HW
|
||||||
PC_8 = 0x28,
|
PC_8 = 0x28,
|
||||||
PC_8_ALT0 = PC_8 | ALT0, // same pin used for alternate HW
|
PC_8_ALT0 = PC_8 | ALT0, // same pin used for alternate HW
|
||||||
PC_9 = 0x29,
|
PC_9 = 0x29,
|
||||||
PC_9_ALT0 = PC_9 | ALT0, // same pin used for alternate HW
|
PC_9_ALT0 = PC_9 | ALT0, // same pin used for alternate HW
|
||||||
PC_10 = 0x2A,
|
PC_10 = 0x2A,
|
||||||
PC_10_ALT0 = PC_10 | ALT0, // same pin used for alternate HW
|
PC_10_ALT0 = PC_10 | ALT0, // same pin used for alternate HW
|
||||||
PC_11 = 0x2B,
|
PC_11 = 0x2B,
|
||||||
|
|
@ -212,15 +211,15 @@ typedef enum {
|
||||||
PF_2 = 0x52,
|
PF_2 = 0x52,
|
||||||
PF_3 = 0x53,
|
PF_3 = 0x53,
|
||||||
PF_4 = 0x54,
|
PF_4 = 0x54,
|
||||||
PF_4_ALT0 = PF_4 | ALT0, // same pin used for alternate HW
|
PF_4_ALT0 = PF_4 | ALT0, // same pin used for alternate HW
|
||||||
PF_5 = 0x55,
|
PF_5 = 0x55,
|
||||||
PF_6 = 0x56,
|
PF_6 = 0x56,
|
||||||
PF_6_ALT0 = PF_6 | ALT0, // same pin used for alternate HW
|
PF_6_ALT0 = PF_6 | ALT0, // same pin used for alternate HW
|
||||||
PF_7 = 0x57,
|
PF_7 = 0x57,
|
||||||
PF_8 = 0x58,
|
PF_8 = 0x58,
|
||||||
PF_8_ALT0 = PF_8 | ALT0, // same pin used for alternate HW
|
PF_8_ALT0 = PF_8 | ALT0, // same pin used for alternate HW
|
||||||
PF_9 = 0x59,
|
PF_9 = 0x59,
|
||||||
PF_9_ALT0 = PF_9 | ALT0, // same pin used for alternate HW
|
PF_9_ALT0 = PF_9 | ALT0, // same pin used for alternate HW
|
||||||
PF_10 = 0x5A,
|
PF_10 = 0x5A,
|
||||||
PF_10_ALT0 = PF_10 | ALT0, // same pin used for alternate HW
|
PF_10_ALT0 = PF_10 | ALT0, // same pin used for alternate HW
|
||||||
PF_11 = 0x5B,
|
PF_11 = 0x5B,
|
||||||
|
|
@ -250,11 +249,11 @@ typedef enum {
|
||||||
PH_1 = 0x71,
|
PH_1 = 0x71,
|
||||||
PH_2 = 0x72,
|
PH_2 = 0x72,
|
||||||
PH_3 = 0x73,
|
PH_3 = 0x73,
|
||||||
PH_3_ALT0 = PH_3 | ALT0, // same pin used for alternate HW
|
PH_3_ALT0 = PH_3 | ALT0, // same pin used for alternate HW
|
||||||
PH_4 = 0x74,
|
PH_4 = 0x74,
|
||||||
PH_4_ALT0 = PH_4 | ALT0, // same pin used for alternate HW
|
PH_4_ALT0 = PH_4 | ALT0, // same pin used for alternate HW
|
||||||
PH_5 = 0x75,
|
PH_5 = 0x75,
|
||||||
PH_5_ALT0 = PH_5 | ALT0, // same pin used for alternate HW
|
PH_5_ALT0 = PH_5 | ALT0, // same pin used for alternate HW
|
||||||
PH_6 = 0x76,
|
PH_6 = 0x76,
|
||||||
PH_7 = 0x77,
|
PH_7 = 0x77,
|
||||||
PH_8 = 0x78,
|
PH_8 = 0x78,
|
||||||
|
|
@ -290,9 +289,9 @@ typedef enum {
|
||||||
PJ_6 = 0x96,
|
PJ_6 = 0x96,
|
||||||
PJ_7 = 0x97,
|
PJ_7 = 0x97,
|
||||||
PJ_8 = 0x98,
|
PJ_8 = 0x98,
|
||||||
PJ_8_ALT0 = PJ_8 | ALT0, // same pin used for alternate HW
|
PJ_8_ALT0 = PJ_8 | ALT0, // same pin used for alternate HW
|
||||||
PJ_9 = 0x99,
|
PJ_9 = 0x99,
|
||||||
PJ_9_ALT0 = PJ_9 | ALT0, // same pin used for alternate HW
|
PJ_9_ALT0 = PJ_9 | ALT0, // same pin used for alternate HW
|
||||||
PJ_10 = 0x9A,
|
PJ_10 = 0x9A,
|
||||||
PJ_10_ALT0 = PJ_10 | ALT0, // same pin used for alternate HW
|
PJ_10_ALT0 = PJ_10 | ALT0, // same pin used for alternate HW
|
||||||
PJ_11 = 0x9B,
|
PJ_11 = 0x9B,
|
||||||
|
|
@ -302,9 +301,9 @@ typedef enum {
|
||||||
PJ_14 = 0x9E,
|
PJ_14 = 0x9E,
|
||||||
PJ_15 = 0x9F,
|
PJ_15 = 0x9F,
|
||||||
PK_0 = 0xA0,
|
PK_0 = 0xA0,
|
||||||
PK_0_ALT0 = PK_0 | ALT0, // same pin used for alternate HW
|
PK_0_ALT0 = PK_0 | ALT0, // same pin used for alternate HW
|
||||||
PK_1 = 0xA1,
|
PK_1 = 0xA1,
|
||||||
PK_1_ALT0 = PK_1 | ALT0, // same pin used for alternate HW
|
PK_1_ALT0 = PK_1 | ALT0, // same pin used for alternate HW
|
||||||
PK_2 = 0xA2,
|
PK_2 = 0xA2,
|
||||||
PK_3 = 0xA3,
|
PK_3 = 0xA3,
|
||||||
PK_4 = 0xA4,
|
PK_4 = 0xA4,
|
||||||
|
|
@ -321,21 +320,22 @@ typedef enum {
|
||||||
WL_SDIO_CMD = PD_2,
|
WL_SDIO_CMD = PD_2,
|
||||||
WL_SDIO_CLK = PC_12,
|
WL_SDIO_CLK = PC_12,
|
||||||
|
|
||||||
// ADC internal channels
|
/**** ADC internal channels ****/
|
||||||
ADC_TEMP = 0xF0,
|
|
||||||
ADC_VREF = 0xF1,
|
ADC_TEMP = 0xF0, // Internal pin virtual value
|
||||||
ADC_VBAT = 0xF2,
|
ADC_VREF = 0xF1, // Internal pin virtual value
|
||||||
|
ADC_VBAT = 0xF2, // Internal pin virtual value
|
||||||
|
|
||||||
// STDIO for console print
|
// STDIO for console print
|
||||||
#ifdef MBED_CONF_TARGET_STDIO_UART_TX
|
#ifdef MBED_CONF_TARGET_STDIO_UART_TX
|
||||||
STDIO_UART_TX = MBED_CONF_TARGET_STDIO_UART_TX,
|
CONSOLE_TX = MBED_CONF_TARGET_STDIO_UART_TX,
|
||||||
#else
|
#else
|
||||||
STDIO_UART_TX = PA_9,
|
CONSOLE_TX = PA_9,
|
||||||
#endif
|
#endif
|
||||||
#ifdef MBED_CONF_TARGET_STDIO_UART_RX
|
#ifdef MBED_CONF_TARGET_STDIO_UART_RX
|
||||||
STDIO_UART_RX = MBED_CONF_TARGET_STDIO_UART_RX,
|
CONSOLE_RX = MBED_CONF_TARGET_STDIO_UART_RX,
|
||||||
#else
|
#else
|
||||||
STDIO_UART_RX = PA_10,
|
CONSOLE_RX = PA_10,
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
//Led mappings
|
//Led mappings
|
||||||
|
|
@ -343,11 +343,6 @@ typedef enum {
|
||||||
LED_GREEN = PK_6, //Green
|
LED_GREEN = PK_6, //Green
|
||||||
LED_BLUE = PK_7, //Blue
|
LED_BLUE = PK_7, //Blue
|
||||||
|
|
||||||
//mbed original LED naming
|
|
||||||
LED1 = LED_RED,
|
|
||||||
LED2 = LED_GREEN,
|
|
||||||
LED3 = LED_BLUE,
|
|
||||||
|
|
||||||
CYBSP_BT_UART_RX = PF_6,
|
CYBSP_BT_UART_RX = PF_6,
|
||||||
CYBSP_BT_UART_TX = PA_15,
|
CYBSP_BT_UART_TX = PA_15,
|
||||||
CYBSP_BT_UART_RTS = PF_8,
|
CYBSP_BT_UART_RTS = PF_8,
|
||||||
|
|
@ -357,17 +352,6 @@ typedef enum {
|
||||||
CYBSP_BT_HOST_WAKE = PJ_13,
|
CYBSP_BT_HOST_WAKE = PJ_13,
|
||||||
CYBSP_BT_DEVICE_WAKE = PJ_14,
|
CYBSP_BT_DEVICE_WAKE = PJ_14,
|
||||||
|
|
||||||
USER_BUTTON = PC_13,
|
|
||||||
// Standardized button names
|
|
||||||
BUTTON1 = USER_BUTTON,
|
|
||||||
SERIAL_TX = STDIO_UART_TX, // Virtual Com Port
|
|
||||||
SERIAL_RX = STDIO_UART_RX, // Virtual Com Port
|
|
||||||
CONSOLE_TX = STDIO_UART_TX, // Virtual Com Port
|
|
||||||
CONSOLE_RX = STDIO_UART_RX, // Virtual Com Port
|
|
||||||
I2C_SCL = PB_6,
|
|
||||||
I2C_SDA = PB_7,
|
|
||||||
PWM_OUT = PD_15,
|
|
||||||
|
|
||||||
/**** QSPI FLASH pins ****/
|
/**** QSPI FLASH pins ****/
|
||||||
QSPI_FLASH1_IO0 = PD_11,
|
QSPI_FLASH1_IO0 = PD_11,
|
||||||
QSPI_FLASH1_IO1 = PD_12,
|
QSPI_FLASH1_IO1 = PD_12,
|
||||||
|
|
@ -376,12 +360,14 @@ typedef enum {
|
||||||
QSPI_FLASH1_SCK = PF_10,
|
QSPI_FLASH1_SCK = PF_10,
|
||||||
QSPI_FLASH1_CSN = PG_6,
|
QSPI_FLASH1_CSN = PG_6,
|
||||||
|
|
||||||
/**** USB pins ****/
|
/**** USB FS pins ****/
|
||||||
USB_OTG_FS_DM = PA_11,
|
USB_OTG_FS_DM = PA_11,
|
||||||
USB_OTG_FS_DP = PA_12,
|
USB_OTG_FS_DP = PA_12,
|
||||||
USB_OTG_FS_ID = PA_10,
|
USB_OTG_FS_ID = PA_10,
|
||||||
USB_OTG_FS_SOF = PA_8,
|
USB_OTG_FS_SOF = PA_8,
|
||||||
USB_OTG_FS_VBUS = PA_9,
|
USB_OTG_FS_VBUS = PA_9,
|
||||||
|
|
||||||
|
/**** USB HS pins ****/
|
||||||
USB_OTG_HS_DM = PB_14,
|
USB_OTG_HS_DM = PB_14,
|
||||||
USB_OTG_HS_DP = PB_15,
|
USB_OTG_HS_DP = PB_15,
|
||||||
USB_OTG_HS_ID = PB_12,
|
USB_OTG_HS_ID = PB_12,
|
||||||
|
|
@ -446,6 +432,12 @@ typedef enum {
|
||||||
NC = (int)0xFFFFFFFF
|
NC = (int)0xFFFFFFFF
|
||||||
} PinName;
|
} PinName;
|
||||||
|
|
||||||
|
// Standardized LED and button names
|
||||||
|
#define LED1 LED_RED
|
||||||
|
#define LED2 LED_GREEN
|
||||||
|
#define LED3 LED_BLUE
|
||||||
|
#define BUTTON1 PC_13
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@
|
||||||
* SPDX-License-Identifier: BSD-3-Clause
|
* SPDX-License-Identifier: BSD-3-Clause
|
||||||
******************************************************************************
|
******************************************************************************
|
||||||
*
|
*
|
||||||
* Copyright (c) 2016-2020 STMicroelectronics.
|
* Copyright (c) 2016-2021 STMicroelectronics.
|
||||||
* All rights reserved.
|
* All rights reserved.
|
||||||
*
|
*
|
||||||
* This software component is licensed by ST under BSD 3-Clause license,
|
* This software component is licensed by ST under BSD 3-Clause license,
|
||||||
|
|
@ -33,12 +33,9 @@ typedef enum {
|
||||||
ALT0 = 0x100,
|
ALT0 = 0x100,
|
||||||
ALT1 = 0x200,
|
ALT1 = 0x200,
|
||||||
ALT2 = 0x300,
|
ALT2 = 0x300,
|
||||||
ALT3 = 0x400,
|
|
||||||
ALT4 = 0x500
|
|
||||||
} ALTx;
|
} ALTx;
|
||||||
|
|
||||||
typedef enum {
|
typedef enum {
|
||||||
|
|
||||||
PA_0 = 0x00,
|
PA_0 = 0x00,
|
||||||
PA_0C = PA_0 | ALTC, // dual pad
|
PA_0C = PA_0 | ALTC, // dual pad
|
||||||
PA_1 = 0x01,
|
PA_1 = 0x01,
|
||||||
|
|
@ -205,13 +202,14 @@ typedef enum {
|
||||||
ADC_VBAT = 0xF2, // Internal pin virtual value
|
ADC_VBAT = 0xF2, // Internal pin virtual value
|
||||||
|
|
||||||
#ifdef TARGET_FF_ARDUINO_UNO
|
#ifdef TARGET_FF_ARDUINO_UNO
|
||||||
// Arduino Uno(Rev3) Header pin connection naming
|
// Arduino Uno (Rev3) pins
|
||||||
ARDUINO_UNO_A0 = PA_3,
|
ARDUINO_UNO_A0 = PA_3,
|
||||||
ARDUINO_UNO_A1 = PC_0,
|
ARDUINO_UNO_A1 = PC_0,
|
||||||
ARDUINO_UNO_A2 = PC_3C,
|
ARDUINO_UNO_A2 = PC_3C,
|
||||||
ARDUINO_UNO_A3 = PB_1,
|
ARDUINO_UNO_A3 = PB_1,
|
||||||
ARDUINO_UNO_A4 = PC_2C,
|
ARDUINO_UNO_A4 = PC_2C,
|
||||||
ARDUINO_UNO_A5 = PF_11,
|
ARDUINO_UNO_A5 = PF_11,
|
||||||
|
|
||||||
ARDUINO_UNO_D0 = PB_7,
|
ARDUINO_UNO_D0 = PB_7,
|
||||||
ARDUINO_UNO_D1 = PB_6,
|
ARDUINO_UNO_D1 = PB_6,
|
||||||
ARDUINO_UNO_D2 = PG_14,
|
ARDUINO_UNO_D2 = PG_14,
|
||||||
|
|
@ -231,9 +229,9 @@ typedef enum {
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
// ST ZIO connector extending Arduino Uno
|
// ST ZIO connector extending Arduino Uno
|
||||||
A6 = PC_1,
|
A6 = PC_1,
|
||||||
A7 = PC_5,
|
A7 = PC_5,
|
||||||
A8 = PA_2,
|
A8 = PA_2,
|
||||||
D16 = PC_6,
|
D16 = PC_6,
|
||||||
D17 = PB_15,
|
D17 = PB_15,
|
||||||
D18 = PB_13,
|
D18 = PB_13,
|
||||||
|
|
@ -318,6 +316,8 @@ typedef enum {
|
||||||
USB_OTG_HS_ULPI_D5 = PB_12,
|
USB_OTG_HS_ULPI_D5 = PB_12,
|
||||||
USB_OTG_HS_ULPI_D6 = PB_13,
|
USB_OTG_HS_ULPI_D6 = PB_13,
|
||||||
USB_OTG_HS_ULPI_D7 = PB_5,
|
USB_OTG_HS_ULPI_D7 = PB_5,
|
||||||
|
USB_OTG_HS_ULPI_DIR = PC_2C,
|
||||||
|
USB_OTG_HS_ULPI_NXT = PC_3C,
|
||||||
USB_OTG_HS_ULPI_STP = PC_0,
|
USB_OTG_HS_ULPI_STP = PC_0,
|
||||||
USB_OTG_HS_VBUS = PA_9,
|
USB_OTG_HS_VBUS = PA_9,
|
||||||
|
|
||||||
|
|
@ -356,11 +356,10 @@ typedef enum {
|
||||||
} PinName;
|
} PinName;
|
||||||
|
|
||||||
// Standardized LED and button names
|
// Standardized LED and button names
|
||||||
#define LED1 PB_0 // LD1
|
#define LED1 PB_0 // LD1 (Green Led)
|
||||||
#define LED2 PB_14 // LD3
|
#define LED2 PE_1 // LD2 (Yellow Led)
|
||||||
#define LED3 PE_1 // LD2
|
#define LED3 PB_14 // LD3 (Red Led)
|
||||||
#define BUTTON1 PC_13 // B1
|
#define BUTTON1 PC_13 // B1 (Blue PushButton)
|
||||||
|
|
||||||
|
|
||||||
#ifdef __cplusplus
|
#ifdef __cplusplus
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue