-
Notifications
You must be signed in to change notification settings - Fork 63
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
Unused static variable in ReceiveData() #12
Comments
Hi, thanks for pointing this out! Looks like some leftover code - we'll take a look at this. |
I am closing in on the original problem I am investigating - there is a race condition in The CMSIS-Driver/WiFi/ESP32/ESP32_Serial.c Lines 59 to 60 in b2a6e81
The COM driver uses DMA to receive serial data into the CMSIS-Driver/WiFi/ESP32/ESP32_Serial.c Line 269 in b2a6e81
Then the DMA fills the buffer, CMSIS-Driver/WiFi/ESP32/ESP32_Serial.c Line 407 in b2a6e81
In CMSIS-Driver/WiFi/ESP32/ESP32_Serial.c Lines 344 to 345 in b2a6e81
What I am seeing is that I've confirmed that if rxc + GetRxCount() is less than rxi, if you immediately re-read the values then rxc changes. Here's the quick fix, but there must be something better. Also I don't know what happens when the 32 bit values finally roll over.
|
I'm not sure where this code repository is, but found another bug. MCI_STM32F7xx.c V1.10
Always will fail.
Is probably the intention. |
Many thanks again for the analysis and further investigation! Second one, MCI driver implementation: MCI_STM32F7xx.c and its code are not part of any public repository, so is also good that you reported it in this context. I checked the MCI driver code and the problem was already found but the STM32F7xx DFP was not yet released. We'll need to check the release schedule but till then you already have working solution. |
There is a static variable
n_prev
in the ESP32 functionReceiveData
which is assigned but not used for anything.CMSIS-Driver/WiFi/ESP32/ESP32.c
Line 574 in b2a6e81
CMSIS-Driver/WiFi/ESP32/ESP32.c
Lines 588 to 591 in b2a6e81
The text was updated successfully, but these errors were encountered: