The library is designed to connect the MBED boards to the ThingSpeak IoT cloud.
Fork of Thingspeak by
Diff: Thingspeak.h
- Revision:
- 0:d98f92bb426f
- Child:
- 1:0c196a572d6b
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/Thingspeak.h Mon Feb 12 10:18:15 2018 +0000 @@ -0,0 +1,26 @@ +#ifndef MBED_THINGSPEAK_H +#define MBED_THINGSPEAK_H + +#include "mbed.h" +#include "HTTPClient.h" + +class Thingspeak { + +public: +//This function post data to the thingspeak cloud +/** Execute a POST request on the a private URL obtained from inputs' arguments +Blocks until completion +@param channelWriteAPIKey : your Channel Write API Key +@param fieldNumber : field number of your channel +@param fieldValue : field value of the entered field +@return 0 on success, HTTP error (<0) on failure +*/ + HTTPResult PostDataToChannel(char* channelWriteAPIKey, int fieldNumber, int fieldValue); + + +private: + HTTPClient _http; + +}; + +#endif \ No newline at end of file