How to Quick Connect STM32U5 to Azure IoT Central
- Subscribe to RSS Feed
- Mark as New
- Mark as Read
- Bookmark
- Subscribe
- Email to a Friend
- Printer Friendly Page
- Report Inappropriate Content
on ‎2021-10-26 1:29 PM
STM32U5 Azure Quick Connect is the fastest way to get your B-U585I-IOT02A Discovery Kit up and running with Azure IoT Central and Plug and Play. This demonstration reduces software requirements, configuration steps, and start-up time to show how easy it is to leverage IoT solutions with STM32 microcontrollers and Azure IoT.
Goal: Connect the B-U585I-IOT02A Discovery Kit to a free Azure IoT Central Application and publish sensor data (as seen below) within a matter of minutes.
1. Software Requirements
- Python 3
- Ensure install includes pip and python is added to path
- PySerial
- Install using pip
- STM32U5 Azure Quick Connect Package:
2. Hardware Requirements
- B-U585I-IOT02A Discovery Kit
- Micro-USB Cable
3. Create an Azure IoT Central Application
Click the Quick Connect Application Template and login with a valid Microsoft account (no subscription required)
After choosing a unique Application name, URL, and Pricing plan click ‘Create’
4. Add A Device to the Central Application
In the menu on the left select ‘Devices’
Select ‘New’ to add a new device
Enter a unique ‘Device name’ and ‘Device ID’
Choose ‘B-U585I-IOT02A IoT Node 2 discovery kit.’ as the Device Template.
Make sure ‘Simulate this device’ is not selected
And select ‘Create’
Your new device should now populate in the devices tab
5. Collect Connection Credentials
Click on the ‘Device Name’ of the device you want to connect to
Click ‘Connect’
Here you can view all the required device Connection Credentials
In File Explorer Navigate to STM32U5_Azure_QuickConnect and open Config.txt
Enter the Wi-Fi SSID and Password for your 2.4Ghz network
Copy and Paste the ID Scope, Device ID, and Primary Key into this file and save.
6. Run Quick Connect Executable
Connect your Discovery Kit using the Micro-USB cable as pictured below
Ensure that you downloaded the correct STM32U5_Azure_QuickConnect package for you operating system above and run the STM32U5_AZURE_QuickConnect.exe
Script logs can be seen in the window:
8. Monitor Device Activity
Navigate back to your device in your central application and you can see a summary of the incoming data
Under ‘Raw data’ specific MQTT messages can be viewed
9. Next Steps
Customize the Dashboard and Manage Devices in Azure IoT Central
Export data from IoT Central Application
- Mark as Read
- Mark as New
- Bookmark
- Permalink
- Email to a Friend
- Report Inappropriate Content
This was very helpful! Where can we find the source code for this application?
- Mark as Read
- Mark as New
- Bookmark
- Permalink
- Email to a Friend
- Report Inappropriate Content
Here is the link to the source code: https://github.com/azure-rtos/samples/releases/download/v6.1_rel/Azure_RTOS_6.1_B-U585I-IOT02A_IAR_Samples_Beta_2021_10_01.zip
It is not exactly the same as the code used in this tutorial as the quick connect example is intended as an introduction/demonstration.
- Mark as Read
- Mark as New
- Bookmark
- Permalink
- Email to a Friend
- Report Inappropriate Content
Thanks for you reply!
I already went through this and made it work - a little caveat though, I had to build it using IAR IDE and was hoping if it's supposed to be added to the STM32CubeIDE projects sometime soon?
Alternatively, I can convert it to an STM32CubeIDE project I assume, but would be great to have everything at one place.
- Mark as Read
- Mark as New
- Bookmark
- Permalink
- Email to a Friend
- Report Inappropriate Content
Any chance I can get the source code of ​ this project on B-U585I-IOT02A Discovery Kit?
there isn't source code from Github. thanks!​
- Mark as Read
- Mark as New
- Bookmark
- Permalink
- Email to a Friend
- Report Inappropriate Content
Is there any user guide: Using STM32Cube IDE to connect B-U585I-IOT02A Discovery Kit to Azure IoT?