store Data to File on ESP8266

Posted on
  • Hi,

    does anyone know how to store some JSON Data on an ESP8266 ?

    Thanks in advance

  • Yes you can write to free flash check out the Flash module

    http://www.espruino.com/Reference#Flash

  • And http://www.espruino.com/FlashEEPROM for a cleaner wrapper around it

  • Hello again, i have another issue. I make a http request to a JSON RPC Server. Everything works fine so far but sometimes i get no response even i the server is responding (parallel test with node js). If i log out more details i can see it triggers a socket timeout. If i start the device again everything works fine.

    Is there a way to get this event or to catch this timeout ?

  • As I understand it socket errors on ESP8266 are commonly down to the fact you can only have so many open sockets. It's not many - I seem to think I've read 5. As for catching I don't know. If you slow down your poll rate does that help?

    Maybe jump on the gitter.im/Espruino/espruino channel. There's people more familiar with this stuff on there.

  • Thanks. I trigger an http request every 3 sec. Actually the connection should close and released after every request thus there should only one socket open at all.

  • Actually the connection should close and released after every request thus there should only one socket open at all

    Yes. But not much headroom if things error and can't close. Have you made progress on this - I see you've posted to Gitter?

  • Yes and i got an answer already. Since i reduced the interval of the request to 3 sec. it seems to work more reliable ;-)

  • Post a reply
    • Bold
    • Italics
    • Link
    • Image
    • List
    • Quote
    • code
    • Preview
About

store Data to File on ESP8266

Posted by Avatar for user66681 @user66681

Actions