I added the CIPHEAD=1 setting to init and I took the send method of the ESP8266 driver now and I call at.debug() in the callback.
It now looks like this:
send : function(sckt, data) { if (at.isBusy() || socks[sckt]=="Wait") return 0; if (!socks[sckt]) return -1; // error - close it var f = function(d) { console.log(d); at.debug(); if (d=="> ") return f; }; at.cmd('AT+CIPSEND='+sckt+','+data.length+'\r\n'+data, 10000, f); return data.length; }
The output is the following:
_____ _ | __|___ ___ ___ _ _|_|___ ___ | __|_ -| . | _| | | | | . | |_____|___| _|_| |___|_|_|_|___| |_| http://espruino.com 1v80 Copyright 2015 G.Williams >echo(0); =undefined null IP:10.54.158.176 undefined ["AT+CIPSEND=0,31\r\nclose\r\nHost: http://www.pur3.co.uk\r\n\r\n" ] "> \r\n0" <--- "\r\n0" > ] "0, CLOSED\r\n\r\nERROR\r\n" <--- ", CLOSED\r\n\r\nERROR\r\n" ERROR ["AT+CIPCLOSE=0\r\n" ] "\r" <--- "\r" ] "\nERROR\r\n" <--- "\nERROR\r\n" >
@net-tobi started
Espruino is a JavaScript interpreter for low-power Microcontrollers. This site is both a support community for Espruino and a place to share what you are working on.
I added the CIPHEAD=1 setting to init and I took the send method of the ESP8266 driver now and I call at.debug() in the callback.
It now looks like this:
The output is the following: