I have a ESP8266 (ESP-12E) on a module that I got from ebay. It's this one:
http://www.ebay.com/itm/191607499973?_t ... EBIDX%3AIT
I can program with the Arduino IDE (1.6.11). I'm using the latest pubsubclient from Nick O'Leary (v2.4). I've updated my raspberry pi with the latest mosquitto. But the ESP8266 is having issues connecting to the MQTT broker. I get a return error code rc=-4.
I see that the ESP8266 has an IP address, and I can even ping it from my PC. I can publish/subscribe to Mosquitto on the Pi from my PC, so that part works. But the ESP8266 can never connect to the broker.
I'm tried loading the "Hello from ESP8266" webserver sketch, and that works. But MQTT refuses to work.
Are there any other things I'm missing? I've tried googling on MQTT issues and the most common one is not having updated Mosquitto.