Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
ThingSpeak Class Reference
Class for sending data to ThingSpeak over ethernet, Class is using old mbed library revision and SensorsThingSpeak from https://developer.mbed.org/teams/TVZ-Mechatronics-Team/code/SensorsThingSpeak/ Example: More...
#include <ThingSpeak.h>
Public Member Functions | |
| ThingSpeak (char *) | |
| Write api key provided from ThingSpek channel. | |
| void | connect () |
| Establishing ethernet connection until connected. | |
| float | pull (long int, int) |
| Funkcion for pulling data from ThingSpeak. | |
| void | setField (float field, int i) |
| Setting values to the field, they should be set in order. | |
Detailed Description
Class for sending data to ThingSpeak over ethernet, Class is using old mbed library revision and SensorsThingSpeak from https://developer.mbed.org/teams/TVZ-Mechatronics-Team/code/SensorsThingSpeak/ Example:
#include "mbed.h" #include "ThingSpeak.h" ThingSpeak thingSpeak("XXXXXXXXXXXXXXXX"); int main() { int i = 1; flot value = 3.14; thingSpeak.connect(); thingSpeak.setField(value,i) thingSpeak.putUp(); }
Definition at line 27 of file ThingSpeak.h.
Constructor & Destructor Documentation
| ThingSpeak | ( | char * | Key ) |
Write api key provided from ThingSpek channel.
- Parameters:
-
write api key provided from ThingSpeak channel.
Definition at line 8 of file ThingSpeak.cpp.
Member Function Documentation
| void connect | ( | ) |
Establishing ethernet connection until connected.
Definition at line 30 of file ThingSpeak.cpp.
| float pull | ( | long int | readKey, |
| int | field | ||
| ) |
Funkcion for pulling data from ThingSpeak.
- Parameters:
-
readKey Channel feed number Field number.
Definition at line 15 of file ThingSpeak.cpp.
| void setField | ( | float | field, |
| int | i | ||
| ) |
Setting values to the field, they should be set in order.
It's not required to set them all (example: you can set 1, 2, 3 or 1, 3)
- Parameters:
-
Field value to store on. i number of a field.
Definition at line 40 of file ThingSpeak.cpp.
Generated on Sat Jul 16 2022 20:38:28 by
1.7.2