ARM GAS /tmp/ccN5SJrP.s page 1 1 .cpu cortex-m4 2 .eabi_attribute 27, 1 3 .eabi_attribute 28, 1 4 .eabi_attribute 20, 1 5 .eabi_attribute 21, 1 6 .eabi_attribute 23, 3 7 .eabi_attribute 24, 1 8 .eabi_attribute 25, 1 9 .eabi_attribute 26, 1 10 .eabi_attribute 30, 1 11 .eabi_attribute 34, 1 12 .eabi_attribute 18, 4 13 .file "stm32f4xx_hal_gpio.c" 14 .text 15 .Ltext0: 16 .cfi_sections .debug_frame 17 .section .text.HAL_GPIO_Init,"ax",%progbits 18 .align 1 19 .global HAL_GPIO_Init 20 .syntax unified 21 .thumb 22 .thumb_func 23 .fpu fpv4-sp-d16 25 HAL_GPIO_Init: 26 .LFB130: 27 .file 1 "Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c" 1:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** 2:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** ****************************************************************************** 3:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @file stm32f4xx_hal_gpio.c 4:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @author MCD Application Team 5:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @brief GPIO HAL module driver. 6:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * This file provides firmware functions to manage the following 7:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * functionalities of the General Purpose Input/Output (GPIO) peripheral: 8:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * + Initialization and de-initialization functions 9:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * + IO operation functions 10:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * 11:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** @verbatim 12:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** ============================================================================== 13:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** ##### GPIO Peripheral features ##### 14:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** ============================================================================== 15:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** [..] 16:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** Subject to the specific hardware characteristics of each I/O port listed in the datasheet, each 17:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** port bit of the General Purpose IO (GPIO) Ports, can be individually configured by software 18:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** in several modes: 19:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (+) Input mode 20:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (+) Analog mode 21:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (+) Output mode 22:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (+) Alternate function mode 23:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (+) External interrupt/event lines 24:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 25:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** [..] 26:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** During and just after reset, the alternate functions and external interrupt 27:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** lines are not active and the I/O ports are configured in input floating mode. 28:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 29:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** [..] 30:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** All GPIO pins have weak internal pull-up and pull-down resistors, which can be 31:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** activated or not. ARM GAS /tmp/ccN5SJrP.s page 2 32:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 33:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** [..] 34:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** In Output or Alternate mode, each IO can be configured on open-drain or push-pull 35:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** type and the IO speed can be selected depending on the VDD value. 36:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 37:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** [..] 38:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** All ports have external interrupt/event capability. To use external interrupt 39:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** lines, the port must be configured in input mode. All available GPIO pins are 40:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** connected to the 16 external interrupt/event lines from EXTI0 to EXTI15. 41:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 42:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** [..] 43:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** The external interrupt/event controller consists of up to 23 edge detectors 44:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (16 lines are connected to GPIO) for generating event/interrupt requests (each 45:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** input line can be independently configured to select the type (interrupt or event) 46:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** and the corresponding trigger event (rising or falling or both). Each line can 47:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** also be masked independently. 48:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 49:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** ##### How to use this driver ##### 50:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** ============================================================================== 51:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** [..] 52:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (#) Enable the GPIO AHB clock using the following function: __HAL_RCC_GPIOx_CLK_ENABLE(). 53:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 54:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (#) Configure the GPIO pin(s) using HAL_GPIO_Init(). 55:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (++) Configure the IO mode using "Mode" member from GPIO_InitTypeDef structure 56:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (++) Activate Pull-up, Pull-down resistor using "Pull" member from GPIO_InitTypeDef 57:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** structure. 58:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (++) In case of Output or alternate function mode selection: the speed is 59:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** configured through "Speed" member from GPIO_InitTypeDef structure. 60:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (++) In alternate mode is selection, the alternate function connected to the IO 61:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** is configured through "Alternate" member from GPIO_InitTypeDef structure. 62:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (++) Analog mode is required when a pin is to be used as ADC channel 63:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** or DAC output. 64:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (++) In case of external interrupt/event selection the "Mode" member from 65:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIO_InitTypeDef structure select the type (interrupt or event) and 66:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** the corresponding trigger event (rising or falling or both). 67:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 68:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (#) In case of external interrupt/event mode selection, configure NVIC IRQ priority 69:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** mapped to the EXTI line using HAL_NVIC_SetPriority() and enable it using 70:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** HAL_NVIC_EnableIRQ(). 71:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 72:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (#) To get the level of a pin configured in input mode use HAL_GPIO_ReadPin(). 73:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 74:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (#) To set/reset the level of a pin configured in output mode use 75:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** HAL_GPIO_WritePin()/HAL_GPIO_TogglePin(). 76:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 77:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (#) To lock pin configuration until next reset use HAL_GPIO_LockPin(). 78:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 79:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 80:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (#) During and just after reset, the alternate functions are not 81:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** active and the GPIO pins are configured in input floating mode (except JTAG 82:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** pins). 83:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 84:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (#) The LSE oscillator pins OSC32_IN and OSC32_OUT can be used as general purpose 85:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (PC14 and PC15, respectively) when the LSE oscillator is off. The LSE has 86:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** priority over the GPIO function. 87:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 88:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (#) The HSE oscillator pins OSC_IN/OSC_OUT can be used as ARM GAS /tmp/ccN5SJrP.s page 3 89:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** general purpose PH0 and PH1, respectively, when the HSE oscillator is off. 90:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** The HSE has priority over the GPIO function. 91:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 92:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** @endverbatim 93:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** ****************************************************************************** 94:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @attention 95:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * 96:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** *

© Copyright (c) 2017 STMicroelectronics. 97:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * All rights reserved.

98:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * 99:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * This software component is licensed by ST under BSD 3-Clause license, 100:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * the "License"; You may not use this file except in compliance with the 101:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * License. You may obtain a copy of the License at: 102:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * opensource.org/licenses/BSD-3-Clause 103:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * 104:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** ****************************************************************************** 105:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 106:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 107:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Includes ------------------------------------------------------------------*/ 108:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** #include "stm32f4xx_hal.h" 109:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 110:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** @addtogroup STM32F4xx_HAL_Driver 111:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @{ 112:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 113:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 114:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** @defgroup GPIO GPIO 115:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @brief GPIO HAL module driver 116:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @{ 117:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 118:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 119:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** #ifdef HAL_GPIO_MODULE_ENABLED 120:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 121:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Private typedef -----------------------------------------------------------*/ 122:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Private define ------------------------------------------------------------*/ 123:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** @addtogroup GPIO_Private_Constants GPIO Private Constants 124:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @{ 125:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 126:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** #define GPIO_MODE 0x00000003U 127:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** #define EXTI_MODE 0x10000000U 128:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** #define GPIO_MODE_IT 0x00010000U 129:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** #define GPIO_MODE_EVT 0x00020000U 130:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** #define RISING_EDGE 0x00100000U 131:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** #define FALLING_EDGE 0x00200000U 132:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** #define GPIO_OUTPUT_TYPE 0x00000010U 133:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 134:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** #define GPIO_NUMBER 16U 135:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** 136:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @} 137:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 138:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Private macro -------------------------------------------------------------*/ 139:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Private variables ---------------------------------------------------------*/ 140:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Private function prototypes -----------------------------------------------*/ 141:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Private functions ---------------------------------------------------------*/ 142:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Exported functions --------------------------------------------------------*/ 143:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** @defgroup GPIO_Exported_Functions GPIO Exported Functions 144:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @{ 145:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ ARM GAS /tmp/ccN5SJrP.s page 4 146:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 147:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** @defgroup GPIO_Exported_Functions_Group1 Initialization and de-initialization functions 148:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @brief Initialization and Configuration functions 149:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * 150:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** @verbatim 151:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** =============================================================================== 152:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** ##### Initialization and de-initialization functions ##### 153:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** =============================================================================== 154:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** [..] 155:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** This section provides functions allowing to initialize and de-initialize the GPIOs 156:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** to be ready for use. 157:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 158:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** @endverbatim 159:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @{ 160:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 161:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 162:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 163:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** 164:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @brief Initializes the GPIOx peripheral according to the specified parameters in the GPIO_Init 165:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param GPIOx where x can be (A..K) to select the GPIO peripheral for STM32F429X device or 166:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * x can be (A..I) to select the GPIO peripheral for STM32F40XX and STM32F427 167:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param GPIO_Init pointer to a GPIO_InitTypeDef structure that contains 168:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * the configuration information for the specified GPIO peripheral. 169:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @retval None 170:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 171:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** void HAL_GPIO_Init(GPIO_TypeDef *GPIOx, GPIO_InitTypeDef *GPIO_Init) 172:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 28 .loc 1 172 0 29 .cfi_startproc 30 @ args = 0, pretend = 0, frame = 8 31 @ frame_needed = 0, uses_anonymous_args = 0 32 .LVL0: 33 0000 F0B5 push {r4, r5, r6, r7, lr} 34 .LCFI0: 35 .cfi_def_cfa_offset 20 36 .cfi_offset 4, -20 37 .cfi_offset 5, -16 38 .cfi_offset 6, -12 39 .cfi_offset 7, -8 40 .cfi_offset 14, -4 41 0002 83B0 sub sp, sp, #12 42 .LCFI1: 43 .cfi_def_cfa_offset 32 44 .LVL1: 173:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** uint32_t position; 174:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** uint32_t ioposition = 0x00U; 175:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** uint32_t iocurrent = 0x00U; 176:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** uint32_t temp = 0x00U; 177:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 178:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Check the parameters */ 179:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** assert_param(IS_GPIO_ALL_INSTANCE(GPIOx)); 180:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** assert_param(IS_GPIO_PIN(GPIO_Init->Pin)); 181:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** assert_param(IS_GPIO_MODE(GPIO_Init->Mode)); 182:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** assert_param(IS_GPIO_PULL(GPIO_Init->Pull)); 183:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 184:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Configure the port pins */ 185:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** for(position = 0U; position < GPIO_NUMBER; position++) ARM GAS /tmp/ccN5SJrP.s page 5 45 .loc 1 185 0 46 0004 0024 movs r4, #0 47 0006 4BE0 b .L2 48 .LVL2: 49 .L4: 186:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 187:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Get the IO position */ 188:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** ioposition = 0x01U << position; 189:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Get the current IO position */ 190:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** iocurrent = (uint32_t)(GPIO_Init->Pin) & ioposition; 191:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 192:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if(iocurrent == ioposition) 193:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 194:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /*--------------------- GPIO Mode Configuration ------------------------*/ 195:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* In case of Alternate function mode selection */ 196:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if((GPIO_Init->Mode == GPIO_MODE_AF_PP) || (GPIO_Init->Mode == GPIO_MODE_AF_OD)) 197:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 198:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Check the Alternate function parameter */ 199:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** assert_param(IS_GPIO_AF(GPIO_Init->Alternate)); 200:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Configure Alternate function mapped with the current IO */ 201:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp = GPIOx->AFR[position >> 3U]; 50 .loc 1 201 0 51 0008 4FEAD40E lsr lr, r4, #3 52 000c 0EF1080E add lr, lr, #8 53 0010 50F82E20 ldr r2, [r0, lr, lsl #2] 54 .LVL3: 202:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~(0xFU << ((uint32_t)(position & 0x07U) * 4U)) ; 55 .loc 1 202 0 56 0014 04F00706 and r6, r4, #7 57 0018 B600 lsls r6, r6, #2 58 001a 0F27 movs r7, #15 59 001c B740 lsls r7, r7, r6 60 001e 22EA0702 bic r2, r2, r7 61 .LVL4: 203:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= ((uint32_t)(GPIO_Init->Alternate) << (((uint32_t)position & 0x07U) * 4U)); 62 .loc 1 203 0 63 0022 0F69 ldr r7, [r1, #16] 64 0024 07FA06F6 lsl r6, r7, r6 65 0028 3243 orrs r2, r2, r6 66 .LVL5: 204:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->AFR[position >> 3U] = temp; 67 .loc 1 204 0 68 002a 40F82E20 str r2, [r0, lr, lsl #2] 69 002e 46E0 b .L5 70 .LVL6: 71 .L24: 205:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 206:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 207:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Configure IO Direction mode (Input, Output, Alternate or Analog) */ 208:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp = GPIOx->MODER; 209:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~(GPIO_MODER_MODER0 << (position * 2U)); 210:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= ((GPIO_Init->Mode & GPIO_MODE) << (position * 2U)); 211:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->MODER = temp; 212:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 213:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* In case of Output or Alternate function mode selection */ 214:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if((GPIO_Init->Mode == GPIO_MODE_OUTPUT_PP) || (GPIO_Init->Mode == GPIO_MODE_AF_PP) || 215:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (GPIO_Init->Mode == GPIO_MODE_OUTPUT_OD) || (GPIO_Init->Mode == GPIO_MODE_AF_OD)) ARM GAS /tmp/ccN5SJrP.s page 6 216:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 217:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Check the Speed parameter */ 218:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** assert_param(IS_GPIO_SPEED(GPIO_Init->Speed)); 219:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Configure the IO Speed */ 220:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp = GPIOx->OSPEEDR; 221:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~(GPIO_OSPEEDER_OSPEEDR0 << (position * 2U)); 222:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= (GPIO_Init->Speed << (position * 2U)); 223:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->OSPEEDR = temp; 224:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 225:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Configure the IO Output Type */ 226:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp = GPIOx->OTYPER; 227:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~(GPIO_OTYPER_OT_0 << position) ; 228:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= (((GPIO_Init->Mode & GPIO_OUTPUT_TYPE) >> 4U) << position); 229:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->OTYPER = temp; 230:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 231:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 232:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Activate the Pull-up or Pull down resistor for the current IO */ 233:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp = GPIOx->PUPDR; 234:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~(GPIO_PUPDR_PUPDR0 << (position * 2U)); 235:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= ((GPIO_Init->Pull) << (position * 2U)); 236:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->PUPDR = temp; 237:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 238:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /*--------------------- EXTI Mode Configuration ------------------------*/ 239:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Configure the External Interrupt or event for the current IO */ 240:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if((GPIO_Init->Mode & EXTI_MODE) == EXTI_MODE) 241:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 242:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Enable SYSCFG Clock */ 243:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** __HAL_RCC_SYSCFG_CLK_ENABLE(); 244:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 245:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp = SYSCFG->EXTICR[position >> 2U]; 246:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~(0x0FU << (4U * (position & 0x03U))); 247:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= ((uint32_t)(GPIO_GET_INDEX(GPIOx)) << (4U * (position & 0x03U))); 72 .loc 1 247 0 73 0030 0726 movs r6, #7 74 0032 00E0 b .L8 75 .L14: 76 0034 0026 movs r6, #0 77 .L8: 78 .loc 1 247 0 is_stmt 0 discriminator 32 79 0036 06FA0EF6 lsl r6, r6, lr 80 003a 3243 orrs r2, r2, r6 81 .LVL7: 248:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** SYSCFG->EXTICR[position >> 2U] = temp; 82 .loc 1 248 0 is_stmt 1 discriminator 32 83 003c 0233 adds r3, r3, #2 84 003e 5E4E ldr r6, .L25 85 0040 46F82320 str r2, [r6, r3, lsl #2] 249:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 250:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Clear EXTI line configuration */ 251:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp = EXTI->IMR; 86 .loc 1 251 0 discriminator 32 87 0044 5D4B ldr r3, .L25+4 88 0046 1A68 ldr r2, [r3] 89 .LVL8: 252:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~((uint32_t)iocurrent); 90 .loc 1 252 0 discriminator 32 91 0048 EB43 mvns r3, r5 ARM GAS /tmp/ccN5SJrP.s page 7 92 004a 02EA0306 and r6, r2, r3 93 .LVL9: 253:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if((GPIO_Init->Mode & GPIO_MODE_IT) == GPIO_MODE_IT) 94 .loc 1 253 0 discriminator 32 95 004e 4F68 ldr r7, [r1, #4] 96 0050 17F4803F tst r7, #65536 97 0054 01D0 beq .L9 254:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 255:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= iocurrent; 98 .loc 1 255 0 99 0056 45EA0206 orr r6, r5, r2 100 .LVL10: 101 .L9: 256:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 257:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** EXTI->IMR = temp; 102 .loc 1 257 0 103 005a 584A ldr r2, .L25+4 104 005c 1660 str r6, [r2] 258:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 259:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp = EXTI->EMR; 105 .loc 1 259 0 106 005e 5268 ldr r2, [r2, #4] 107 .LVL11: 260:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~((uint32_t)iocurrent); 108 .loc 1 260 0 109 0060 03EA0206 and r6, r3, r2 110 .LVL12: 261:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if((GPIO_Init->Mode & GPIO_MODE_EVT) == GPIO_MODE_EVT) 111 .loc 1 261 0 112 0064 4F68 ldr r7, [r1, #4] 113 0066 17F4003F tst r7, #131072 114 006a 01D0 beq .L10 262:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 263:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= iocurrent; 115 .loc 1 263 0 116 006c 45EA0206 orr r6, r5, r2 117 .LVL13: 118 .L10: 264:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 265:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** EXTI->EMR = temp; 119 .loc 1 265 0 120 0070 524A ldr r2, .L25+4 121 0072 5660 str r6, [r2, #4] 266:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 267:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Clear Rising Falling edge configuration */ 268:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp = EXTI->RTSR; 122 .loc 1 268 0 123 0074 9268 ldr r2, [r2, #8] 124 .LVL14: 269:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~((uint32_t)iocurrent); 125 .loc 1 269 0 126 0076 03EA0206 and r6, r3, r2 127 .LVL15: 270:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if((GPIO_Init->Mode & RISING_EDGE) == RISING_EDGE) 128 .loc 1 270 0 129 007a 4F68 ldr r7, [r1, #4] 130 007c 17F4801F tst r7, #1048576 ARM GAS /tmp/ccN5SJrP.s page 8 131 0080 01D0 beq .L11 271:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 272:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= iocurrent; 132 .loc 1 272 0 133 0082 45EA0206 orr r6, r5, r2 134 .LVL16: 135 .L11: 273:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 274:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** EXTI->RTSR = temp; 136 .loc 1 274 0 137 0086 4D4A ldr r2, .L25+4 138 0088 9660 str r6, [r2, #8] 275:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 276:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp = EXTI->FTSR; 139 .loc 1 276 0 140 008a D268 ldr r2, [r2, #12] 141 .LVL17: 277:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~((uint32_t)iocurrent); 142 .loc 1 277 0 143 008c 1340 ands r3, r3, r2 144 .LVL18: 278:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if((GPIO_Init->Mode & FALLING_EDGE) == FALLING_EDGE) 145 .loc 1 278 0 146 008e 4E68 ldr r6, [r1, #4] 147 0090 16F4001F tst r6, #2097152 148 0094 01D0 beq .L12 279:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 280:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= iocurrent; 149 .loc 1 280 0 150 0096 45EA0203 orr r3, r5, r2 151 .LVL19: 152 .L12: 281:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 282:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** EXTI->FTSR = temp; 153 .loc 1 282 0 154 009a 484A ldr r2, .L25+4 155 009c D360 str r3, [r2, #12] 156 .LVL20: 157 .L3: 185:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 158 .loc 1 185 0 discriminator 2 159 009e 0134 adds r4, r4, #1 160 .LVL21: 161 .L2: 185:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 162 .loc 1 185 0 is_stmt 0 discriminator 1 163 00a0 0F2C cmp r4, #15 164 00a2 00F28680 bhi .L23 188:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Get the current IO position */ 165 .loc 1 188 0 is_stmt 1 166 00a6 0123 movs r3, #1 167 00a8 A340 lsls r3, r3, r4 168 .LVL22: 190:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 169 .loc 1 190 0 170 00aa 0A68 ldr r2, [r1] 171 00ac 03EA0205 and r5, r3, r2 ARM GAS /tmp/ccN5SJrP.s page 9 172 .LVL23: 192:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 173 .loc 1 192 0 174 00b0 AB42 cmp r3, r5 175 00b2 F4D1 bne .L3 196:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 176 .loc 1 196 0 177 00b4 4A68 ldr r2, [r1, #4] 178 00b6 022A cmp r2, #2 179 00b8 A6D0 beq .L4 196:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 180 .loc 1 196 0 is_stmt 0 discriminator 1 181 00ba 122A cmp r2, #18 182 00bc A4D0 beq .L4 183 .L5: 208:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~(GPIO_MODER_MODER0 << (position * 2U)); 184 .loc 1 208 0 is_stmt 1 185 00be 0668 ldr r6, [r0] 186 .LVL24: 209:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= ((GPIO_Init->Mode & GPIO_MODE) << (position * 2U)); 187 .loc 1 209 0 188 00c0 4FEA440E lsl lr, r4, #1 189 00c4 0322 movs r2, #3 190 00c6 02FA0EF2 lsl r2, r2, lr 191 00ca D243 mvns r2, r2 192 00cc 1640 ands r6, r6, r2 193 .LVL25: 210:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->MODER = temp; 194 .loc 1 210 0 195 00ce 4F68 ldr r7, [r1, #4] 196 00d0 07F00307 and r7, r7, #3 197 00d4 07FA0EF7 lsl r7, r7, lr 198 00d8 3E43 orrs r6, r6, r7 199 .LVL26: 211:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 200 .loc 1 211 0 201 00da 0660 str r6, [r0] 214:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (GPIO_Init->Mode == GPIO_MODE_OUTPUT_OD) || (GPIO_Init->Mode == GPIO_MODE_AF_OD)) 202 .loc 1 214 0 203 00dc 4E68 ldr r6, [r1, #4] 204 .LVL27: 205 00de 771E subs r7, r6, #1 206 00e0 012F cmp r7, #1 207 00e2 03D9 bls .L6 214:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** (GPIO_Init->Mode == GPIO_MODE_OUTPUT_OD) || (GPIO_Init->Mode == GPIO_MODE_AF_OD)) 208 .loc 1 214 0 is_stmt 0 discriminator 1 209 00e4 112E cmp r6, #17 210 00e6 01D0 beq .L6 215:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 211 .loc 1 215 0 is_stmt 1 212 00e8 122E cmp r6, #18 213 00ea 0FD1 bne .L7 214 .L6: 220:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~(GPIO_OSPEEDER_OSPEEDR0 << (position * 2U)); 215 .loc 1 220 0 216 00ec 8668 ldr r6, [r0, #8] 217 .LVL28: ARM GAS /tmp/ccN5SJrP.s page 10 221:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= (GPIO_Init->Speed << (position * 2U)); 218 .loc 1 221 0 219 00ee 1640 ands r6, r6, r2 220 .LVL29: 222:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->OSPEEDR = temp; 221 .loc 1 222 0 222 00f0 CF68 ldr r7, [r1, #12] 223 00f2 07FA0EF7 lsl r7, r7, lr 224 00f6 3E43 orrs r6, r6, r7 225 .LVL30: 223:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 226 .loc 1 223 0 227 00f8 8660 str r6, [r0, #8] 226:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~(GPIO_OTYPER_OT_0 << position) ; 228 .loc 1 226 0 229 00fa 4668 ldr r6, [r0, #4] 230 .LVL31: 227:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= (((GPIO_Init->Mode & GPIO_OUTPUT_TYPE) >> 4U) << position); 231 .loc 1 227 0 232 00fc 26EA0303 bic r3, r6, r3 233 .LVL32: 228:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->OTYPER = temp; 234 .loc 1 228 0 235 0100 4E68 ldr r6, [r1, #4] 236 0102 C6F30016 ubfx r6, r6, #4, #1 237 0106 A640 lsls r6, r6, r4 238 0108 3343 orrs r3, r3, r6 239 .LVL33: 229:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 240 .loc 1 229 0 241 010a 4360 str r3, [r0, #4] 242 .LVL34: 243 .L7: 233:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~(GPIO_PUPDR_PUPDR0 << (position * 2U)); 244 .loc 1 233 0 245 010c C368 ldr r3, [r0, #12] 246 .LVL35: 234:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= ((GPIO_Init->Pull) << (position * 2U)); 247 .loc 1 234 0 248 010e 1A40 ands r2, r2, r3 249 .LVL36: 235:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->PUPDR = temp; 250 .loc 1 235 0 251 0110 8B68 ldr r3, [r1, #8] 252 0112 03FA0EF3 lsl r3, r3, lr 253 0116 1A43 orrs r2, r2, r3 254 .LVL37: 236:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 255 .loc 1 236 0 256 0118 C260 str r2, [r0, #12] 240:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 257 .loc 1 240 0 258 011a 4B68 ldr r3, [r1, #4] 259 011c 13F0805F tst r3, #268435456 260 0120 BDD0 beq .L3 261 .LBB2: 243:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** ARM GAS /tmp/ccN5SJrP.s page 11 262 .loc 1 243 0 263 0122 0023 movs r3, #0 264 0124 0193 str r3, [sp, #4] 265 0126 264B ldr r3, .L25+8 266 0128 5A6C ldr r2, [r3, #68] 267 .LVL38: 268 012a 42F48042 orr r2, r2, #16384 269 012e 5A64 str r2, [r3, #68] 270 0130 5B6C ldr r3, [r3, #68] 271 0132 03F48043 and r3, r3, #16384 272 0136 0193 str r3, [sp, #4] 273 0138 019B ldr r3, [sp, #4] 274 .LBE2: 245:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp &= ~(0x0FU << (4U * (position & 0x03U))); 275 .loc 1 245 0 276 013a A308 lsrs r3, r4, #2 277 013c 9E1C adds r6, r3, #2 278 013e 1E4A ldr r2, .L25 279 0140 52F82620 ldr r2, [r2, r6, lsl #2] 280 .LVL39: 246:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** temp |= ((uint32_t)(GPIO_GET_INDEX(GPIOx)) << (4U * (position & 0x03U))); 281 .loc 1 246 0 282 0144 04F00306 and r6, r4, #3 283 0148 4FEA860E lsl lr, r6, #2 284 014c 0F26 movs r6, #15 285 014e 06FA0EF6 lsl r6, r6, lr 286 0152 22EA0602 bic r2, r2, r6 287 .LVL40: 247:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** SYSCFG->EXTICR[position >> 2U] = temp; 288 .loc 1 247 0 289 0156 1B4F ldr r7, .L25+12 290 0158 B842 cmp r0, r7 291 015a 3FF46BAF beq .L14 247:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** SYSCFG->EXTICR[position >> 2U] = temp; 292 .loc 1 247 0 is_stmt 0 discriminator 1 293 015e 1A4E ldr r6, .L25+16 294 0160 B042 cmp r0, r6 295 0162 1AD0 beq .L15 247:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** SYSCFG->EXTICR[position >> 2U] = temp; 296 .loc 1 247 0 discriminator 3 297 0164 06F58066 add r6, r6, #1024 298 0168 B042 cmp r0, r6 299 016a 18D0 beq .L16 247:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** SYSCFG->EXTICR[position >> 2U] = temp; 300 .loc 1 247 0 discriminator 5 301 016c 06F58066 add r6, r6, #1024 302 0170 B042 cmp r0, r6 303 0172 16D0 beq .L17 247:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** SYSCFG->EXTICR[position >> 2U] = temp; 304 .loc 1 247 0 discriminator 7 305 0174 06F58066 add r6, r6, #1024 306 0178 B042 cmp r0, r6 307 017a 14D0 beq .L18 247:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** SYSCFG->EXTICR[position >> 2U] = temp; 308 .loc 1 247 0 discriminator 9 309 017c 06F58066 add r6, r6, #1024 310 0180 B042 cmp r0, r6 ARM GAS /tmp/ccN5SJrP.s page 12 311 0182 12D0 beq .L19 247:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** SYSCFG->EXTICR[position >> 2U] = temp; 312 .loc 1 247 0 discriminator 11 313 0184 06F58066 add r6, r6, #1024 314 0188 B042 cmp r0, r6 315 018a 10D0 beq .L20 247:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** SYSCFG->EXTICR[position >> 2U] = temp; 316 .loc 1 247 0 discriminator 13 317 018c 06F58066 add r6, r6, #1024 318 0190 B042 cmp r0, r6 319 0192 3FF44DAF beq .L24 247:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** SYSCFG->EXTICR[position >> 2U] = temp; 320 .loc 1 247 0 321 0196 0826 movs r6, #8 322 0198 4DE7 b .L8 323 .L15: 324 019a 0126 movs r6, #1 325 .LVL41: 326 019c 4BE7 b .L8 327 .LVL42: 328 .L16: 329 019e 0226 movs r6, #2 330 01a0 49E7 b .L8 331 .L17: 332 01a2 0326 movs r6, #3 333 01a4 47E7 b .L8 334 .L18: 335 01a6 0426 movs r6, #4 336 01a8 45E7 b .L8 337 .L19: 338 01aa 0526 movs r6, #5 339 01ac 43E7 b .L8 340 .L20: 341 01ae 0626 movs r6, #6 342 01b0 41E7 b .L8 343 .LVL43: 344 .L23: 283:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 284:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 285:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 286:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 345 .loc 1 286 0 is_stmt 1 346 01b2 03B0 add sp, sp, #12 347 .LCFI2: 348 .cfi_def_cfa_offset 20 349 @ sp needed 350 01b4 F0BD pop {r4, r5, r6, r7, pc} 351 .LVL44: 352 .L26: 353 01b6 00BF .align 2 354 .L25: 355 01b8 00380140 .word 1073821696 356 01bc 003C0140 .word 1073822720 357 01c0 00380240 .word 1073887232 358 01c4 00000240 .word 1073872896 359 01c8 00040240 .word 1073873920 360 .cfi_endproc ARM GAS /tmp/ccN5SJrP.s page 13 361 .LFE130: 363 .section .text.HAL_GPIO_DeInit,"ax",%progbits 364 .align 1 365 .global HAL_GPIO_DeInit 366 .syntax unified 367 .thumb 368 .thumb_func 369 .fpu fpv4-sp-d16 371 HAL_GPIO_DeInit: 372 .LFB131: 287:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 288:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** 289:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @brief De-initializes the GPIOx peripheral registers to their default reset values. 290:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param GPIOx where x can be (A..K) to select the GPIO peripheral for STM32F429X device or 291:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * x can be (A..I) to select the GPIO peripheral for STM32F40XX and STM32F427 292:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param GPIO_Pin specifies the port bit to be written. 293:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * This parameter can be one of GPIO_PIN_x where x can be (0..15). 294:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @retval None 295:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 296:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** void HAL_GPIO_DeInit(GPIO_TypeDef *GPIOx, uint32_t GPIO_Pin) 297:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 373 .loc 1 297 0 374 .cfi_startproc 375 @ args = 0, pretend = 0, frame = 0 376 @ frame_needed = 0, uses_anonymous_args = 0 377 .LVL45: 298:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** uint32_t position; 299:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** uint32_t ioposition = 0x00U; 300:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** uint32_t iocurrent = 0x00U; 301:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** uint32_t tmp = 0x00U; 302:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 303:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Check the parameters */ 304:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** assert_param(IS_GPIO_ALL_INSTANCE(GPIOx)); 305:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 306:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Configure the port pins */ 307:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** for(position = 0U; position < GPIO_NUMBER; position++) 378 .loc 1 307 0 379 0000 0023 movs r3, #0 380 .LVL46: 381 0002 0F2B cmp r3, #15 382 0004 00F28780 bhi .L44 297:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** uint32_t position; 383 .loc 1 297 0 384 0008 F0B5 push {r4, r5, r6, r7, lr} 385 .LCFI3: 386 .cfi_def_cfa_offset 20 387 .cfi_offset 4, -20 388 .cfi_offset 5, -16 389 .cfi_offset 6, -12 390 .cfi_offset 7, -8 391 .cfi_offset 14, -4 392 000a 29E0 b .L32 393 .LVL47: 394 .L47: 308:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 309:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Get the IO position */ 310:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** ioposition = 0x01U << position; ARM GAS /tmp/ccN5SJrP.s page 14 311:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Get the current IO position */ 312:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** iocurrent = (GPIO_Pin) & ioposition; 313:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 314:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if(iocurrent == ioposition) 315:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 316:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /*------------------------- EXTI Mode Configuration --------------------*/ 317:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** tmp = SYSCFG->EXTICR[position >> 2U]; 318:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** tmp &= (0x0FU << (4U * (position & 0x03U))); 319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if(tmp == ((uint32_t)(GPIO_GET_INDEX(GPIOx)) << (4U * (position & 0x03U)))) 395 .loc 1 319 0 396 000c 0727 movs r7, #7 397 000e 00E0 b .L30 398 .L33: 399 0010 0027 movs r7, #0 400 .L30: 401 .loc 1 319 0 is_stmt 0 discriminator 32 402 0012 07FA05F5 lsl r5, r7, r5 403 0016 AE42 cmp r6, r5 404 0018 64D0 beq .L45 405 .LVL48: 406 .L31: 320:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 321:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Configure the External Interrupt or event for the current IO */ 322:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** tmp = 0x0FU << (4U * (position & 0x03U)); 323:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** SYSCFG->EXTICR[position >> 2U] &= ~tmp; 324:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 325:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Clear EXTI line configuration */ 326:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** EXTI->IMR &= ~((uint32_t)iocurrent); 327:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** EXTI->EMR &= ~((uint32_t)iocurrent); 328:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 329:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Clear Rising Falling edge configuration */ 330:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** EXTI->RTSR &= ~((uint32_t)iocurrent); 331:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** EXTI->FTSR &= ~((uint32_t)iocurrent); 332:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 333:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 334:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /*------------------------- GPIO Mode Configuration --------------------*/ 335:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Configure IO Direction in Input Floating Mode */ 336:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->MODER &= ~(GPIO_MODER_MODER0 << (position * 2U)); 407 .loc 1 336 0 is_stmt 1 408 001a 0568 ldr r5, [r0] 409 001c 5E00 lsls r6, r3, #1 410 001e 0324 movs r4, #3 411 0020 B440 lsls r4, r4, r6 412 0022 E443 mvns r4, r4 413 0024 2540 ands r5, r5, r4 414 0026 0560 str r5, [r0] 337:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 338:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Configure the default Alternate Function in current IO */ 339:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->AFR[position >> 3U] &= ~(0xFU << ((uint32_t)(position & 0x07U) * 4U)) ; 415 .loc 1 339 0 416 0028 DD08 lsrs r5, r3, #3 417 002a 0835 adds r5, r5, #8 418 002c 50F82560 ldr r6, [r0, r5, lsl #2] 419 0030 03F00707 and r7, r3, #7 420 0034 4FEA870E lsl lr, r7, #2 421 0038 0F27 movs r7, #15 422 003a 07FA0EF7 lsl r7, r7, lr ARM GAS /tmp/ccN5SJrP.s page 15 423 003e 26EA0706 bic r6, r6, r7 424 0042 40F82560 str r6, [r0, r5, lsl #2] 340:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 341:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Configure the default value for IO Speed */ 342:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->OSPEEDR &= ~(GPIO_OSPEEDER_OSPEEDR0 << (position * 2U)); 425 .loc 1 342 0 426 0046 8568 ldr r5, [r0, #8] 427 0048 2540 ands r5, r5, r4 428 004a 8560 str r5, [r0, #8] 343:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 344:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Configure the default value IO Output Type */ 345:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->OTYPER &= ~(GPIO_OTYPER_OT_0 << position) ; 429 .loc 1 345 0 430 004c 4568 ldr r5, [r0, #4] 431 004e 25EA0202 bic r2, r5, r2 432 .LVL49: 433 0052 4260 str r2, [r0, #4] 346:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 347:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Deactivate the Pull-up and Pull-down resistor for the current IO */ 348:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->PUPDR &= ~(GPIO_PUPDR_PUPDR0 << (position * 2U)); 434 .loc 1 348 0 435 0054 C268 ldr r2, [r0, #12] 436 0056 1440 ands r4, r4, r2 437 0058 C460 str r4, [r0, #12] 438 .L29: 307:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 439 .loc 1 307 0 discriminator 2 440 005a 0133 adds r3, r3, #1 441 .LVL50: 442 005c 0F2B cmp r3, #15 443 005e 59D8 bhi .L46 444 .LVL51: 445 .L32: 310:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Get the current IO position */ 446 .loc 1 310 0 447 0060 0122 movs r2, #1 448 0062 9A40 lsls r2, r2, r3 449 .LVL52: 312:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 450 .loc 1 312 0 451 0064 02EA0104 and r4, r2, r1 452 .LVL53: 314:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 453 .loc 1 314 0 454 0068 A242 cmp r2, r4 455 006a F6D1 bne .L29 317:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** tmp &= (0x0FU << (4U * (position & 0x03U))); 456 .loc 1 317 0 457 006c 4FEA930E lsr lr, r3, #2 458 0070 0EF10206 add r6, lr, #2 459 0074 284D ldr r5, .L48 460 0076 55F82660 ldr r6, [r5, r6, lsl #2] 461 .LVL54: 318:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if(tmp == ((uint32_t)(GPIO_GET_INDEX(GPIOx)) << (4U * (position & 0x03U)))) 462 .loc 1 318 0 463 007a 03F00305 and r5, r3, #3 464 007e AD00 lsls r5, r5, #2 ARM GAS /tmp/ccN5SJrP.s page 16 465 0080 0F27 movs r7, #15 466 0082 07FA05FC lsl ip, r7, r5 467 0086 06EA0C06 and r6, r6, ip 468 .LVL55: 319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 469 .loc 1 319 0 470 008a 244F ldr r7, .L48+4 471 008c B842 cmp r0, r7 472 008e BFD0 beq .L33 319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 473 .loc 1 319 0 is_stmt 0 discriminator 1 474 0090 07F58067 add r7, r7, #1024 475 0094 B842 cmp r0, r7 476 0096 19D0 beq .L34 319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 477 .loc 1 319 0 discriminator 3 478 0098 07F58067 add r7, r7, #1024 479 009c B842 cmp r0, r7 480 009e 17D0 beq .L35 319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 481 .loc 1 319 0 discriminator 5 482 00a0 07F58067 add r7, r7, #1024 483 00a4 B842 cmp r0, r7 484 00a6 15D0 beq .L36 319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 485 .loc 1 319 0 discriminator 7 486 00a8 07F58067 add r7, r7, #1024 487 00ac B842 cmp r0, r7 488 00ae 13D0 beq .L37 319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 489 .loc 1 319 0 discriminator 9 490 00b0 07F58067 add r7, r7, #1024 491 00b4 B842 cmp r0, r7 492 00b6 11D0 beq .L38 319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 493 .loc 1 319 0 discriminator 11 494 00b8 07F58067 add r7, r7, #1024 495 00bc B842 cmp r0, r7 496 00be 0FD0 beq .L39 319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 497 .loc 1 319 0 discriminator 13 498 00c0 07F58067 add r7, r7, #1024 499 00c4 B842 cmp r0, r7 500 00c6 A1D0 beq .L47 319:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 501 .loc 1 319 0 502 00c8 0827 movs r7, #8 503 00ca A2E7 b .L30 504 .L34: 505 00cc 0127 movs r7, #1 506 00ce A0E7 b .L30 507 .L35: 508 00d0 0227 movs r7, #2 509 00d2 9EE7 b .L30 510 .L36: 511 00d4 0327 movs r7, #3 512 00d6 9CE7 b .L30 ARM GAS /tmp/ccN5SJrP.s page 17 513 .L37: 514 00d8 0427 movs r7, #4 515 00da 9AE7 b .L30 516 .L38: 517 00dc 0527 movs r7, #5 518 00de 98E7 b .L30 519 .L39: 520 00e0 0627 movs r7, #6 521 00e2 96E7 b .L30 522 .L45: 523 .LVL56: 323:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 524 .loc 1 323 0 is_stmt 1 525 00e4 0C4E ldr r6, .L48 526 00e6 0EF10205 add r5, lr, #2 527 00ea 56F82570 ldr r7, [r6, r5, lsl #2] 528 00ee 27EA0C07 bic r7, r7, ip 529 00f2 46F82570 str r7, [r6, r5, lsl #2] 326:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** EXTI->EMR &= ~((uint32_t)iocurrent); 530 .loc 1 326 0 531 00f6 0A4D ldr r5, .L48+8 532 00f8 2E68 ldr r6, [r5] 533 00fa E443 mvns r4, r4 534 .LVL57: 535 00fc 2640 ands r6, r6, r4 536 00fe 2E60 str r6, [r5] 327:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 537 .loc 1 327 0 538 0100 6E68 ldr r6, [r5, #4] 539 0102 2640 ands r6, r6, r4 540 0104 6E60 str r6, [r5, #4] 330:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** EXTI->FTSR &= ~((uint32_t)iocurrent); 541 .loc 1 330 0 542 0106 AE68 ldr r6, [r5, #8] 543 0108 2640 ands r6, r6, r4 544 010a AE60 str r6, [r5, #8] 331:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 545 .loc 1 331 0 546 010c EE68 ldr r6, [r5, #12] 547 010e 3440 ands r4, r4, r6 548 .LVL58: 549 0110 EC60 str r4, [r5, #12] 550 0112 82E7 b .L31 551 .LVL59: 552 .L46: 349:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 350:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 351:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 553 .loc 1 351 0 554 0114 F0BD pop {r4, r5, r6, r7, pc} 555 .LVL60: 556 .L44: 557 .LCFI4: 558 .cfi_def_cfa_offset 0 559 .cfi_restore 4 560 .cfi_restore 5 561 .cfi_restore 6 ARM GAS /tmp/ccN5SJrP.s page 18 562 .cfi_restore 7 563 .cfi_restore 14 564 0116 7047 bx lr 565 .L49: 566 .align 2 567 .L48: 568 0118 00380140 .word 1073821696 569 011c 00000240 .word 1073872896 570 0120 003C0140 .word 1073822720 571 .cfi_endproc 572 .LFE131: 574 .section .text.HAL_GPIO_ReadPin,"ax",%progbits 575 .align 1 576 .global HAL_GPIO_ReadPin 577 .syntax unified 578 .thumb 579 .thumb_func 580 .fpu fpv4-sp-d16 582 HAL_GPIO_ReadPin: 583 .LFB132: 352:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 353:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** 354:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @} 355:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 356:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 357:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** @defgroup GPIO_Exported_Functions_Group2 IO operation functions 358:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @brief GPIO Read and Write 359:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * 360:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** @verbatim 361:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** =============================================================================== 362:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** ##### IO operation functions ##### 363:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** =============================================================================== 364:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 365:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** @endverbatim 366:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @{ 367:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 368:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 369:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** 370:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @brief Reads the specified input port pin. 371:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param GPIOx where x can be (A..K) to select the GPIO peripheral for STM32F429X device or 372:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * x can be (A..I) to select the GPIO peripheral for STM32F40XX and STM32F427 373:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param GPIO_Pin specifies the port bit to read. 374:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * This parameter can be GPIO_PIN_x where x can be (0..15). 375:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @retval The input port pin value. 376:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 377:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIO_PinState HAL_GPIO_ReadPin(GPIO_TypeDef* GPIOx, uint16_t GPIO_Pin) 378:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 584 .loc 1 378 0 585 .cfi_startproc 586 @ args = 0, pretend = 0, frame = 0 587 @ frame_needed = 0, uses_anonymous_args = 0 588 @ link register save eliminated. 589 .LVL61: 379:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIO_PinState bitstatus; 380:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 381:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Check the parameters */ 382:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** assert_param(IS_GPIO_PIN(GPIO_Pin)); ARM GAS /tmp/ccN5SJrP.s page 19 383:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 384:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if((GPIOx->IDR & GPIO_Pin) != (uint32_t)GPIO_PIN_RESET) 590 .loc 1 384 0 591 0000 0369 ldr r3, [r0, #16] 592 0002 1942 tst r1, r3 593 0004 01D1 bne .L53 385:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 386:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** bitstatus = GPIO_PIN_SET; 387:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 388:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** else 389:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 390:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** bitstatus = GPIO_PIN_RESET; 594 .loc 1 390 0 595 0006 0020 movs r0, #0 596 .LVL62: 391:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 392:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** return bitstatus; 393:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 597 .loc 1 393 0 598 0008 7047 bx lr 599 .LVL63: 600 .L53: 386:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 601 .loc 1 386 0 602 000a 0120 movs r0, #1 603 .LVL64: 604 000c 7047 bx lr 605 .cfi_endproc 606 .LFE132: 608 .section .text.HAL_GPIO_WritePin,"ax",%progbits 609 .align 1 610 .global HAL_GPIO_WritePin 611 .syntax unified 612 .thumb 613 .thumb_func 614 .fpu fpv4-sp-d16 616 HAL_GPIO_WritePin: 617 .LFB133: 394:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 395:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** 396:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @brief Sets or clears the selected data port bit. 397:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * 398:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @note This function uses GPIOx_BSRR register to allow atomic read/modify 399:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * accesses. In this way, there is no risk of an IRQ occurring between 400:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * the read and the modify access. 401:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * 402:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param GPIOx where x can be (A..K) to select the GPIO peripheral for STM32F429X device or 403:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * x can be (A..I) to select the GPIO peripheral for STM32F40XX and STM32F427 404:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param GPIO_Pin specifies the port bit to be written. 405:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * This parameter can be one of GPIO_PIN_x where x can be (0..15). 406:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param PinState specifies the value to be written to the selected bit. 407:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * This parameter can be one of the GPIO_PinState enum values: 408:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @arg GPIO_PIN_RESET: to clear the port pin 409:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @arg GPIO_PIN_SET: to set the port pin 410:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @retval None 411:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 412:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** void HAL_GPIO_WritePin(GPIO_TypeDef* GPIOx, uint16_t GPIO_Pin, GPIO_PinState PinState) ARM GAS /tmp/ccN5SJrP.s page 20 413:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 618 .loc 1 413 0 619 .cfi_startproc 620 @ args = 0, pretend = 0, frame = 0 621 @ frame_needed = 0, uses_anonymous_args = 0 622 @ link register save eliminated. 623 .LVL65: 414:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Check the parameters */ 415:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** assert_param(IS_GPIO_PIN(GPIO_Pin)); 416:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** assert_param(IS_GPIO_PIN_ACTION(PinState)); 417:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 418:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if(PinState != GPIO_PIN_RESET) 624 .loc 1 418 0 625 0000 12B9 cbnz r2, .L57 419:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 420:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->BSRR = GPIO_Pin; 421:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 422:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** else 423:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 424:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->BSRR = (uint32_t)GPIO_Pin << 16U; 626 .loc 1 424 0 627 0002 0904 lsls r1, r1, #16 628 .LVL66: 629 0004 8161 str r1, [r0, #24] 630 0006 7047 bx lr 631 .LVL67: 632 .L57: 420:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 633 .loc 1 420 0 634 0008 8161 str r1, [r0, #24] 635 000a 7047 bx lr 636 .cfi_endproc 637 .LFE133: 639 .section .text.HAL_GPIO_TogglePin,"ax",%progbits 640 .align 1 641 .global HAL_GPIO_TogglePin 642 .syntax unified 643 .thumb 644 .thumb_func 645 .fpu fpv4-sp-d16 647 HAL_GPIO_TogglePin: 648 .LFB134: 425:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 426:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 427:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 428:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** 429:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @brief Toggles the specified GPIO pins. 430:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param GPIOx Where x can be (A..K) to select the GPIO peripheral for STM32F429X device or 431:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * x can be (A..I) to select the GPIO peripheral for STM32F40XX and STM32F427 432:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param GPIO_Pin Specifies the pins to be toggled. 433:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @retval None 434:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 435:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** void HAL_GPIO_TogglePin(GPIO_TypeDef* GPIOx, uint16_t GPIO_Pin) 436:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 649 .loc 1 436 0 650 .cfi_startproc 651 @ args = 0, pretend = 0, frame = 0 ARM GAS /tmp/ccN5SJrP.s page 21 652 @ frame_needed = 0, uses_anonymous_args = 0 653 @ link register save eliminated. 654 .LVL68: 437:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Check the parameters */ 438:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** assert_param(IS_GPIO_PIN(GPIO_Pin)); 439:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 440:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if ((GPIOx->ODR & GPIO_Pin) == GPIO_Pin) 655 .loc 1 440 0 656 0000 4369 ldr r3, [r0, #20] 657 0002 31EA0303 bics r3, r1, r3 658 0006 01D0 beq .L61 441:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 442:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->BSRR = (uint32_t)GPIO_Pin << GPIO_NUMBER; 443:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 444:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** else 445:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 446:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->BSRR = GPIO_Pin; 659 .loc 1 446 0 660 0008 8161 str r1, [r0, #24] 661 000a 7047 bx lr 662 .L61: 442:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 663 .loc 1 442 0 664 000c 0904 lsls r1, r1, #16 665 .LVL69: 666 000e 8161 str r1, [r0, #24] 667 0010 7047 bx lr 668 .cfi_endproc 669 .LFE134: 671 .section .text.HAL_GPIO_LockPin,"ax",%progbits 672 .align 1 673 .global HAL_GPIO_LockPin 674 .syntax unified 675 .thumb 676 .thumb_func 677 .fpu fpv4-sp-d16 679 HAL_GPIO_LockPin: 680 .LFB135: 447:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 448:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 449:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 450:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** 451:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @brief Locks GPIO Pins configuration registers. 452:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @note The locked registers are GPIOx_MODER, GPIOx_OTYPER, GPIOx_OSPEEDR, 453:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * GPIOx_PUPDR, GPIOx_AFRL and GPIOx_AFRH. 454:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @note The configuration of the locked GPIO pins can no longer be modified 455:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * until the next reset. 456:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param GPIOx where x can be (A..F) to select the GPIO peripheral for STM32F4 family 457:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param GPIO_Pin specifies the port bit to be locked. 458:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * This parameter can be any combination of GPIO_PIN_x where x can be (0..15). 459:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @retval None 460:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 461:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** HAL_StatusTypeDef HAL_GPIO_LockPin(GPIO_TypeDef* GPIOx, uint16_t GPIO_Pin) 462:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 681 .loc 1 462 0 682 .cfi_startproc 683 @ args = 0, pretend = 0, frame = 8 ARM GAS /tmp/ccN5SJrP.s page 22 684 @ frame_needed = 0, uses_anonymous_args = 0 685 @ link register save eliminated. 686 .LVL70: 687 0000 82B0 sub sp, sp, #8 688 .LCFI5: 689 .cfi_def_cfa_offset 8 463:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** __IO uint32_t tmp = GPIO_LCKR_LCKK; 690 .loc 1 463 0 691 0002 4FF48033 mov r3, #65536 692 0006 0193 str r3, [sp, #4] 464:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 465:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Check the parameters */ 466:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** assert_param(IS_GPIO_PIN(GPIO_Pin)); 467:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 468:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Apply lock key write sequence */ 469:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** tmp |= GPIO_Pin; 693 .loc 1 469 0 694 0008 019B ldr r3, [sp, #4] 695 000a 0B43 orrs r3, r3, r1 696 000c 0193 str r3, [sp, #4] 470:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Set LCKx bit(s): LCKK='1' + LCK[15-0] */ 471:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->LCKR = tmp; 697 .loc 1 471 0 698 000e 019B ldr r3, [sp, #4] 699 0010 C361 str r3, [r0, #28] 472:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Reset LCKx bit(s): LCKK='0' + LCK[15-0] */ 473:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->LCKR = GPIO_Pin; 700 .loc 1 473 0 701 0012 C161 str r1, [r0, #28] 474:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Set LCKx bit(s): LCKK='1' + LCK[15-0] */ 475:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** GPIOx->LCKR = tmp; 702 .loc 1 475 0 703 0014 019B ldr r3, [sp, #4] 704 0016 C361 str r3, [r0, #28] 476:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* Read LCKK bit*/ 477:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** tmp = GPIOx->LCKR; 705 .loc 1 477 0 706 0018 C369 ldr r3, [r0, #28] 707 001a 0193 str r3, [sp, #4] 478:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 479:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if((GPIOx->LCKR & GPIO_LCKR_LCKK) != RESET) 708 .loc 1 479 0 709 001c C369 ldr r3, [r0, #28] 710 001e 13F4803F tst r3, #65536 711 0022 02D1 bne .L66 480:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 481:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** return HAL_OK; 482:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 483:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** else 484:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 485:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** return HAL_ERROR; 712 .loc 1 485 0 713 0024 0120 movs r0, #1 714 .LVL71: 715 .L63: 486:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 487:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } ARM GAS /tmp/ccN5SJrP.s page 23 716 .loc 1 487 0 717 0026 02B0 add sp, sp, #8 718 .LCFI6: 719 .cfi_remember_state 720 .cfi_def_cfa_offset 0 721 @ sp needed 722 0028 7047 bx lr 723 .LVL72: 724 .L66: 725 .LCFI7: 726 .cfi_restore_state 481:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 727 .loc 1 481 0 728 002a 0020 movs r0, #0 729 .LVL73: 730 002c FBE7 b .L63 731 .cfi_endproc 732 .LFE135: 734 .section .text.HAL_GPIO_EXTI_Callback,"ax",%progbits 735 .align 1 736 .weak HAL_GPIO_EXTI_Callback 737 .syntax unified 738 .thumb 739 .thumb_func 740 .fpu fpv4-sp-d16 742 HAL_GPIO_EXTI_Callback: 743 .LFB137: 488:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 489:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** 490:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @brief This function handles EXTI interrupt request. 491:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param GPIO_Pin Specifies the pins connected EXTI line 492:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @retval None 493:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 494:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** void HAL_GPIO_EXTI_IRQHandler(uint16_t GPIO_Pin) 495:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 496:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* EXTI line interrupt detected */ 497:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** if(__HAL_GPIO_EXTI_GET_IT(GPIO_Pin) != RESET) 498:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 499:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** __HAL_GPIO_EXTI_CLEAR_IT(GPIO_Pin); 500:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** HAL_GPIO_EXTI_Callback(GPIO_Pin); 501:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 502:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 503:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 504:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /** 505:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @brief EXTI line detection callbacks. 506:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @param GPIO_Pin Specifies the pins connected EXTI line 507:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** * @retval None 508:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** */ 509:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** __weak void HAL_GPIO_EXTI_Callback(uint16_t GPIO_Pin) 510:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 744 .loc 1 510 0 745 .cfi_startproc 746 @ args = 0, pretend = 0, frame = 0 747 @ frame_needed = 0, uses_anonymous_args = 0 748 @ link register save eliminated. 749 .LVL74: 750 0000 7047 bx lr ARM GAS /tmp/ccN5SJrP.s page 24 751 .cfi_endproc 752 .LFE137: 754 .section .text.HAL_GPIO_EXTI_IRQHandler,"ax",%progbits 755 .align 1 756 .global HAL_GPIO_EXTI_IRQHandler 757 .syntax unified 758 .thumb 759 .thumb_func 760 .fpu fpv4-sp-d16 762 HAL_GPIO_EXTI_IRQHandler: 763 .LFB136: 495:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* EXTI line interrupt detected */ 764 .loc 1 495 0 765 .cfi_startproc 766 @ args = 0, pretend = 0, frame = 0 767 @ frame_needed = 0, uses_anonymous_args = 0 768 .LVL75: 495:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** /* EXTI line interrupt detected */ 769 .loc 1 495 0 770 0000 08B5 push {r3, lr} 771 .LCFI8: 772 .cfi_def_cfa_offset 8 773 .cfi_offset 3, -8 774 .cfi_offset 14, -4 497:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** { 775 .loc 1 497 0 776 0002 054B ldr r3, .L72 777 0004 5B69 ldr r3, [r3, #20] 778 0006 0342 tst r3, r0 779 0008 00D1 bne .L71 780 .LVL76: 781 .L68: 782 000a 08BD pop {r3, pc} 783 .LVL77: 784 .L71: 499:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** HAL_GPIO_EXTI_Callback(GPIO_Pin); 785 .loc 1 499 0 786 000c 024B ldr r3, .L72 787 000e 5861 str r0, [r3, #20] 500:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** } 788 .loc 1 500 0 789 0010 FFF7FEFF bl HAL_GPIO_EXTI_Callback 790 .LVL78: 502:Drivers/STM32F4xx_HAL_Driver/Src/stm32f4xx_hal_gpio.c **** 791 .loc 1 502 0 792 0014 F9E7 b .L68 793 .L73: 794 0016 00BF .align 2 795 .L72: 796 0018 003C0140 .word 1073822720 797 .cfi_endproc 798 .LFE136: 800 .text 801 .Letext0: 802 .file 2 "/usr/include/newlib/machine/_default_types.h" 803 .file 3 "/usr/include/newlib/sys/_stdint.h" 804 .file 4 "Drivers/CMSIS/Include/core_cm4.h" ARM GAS /tmp/ccN5SJrP.s page 25 805 .file 5 "Drivers/CMSIS/Device/ST/STM32F4xx/Include/system_stm32f4xx.h" 806 .file 6 "Drivers/CMSIS/Device/ST/STM32F4xx/Include/stm32f407xx.h" 807 .file 7 "Drivers/CMSIS/Device/ST/STM32F4xx/Include/stm32f4xx.h" 808 .file 8 "Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_def.h" 809 .file 9 "Drivers/STM32F4xx_HAL_Driver/Inc/stm32f4xx_hal_gpio.h" ARM GAS /tmp/ccN5SJrP.s page 26 DEFINED SYMBOLS *ABS*:0000000000000000 stm32f4xx_hal_gpio.c /tmp/ccN5SJrP.s:18 .text.HAL_GPIO_Init:0000000000000000 $t /tmp/ccN5SJrP.s:25 .text.HAL_GPIO_Init:0000000000000000 HAL_GPIO_Init /tmp/ccN5SJrP.s:355 .text.HAL_GPIO_Init:00000000000001b8 $d /tmp/ccN5SJrP.s:364 .text.HAL_GPIO_DeInit:0000000000000000 $t /tmp/ccN5SJrP.s:371 .text.HAL_GPIO_DeInit:0000000000000000 HAL_GPIO_DeInit /tmp/ccN5SJrP.s:568 .text.HAL_GPIO_DeInit:0000000000000118 $d /tmp/ccN5SJrP.s:575 .text.HAL_GPIO_ReadPin:0000000000000000 $t /tmp/ccN5SJrP.s:582 .text.HAL_GPIO_ReadPin:0000000000000000 HAL_GPIO_ReadPin /tmp/ccN5SJrP.s:609 .text.HAL_GPIO_WritePin:0000000000000000 $t /tmp/ccN5SJrP.s:616 .text.HAL_GPIO_WritePin:0000000000000000 HAL_GPIO_WritePin /tmp/ccN5SJrP.s:640 .text.HAL_GPIO_TogglePin:0000000000000000 $t /tmp/ccN5SJrP.s:647 .text.HAL_GPIO_TogglePin:0000000000000000 HAL_GPIO_TogglePin /tmp/ccN5SJrP.s:672 .text.HAL_GPIO_LockPin:0000000000000000 $t /tmp/ccN5SJrP.s:679 .text.HAL_GPIO_LockPin:0000000000000000 HAL_GPIO_LockPin /tmp/ccN5SJrP.s:735 .text.HAL_GPIO_EXTI_Callback:0000000000000000 $t /tmp/ccN5SJrP.s:742 .text.HAL_GPIO_EXTI_Callback:0000000000000000 HAL_GPIO_EXTI_Callback /tmp/ccN5SJrP.s:755 .text.HAL_GPIO_EXTI_IRQHandler:0000000000000000 $t /tmp/ccN5SJrP.s:762 .text.HAL_GPIO_EXTI_IRQHandler:0000000000000000 HAL_GPIO_EXTI_IRQHandler /tmp/ccN5SJrP.s:796 .text.HAL_GPIO_EXTI_IRQHandler:0000000000000018 $d .debug_frame:0000000000000010 $d NO UNDEFINED SYMBOLS