Senior Software Engineer, Microsoft MVP on Windows Embedded and IoT. Devices to cloud, IoT, M2M and embedded systems.
Finally, the M2Mqtt project, which includes the client library and the GnatMQ broker, has its official website !
In addition to a dedicated blog, there is a documentation section that currently contains the architecture description of the client library, the main advantages in using it and a simple application example. As for the broker, are the main features implemented and future.
In addition, the download section lists all the link to download the project (CodePlex, Nuget and Microsoft Code Gallery).
My objective is also to add a "case study" section with application examples, hobbistic or professional, and/or demos of those who are using the library and/or the broker. Obviously, anyone who wants to participate can contact through the contact section !
In this post, we'll see how easy it is to execute GnatMQ, the MQTT broker for .NET Framework, in the Cloud using the Microsoft Azure platform. The execution of the broker can be started through a Worker Role that is one of the "Cloud Services" offered by Microsoft.
Create the Cloud Service
In the "Server Explorer", click with the right button on "Windows Azure" and "Connect to Windows Azure ..." and execute login using our Azure credentials(the ones we use in the online management portal).
The "Server Explorer" refreshes and displays all the "Windows Azure" services currently active with our account (Cloud Services for web role and worker role, Service Bus with its namespaces, Virtual Machines and so on).
Since our goal is to execute the GnatMQ broker in a worker role, we need to create a new "Cloud Services", right-clicking on it and selecting "Create Cloud Service ...". Select the subscription you want to associate the new service, the name and the region where it will be executed.
The creation o ...
Development of M2Mqtt library continues .... now reached the version 126.96.36.199 !
This time the new features are related to two requests from people who are using it.
First, I added more overloads for Connect() method, because from when I removed the default parameters (for compatibility with older versions of the .Net Framework) I left the more complex constructor that requires all parameters. Many people, not knowing well the MQTT protocol, found themselves in difficulty in deciding what values to pass to lesser known parameters (will message, clean session, ...).
A further new feature concerns the client disconnected event (from the MQTT broker) that was requested on the official CodePlex web site. The MqttClient class exposes MqttMsgDisconnected event that is raised when a condition of connection failure with the broker is detected and typically in two cases :
when there isn’t network traffic, when client sends the PINGREQ message (relative to the keep-alive) it doesn’t receive ...
In the course of this tutorial we will see how it is possible to use the Raspberry Pi as a AMQP (Advanced Message Queuing Protocol) client and connect it to Windows Azure Service Bus that supports the AMQP version 1.0.
Obviously, the choice of the client library is almost forced : Apache Qpid Proton. This library developed in C still provides the bindings for other languages including Java, Python, and PHP but in the course of the article we will use only the native version.
Generally, the Raspberry Pi is used with the Raspbian (based on Debian) distribution which is a Linux distribution. This means that we can install the Qpid Proton library as we do on a normal Ubuntu distribution on a PC or on a virtual machine on Windows Azure.
Connect to the Raspberry Pi
All of the following operations can be performed by directly accessing the Raspberry Pi through a monitor, keyboard, and mouse connected to it or remotely through the use of SSH connection.
The latter solution is certainly the most convenient, usi ...
As a further confirmation that Microsoft wants to be part of the business of the Internet of Things, was released a "limited preview" of a new product on Azure: Azure Microsoft Intelligent System Service.
The primary objective is to provide a single platform capable of acquiring data generated by heterogeneous systems (and thus non-Microsoft) for further processing and analyzing in real-time with tools like HDInsight.
The main features will be :
Connectivity : ability to connect any device regardless of onboard operating system;
Configuration : definition of rules to automate processes on the device;
Administration : ability to monitor, configure and update devices in the field;
Extensibility : greater scalability and efficiency through infrastructure based on cloud;
At the following link, it is possible to request a limited preview to which potential users will have access as a result of a questionnaire for assessing the project to ...
One of the protocols most commonly used in the messaging systems that can be also used for the Internet of Things is the AMQP (Advanced Message Queuing Protocol) that already is OASIS standard and now it is at version 1.0.
The Service Bus offered by Windows Azure supports this protocol, that ensures communication between clients developed on different platforms. In the case of a Microsoft platform we have no problem thanks to the Windows Azure SDK (now at version 2.3) that completely abstracts the underlying communication protocol with the Service Bus (AMQP, SBMP, ...) thanks to its programming model.
if we are working on a non-Microsoft system, one of the best choices is to adopt the libraries of the Apache Qpid project and in particular the Qpid Proton. This library is developed in C and it provides the bindings for other languages including Java, Python, and PHP.
In this tutorial, we will see how to create an Ubuntu Server 12.04 LTS virtual machine on Windows Azure, install and use the Qpid Pr ...
With a week later than the expected output, I finally released in Beta an MQTT broker completely developed in C# that can run on .NET Framework and .NET Compact Framework 3.9 (on systems with Windows Embedded Compact 2013) his name is ... GnatMQ !
It has the M2Mqtt library “core” with which it shares the features of MQTT protocol about the part of the connection to the clients and the messages management.
Obviously, it is completely open source and available on CodePlex but is currently in Beta version (aspect numerous reports on your part!).
Main features included in the current release :
All three Quality of Service (QoS) Levels (at most once, at least once, exactly once);
Will message (QoS, topic and message);
Username/Password via a User Access Control;
Subscription to topics with wildcards;
Publish and subscribe handle using inf ...
Yesterday, my afternoon's work was interrupted by one of the most beautiful email that I could receive: I was nominated as a Microsoft MVP for Windows Embedded category !
This award is the result of my passion and desire to share my knowledge with other people that started in 2011, the year in which I began to follow events organized by my current regional community DotNetCampania, which are subsequently became a member. Kidnapped from the soul with which they were held events, I have decided to become an active part of it and my first thanks go to all those that are part of it, because it is thanks to them that I have received this award which of course is for all them !
Thanks to Cristina Gonzalez Herrero who is my MVP community lead starting from yesterday and who will follow me in this year to do better for the community.
Thanks to all the Italians Windows Embedded MVP who believed in me. In the time order I first met them, thanks to Valter Minute, the first guru and symbol of the Microsoft e ...
Today is "born" a new dedicated website by Microsoft on the Internet of Things that talks about the Internet of Your Things and highlights that the IoT can be achieved by each of us with his own "things" that can interconnect with each other through the Cloud.
On the website you can find all the information about this new (or already mature ?) project on which Microsoft is focusing its business using what is already good for the embedded world (all operating systems of the Windows Embedded family to which I would add the .NET Micro Framework) and joining it to the powerful of the Cloud (Microsoft Azure is well known).
It's true what the new CEO Satya Nadella said with intention to want "a cloud for everyone , on every device" for which the #cloud4device can be understood in its most general main, not only smartphones and tablets but also devices and "things" that connect to the big network !
You can subscribe to a newsletter that will begin on July 1st, but ... maybe from that date ... we'll see ...
If using 188.8.131.52 version you realize that Connect and Disconnect events are not raised ... it is correct ... they are not handled in the client and you need to update the library or ignore them !
I released an update M2Mqtt library (version 184.108.40.206) that lays out this oversight.
Following the code merge between the M2Mqtt client library and the future GnatMQ broker I made the mistake of including the SUBSCRIBE, UNSUBSCRIBE, CONNECT and DISCONNECT messages handling also in the client (of course without any sense) with the corresponding events.
The update is available as always on Nuget and I proceeded to update the corresponding M2Mqtt4CE component for Windows Embedded Compact 2013.
View this page in another language: