3-Wire-SPI on ESP32-WROOM-32UE
3-Wire-SPI on ESP32-WROOM-32UE
How to perform 3-Wire-SPI communication on ESP32-WROOM-32UE ? We're using AD7091R sensor.
Re: 3-Wire-SPI on ESP32-WROOM-32UE
Just dont use the 4'th wire
Re: 3-Wire-SPI on ESP32-WROOM-32UE
Unfortunately, very less number of contents are available in this topic. I could only find this.
https://electronics.stackexchange.com/q ... i-to-esp32
https://electronics.stackexchange.com/q ... i-to-esp32
Re: 3-Wire-SPI on ESP32-WROOM-32UE
When you initialise your SPI bus. just set the MOSI to -1.
Code: Select all
// spi_bus_config_t
buscfg.sclk_io_num = PIN_NUM_CLK; // GPIO pin for Spi CLocK signal, or -1 if not used.
buscfg.mosi_io_num = -1; // GPIO pin for Master Out Slave In (=spi_d) signal, or -1 if not used.
buscfg.miso_io_num = PIN_NUM_MISO; // GPIO pin for Master In Slave Out (=spi_q) signal, or -1 if not used.O
buscfg.quadwp_io_num = -1; // GPIO pin for WP (Write Protect) signal which is used as D2 in 4-bit
communication modes, or -1 if not used.
buscfg.quadhd_io_num = -1; // GPIO pin for HD (HolD) signal which is used as D3 in 4-bit communication
modes, or -1 if not used.
buscfg.max_transfer_sz = 0; // Maximum transfer size, in bytes. Defaults to 4094 if 0.
ESP_ERROR_CHECK(spi_bus_initialize(HSPI_HOST, &buscfg, 1));
Who is online
Users browsing this forum: Baidu [Spider], Bing [Bot] and 140 guests