mirror of
https://github.com/sle118/squeezelite-esp32.git
synced 2025-12-06 11:36:59 +03:00
add SPI display's CS pre/post
This commit is contained in:
@@ -51,7 +51,10 @@ bool GDS_SPIAttachDevice( struct GDS_Device* Device, int Width, int Height, int
|
||||
SPIDeviceConfig.spics_io_num = CSPin;
|
||||
SPIDeviceConfig.queue_size = 1;
|
||||
SPIDeviceConfig.flags = SPI_DEVICE_NO_DUMMY;
|
||||
|
||||
SPIDeviceConfig.cs_ena_pretrans = Device->CS_pre;
|
||||
SPIDeviceConfig.cs_ena_posttrans = Device->CS_post;
|
||||
SPIDeviceConfig.mode = Device->SPI_mode;
|
||||
|
||||
ESP_ERROR_CHECK_NONFATAL( spi_bus_add_device( SPIHost, &SPIDeviceConfig, &SPIDevice ), return false );
|
||||
|
||||
Device->WriteCommand = SPIDefaultWriteCommand;
|
||||
|
||||
Reference in New Issue
Block a user