实现串口驱动,移植方便
This commit is contained in:
@ -10,14 +10,16 @@
|
||||
#ifndef LED_H
|
||||
#define LED_H
|
||||
|
||||
#include "stm32f4xx_hal.h"
|
||||
#include <stdint.h>
|
||||
#include <stddef.h>
|
||||
#include "hal_gpio.h"
|
||||
|
||||
/**
|
||||
* @brief LED configuration structure
|
||||
*/
|
||||
typedef struct {
|
||||
GPIO_TypeDef *gpio_port; /*!< GPIO port */
|
||||
uint16_t gpio_pin; /*!< GPIO pin */
|
||||
hal_gpio_port_t gpio_port; /*!< GPIO port */
|
||||
hal_gpio_pin_t gpio_pin; /*!< GPIO pin */
|
||||
} led_config_t;
|
||||
|
||||
/**
|
||||
|
||||
Reference in New Issue
Block a user