add 10KB of RAM to your esp8266 #5244
Replies: 1 comment
-
Posted at 2015-11-24 by tve Well, I can now run 5 concurrent HTTP GET requests and not crash, that's progress :-). I can also run 100 successive GET requests and they work. Trying to run 1000 has one fail at some point, but doesn't crash. We have progress but we ain't there quite yet... Posted at 2015-11-24 by @gfwilliams Wow, that's definitely looking a lot better! So presumably that means there are no memory leaks when using HTTP GET then - you only have 1000 vars so even if it lost 1 each time it should have failed if there was a problem :) Posted at 2015-11-24 by JumJum Tested the flash-strings version. Everything is running fine. BTW, there was a discussion about large(1400 ?) and small(576 ?) buffers. Which one is used in your build ?
Posted at 2015-11-24 by Ollie @tve great stuff! Posted at 2015-11-24 by JumJum Some more testing :-)
Posted at 2015-11-24 by Kolban Would it be possible to place builds here: https://github.com/espruino/EspruinoBuilds/tree/master/ESP8266 I'm thinking that as long as a build is consistent with what is in Github, then we should be good. Later ... build placed at ... https://github.com/espruino/EspruinoBuilds/tree/master/ESP8266 Posted at 2015-11-25 by tve
I'm using the 536 MSS libwip, i.e., TCP packets have 536 bytes max. Due to the way the Espruino sockets library and the esp8266 SDK interact there are a number of buffering issues so I think that a smaller MSS at the expense of some top-speed is worthwhile. We will be trading some of the RAM gained in for extra features and perhaps more JsVars, so I'm sure it will get tight again... Posted at 2015-11-25 by @gfwilliams Yes, 536 MSS is definitely the way to go! As things currently stand, Espruino's never going to fill up even those packets. As far as builds go, I'll include the binary in the download bundle and on the Espruino site itself. I still need to polish http://www.espruino.com/binaries/travis/ but when that is done with symlinks to the latest build I think we should put builds there and retire EspruinoBuilds - so it's then the same as every other board. I looked at doing GitHub uploads from travis, but as @tve said it's a bit of an abuse of GitHub, and it also seemed a bit awkward to do. Posted at 2015-11-26 by tve Cool, can't wait. In the end, for me the litmus test is to be able to look at a message like http://forum.espruino.com/conversations/278147/#comment12647395 and see something like Posted at 2015-11-26 by @gfwilliams Yes, maybe it's actually better for us to put the commit hash directly in the Espruino startup screen. After all, it's reported in Posted at 2015-11-26 by @gfwilliams And the latest builds are now at: http://www.espruino.com/binaries/travis/master/ Note: ironically Espruino and Pico builds won't work out of the box, because when flashed to the board they need offsetting by the bootloader size (16384 on the Pico, and 10240 on the Espruino board). Posted at 2015-11-27 by Kolban @gfwilliams Can you clarify the last post? Are you saying that for ESP8266 users, the latest build as build by Travis can now be downloaded at the URL provided above. Does this mean that should now be where we point end users to obtain the latest build? If that is the case, then we probably need to shutdown EspruinoBuilds to reduce the sources of confusion. Posted at 2015-11-27 by @gfwilliams Yes, that's correct - at that link there will be the absolute latest build of Espruino available. However that may not be what everyone wants, as it could be a bit hit or miss whether it works or not. It might be better to keep EspruinoBuilds going for a bit with a Neil-curated version of Espruino for the ESP8266. I think when I do the next full release (probably 1v84 - I plan to rush 1v83 out now because of an issue with the Pico's 1v82 firmware) I'll stick ESP8266 in the downloads and get the |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Posted at 2015-11-24 by tve
Want more RAM? Try this build:
https://s3.amazonaws.com/s3.voneicken.com/espruino/espruino_1v81.tve_esp8266-flash-strings_662306b_esp8266.tgz
This does not add more JS variables, it adds more heap to be used for network connections and stuff like that. Before this improvement I couldn't make an HTTP GET complete, now it's no problem. The extra RAM is gained by moving string constants to flash, so some performance impact is to be expected. (Don't ask me to quantify.)
Beta Was this translation helpful? Give feedback.
All reactions