Replies: 1 comment
-
I think you're going to have to hook the IRQ yourself and do your work. If you don't actually call FWIW, I believe you can disable the FIFO or set the interrupt to be "FIFO not empty". There's also a FIFO-not-emptied timeout IRQ you could also look into (not sure at the BPS you're running if that hits <5ms or so). |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I have uart communication (19200 8E1) where single bytes needs to be handeled in a certain amount of time. (5ms, better 1 or 2).
Currently we handle this with ensuring loop frequency does not drop below 200Hz (5ms), but especially with IP communication this is not anymore possible.
So instead of polling the uart within loop (currently using SetPoolingMode()) I think about using uart interrupt to handle the time-crtical stuff - the normal uart handling is not suitable, be
I don't think there is a way to do that with the current SerialUART of the core.
I can think of just don't using "Serial1/2" and implementing an own driver (thaht should work right?) or maybe, when you too think that maybe usefull, adding this functionallity to the cores driver in a way the user can select the behaviour.
I can also think about polling in a timer-isr but that seems a little much overhead.
Or maybe, it could use the cores driver in polling mode and register the interrupt myself..
but while reading through sdk and rp2040 datasheet, it seems not to be possible to have an interrupt for receiving every single byte anyway.
So, the timer may be my only solution...
What are youre 2cents about this?
Thanks.
Beta Was this translation helpful? Give feedback.
All reactions