itead / ITEADLIB_Arduino_WeeESP8266

An easy-to-use Arduino ESP8266 library besed on AT firmware.
MIT License
529 stars 284 forks source link

Update esp8266.cpp #47

Closed odilonafonso closed 8 years ago

odilonafonso commented 8 years ago

When a AT Command return successfull (OK) the method recvFindAndFilter search for String target argument ("OK"); sometimes the method locate target but don't locate String begin or String end arguments from the caller and because this the method set data = "" and return false to the caller. The replace code above set the data argument with the substring from the buffer (data_tmp) initial position to the target position (+target length) and return true to the caller.