Notice. New forum software under development. It's going to miss a few functions and look a bit ugly for a while, but I'm working on it full time now as the old forum was too unstable. Couple days, all good. If you notice any issues, please contact me.
|
Forum Index : Microcontroller and PC projects : WebMite stability
Author | Message | ||||
matherp Guru Joined: 11/12/2012 Location: United KingdomPosts: 9122 |
The stability of the WebMite code is a continuing concern. Your reports of issues are of course welcome but make little sense in terms of the code itself. For example RC4 may be reported as more or less stable than RC3 when from my perspective the web code hasn't changed at all. The only difference is a re-compile or the addition of totally unrelated code. The PicoW sdk makes extensive use of the C heap (malloc/free) whereas MMBasic has its own heap mechanism written by Geoff which is simple and completely robust. It also has the advantage that it is initialised each time a program is run so any memory leaks will never have an effect outside of the run of the single current program and are therefore easy to diagnose and fix. In order to support TLS on the Webmite I have had to allocate 36Kbytes of our precious RAM to the heap and yet (as evidenced by a recent user post) even that can be exceeded. Moreover, every Web activity in the sdk also uses the C heap and there is no way to clean that up other than a reboot so any ongoing fragmentation of the heap may eventually lead to a crash. In order to simplify things going forward I propose to remove TLS functionality. This was always of limited use as many sites require SSL over TLS (not practical to implement give the resource requirements) or use an unsupported TLS coding. This will free up a lot of RAM some of which I can return to MMbasic use as well as ensuring the C heap is plenty big enough for the less demanding web requirements. My suspicion is that many of the faults seen may be a result of the huge amount of detritus that floats around on our networks that the pico code either cannot handle or that cause resource usage that exceeds availability. Browsers can also be too clever, preemptively making requests before an actual user transaction. Historically, I've tested with Edge, Chrome and Firefox and they all do different things in terms of timing and requests made - not helpful Thoughts and comments on removing TLS and anything else welcome |
||||
Geoffg Guru Joined: 06/06/2011 Location: AustraliaPosts: 3194 |
I very much agree with removing TLS. I have tried using it and the problem is that most websites also want SSL... so, no go. The basic functionality of the WebMite is fantastic and I cannot see the benefits of hindering it with something with limited functionality. This is a microcontroller and you cannot have everything. BTW commiserations with being forced to use malloc() - it is fine for big systems with lots of RAM, not so good for small microcontrollers. Geoff Geoff Graham - http://geoffg.net |
||||
TassyJim Guru Joined: 07/08/2011 Location: AustraliaPosts: 6100 |
I agree with making things simpler by removing TLS. I keep trying different ideas to try and track down the issues but when things can run perfectly for 3 days then a couple of lockups it is slow work. My latest effort is to shift the test system into my inner lan which is a lot quieter and uses a different router/accesses point. Thanks for all the effort which must take you away from more interesting challenges. Jim VK7JH MMedit MMBasic Help |
||||
matherp Guru Joined: 11/12/2012 Location: United KingdomPosts: 9122 |
Here is a version with TLS CLIENT functionality removed and the memory re-allocated. Loading it will kill your A: drive as well as resetting all options. Please give it a go and let me know if you see any issues. I've had it running Geoff's watering controller for a few hours now with no issues. The one area that has changed is MQTT as it allowed port 8883 and TLS and now doesn't so that will need properly testing which I haven't had time to do thus far. PicoMiteWeb.zip |
||||
Geoffg Guru Joined: 06/06/2011 Location: AustraliaPosts: 3194 |
I have two systems running in parallel with the same BASIC program. One is B10 which seems to fall over roughly every two days while the other (RC4) has been running fine for a week. So you seem to be on track to fix the issue. I will leave these untouched for another week just to evaluate the RC4 version. Geoff Geoff Graham - http://geoffg.net |
||||
pwillard Senior Member Joined: 07/06/2022 Location: United StatesPosts: 292 |
Well, my experience with TLS was not great and I fell back to using a non-Tls API again, so losing it makes sense to me. I personally can't justify the "pain" of using TLS in a home network and if there remain to be non-TLS APIs, all is well in my world. |
||||
Mixtel90 Guru Joined: 05/10/2019 Location: United KingdomPosts: 6798 |
I see Microsoft are due to discontinue TLS 1.0 and 1.1 in Windows before long. Perhaps there's something they aren't telling people? :) Mick Zilog Inside! nascom.info for Nascom & Gemini Preliminary MMBasic docs & my PCB designs |
||||
karlelch Senior Member Joined: 30/10/2014 Location: GermanyPosts: 172 |
Peter, thanks for your efforts to track down the WebMite stability issues. I uploaded your TLS-free firmware and will test it in the coming days. I am using MQTT and so far, my application has not complained ... I report back. Best Thomas |
||||
Print this page |