thingspark example
Dependencies: MbedJSONValue mbed-http HTS221
Diff: source/channel-field-entrys.cpp
- Revision:
- 39:9856f09a1333
- Parent:
- 38:7734b54de565
--- a/source/channel-field-entrys.cpp Sat Dec 28 07:53:23 2019 +0000 +++ b/source/channel-field-entrys.cpp Sun Dec 29 03:14:52 2019 +0000 @@ -12,7 +12,7 @@ char* thingspark_URL = "http://api.thingspark.kr"; -char* thingspark_APIkey = "1yUxh3Dh77DUQyOt"; +char* thingspark_APIkey = "CHANGE API KEY"; char urlBuffer[256]; /* List of trusted root CA certificates @@ -79,14 +79,15 @@ const char * json = res->get_body_as_string().c_str(); printf("\nBody (%lu bytes):\n\n%s\n", res->get_body_length(), json); - -/* + /* + MbedJSONValue mbedjson; //parse the previous string and fill the object demo parse(mbedjson, json); - +*/ + /* std::string my_str; my_str = mbedjson["channel"].get<std::string>(); printf("channel: %s\r\n", my_str.c_str());