[bsp][nxp] mcxn947基础上去除多余修改:
This commit is contained in:
parent
42e01a80a0
commit
447a10c964
|
@ -80,10 +80,36 @@ static struct lpc_spi lpc_obj[] =
|
|||
#endif
|
||||
};
|
||||
|
||||
static rt_err_t spi_configure(struct rt_spi_device *device, struct rt_spi_configuration *cfg)
|
||||
|
||||
struct lpc_sw_spi_cs
|
||||
{
|
||||
rt_uint32_t pin;
|
||||
};
|
||||
|
||||
|
||||
rt_err_t rt_hw_spi_device_attach(const char *bus_name, const char *device_name, rt_uint32_t pin)
|
||||
{
|
||||
rt_err_t ret = RT_EOK;
|
||||
|
||||
struct rt_spi_device *spi_device = (struct rt_spi_device *)rt_malloc(sizeof(struct rt_spi_device));
|
||||
struct lpc_sw_spi_cs *cs_pin = (struct lpc_sw_spi_cs *)rt_malloc(sizeof(struct lpc_sw_spi_cs));
|
||||
|
||||
cs_pin->pin = pin;
|
||||
rt_pin_mode(pin, PIN_MODE_OUTPUT);
|
||||
rt_pin_write(pin, PIN_HIGH);
|
||||
|
||||
ret = rt_spi_bus_attach_device(spi_device, device_name, bus_name, (void *)cs_pin);
|
||||
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
||||
static rt_err_t spi_configure(struct rt_spi_device *device, struct rt_spi_configuration *cfg)
|
||||
{
|
||||
rt_err_t ret = RT_EOK;
|
||||
// struct lpc_spi *spi = RT_NULL;
|
||||
// spi = (struct lpc_spi *)(device->bus->parent.user_data);
|
||||
// ret = lpc_spi_init(spi->SPIx, cfg);
|
||||
return ret;
|
||||
}
|
||||
|
||||
|
|
|
@ -140,7 +140,7 @@ CONFIG_RT_SERIAL_RB_BUFSZ=64
|
|||
# CONFIG_RT_USING_I2C is not set
|
||||
# CONFIG_RT_USING_PHY is not set
|
||||
# CONFIG_RT_USING_ADC is not set
|
||||
CONFIG_RT_USING_DAC=y
|
||||
# CONFIG_RT_USING_DAC is not set
|
||||
# CONFIG_RT_USING_NULL is not set
|
||||
# CONFIG_RT_USING_ZERO is not set
|
||||
# CONFIG_RT_USING_RANDOM is not set
|
||||
|
@ -150,18 +150,7 @@ CONFIG_RT_USING_DAC=y
|
|||
# CONFIG_RT_USING_PM is not set
|
||||
# CONFIG_RT_USING_RTC is not set
|
||||
# CONFIG_RT_USING_SDIO is not set
|
||||
CONFIG_RT_USING_SPI=y
|
||||
# CONFIG_RT_USING_SPI_BITOPS is not set
|
||||
CONFIG_RT_USING_QSPI=y
|
||||
# CONFIG_RT_USING_SPI_MSD is not set
|
||||
CONFIG_RT_USING_SFUD=y
|
||||
CONFIG_RT_SFUD_USING_SFDP=y
|
||||
CONFIG_RT_SFUD_USING_FLASH_INFO_TABLE=y
|
||||
CONFIG_RT_SFUD_USING_QSPI=y
|
||||
CONFIG_RT_SFUD_SPI_MAX_HZ=50000000
|
||||
CONFIG_RT_DEBUG_SFUD=y
|
||||
# CONFIG_RT_USING_ENC28J60 is not set
|
||||
# CONFIG_RT_USING_SPI_WIFI is not set
|
||||
# CONFIG_RT_USING_SPI is not set
|
||||
# CONFIG_RT_USING_WDT is not set
|
||||
# CONFIG_RT_USING_AUDIO is not set
|
||||
# CONFIG_RT_USING_SENSOR is not set
|
||||
|
@ -1121,17 +1110,14 @@ CONFIG_SOC_MCXN947=y
|
|||
#
|
||||
# On-chip Peripheral Drivers
|
||||
#
|
||||
CONFIG_BSP_USING_DMA=y
|
||||
# CONFIG_BSP_USING_DMA is not set
|
||||
CONFIG_BSP_USING_PIN=y
|
||||
CONFIG_BSP_USING_UART=y
|
||||
CONFIG_BSP_USING_UART4=y
|
||||
CONFIG_BSP_USING_UART5=y
|
||||
CONFIG_BSP_USING_UART2=y
|
||||
# CONFIG_BSP_USING_I2C is not set
|
||||
CONFIG_BSP_USING_SPI=y
|
||||
CONFIG_BSP_USING_SPI3=y
|
||||
CONFIG_BSP_USING_SPI7=y
|
||||
CONFIG_BSP_USING_SPI8=y
|
||||
# CONFIG_BSP_USING_SPI is not set
|
||||
# CONFIG_BSP_USING_ADC is not set
|
||||
# CONFIG_BSP_USING_DAC is not set
|
||||
# CONFIG_BSP_USING_SDIO is not set
|
||||
|
|
|
@ -64,7 +64,7 @@ void BOARD_InitBootPins(void)
|
|||
// PORT1->PCR[4] = PORT_PCR_MUX(2) | PORT_PCR_PS(0) | PORT_PCR_PE(0) | PORT_PCR_IBE(1); /* FC3_4 D[3] */
|
||||
// PORT1->PCR[5] = PORT_PCR_MUX(2) | PORT_PCR_PS(0) | PORT_PCR_PE(0) | PORT_PCR_IBE(1); /* FC3_5 D[2] */
|
||||
|
||||
/* QSPI */
|
||||
/* SPI */
|
||||
PORT3->PCR[8] = PORT_PCR_MUX(3) | PORT_PCR_PS(0) | PORT_PCR_PE(0) | PORT_PCR_IBE(1); /* FC7_P0, MOSI */
|
||||
PORT3->PCR[9] = PORT_PCR_MUX(3) | PORT_PCR_PS(0) | PORT_PCR_PE(0) | PORT_PCR_IBE(1); /* FC7_P2, MISO */
|
||||
PORT3->PCR[7] = PORT_PCR_MUX(3) | PORT_PCR_PS(0) | PORT_PCR_PE(0) | PORT_PCR_IBE(1); /* FC7_P1, CLK */
|
||||
|
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
@ -91,15 +91,6 @@
|
|||
#define RT_USING_SERIAL_V1
|
||||
#define RT_SERIAL_USING_DMA
|
||||
#define RT_SERIAL_RB_BUFSZ 64
|
||||
#define RT_USING_DAC
|
||||
#define RT_USING_SPI
|
||||
#define RT_USING_QSPI
|
||||
#define RT_USING_SFUD
|
||||
#define RT_SFUD_USING_SFDP
|
||||
#define RT_SFUD_USING_FLASH_INFO_TABLE
|
||||
#define RT_SFUD_USING_QSPI
|
||||
#define RT_SFUD_SPI_MAX_HZ 50000000
|
||||
#define RT_DEBUG_SFUD
|
||||
#define RT_USING_PIN
|
||||
#define RT_USING_HWTIMER
|
||||
|
||||
|
@ -290,16 +281,11 @@
|
|||
|
||||
/* On-chip Peripheral Drivers */
|
||||
|
||||
#define BSP_USING_DMA
|
||||
#define BSP_USING_PIN
|
||||
#define BSP_USING_UART
|
||||
#define BSP_USING_UART4
|
||||
#define BSP_USING_UART5
|
||||
#define BSP_USING_UART2
|
||||
#define BSP_USING_SPI
|
||||
#define BSP_USING_SPI3
|
||||
#define BSP_USING_SPI7
|
||||
#define BSP_USING_SPI8
|
||||
|
||||
/* Board extended module Drivers */
|
||||
|
||||
|
|
Loading…
Reference in New Issue