-
Notifications
You must be signed in to change notification settings - Fork 27
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
UIP Code Retransmission Timeout problem #167
Comments
Testing has gone well so I think I might go ahead with a release. In my systems I'm very pleased with how well this is working. I may have been too harsh with regard to the uip.c code. If I consider that it was really designed for HTML interaction (not MQTT), and may have been designed for environments where there was a LOT more RAM available so that entire HTML transactions fit in a single segment (not broken up into many segments as I have to do), then maybe 1 transaction per second would be acceptable. We don't have that: We must handle MQTT transactions on the order of 10's of milliseconds, and due to RAM limitations even simple webpages are transmitted as multiple segments. Enough said ... it is fixed now. I haven't been able to recreate the "connection reset" error. But I think it is still there. I will open a new issue to track that. |
Addressed in release 20230416 1116 |
While investigating Issue 159 I came back to a very old problem that I have looked into before and thought I had resolved, or at least mitigated. As code was added and the processor became busier I would see an increasing number of retransmissions of Browser packets and some Browser corruption. Adjustments to the repetition rate of the "periodic_service" call seemed to improve the situation, but those adjustments were gradually degrading MQTT performance.
I've finally determined what was going wrong, and the source of the issue is surprising. There is a problem in the "timer" functionality of the publicly sourced uip.c code. This problem is as follows:
Why is this a problem?
So you might think "well the periodic_service routine should be called at 1 second intervals to match the way the uip timer code was written".
The fix:
I've been testing for a few days now and only rarely see a retransmission timeout, typically when I deliberately connect to a weak WIFI signal. For the general case performance is greatly improved. I want to test further because I am still seeing an occasional "connection reset" error when doing code upgrades over ethernet. In that instance the upload is working fine, but the browser repaint after upload completion seems to get interrupted. That issue has also always been present and may be due to a different problem.
The text was updated successfully, but these errors were encountered: