Page 1 of 1

SPI setup via AT commands

Posted: Wed Dec 17, 2025 9:36 pm
by JuanFrancisco
Hi,
I'm running into an issue with the ESP AT firmware on an ESP32, using AT firmware v3.4.0.0.
I'm testing the DRVSPI AT commands and I'm seeing a behavior that I can't explain. As you know, the SPI-related commands available in the stack are:
- AT+DRVSPICONFGPIO
- AT+DRVSPIINIT
- AT+DRVSPIREAD
- AT+DRVSPIWRITE

The issue is the following:
- AT+DRVSPICONFGPIO` always returns OK
- AT+DRVSPIINIT always returns ERROR

This happens regardless of:
- SPI mode
- Clock frequency
- Address and command bits
- GPIO selection using AT+DRVSPICONFGPIO

So, GPIO assignment seems to work correctly, but SPI initialization itself never succeeds.
Any clarification on the intended usage of DRVSPI would be appreciated :)

Thanks!
Juan

PS: the same behavior was reported some time ago: viewtopic.php?t=29580

Re: SPI setup via AT commands

Posted: Mon Jan 12, 2026 12:44 pm
by esp-at
@JuanFrancisco Hi, could you please compile the AT firmware in your PC and see what happen from AT log port (GPIO1).

Use latest master branch and enable more logs to see what happened:
https://docs.espressif.com/projects/esp ... _logs.html

python build.py menuconfig > Component config > Log output > Debug (Or above Info)
python build.py menuconfig > Component config > AT > Enable ESP-AT Debug
python build.py menuconfig > Component config > AT > Enable ESP-AT Debug > Logging the data sent from AT to MCU (AT ---> MCU)
python build.py menuconfig > Component config > AT > Enable ESP-AT Debug > Logging the data sent from AT to MCU (AT ---> MCU) > The maximum length of the data sent from AT to MCU to be logged > 8192
python build.py menuconfig > Component config > AT > Enable ESP-AT Debug > Logging the data received by AT from MCU (AT <---- MCU)
python build.py menuconfig > Component config > AT > Enable ESP-AT Debug > Logging the data received by AT from MCU (AT <---- MCU) > The maximum length of the data received by AT from MCU to be logged > 8192

The AT log port output should give more logs.