Alex Leung
/
HealthTracker
Test version
Diff: main.cpp
- Revision:
- 1:bd9f39f9d91c
- Parent:
- 0:4be500de690c
diff -r 4be500de690c -r bd9f39f9d91c main.cpp --- a/main.cpp Tue Mar 20 02:09:21 2018 +0000 +++ b/main.cpp Tue Mar 20 02:21:49 2018 +0000 @@ -3,8 +3,12 @@ #include "MAX30102.h" #include "LEDS.h" #include "WIFI.h" +#include "ESP8266Interface.h" +#define MAX_BRIGHTNESS 255 -#define MAX_BRIGHTNESS 255 +#define MBED_CONF_APP_NETWORK_INTERFACE WIFI_ESP8266 +#define MBED_CONF_EASY_CONNECT_WIFI_ESP8266_TX PC_10 +#define MBED_CONF_EASY_CONNECT_WIFI_ESP8266_RX PC_11 extern int* ReadDS1621(void); uint32_t aun_ir_buffer[500]; //IR LED sensor data int32_t n_ir_buffer_length; //data length @@ -16,7 +20,7 @@ uint8_t uch_dummy; Serial pc(USBTX, USBRX); //initializes the serial port, TX-PA2, RX-PA3 - +ESP8266Interface wifi(MBED_CONF_EASY_CONNECT_WIFI_ESP8266_TX, MBED_CONF_EASY_CONNECT_WIFI_ESP8266_RX); PwmOut pwmled(PA_10); //initializes the pwm output PB3 that connects to the LED DigitalIn INT(PC_5); //pin PB7 connects to the interrupt output pin of the MAX30102 DigitalOut led(PC_9); //PC13 connects to the on board user LED