IoTHub raw messaging client sample using MQTT

Dependencies:   EthernetInterface NTPClient mbed-rtos mbed wolfSSL azure_c_shared_utility iothub_client azure_umqtt_c iothub_mqtt_transport

Revision:
45:c5727007e4f0
Parent:
44:093816abb152
Child:
47:7a04f9462a19
--- a/iothub_client_sample_mqtt.c	Fri Aug 25 11:24:45 2017 -0700
+++ b/iothub_client_sample_mqtt.c	Mon Sep 11 09:24:58 2017 -0700
@@ -12,8 +12,12 @@
 #include "iothubtransportmqtt.h"
 
 #ifdef MBED_BUILD_TIMESTAMP
+#define SET_TRUSTED_CERT_IN_SAMPLES
+#endif // MBED_BUILD_TIMESTAMP
+
+#ifdef SET_TRUSTED_CERT_IN_SAMPLES
 #include "certs.h"
-#endif // MBED_BUILD_TIMESTAMP
+#endif // SET_TRUSTED_CERT_IN_SAMPLES
 
 /*String containing Hostname, Device Id & Device Key in the format:                         */
 /*  "HostName=<host_name>;DeviceId=<device_id>;SharedAccessKey=<device_key>"                */
@@ -149,13 +153,13 @@
             bool traceOn = true;
             IoTHubClient_LL_SetOption(iotHubClientHandle, "logtrace", &traceOn);
 
-#ifdef MBED_BUILD_TIMESTAMP
+#ifdef SET_TRUSTED_CERT_IN_SAMPLES
             // For mbed add the certificate information
             if (IoTHubClient_LL_SetOption(iotHubClientHandle, "TrustedCerts", certificates) != IOTHUB_CLIENT_OK)
             {
                 printf("failure to set option \"TrustedCerts\"\r\n");
             }
-#endif // MBED_BUILD_TIMESTAMP
+#endif // SET_TRUSTED_CERT_IN_SAMPLES
 
             /* Setting Message call back, so we can receive Commands. */
             if (IoTHubClient_LL_SetMessageCallback(iotHubClientHandle, ReceiveMessageCallback, &receiveContext) != IOTHUB_CLIENT_OK)