• Hi @Pedro
    The way of patching this stuff is to clone https://github.com/espruino/Espruino into your own name.
    Then you can make a branch, say called 4MB, and then do your updates into the branch.

    Then when you are ready, you do a pull request to the /espruino/Espruino master.

    I think you might need to reserve some heap space for the wifi, as it looks like you don't have much heap space left after the vars increase. The buffer for IP are made dynamically and a free heap of 3344 might not be enough.

  • Thanks @Wilberforce, will try to branch the code so that it can be reviewed.
    Regarding your comment on free heap, I just pushed it to the limit (2048 jsvars dynamically allocated). I agree at some point I need to put some check to keep a minimum heap available, failing to create a new jsvar block, but the result should be the same : memory full / bad things happen :)
    Currently new jsvars are allocated in blocks of 128, so it does not go directly from 31KB heap to 3KB heap.

About

Avatar for Wilberforce @Wilberforce started