Azure Event Hubs C Client - azure

I am trying to send messages to Azure Event Hubs from an Arduino with a Wifi extension. Is there a way to upload the data without using the provided libraries?

You will need some kind of device to act as a gateway. The Adruino board cannot provide this functionality. Most likely, you will need to connect the device to a Raspberry Pi and send the messages using the Pi. Below is directions and code on how to set this up.
https://github.com/MSOpenTech/connectthedots

Related

Send REST API requests through Azure IoT Hub to a Raspberry Pi webserver

I'll start off by apologizing if this has been asked and answered, but I've been researching this for a few days and either I'm not understanding what I'm reading or I'm trying to do something unique or not possible(guessing it's the former).
Currently what I have is a Raspberry Pi that has a webserver running and a web UI for controlling what's connected to it. It has a slew of REST API's that can be accessed to perform various tasks. I have a couple of these setup with static IP addresses and all works great. My problem is scale. The potential exists to have hundreds(to thousands) of these running and need to be controlled by a single mobile app. I don't want to have thousands of static IP's. Though this would be the easiest solution it certainly wouldn't be cost effective and most likely a nightmare to manage.
My desire is to "connect" all of these Raspberry Pi webservers to the Azure IoT hub. The webservers do not need to talk to each other, but the mobile app needs to be able to send REST messages to each server individually.
The coding of the app, the coding on the Pi's and any additional coding is not an issue. I've been an applications developer for over 20 years so coding is not an issue.
So, my questions are:
What is the minimum necessary to be running on the Pi to connect to the Azure IoT Hub?
Do I understand correctly that to do what I've described above, I have to send a message to the Hub and then the Hub sends a message to the device?
Does anything exist to define the Pi as an endpoint and just be able to send the REST messages directly to that?
Any help provided, even links to relevant documents, would be greatly appreciated. Thank you!
Have you checked the official documentation? It contains an example of what you're trying to achieve (send data from device to iot hub / send command from iot hub to device)
https://learn.microsoft.com/en-us/azure/iot-hub/iot-hub-csharp-csharp-c2d
All you need is the connection string to the Azure IOT Hub. To register your device, please visit: https://learn.microsoft.com/en-us/azure/iot-hub/iot-hub-devguide-sdks

Connecting to a custom device via Bluetooth when its SDK is unavailable

I am building an Android app in which I need to connect to an custom device over classic Bluetooth (preferably). My problem is SDK for that device is not created to facilitate the connection. Now I am stuck onto the part where I need to create a Socket which will be opened by the custom device which is acting as a server and other Android devices will act as clients and connect to it.
I am stuck at the part where we need to have identical UUIDs at both client and server for the socket connection to work. I am following the BleutoothChatApp as reference for this but I cannot always make sure that both my app and custom device will have identical UUIDs. Because I may or may not be able to hard code the UUID in custom device.
What can I do in such case.?
Also when I try to use BLE and search for services, I discover only one service which has no description or anything.
What can I do in such cases. What will be the best approach to create a connection to that device.?
You get multiple UUIDs for the same device because the devices offer multiple services. Base UUID for Bluetooth is "00000000-0000-1000-8000-00805F9B34FB".
If you find this UUID in a device, it means it supports Bluetooth Service. Use the UUID for connecting to the device.

Parse Arduino Uno data directly to IoT

I'm making a temperature, humidity and moisture sensor system where data should be sent over to Iot hub (Cloud) every second. I have used an Arduino and Ethernet shield.
I'm able to create sensor data every second. It sends this data to the IoT hub directly from Arduino without a Raspberry Pi or PC|VS Studio. I have already created a job stream on Azure as well. Is there any mechanism with which I could send this data to Azure IoT hub directly? Thanks in advance.
You can look at the libraries for IoT Hub here:
Azure IOT SDK for C
A Quick search on the Arduino site also contains lots of examples of devices connecting to the IoT hub. I imagine you can use both AMQP and also MQTT protocols for this directly from your Arduino. I'm using MQTT in my ESP8266's without VS involved, all written in the Arduino IDE.
You can also find the Azure IoT Arduino libraries here.
Note that required libs (AzureIoTHub, AzureIoTUtility, AzureIoTProtocol_HTTP and AzureIoTProtocol_MQTT) are all published in the Arduino IDE lib manager, so you can just install them from there (no need to clone the repos).
The docs and the samples are not quite up to date (which we'll fix real soon) but you can find an MQTT sample in the MQTT lib repository.

Connecting Android device sensors with NodeRED

I am new bee to NodeRED. I refer tutorial on NodeRED connecting devices such as raspberry PI. The partial documentation on NodeRED Website is available that states that how developers can reads sensors connected to GPIO pins on Raspberry PI.
Similar way, I would like to know - how can I read sensors (e.g., proximity sensors, GPS, Accelerometer) on Android device with NodeRED? More specifically, I would like to play with Android device sensors with NodeRED? I have tried to google documentations related to it, but did not find it.
You will need to write an Android app to expose the sensors in a way that can be ingested into Node-RED, I would suggest publishing the values to a MQTT broker.
Node-RED can then subscribe to the topics and process the sensor values.
write an android app, that will expose the android sensor.
either push the data from Android to MQTT server (best choice) or use a microservice like AWS lamda or Firebase .
if used pub-sub with MQTT call it on Node-red, or call Lamda function Api endpoint on node-red or call the firebase directly on Node-red,
choose wisely according to your requirements.

nodejs IoT device to device communication

so im working on a my bachelor thesis and for that i need to implement, in a smarthome, d2d communication between IoT devices. So i want to implement the usuall server work, like noticing if a device connects/ disconnects etc. to the IoT devices, so no server/hub is needed at home.
But I can't find good solutions for it, for websockets i need a server, for mqtt a broker and so on, but all need a server.
I found that d2d is done with "LTE" similar technology but i would like to do it with web-protocols.
So my question:
Is there a way to let IoT devices talk to each other over the network?
My IoT devices (raspberry pis) currently use nodejs with typescript but I'm not starting a server, they only have a mqtt connection to publish there sensor data to the users.
Thanks in advance.
And if im understanding something wrong, please say it. :)

Resources