Azure IoT Hub
42 TopicsConnect your simulated device to your IoT hub using .NET
I went through the Microsoft tutorial "Getting Started with Azure IoT Hub" link - https://docs.microsoft.com/en-us/azure/iot-hub/iot-hub-csharp-csharp-getstarted At runtime it gives the error - Microsoft.ServiceBus.Messaging.MessagingCommunicationException occurred HResult=0x80131500 Message=An error occurred during communication with 'DeviceGateway_c55eb685be2644918785348b055d9c5a:ihsuprodblres058dednamespace.servicebus.windows.net:5671'. Check the connection information, then retry. Source=Microsoft.ServiceBus StackTrace: at Microsoft.ServiceBus.Common.AsyncResult.End[TAsyncResult](IAsyncResult result) at Microsoft.ServiceBus.Messaging.IteratorAsyncResult`1.RunSynchronously() at Microsoft.ServiceBus.Messaging.Amqp.AmqpEventHubClient.GetRuntimeInformation() at ReadDeviceToCloudMessages.Program.Main(String[] args) in E:\IoThub\IotHubGetStarted\ReadDeviceToCloudMessages\Program.cs:line 34 Inner Exception 1: SocketException: A connection attempt failed because the connected party did not properly respond after a period of time, or established connection failed because connected host has failed to respond I am attaching screenshot of the exact position of error. Please suggest a solution. Thank you3.8KViews0likes6CommentsHow is the Event Data's Sequence Number and Offset created on Event Hub?
Hi all; I did some tutorial about Event Hub. The sequence number and offset of a event look like a auto increament number (+1). I wonder if the number of event is too big or the event is last more than 7 days, will Azure Event hub delete and reset sequence and offset? If these properties reset, which point do begin ? (From 0,1 ... etc) Can you help me answer these questions above. Thanks in advance.3.5KViews0likes0CommentsHubs, Sharding and Partitioning
It seems there is a some misunderstanding related to sharding and partitioning when talking about IoT and Microsoft Azure platform. Here is my recommendation about how we should thnk about this. EventHub uses internally messaging feature called 'partitioning'. To understand how that works I would recommend to read more about this in context of service bus. It basically enables multiple message brokers instead of a single one. So, this is called partitioing even if some people might call this shrading. IotHub also uses same (or similar) technic as EventHub. However, when we talk about IotHub 'shards' we do not think about partitioning on message level. It is rather using of multiple IotHubs inside of same solution. This is not some specific technology under the hub. To use multiple IotHubs inside of a single solution, You should decide how device provisioning is done. Dev1-Hub1, Dev2->Hub2 etc.2.6KViews6likes0CommentsAPI to create and delete devices in Iot hub?
Is it possible to create/delete Iot devices by invoking an API from third party application. If so could you please share me the steps. Also is there any other alternative methods we could create/delete devices without manual intervention?2.5KViews0likes1CommentHow to build a simple IoT Edge Version 2 Heartbeat Module
Recently, the Microsoft Azure IoT Edge platform was updated with more features, better documentation and lots of goodies. Yes, the learning curve of this new version is steep, especially if you are new (like me) to Docker. But once you just have started building your own Edge solution, things seem to fall into place. A logical flow seems to be described in the Microsoft documentation: Simulate an IoT Edge device in Windows Simulate an IoT Edge device in Linux Develop and deploy a C# module Deploy Azure Stream Analytics as a module Deploy Azure Machine Learning as a module Deploy Azure Functions as a module Looks easy, doesn't it? But reading the comments, people are still confused. First of all: DO NOT MIX VERSION ONE AND VERSION TWO DOCUMENTATION. Version one is based on one executable (gw.exe) which injects classes from DLL's (a configuration file has to be supplied). Modules are just classes in the DLL's. Version two is based on Docker Containers, each module is a separate container and therefore each module is a separate executable. These modules share the same logic to connect to a message bus which provides the routing. This 'runtime' has to be installed on the Edge machine, next to/outside the Docker containers. Note: the good thing is that the architecture still stands, multiple modules on top of a messagebus and messages are routed. The better thing is that the routing is now far more intelligent. And Microsoft has provided some guidance for migration After that, work your way through the documentation provided above, and check out my recent blogs: Deploy an Azure StreamAnalytics Job on the IotEdge Introduction to the Microsoft Azure IoTEdge Modbus-tcp-iotedge module Better property roundtrip for Azure IoIEdge Module Twin OK, I know, the learning curve is still steep. How about a full example of a simple module? The full article can be found here The source code of this module is available on Github The module is available for download as a Docker image2.4KViews0likes0CommentsIntroduction to the microsoft/azureiotedge-modbus-tcp IoTEdge Module
The newest version of the Azure IoTEdge solution is a very promising platform. The combination of remote provisioning the modules, the power of twin configuration and the new routing is interesting. But the learning curve is pretty steep. The first version was based on programming an application. The new version is based on docker images, each being a separate application, which has to be stored in the container registry of your choice (like Docker Hub or your own container registry in Azure. So once you have learned how to build and deploy your own modules, you can check out the modules Microsoft already supplies. One of these modules is a Modbus module. It's available at the Docker Hub of Microsoft. Modbus is a great protocol for highspeed communication over TCP and I have already blogged about it, using the previous IoTEdge SDK version. Let's check out how we get some telemetry from it. Read the full article here2.2KViews1like0CommentsAndruino R2, a cloud robots using Azure iot (ROS to Azure iot interface)
Andruino R2 using Azure iot hub to collect and publish robot's sensor data on a Web. Datas sensor come from a ROS topic. Video: https://www.youtube.com/watch?v=fxeoljZsCfo Andruino R2 is an open educational low-cost (components about 35€/USD) modular and extendable mobile robot based on Android and Arduino, integrated in the cloud, to be used as an educational tool in labs and classrooms of STEM, ICT vocational training or engineering courses, as well as in e-learning or MOOC courses as an alternative or, complementary, to virtual labs and soft robotics simulation. It is a first step introducing what we call “BYOR: Bring Your Own Robot” education policy equivalent to “BYOD: Bring your own devices”. Andruino it is powerful but easy to construct and extremely low cost, as it is based in the student's smartphone. Andruino R2 is compatible with ROS (Robot Operating System) and with iot clouds and try to bring deep learning and other advanced techniques to the STEM's and VET's classrooms. Author: @andruinos License: CC-BY-SA https://creativecommons.org/licenses/by-sa/2.0/2KViews0likes0CommentsRoute IoT device messages to Azure Storage with Azure IoT Hub
Azure Storage containers is the new custom endpoint type available with IoT Hub. Azure Storage containers joins Service Bus queues, topics, and Event Hubs as supported custom endpoint types for IoT Hub message routing. Storage was the most requested endpoint type for message routing because it makes it super simple to build a cold-path analytics pipeline. The best part, it’s available everywhere. Just as a reminder, IoT Hub can write messages to multiple endpoints, so with this feature improvement customers can both send the message through a hot-path analytics pipeline, as well as push the message to storage for cold-path analytics or long-term archival. Cold-path analytics are used to process data which requires more complex processing than simple windowing or thresholding, and cold-path analytics often uses data from devices over a longer period of time. With this feature update, you can set up your hot- and cold-path analytics easily in IoT Hub routes. Read about it in the Azure blog.1.7KViews0likes0Comments