TES WEBSERVER ESP8266 STM32F401-RE
Fork of ESP8266-WEB-Mbed-Controller by
Diff: main.cpp
- Revision:
- 4:54d4cfc9ef4b
- Parent:
- 3:f7febfa77784
--- a/main.cpp Tue Feb 24 23:58:24 2015 +0000 +++ b/main.cpp Mon Apr 03 02:48:55 2017 +0000 @@ -1,17 +1,14 @@ // ESP8266 Static page WEB server to control Mbed #include "mbed.h" -#include "DS18B20.h" Serial pc(USBTX, USBRX); -Serial esp(PTE0, PTE1); // tx, rx - -DS18B20 thermom(A0, DS18B20::RES_12_BIT); +Serial esp(PB_6, PA_10); // tx, rx // Standard Mbed LED definitions -DigitalOut led1(LED_RED); // (PTB18) -DigitalOut led2(LED_GREEN); // (PTB19) -DigitalOut led3(LED_BLUE); // (PTD1) +DigitalOut led1(D11); // (PTB18) +DigitalOut led2(D12); // (PTB19) +DigitalOut led3(D13); // (PTD1) // Digital Out and In pins, can be configured to any suitable pin depending on Platform DigitalOut Out1(D7); @@ -299,8 +296,8 @@ // Temperature example void gettemp() { - temperature=thermom.GetTemperature(); // comment this out if no sensor connected - //temperature = 21.357; // include for dummy value + //temperature=thermom.GetTemperature(); // comment this out if no sensor connected + temperature = 21.357; // include for dummy value sprintf(Temp,"%3.3f",temperature); } // Get RTC time