[bsp] Add pin equipment for stm32f429-apollo

This commit is contained in:
SummerGift 2018-03-28 15:15:09 +08:00
parent 883290ddef
commit f596c5ad88
4 changed files with 1915 additions and 1 deletions

View File

@ -29,7 +29,7 @@ if GetDepend(['RT_USING_I2C']) or GetDepend('RT_USING_LWIP'):
# add gpio drivers.
if GetDepend('RT_USING_PIN'):
src += ['gpio.c']
src += ['drv_gpio.c']
# add spi drivers.
if GetDepend('RT_USING_SPI'):

View File

@ -77,6 +77,8 @@ void rt_hw_board_init(void);
#define FINSH_DEVICE_NAME CONSOLE_DEVICE
#define STM32F4xx_PIN_NUMBERS 176
void Error_Handler(void);
#endif

File diff suppressed because it is too large Load Diff

View File

@ -0,0 +1,30 @@
/*
* File : drv_gpio.h
* This file is part of RT-Thread RTOS
* COPYRIGHT (C) 2015, RT-Thread Development Team
*
* The license and distribution terms for this file may be
* found in the file LICENSE in this distribution or at
* http://www.rt-thread.org/license/LICENSE
*
* Change Logs:
* Date Author Notes
* 2015-01-05 Bernard the first version
*/
#ifndef GPIO_H__
#define GPIO_H__
struct stm32_hw_pin_userdata
{
int pin;
uint32_t mode;
};
#define PIN_USERDATA_END {-1,0}
extern struct stm32_hw_pin_userdata stm32_pins[];
int rt_hw_pin_init(void);
#endif