You are reading a single comment by @SteveHayles and its replies. Click here to read the full conversation.
  • Hi @Gordon,

    Sorry that this is dragging on, for me adding the new files (AT.js and EspruinoWifi.js) results in not being able to do simple sends. No stack trace obviously but it looks like the AT+CIPSEND gets to the "OK" clause in EspruinoWifi.js and the callback is returned and assigned to the lineCallback in AT.js.

    At this stage (after the lineCallback and before if (handled&&dataCount) return cb("");) the variable line equates to "OK\r\n> ". This is then substring'd with line = line.substr(i+2); to "> " and the final statement of the loop i = line.indexOf("\r\n"); will return -1 and the loop exits.

    I think this leaves the ESP8266 module waiting for data and therefore not sending anymore and we have effectively discarded the incoming "> ". If I add a check in the end of the loop as follows then it works but obviously this has no place in the AT module

    if (line=="> " && lineCallback){
       //debugger;
       lineCallback(line);
    }
    

    I am trying to work out what I have missed but the files are straight cut and paste from your recent commits. Thanks for your ongoing help, this module is in a very important part of a project I am working on and we are very keen to get this working.

    Steve

About

Avatar for SteveHayles @SteveHayles started