ESP8266 LIFE

This is turning into a diary – my life with the ESP8266 – sounds like a serious disease.

Last night I tried increasing the speed at which my Arduino-like board talks to the ESP8266. I’ve been using 115,200 baud and it was suggested that the problem might not exist at HIGHER speeds. Sadly the Arduino-type boards just will not talk at much higher speeds – either because of inaccuracies or because of the resistive divider I use to talk to the ESP-01.  As the results were SO bad at high speed, I thought I’d try a LOWER speed just in case, in fact it was my serial that was causing the “busy…s” problem – turns out it wasn’t.

So this morning I received a reply from one chap who has tried the LUA version of the ESP8266 software only to find it crashes for him when stressed. His example code is as follows:

i = 0 repeat print (i) i=i+1 until (i == 800)

Well there’s a surprise and another hope dashed for now. Meanwhile the latest Frankenstein code (all of this is referred to in previous blogs) failed last night – latest BINARY files go into a loop on powerup. Hopefully we’ll see another release of that tonight as the author is now aware of the issue.

For my own part, I received an email from ESPRESSIF to ask me to test an archive file they sent me – an experimental version of the software to see if the “busy…s” problem would go away.  That was nice of them and it’s good to know that someone at least understands there is an issue.  I’m including the contents of my reply and their email so you can see the problem and how it occurs.

Here it is in total….my response to Espressif followed by their original email trail – you’ll see they acknowledge the issue, were originally too busy but it’s nice to see them now trying to help.  This is running at 115,200 on an Arduino-type board with 2 UARTS – one for the ESP-01, one for the Serial debug.

………..

Thank you for the test code… but the problem still exists with the new code.  Here is an example.

AT+CIPSEND=0,3
> 1
SEND OK
+IPD,0,4:GO3
OK
AT+CIPSEND=0,3
> 0
SEND OK
+IPD,0,4:GO2
OK
AT+CIPSEND=0,3
> 0
0,OFF
0,CONNECT
+IPD,0,4:GO3
OK
AT+CIPSEND=0,3
busy s…
0
busy s…
DOING A FULL RESET

So.. here is what I do..

I use an Android program called NETIO (http://netio.davideickhoff.de/en/)

My Arduino (Mega) uses TWO Serial ports at 115200 – one to talk to the debug serial you see above – and one to talk to the ESP-01 board… hence there are responses above from the ESP-01 AND messages from the board. You can see at the end I am doing a reset to make the board recover but this is not the solution.

Here is what happens…

On power-up my program looks for a valid IP address and if it does not find one it sets up the board. It sends one instruction at a time, waiting for the relevant response – or a timeout.

It sets up the connection to my router then sets up a TCP/IP listener on port 4000. From there, when the APP is running on my phone that sends requests for button status to the ESP-01 – and my board picks that up and sends responses… to say a LED is on or off…

AT+CIPMODE=0
AT+RESET
AT+CWJAP=”loft-east”,”1012423423”
AT+CIPMUX=0
AT+CIFSR?
AT+CIPMUX=1
AT+CIPSERVER=1,4000
AT+CIPSTO=10

The board then receives messages from the Android APP

+IPD,0,4,G01

The instruction is requesting the state of LED1

Arduino sends back a reply…

AT+CIPSEND=0,3
0

i.e. It is sending 3 characters = “0” followed by CR/LF.

So typically we see checks for 4 LEDS as such.

+IPD,0,4,G01
AT+CIPSEND=0,3
0
+IPD,0,4,G02
AT+CIPSEND=0,3
0
+IPD,0,4,G03
AT+CIPSEND=0,3
0
+IPD,0,4,G04
AT+CIPSEND=0,3
0

The above shows 4 requests for status – for lamps 1-4 and the Arduino sends back “0” in each case for lamp OFF (or “1” for lamp ON).

This happens continuously.

This works perfectly.. BUT… at any time I might turn the phone off [or swap apps] – or go out of range. Much of the time the data simply stops – and recovers when I start again – but SOMETIMES as in the example above – the BUSY_S occurs and that is the end of it, a reset is required…

Can you help eliminate this bug. I have no control over the NETIO APP – which works utterly perfectly with wired Ethernet.

Regards

Peter.

From: support-at@espressif.com [mailto:support-at@espressif.com]
Sent: 17 November 2014 02:53
To: pete
Cc: support-at@espressif.com
Subject: Re: RE: Esp 01

Hi,

Please test bins as the attachment, if it still has “busy s”problem or not

boot_v1.1.bin downloads to flash 0x00000

user1.bin downloads to flash 0x01000

esp_init_data_default.bin downloads to flash 0x7C000

blank.bin downloads to flash 0x7E000

If it still has“busy s”problem, please tell us your test steps, list of AT commands that you sent. 

Thanks for your interest in ESP8266.

Regards,


support-at@espressif.com

From: Peter Scargill

Date: 2014-10-30 17:39

To: support-at@espressif.com

Subject: RE: Esp 01

Thanks but many of us merely want to USE the module, not develop it – I have no experience of using GCC and the Linux environment, I simply want a WIFI module that works. Please fix the firmware so that the “busy s” problem goes away..

Regards

Pete

From: support-at@espressif.com [mailto:support-at@espressif.com]
Sent: 30 October 2014 08:12
To: pete
Cc: support-at@espressif.com
Subject: Re: Esp 01

Hi,

Sorry, our schedule is so full that we will put this till later,

but our code is open source now,  on BBS http://bbs.espressif.com/

You can get full source code and do your own development

Regards,


support-at@espressif.com

From: Peter Scargill

Date: 2014-10-30 15:57

To: support-at@espressif.com

Subject: Esp 01

Hi

Esp01 esp8266…  When will we see a fix for the “busy s…” Problem?? We

are unable to make serious use of these boards until this is fixed.

Currently using 0922 version software.

Regards

Peter Scargill

Advertisements

2 thoughts on “ESP8266 LIFE

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s