WIP. send a large constant string twice a second, in order to test out the transport with something indicative of our required load.
Dependencies: FXOS8700CQ NTPClient azure_umqtt_c iothub_mqtt_transport mbed-rtos mbed wolfSSL Socket lwip-eth lwip-sys lwip
Fork of FXOS8700CQ_To_Azure_IoT by
Diff: main.cpp
- Revision:
- 7:0d1a0fe537dc
- Parent:
- 6:66576aa3d4e3
--- a/main.cpp Thu Jan 05 02:10:23 2017 +0000 +++ b/main.cpp Thu Jan 05 23:40:24 2017 +0000 @@ -27,7 +27,8 @@ #include "certs.h" //JH A dummy string to send every 0.5 sec. -#define dummystring "{\"timestamp\":12345678901234567890,\"device\":\"JulianTestSensor\",\"A\":[+0000,-0002,+0001],\"B\":[-0002,-0001,-0004],\"C\":[-0003,-0002,-0002],\"D\":[-0002,-0003,-0004],\"E\":[-0002,-0002,-0002],\"F\":[-0002,-0004,-0001],\"G\":[-0001,-0002,-0004],\"H\":[-0003,-0002,-0003],\"I\":[-0003,-0002,+0000],\"J\":[-0002,-0003,-0001],\"K\":[-0003,-0001,-0002],\"L\":[-0001,-0003,-0003],\"M\":[-0003,-0003,-0004],\"N\":[-0001,-0003,-0004],\"O\":[-0003,-0002,+0000],\"P\":[-0001,-0002,-0004],\"Q\":[-0003,-0003,+0000],\"R\":[-0002,-0003,-0002],\"S\":[-0001,-0002,-0004],\"T\":[-0002,-0003,-0003],\"U\":[-0005,-0001,-0002],\"V\":[+0000,-0003,+0000],\"W\":[-0003,-0002,-0008],\"X\":[+0000,-0003,+0000]}" +//#define dummystring "{\"timestamp\":12345678901234567890,\"device\":\"JulianTestSensor\",\"A\":[+0000,-0002,+0001],\"B\":[-0002,-0001,-0004],\"C\":[-0003,-0002,-0002],\"D\":[-0002,-0003,-0004],\"E\":[-0002,-0002,-0002],\"F\":[-0002,-0004,-0001],\"G\":[-0001,-0002,-0004],\"H\":[-0003,-0002,-0003],\"I\":[-0003,-0002,+0000],\"J\":[-0002,-0003,-0001],\"K\":[-0003,-0001,-0002],\"L\":[-0001,-0003,-0003],\"M\":[-0003,-0003,-0004],\"N\":[-0001,-0003,-0004],\"O\":[-0003,-0002,+0000],\"P\":[-0001,-0002,-0004],\"Q\":[-0003,-0003,+0000],\"R\":[-0002,-0003,-0002],\"S\":[-0001,-0002,-0004],\"T\":[-0002,-0003,-0003],\"U\":[-0005,-0001,-0002],\"V\":[+0000,-0003,+0000],\"W\":[-0003,-0002,-0008],\"X\":[+0000,-0003,+0000]}" +#define dummystring "{\"timestamp\":12345678901234567890,\"device\":\"JulianTestSensor\",\"largest magnitude\":1234}" int readingToJSON(char *buffer, int bufferlen, READING &reading) {