Chat freely about anything...

User avatar
By rvbcrs
#6485 Hi! Great work! I'm trying your code, but somehow I'm not able to get it to work. I have compiled you code and flashed it to my ESP8266 after it is finished I connect to it with Coolterm and I see this:

Code: Select allscandone
STATION_IDLE
add 0
aid 2
pm open phy_2,type:2 0 0
cnt
STATION_IDLE

connected with [i][MY-SSID][/i], channel 2
dhcp client start...
STATION_IDLE
STATION_IDLE
STATION_IDLE
ip:192.168.1.121,mask:255.255.255.0,gw:192.168.1.1
TCP: Connect to ip  192.168.1.101:1883
client handshake start.
TCP: Reconnect to 192.168.1.101:1883
TCP: Connect to ip  192.168.1.101:1883
TCP:Reconect to: 192.168.1.101:1883
client handshake start.
TCP: Reconnect to 192.168.1.101:1883


I use Really Small Broker as broker and I see the following:
Image

Can you please help me out? what am I missing?
Do I need to do anything with this:
Code: Select all#define MQTT_CLIENT_ID      "DVES_%08X"
#define MQTT_USER         "DVES_USER"
#define MQTT_PASS         "DVES_PASS"


Thanks!
User avatar
By RichardS
#6544 SUGGESTION

It would be nice if some people can step forward and create at least for now a nice simple lesson on how MQTT works on the WIKI, I think this is a very nice new powerful addition to the ESP8266 and people would love to use it if they understood it more.

We can add a special section to the WIKI that would have a beginners tutorial to begin with and then later list the usage of the library's functions.

Richard.
User avatar
By rvbcrs
#6572
tuanpm wrote:Please change SEC_SSL to SEC_NONSSL like this:
Code: Select allMQTT_InitConnection(&mqttClient, sysCfg.mqtt_host, sysCfg.mqtt_port, SEC_NONSSL);


Great that was it!! Working great now! Next step is figuring out how to get a rgb led responding to the mqtt messages! :)