Karthik Murugan
Karthik Murugan

Reputation: 1439

Understanding AWS IoT from an Application perspective

I understand Aws IoT from a device perspective that it should connect with a certificate and sync with its shadow and push messages to topics. But I struggle to understand from the perspective of a Web App or a Mobile App. My basic questions are,

  1. How to register an Application with AWS IoT?
  2. What is the Authentication and Authorization mechanism for Applications?
  3. How to grant an App access to a set of devices?
  4. How can the App listen to messages from devices of interest?
  5. How can the App send a command to device? I understand this is by updating Device's shadow?

Upvotes: 0

Views: 221

Answers (1)

Keivan
Keivan

Reputation: 1781

Generally, if you want to connect any application (Mobile, Web,...) to any AWS Services, you should consider two things. First, using AWS SDKs which you can find them here. Second, the application should have correct Authentication and Authorization attached to a user/group defined in IAM or Cognito. In regards to your questions:

  1. For registering an application in AWS IoT, first it should be defined as an IoT thing and with correct policies, it can publish/subscribe to topics. Consider that, you should put certificates into the device. For connecting to AWS IoT services you can use AWS IoT SDKs, more information can be found here.

    2 & 3. It depends on your project. You can define your application to have access to a specific thing in AWS IoT or you can define it to access all things in AWS IoT service (using IAM, Cognito or Temporary Security Credentials). You should consider correct policies for your application. You can find more information about authentication and authorization for AWS IoT here.

  2. AWS IoT has MQTT broker which handles the communication between entities that publish or subscribe to a topics. So if the application wants to get data from specific device, it should subscribe to the topic that things publish to.

  3. It can be done by publishing data to a topic which thing has subscribed to.

Thing shadow is actually the digital twin of actual thing so it should contains information which is related to the thing such as available resources, etc.

Upvotes: 2

Related Questions