Thermometer connected to internet
Dependencies: BME280 EthernetInterface FXOS8700Q HTTPClient-wolfSSL NTPClient NetworkAPI OAuth4Tw TSL2561_I2C eCompass_FPU_Lib mbed-rtos mbed wolfSSL
Fork of TCP_Server_Example by
Diff: EnvServer.h
- Revision:
- 12:12369ee344ab
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/EnvServer.h Sun Sep 27 11:04:54 2015 +0000 @@ -0,0 +1,30 @@ +#ifndef ENV_SERVER_H +#define ENV_SERVER_H + +#include "mbed.h" + +#include "NetworkAPI/buffer.hpp" +#include "NetworkAPI/select.hpp" +#include "NetworkAPI/ip/address.hpp" +#include "NetworkAPI/tcp/socket.hpp" +using namespace network; + +#define MAX_CLIENTS 2 +#define WAIT_PORT 12345 + +#define TEMP_CMD "TMP" +#define HUMIDITY_CMD "HMD" +#define PRESSURE_CMD "PRS" +#define ILLUM_CMD "ILM" + +extern Select select; +extern tcp::Socket server; +extern tcp::Socket client[MAX_CLIENTS]; +extern tcp::Socket *socket; + +void EnvServer(void const *arg); + + +#endif + +