Cant read from socket problem


#1

I am using an arduino nano with esp01 for wifi connectivity. I can connect to my wifi but i keep getting “disconnecting 3” and no data is sent to thinger servers. In debbuging mode i get this:

Blockquote
[WiFiEsp] Initializing ESP modul[WiFiEsp] Initializing ESP module
[WiFiEsp] >>> TIMEOUT >>>
[WiFiEsp] >>> TIMEOUT >>>
[WiFiEsp] Initilization successful - 2.0.0
[NETWORK] Starting connection…
test_in_connect_network
[NETWORK] Connecting to network The boozy’s
test_in_THINGER DEBUG VALUE
[WiFiEsp] Connected to The boozy’s
[NETWORK] Connected to WiFi!
[NETWORK] Getting IP Address…
[NETWORK] Got IP Address: 192.168.1.22
test_in_connect_network
[NETWORK] Connected!
network connected is ok
[_SOCKET] Connecting to iot.thinger.io:25202
[_SOCKET] Using secure TLS/SSL connection: yes
[WiFiEsp] Connecting to iot.thinger.io
[_SOCKET] Connected!
[THINGER] Authenticating. User: Ofarshi Device: green
[THINGER] Writing bytes: 35 [OK]
[_SOCKET] Cannot read from socket!
[THINGER] Auth Failed! Check username, device id, or device credentials.
[WiFiEsp] Disconnecting 3
[_SOCKET] Is now closed!


#2

Have you double check that parameters? (username, device id, credentials)


#3

Sure i did.
I even tried changing the credentials and in username i tried also the email


#4

BTW, I’m using the WiFiEsp library by bportaluri, so I had to modify ThingerWifi.h
from this:

#define ThingerWifi ThingerWifiClient

to this:

#define ThingerWifi ThingerWifiClient


#5

Can someone please help me on this?
Maybe something is not configured right in the esp?
maybe i’m missing something?


#6

Have you tried with example sketch?

That´s how I start everything with thinger.

Other thing that I would do is try to update thinger.io library, or maybe downgrade to a previous versions, in an opportunity, I sorted an issue with a GSM deploy, downgrading thinger library.

Hope this helps