-
Notifications
You must be signed in to change notification settings - Fork 180
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
NG sdio driver is not stable #362
Comments
It is very important that you use exact same code (git commit) at both ESP and host. Can you please confirm the git commit at both, ESP and Host? |
The image attachment is failed, somehow. In your #362 (comment), the ESP log shows 1.0.1 and host log shows ESP was detected to be 1.0.2, which seems incorrect. Can you try both ESP and host on master? |
In the earlier logs the system state looks not even reached to stable data path state |
Both 1.0.2,logs like this: |
As we can see, it was normal at the beginning, then send data error, and sdio card removed |
So what am I missing with porting to make system stable?? |
To seperate, there are three blocks in system,
Is this a new yocto port you had been trying? Transport related issues could be ruled out when running Transport test in tx and rx direction. |
I am trying iMX6UL yocto, and I think others have succeed to port on it in #137 . I run test process iperf3, Is there any difference between running Transport test and running it? |
Yes iperf involves TCP/IP, wifi, and transport. With raw throughout test above we would get early indication if there is any wrong before wifi & tcp-ip actually coming into picture. Raw throughout also would let us know the max capability of transport as such (iperf max ceiling). If this is new port on imx you might also would need to find the dependencies of wpa supplicant. Those recipies also would be needed to include. For example rfkill, etc. I can dig which software we needed for imx8mm work on yocto, only if this is your new port. If this is not a new port and it has already worked at least one time with all iperf rx and tx, we would need to see.this from different angle then. Yocto is complicated system and getting softwares needed to be running is pre-requisite for ESP-Hosted to be running. But just in your case we also have imx8mm running fine. As it might be similar to imx6 we can just provide extra suggestions as we are able to, to get your yocto port up and running fast. Also can you limit the sdio clock to say 5M? esp-hosted/esp_hosted_fg/host/linux/host_driver/esp32/sdio/esp_sdio.c Lines 744 to 748 in 3c3fc10
|
I have tried to modify DTS, lower sdio clock to 5M, like this: &usdhc2 { Is it the same effect as modifying esp_sdio.c |
It may work. You can confirm by running
With this change, raw throughout if works fine, we can move to higher layer. On another note, I see the AP provided IP address, This is network address change (first one is 192.168.5.x other is 192.168.1.x). |
Also, is it possible to test with master at ESP and host? @kapilkedawat ,
|
192.168.1.x, 192.168.5.x, They belong to the front and back level routers, ignore this. |
I have cross compiled the sdio driver with enable TEST_RAW_TP, but how to start raw test after loading drive by exec "insmod esp32_sdio.ko resetpin=44"? |
on latest master, see esp-hosted/esp_hosted_ng/host/rpi_init.sh Line 66 in 3c3fc10
|
root@myd-y6ull14x14: |
rst:0x1 (POWERON_RESET),boot:0x3f (SPI_FAST_FLASH_BOOT) I (1050) FW_SDIO_SLAVE: Using SDIO interface I (2166) wifi:mode : sta (94:b5:55:0b:c2:90) I (2188) FW_MAIN: Get MAC command I (2406) FW_MAIN: Unsupported cmd[0x14] received |
This is okay as long as ESP is reset consistently |
Raw transport test at 50M HZ ,it always run error. By lower the clock, it may be OK, but when running iperf test, it also go wrong. Is this problem related to sdio communication ? |
This looks to be fine. Is the ESP log okay? |
#362 (comment) |
|
Great! Thanks for the picture.
|
Hello @hustzju , So does the lower SDIO clock frequency, like 5M, works fine for iperf3 etc (basically, iperf-ttcp-wifi-transport) in rx and tx? If no, stop here and let us know that first! Only if 5M works without issues, Can you please try below and get both ESP and Host logs with higher frequency
|
It also goes wrong at 5M clock when running iperf3, only run longer then 50M. 50M go wrong immediately. |
I assume, you meant 'comment' instead of 'uncomment' ? Can you please make sure if SDIO GPIOs are not getting re-used by any other peripherals in your system? Worst case, can you please try 1-bit sdio mode? |
What is the data rate you see when 5M iperf3 is run with TCP? If your raw throughput was around 14Mbps, it could reach 8-12Mbps? I am trying to understand if & why sdio lines are behaving unstable. You can also enable the SDIO checksum at both sides, to check the validity of the packets. |
any updates? |
We have successfully implemented the SDIO solution On my imx6ul board, and test is OK.
but when produce first batch of circuit boards with new Wi-Fi mode, A new problem arises.
esp32 driver could be loaded correctly,and connecting wifi works well,but When transmitting large amounts of data,
SDIO wifi driver is not stable, sdio send data error and time out always occur,and then
we receive the log "mmc1: card 0001 removed".
host log:
host_log.txt
esp32 log:
esp32_output.log.txt
please give me some advice, thanks.
The text was updated successfully, but these errors were encountered: