mirror of
https://github.com/espressif/esp-idf.git
synced 2025-08-03 12:44:33 +02:00
driver test: disable the spi master performance test when psram is used
This commit is contained in:
committed by
bot
parent
712aa3daa7
commit
69059ea2cc
@@ -1020,7 +1020,9 @@ TEST_CASE("spi_speed","[spi]")
|
|||||||
for (int i = 0; i < TEST_TIMES; i++) {
|
for (int i = 0; i < TEST_TIMES; i++) {
|
||||||
ESP_LOGI(TAG, "%.2lf", GET_US_BY_CCOUNT(t_flight_sorted[i]));
|
ESP_LOGI(TAG, "%.2lf", GET_US_BY_CCOUNT(t_flight_sorted[i]));
|
||||||
}
|
}
|
||||||
|
#ifndef CONFIG_SPIRAM_SUPPORT
|
||||||
TEST_PERFORMANCE_LESS_THAN(SPI_PER_TRANS_NO_POLLING, "%d us", (int)GET_US_BY_CCOUNT(t_flight_sorted[(TEST_TIMES+1)/2]));
|
TEST_PERFORMANCE_LESS_THAN(SPI_PER_TRANS_NO_POLLING, "%d us", (int)GET_US_BY_CCOUNT(t_flight_sorted[(TEST_TIMES+1)/2]));
|
||||||
|
#endif
|
||||||
|
|
||||||
//acquire the bus to send polling transactions faster
|
//acquire the bus to send polling transactions faster
|
||||||
ret = spi_device_acquire_bus(spi, portMAX_DELAY);
|
ret = spi_device_acquire_bus(spi, portMAX_DELAY);
|
||||||
@@ -1035,7 +1037,9 @@ TEST_CASE("spi_speed","[spi]")
|
|||||||
for (int i = 0; i < TEST_TIMES; i++) {
|
for (int i = 0; i < TEST_TIMES; i++) {
|
||||||
ESP_LOGI(TAG, "%.2lf", GET_US_BY_CCOUNT(t_flight_sorted[i]));
|
ESP_LOGI(TAG, "%.2lf", GET_US_BY_CCOUNT(t_flight_sorted[i]));
|
||||||
}
|
}
|
||||||
|
#ifndef CONFIG_SPIRAM_SUPPORT
|
||||||
TEST_PERFORMANCE_LESS_THAN(SPI_PER_TRANS_POLLING, "%d us", (int)GET_US_BY_CCOUNT(t_flight_sorted[(TEST_TIMES+1)/2]));
|
TEST_PERFORMANCE_LESS_THAN(SPI_PER_TRANS_POLLING, "%d us", (int)GET_US_BY_CCOUNT(t_flight_sorted[(TEST_TIMES+1)/2]));
|
||||||
|
#endif
|
||||||
|
|
||||||
//release the bus
|
//release the bus
|
||||||
spi_device_release_bus(spi);
|
spi_device_release_bus(spi);
|
||||||
@@ -1053,7 +1057,9 @@ TEST_CASE("spi_speed","[spi]")
|
|||||||
for (int i = 0; i < TEST_TIMES; i++) {
|
for (int i = 0; i < TEST_TIMES; i++) {
|
||||||
ESP_LOGI(TAG, "%.2lf", GET_US_BY_CCOUNT(t_flight_sorted[i]));
|
ESP_LOGI(TAG, "%.2lf", GET_US_BY_CCOUNT(t_flight_sorted[i]));
|
||||||
}
|
}
|
||||||
|
#ifndef CONFIG_SPIRAM_SUPPORT
|
||||||
TEST_PERFORMANCE_LESS_THAN(SPI_PER_TRANS_NO_POLLING_NO_DMA, "%d us", (int)GET_US_BY_CCOUNT(t_flight_sorted[(TEST_TIMES+1)/2]));
|
TEST_PERFORMANCE_LESS_THAN(SPI_PER_TRANS_NO_POLLING_NO_DMA, "%d us", (int)GET_US_BY_CCOUNT(t_flight_sorted[(TEST_TIMES+1)/2]));
|
||||||
|
#endif
|
||||||
|
|
||||||
//acquire the bus to send polling transactions faster
|
//acquire the bus to send polling transactions faster
|
||||||
ret = spi_device_acquire_bus(spi, portMAX_DELAY);
|
ret = spi_device_acquire_bus(spi, portMAX_DELAY);
|
||||||
@@ -1067,7 +1073,9 @@ TEST_CASE("spi_speed","[spi]")
|
|||||||
for (int i = 0; i < TEST_TIMES; i++) {
|
for (int i = 0; i < TEST_TIMES; i++) {
|
||||||
ESP_LOGI(TAG, "%.2lf", GET_US_BY_CCOUNT(t_flight_sorted[i]));
|
ESP_LOGI(TAG, "%.2lf", GET_US_BY_CCOUNT(t_flight_sorted[i]));
|
||||||
}
|
}
|
||||||
|
#ifndef CONFIG_SPIRAM_SUPPORT
|
||||||
TEST_PERFORMANCE_LESS_THAN(SPI_PER_TRANS_POLLING_NO_DMA, "%d us", (int)GET_US_BY_CCOUNT(t_flight_sorted[(TEST_TIMES+1)/2]));
|
TEST_PERFORMANCE_LESS_THAN(SPI_PER_TRANS_POLLING_NO_DMA, "%d us", (int)GET_US_BY_CCOUNT(t_flight_sorted[(TEST_TIMES+1)/2]));
|
||||||
|
#endif
|
||||||
|
|
||||||
//release the bus
|
//release the bus
|
||||||
spi_device_release_bus(spi);
|
spi_device_release_bus(spi);
|
||||||
|
Reference in New Issue
Block a user