LED(Led)
Macro definition
| Macro definition | value | Annotation |
|---|---|---|
| LED_RCC | RCC_APB2Periph_GPIOB | LED pin clock |
| LED_PORT | GPIOB | LED -controlled GPIO port |
| LED_PIN | GPIO_Pin_3 | LED -controlled GPIO pin |
| LED_ON | GPIO_SetBits(LED_PORT, LED_PIN) | Open LED |
| LED_OFF | GPIO_ResetBits(LED_PORT, LED_PIN) | Turn off the LED |
| LED | PBout(3) | LED status control |
method
init_led_gpio(void)
Initialized LED’s GPIO pin
| Return value | type |
|---|---|
| none | void |
init_gpio(void)
Initialize GPIO pin
| Return value | type |
|---|---|
| 无 | void |