Skip to content

Latest commit

 

History

History
 
 

samples

Samples for the Azure IoT device SDK for C leveraging the serializer library

This folder contains simple samples showing how to use the various features of the Microsoft Azure IoT Hub service leveraging the serializer library from a device running C code.

List of samples

  • Simple send and receive messages:

    • simplesample_mqtt: send and receive messages from a single device over an MQTT connection
    • simplesample_amqp: send and receive messages from a single device over an AMQP connection
    • simplesample_http: send and receive messages from a single device over an HTTP connection
    • remote_monitoring: Implements the device code used to connect to an Azure IoT Suite Remote Monitoring preconfigured solution
    • temp_sensor_anomaly: simple sample for an mbed application that collects temperature information from sensors, sends them to Azure IoT Hub and trigger a buzzer when receiving a command from Azure IoT Hub
  • Device services samples (Device Twins, Methods, and Device Management):

    • devicetwin_simplesample: Implements the device code to utilize the Azure IoT Hub Device Twins feature

How to compile and run the samples

Prior to running the samples, you will need to have an instance of Azure IoT Hub available and a device Identity created in the hub.

It is recommended to leverage the library packages when available to run the samples, but sometimes you will need to compile the SDK for/on your device in order to be able to run the samples.

This documents describes in details how to prepare you development environment as well as how to run the samples on Linux, Windows or other platforms.