STM32F103C8T6,ONENET,ESP8266
Dependents: STM32F103C8T6_OneNet_IoT
Revision 1:8512a7d76959, committed 2019-11-07
- Comitter:
- dadangjia
- Date:
- Thu Nov 07 23:56:29 2019 +0000
- Parent:
- 0:cbe8a0553d45
- Commit message:
- STM32F103C8T6,ONENET,ESP8266,DH11
Changed in this revision
wifi_example.cpp | Show annotated file Show diff for this revision Revisions of this file |
wifi_example.h | Show annotated file Show diff for this revision Revisions of this file |
diff -r cbe8a0553d45 -r 8512a7d76959 wifi_example.cpp --- a/wifi_example.cpp Wed Mar 29 03:08:46 2017 +0000 +++ b/wifi_example.cpp Thu Nov 07 23:56:29 2019 +0000 @@ -9,7 +9,7 @@ #include "wifi_example.h" ESP8266 wifi(PA_9,PA_10); -Serial pc(SERIAL_TX, SERIAL_RX); +Serial pc(PB_10, PB_11); //蓝牙串口波特率115200 EdpPacket* send_pack; char send_buf[MAX_SEND_BUF_LEN]; @@ -20,6 +20,7 @@ void connectInit(void) { bool ret; + pc.baud(115200); pc.printf("starting......\r\n"); wifi.reset(); wait_ms(500); @@ -132,7 +133,6 @@ DeleteBuffer(&send_pack); //delete send_packge, unless may cause memory leak } else { pc.printf("normal data sended\r\n"); - DeleteBuffer(&send_pack); //delete send_packge, unless may cause memory leak } wait_ms(500); }
diff -r cbe8a0553d45 -r 8512a7d76959 wifi_example.h --- a/wifi_example.h Wed Mar 29 03:08:46 2017 +0000 +++ b/wifi_example.h Thu Nov 07 23:56:29 2019 +0000 @@ -12,10 +12,10 @@ #include <stdlib.h> #include <string.h> -#define DEVICEID "5116906" -#define APIKEY "E75QrwTpTp5hmWCxljc0Seg1KS0=" -#define APNAME "AnChuangKongJian" -#define APPASSWD "jiasuqi@0111" +#define DEVICEID "518299613" +#define APIKEY "D1cJ=yPG0qAHmWd3G7cNivNrj2w=" +#define APNAME "OrayBox-4DBE" +#define APPASSWD "zhuxiweiyang" #define TCPNUM 0 #define TCPADD "jjfaedp.hedevice.com" #define TCPPORT 876