SPI: change the different soc's spi defintion location and fix the bug that wrong dummy cycle under quad spi mode

This commit is contained in:
gaoxu
2022-09-15 16:03:54 +08:00
parent 6075806400
commit 8095142796
9 changed files with 405 additions and 145 deletions

View File

@@ -30,6 +30,7 @@
#include <esp_types.h>
#include "hal/hal_defs.h"
#include <stdlib.h> //for abs()
#include "hal/spi_types.h"
#ifdef __cplusplus
extern "C" {
@@ -1069,6 +1070,29 @@ static inline void spi_dma_ll_enable_out_auto_wrback(spi_dma_dev_t *dma_out, uin
//does not configure it in ESP32
}
/**
* Get the spi communication command
*
* @param cmd_t Base command value
* @param line_mode Line mode of SPI transaction phases: CMD, ADDR, DOUT/DIN.
*/
static inline uint16_t spi_ll_get_slave_hd_command(spi_command_t cmd_t, spi_line_mode_t line_mode)
{
//This is not supported in esp32
return 0;
}
/**
* Get the dummy bits
*
* @param line_mode Line mode of SPI transaction phases: CMD, ADDR, DOUT/DIN.
*/
static inline int spi_ll_get_slave_hd_dummy_bits(spi_line_mode_t line_mode)
{
//This is not supported in esp32
return 0;
}
#undef SPI_LL_RST_MASK
#undef SPI_LL_UNUSED_INT_MASK