-
Notifications
You must be signed in to change notification settings - Fork 166
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
esp-hosted-fg for esp32c2, spi master on mcu, raw throught testing is assert failed #519
Comments
Esp32-c2 is low memory chipset. If you need higher throughput might need to disable bluetooth. As much as iram to be optimised to let wifi and spi queues memory. If you increase spi queues, it would crash when wifi back pressure is high (queue loading would exhaust memory). If you notice the checksum errors, there is spi timing issues on your setup. You need to have 0 checksum errors. If ESP to host throughput is not correct, please check data ready pin interrupt is fired correctly. Handshake, data ready and reset pin are mandatory pins. Also ensure that you are using 26MHz crystal. If you are using 40MHz crystal, software may not work correctly and also would not show any reason why it would not work. Also disable mempool should be disabled by default to conserve some memory. The spi frequency can go till 40MHz. But only if you have PCB. stepwise increase could be attempted. As you get 70 KB/s, I assume your reset pin, handshake and data ready are already working. But why the ESP to host traffic is not working in that case? If you use jumper wires, ensure to have minimal length and good contact points. At the max length 10cm. All equal. 70KBps i.e. half mbps is extremely low throughput. The throughput depends minimum of two:
Wifi max iperf UDP traffic should really reach around your transport max (little less, but just there). Raw throughput in either direction should really be symmetrical speed in spi. |
@mantriyogesh thanks for your reply!
i use
my usage scenario requires both wifi and Bluetooth
i do use reset pin, handshake and data ready pin, we welded the ESP8684-MINI-1 module to the PCB, also welded the ESP32C3-MINI-1 module to the other PCB, which means i test both module as spi slave. i use the same mcu host code, and esp8684 module esp32c3 module use the same esp-hosted commit code ESP->host and host->ESP raw throughput test for ESP32C3-MINI-1 is ok. but raw throughput test for ESP8684-MINI-1 is not ok, esp32c2 crashed when i test ESP->Host raw throughput. i can successfully run the test by modify esp32c2 esp-hosted file ESP->Hostesp32c2 log
Host->ESPi also modify same file esp32c2 log
I tested http download again which http server in a LAN environment, esp32c2 http download average speed can up to 470KB/s. but sometimes esp32c2 would crash suddenly very infrequently iperf test for esp32c2 always crashed, it always assert failed: queue_next_transaction spi_slave_api.c:502 (spi_trans->rx_buffer) . I wonder if there is a stable version for esp32c2 to use? |
I had observed this issue on esp32-c6. and mempool was requesting more in peak rates than expected. But c2 was disabled for lowering code space requirement. I can deep down here and try these on latest master and fix, but might take some time. |
Checklist
Issue or Suggestion Description
Hello,
i use ESP-Hosted-FG for esp32c2, spi master is mcu
it's ok when i use it connect to wifi AP, but http download speed is very slow, about 70KB/s.
i use raw througth testing, but it always assert failed as follow:
1.i want to know how to slove this issue
2.i want to know how to increase wifi speed. i try to increase
CONFIG_ESP_SPI_RX_Q_SIZE
andCONFIG_ESP_SPI_TX_Q_SIZE
, but not work, and it always assert failed: queue_next_transaction spi_slave_api.c:502 (spi_trans->rx_buffer) or assert failed at queue_next_transaction spi_slave_api.c:722ESP-->Host raw throught testing
esp32c2 log
mcu log:
Host-->ESP raw throught testing
esp32c2 log
my environment:
Hardware:
Software:
The text was updated successfully, but these errors were encountered: