ESP8266 Process of connecting to alicloud

* send out “+++” The purpose is to make the ESP8266 Exit touzhuan ;
* AT+RESTORE Return the module to factory settings ;
* AT Judge the quality and working state of the module , Normal will be restored OK;
* ATE0 Turn off echo , There's nothing to say about this ;
* AT+CWMODE_CUR=1 Set to station pattern ;
* .AT+CWJAP_CUR=“ssid”,“password” Connection hotspot , It needs to be changed according to its own hotspot ;
* AT+CIPSTART=“TCP”,“ domain name ”, port connect TCP;
* AT+CIPMODE=1 Set the transmission mode to transparent mode ;
* AT+CIPSEND Tell the module to start transmitting data , Received a message from the module ‘>’ That's it ;
* Sign in MQTT
* Send heartbeat packet
* send message
* receive messages
That's all ESP8266 Module connection to alicloud , All the steps to communicate with Alibaba cloud .

Log in here MQTT, Send heartbeat packet , The content of the message should be based on MQTT From the agreement . Not a single byte can be wrong . In addition, log in MQTT The content of the message should be calculated according to the one machine one secret of alicloud . Then there are the steps 7 Go to step 10 There is a time limit . adopt TCP After connecting to Alibaba cloud server , If 10s I didn't pass the exam MQTT Sign in , Alicloud will kick you down automatically .

Technology