Mercurial > pub > halpp
comparison l476rg/Src/gpio.c @ 2:0c59e7a7782a
Working on GPIO and RCC
author | cin |
---|---|
date | Mon, 16 Jan 2017 11:04:47 +0300 |
parents | 32a3b1785697 |
children |
comparison
equal
deleted
inserted
replaced
1:a0b14b11ad9f | 2:0c59e7a7782a |
---|---|
67 GPIO_InitStruct.Pin = B1_Pin; | 67 GPIO_InitStruct.Pin = B1_Pin; |
68 GPIO_InitStruct.Mode = GPIO_MODE_IT_RISING; | 68 GPIO_InitStruct.Mode = GPIO_MODE_IT_RISING; |
69 GPIO_InitStruct.Pull = GPIO_NOPULL; | 69 GPIO_InitStruct.Pull = GPIO_NOPULL; |
70 HAL_GPIO_Init(B1_GPIO_Port, &GPIO_InitStruct); | 70 HAL_GPIO_Init(B1_GPIO_Port, &GPIO_InitStruct); |
71 | 71 |
72 /*Configure GPIO pin : PA5 */ | |
73 GPIO_InitStruct.Pin = GPIO_PIN_5; | |
74 GPIO_InitStruct.Mode = GPIO_MODE_OUTPUT_PP; | |
75 GPIO_InitStruct.Pull = GPIO_NOPULL; | |
76 GPIO_InitStruct.Speed = GPIO_SPEED_FREQ_LOW; | |
77 HAL_GPIO_Init(GPIOA, &GPIO_InitStruct); | |
78 | |
79 /*Configure GPIO pin Output Level */ | |
80 HAL_GPIO_WritePin(GPIOA, GPIO_PIN_5, GPIO_PIN_RESET); | |
81 | |
72 } | 82 } |
73 | 83 |
74 /* USER CODE BEGIN 2 */ | 84 /* USER CODE BEGIN 2 */ |
75 | 85 |
76 /* USER CODE END 2 */ | 86 /* USER CODE END 2 */ |