Simplify using of UnbufferedSerial(Serial), USBCDC, TCP, SMTP, NTP Fork : https://github.com/YSI-LPS/lib_Transmission
Dependents: lib_Transmission_Serial_example 2022_TICE_Electrolyse lib_Transmission_TCP_example
Diff: lib_Transmission.h
- Revision:
- 6:d6a07fd1548a
- Parent:
- 4:9a4ab4f406ab
- Child:
- 7:98b12722e9e2
--- a/lib_Transmission.h Fri Jul 17 07:51:57 2020 +0000 +++ b/lib_Transmission.h Mon Sep 28 13:15:30 2020 +0000 @@ -26,8 +26,9 @@ #include "EthernetInterface.h" #include <sstream> -#define TCP_CLIENT_TIMEOUT 100 // config client bloquante avec timeout sinon limite de transmission a 1072 octets +#define REQUEST_TIMEOUT 100 // config client bloquante avec timeout sinon limite de transmission a 1072 octets #define SMTP_SERVER "129.175.212.70" // IP sinon utilisation du DNS avec eth.getHostByName("smtp.u-psud.fr") +#define NTP_SERVER "129.175.34.43" // IP sinon utilisation du DNS avec eth.getHostByName("ntp.u-psud.fr") enum enumTRANSMISSION { TCP, SERIAL, BOTH }; enum enumTRANSTATUS { WHITE, CYAN, MAGENTA_ACCEPT, BLUE_CLIENT, YELLOW_CONNECTING, GREEN_GLOBAL_UP, RED_DISCONNECTED, BLACK_INITIALIZE }; @@ -86,7 +87,21 @@ * @param * @returns none */ + time_t ntp(void); + /** + * + * @param + * @param + * @returns none + */ void http(void); + /** + * + * @param + * @param + * @returns none + */ + bool dhcp(void); private: UnbufferedSerial *_serial;