Actual values of Temperature, Pressure and simulated values of Rotation Speed, Power, Wind Speed. Alerts when rotation speed limit exceeds.

At the 1st step ordered Avnet's Azure Sphere Starter-Kit from the Element14 website and followed the tutorial to install the required software, claim device and connect with Azure IoT Central services.





After basic interaction to get more hands-on downloaded samples and started exploring the device. It is capable to interact integrated devices from cloud, It can sync data over the cloud in the most secure way and it is best suitable to manage remotely located devices.


This can be used to connect windmills and sync data over the cloud in the most secure way.


To demonstrate concept I have used Inbuilt temperature and pressure sensors that can provide a windmill condition. 3-Axis accelerometer and gyro can be used to determine direction. Further, we can connect to the turbines panel and extract the rotation speed, the power generated also it can connect with other sensors to get wind speed and oil pressure of the turbine.





These details can be transferred to the cloud via inbuild wifi or ethernet expansion board in a most secure way which can help to generate alerts, extract reports for analytics.

Let's get started dashboard configuration at the cloud.

Clone Sample project change app_manifest.json as per part 5 of tutorial and change code in i2c.c as per the attached code.

Parameters configuration at Azure IoT Central, Under Device Template, configure below as shown in the image.





Alert Configuration

Under Rules add telemetry rule as described below, which will trigger the rule when rotation sped goes beyond 25 rotation per minute for a period of 5 minutes, then save and click on the action, select the email and provide the email address as described below.

Alert Creation


Now Dashboard is ready to display details as below






     // We've seen that the first read of the Accelerometer data is garbage.  If this is the first pass
     // reading data, don't report it to Azure.  Since we're graphing data in Azure, this data point
     // will skew the data.
     if (!firstPass) {

          // Allocate memory for a telemetry message to Azure
          char* pjsonBuffer = (char*)malloc(JSON_BUFFER_SIZE);
          if (pjsonBuffer == NULL) {
               Log_Debug("ERROR: not enough memory to send telemetry");

          // Here taking simulated Power and Speed. Can be integrated in future with the turbine system and wind sensor
          float simulatedPowerkW = 120, simulatedWindSpeedMps = 0.56, simulatedRPM = 18;

          // construct the telemetry message
          snprintf(pjsonBuffer, JSON_BUFFER_SIZE, "{\"gX\":\"%.4lf\", \"gY\":\"%.4lf\", \"gZ\":\"%.4lf\", \"pressure\": \"%.2f\", \"temperature\": \"%.2f\", \"aX\": \"%4.2f\", \"aY\": \"%4.2f\", \"aZ\": \"%4.2f\", \"powerkW\": \"%4.2f\", \"windspeedMps\": \"%4.2f\", \"RPM\": \"%4.2f\"}",
               acceleration_mg[0], acceleration_mg[1], acceleration_mg[2], pressure_hPa, lps22hhTemperature_degC, angular_rate_dps[0], angular_rate_dps[1], angular_rate_dps[2], simulatedPowerkW, simulatedWindSpeedMps, simulatedRPM);

          Log_Debug("\n[Info] Sending telemetry: %s\n", pjsonBuffer);


     firstPass = false;