From 3a71f86235dada7fc4acf3de97c2db7e5c598338 Mon Sep 17 00:00:00 2001 From: Przemyslaw Stekiel Date: Fri, 7 Feb 2020 11:01:41 +0100 Subject: [PATCH] DISCO_L475VG_IOT01A: Add a list of restricted GPIO pins for testing --- .../PeripheralPins.c | 20 +++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/targets/TARGET_STM/TARGET_STM32L4/TARGET_STM32L475xG/TARGET_DISCO_L475VG_IOT01A/PeripheralPins.c b/targets/TARGET_STM/TARGET_STM32L4/TARGET_STM32L475xG/TARGET_DISCO_L475VG_IOT01A/PeripheralPins.c index 67ab04883c8..9b53dda8ff0 100644 --- a/targets/TARGET_STM/TARGET_STM32L4/TARGET_STM32L475xG/TARGET_DISCO_L475VG_IOT01A/PeripheralPins.c +++ b/targets/TARGET_STM/TARGET_STM32L4/TARGET_STM32L475xG/TARGET_DISCO_L475VG_IOT01A/PeripheralPins.c @@ -31,3 +31,23 @@ #include "PeripheralPins.h" #include "mbed_toolchain.h" #include "PeripheralPinMaps.h" + +// List of GPIOs with limited functionality +const PinList *pinmap_gpio_restricted_pins() +{ + static const PinName pins[] = { + D15, // fixed pull-up (for I2C) + D14, // fixed pull-up (for I2C) + PB_10, // fixed pull-up (for I2C) + PB_11, // fixed pull-up (for I2C) + RCC_OSC32_IN, // OSC32_IN + RCC_OSC32_OUT, // OSC32_OUT + RCC_OSC_IN, // OSC_IN + RCC_OSC_OUT // OSC_OUT + }; + static const PinList pin_list = { + sizeof(pins) / sizeof(pins[0]), + pins + }; + return &pin_list; +}