examples/peripherals/spi_master/main/spi_master_example_main.c
//Send data to the ILI9341. Uses spi_device_transmit, which waits until the transfer is complete.
Send data to the ILI9341. Uses spi_device_transmit, which waits until the transfer is complete.
Send data to the ILI9341 . Uses spi_device_transmit which waits until the transfer is complete .
void ili_data(spi_device_handle_t spi, const uint8_t *data, int len) 
{
    esp_err_t ret;
    spi_transaction_t t;
    if (len==0) return;             
    memset(&t, 0, sizeof(t));       
    t.length=len*8;                 
    t.tx_buffer=data;               
    t.user=(void*)1;                
    ret=spi_device_transmit(spi, &t);  
    assert(ret==ESP_OK);            
}
void ili_data ( spi_device_handle_t spi , const uint8_t * data , int len ) { esp_err_t ret ; spi_transaction_t t ; if ( len == 0 ) return ; memset ( & t , 0 , sizeof ( t ) ) ; t . length = len * 8 ; t . tx_buffer = data ; t . user = ( void * ) 1 ; ret = spi_device_transmit ( spi , & t ) ; assert ( ret == ESP_OK ) ; }
Send data to the ILI9341.
Send data to the ILI9341 .
//no need to send anything //Zero out the transaction //Len is in bytes, transaction length is in bits. //Data //D/C needs to be set to 1 //Transmit! //Should have had no issues.