refactor(spi): hal driver doesn't depend on sdkconfig.h

This commit is contained in:
morris
2024-12-03 11:25:43 +08:00
parent 7eb99d7bd6
commit 1316d7b741
20 changed files with 86 additions and 76 deletions

View File

@@ -44,6 +44,9 @@ extern "C" {
#define SPI_LL_CPU_MAX_BIT_LEN (16 * 32) //Fifo len: 16 words
#define SPI_LL_MOSI_FREE_LEVEL 0 //Default level after bus initialized
#define SPI_LL_SLAVE_NEEDS_RESET_WORKAROUND 1
#define SPI_LL_SUPPORT_TIME_TUNING 1
/**
* The data structure holding calculated clock configuration. Since the
* calculation needs long time, it should be calculated during initialization and

View File

@@ -0,0 +1,21 @@
/*
* SPDX-FileCopyrightText: 2015-2024 Espressif Systems (Shanghai) CO LTD
*
* SPDX-License-Identifier: Apache-2.0
*/
#pragma once
#include_next "hal/spi_types.h"
#ifdef __cplusplus
extern "C" {
#endif
#define SPI_HOST _Pragma ("GCC warning \"SPI_HOST is deprecated in favor of SPI1_HOST\"") SPI1_HOST
#define HSPI_HOST _Pragma ("GCC warning \"HSPI_HOST is deprecated in favor of SPI2_HOST\"") SPI2_HOST
#define VSPI_HOST _Pragma ("GCC warning \"VSPI_HOST is deprecated in favor of SPI3_HOST\"") SPI3_HOST
#ifdef __cplusplus
}
#endif