-
Notifications
You must be signed in to change notification settings - Fork 1.1k
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
[BUG] CoRoutine tick overflow #1163
Comments
Why do you need the constant |
half a unsigned long 0x7FFFFFFF, I use limits in cpp , but this is the simplest way in C, maybe ((portTickType)-1)/2 would be more elegant for sure |
Ah...that's what I was afraid of. FreeRTOS currently supports 16-bit and 32-bit native systems so I don't believe hardcoding the numerical value will work. |
Also - can you provide details on what case fails. Looking at the code, it looks like overflow is gracefully handled. For example, lets say that we're on a 32 bit system and that This is the correct, expected behavior. |
As for the later check that you also modified, the current code looks correct. The Imagine your In the case of an overflow, say |
If Tick overflows, coroutine stop working
corrected routine.c in repo https://github.com/bffr05/FreeRTOS-Kernel
Cheers
The text was updated successfully, but these errors were encountered: