Hi. Is there a limit to the size of code we can upload on puck? I am having problems uploading 4767 bytes (with minification around 3030 bytes) of code, usually I'd get an "Uncaught SyntaxError: Got ')'expected EOF" or something similar. From what I can tell the code itself it's not at fault, because if I delete some of it (randomly), I can upload it with no issues. I am controlling puck through Raspberry Pi and using the latest firmware and webIDE. Have tried with and without minification(s).
The code is a bit lengthy so I am not posting it, but I can do so if needed. Thanks.
There shouldn't be an upload limit on normal uploads, no... although if you're uploading with 'Save on send' then there currently is a limit as you have to have enough RAM to hold the data (it can be fixed in an IDE update now 1v96 is out though).
Is it possible that the code you're uploading is actually doing some calculations/work as it is being uploaded?
If so, Espruino could potentially be executing it so slowly that the input buffers get full. Usually if you stick the code you want to run in an onInit function then that'll sort it though.
If you run E.getErrorFlags() then it might give you something like a FIFO_FULL error that'd tell you if it's happening.
Don't worry about formatting, just type in the text and we'll take care of making sense of it. We will auto-convert links, and if you put asterisks around words we will make them bold.
For a full reference visit the Markdown syntax.
© Espruino, powered by microcosm.
Report a problem