Implementation for accessing IoT AWS IoT

AWS IoT provides secure, bi-directional communication between Internet-connected things (such as sensors, actuators, embedded devices, or smart appliances) and the AWS cloud. You can discover your custom IoT-Data endpoint to communicate with, configure rules for data processing and integration with other services, organize resources associated with each thing (Thing Registry), configure logging, and create and manage policies and credentials to authenticate things.

For more information about how AWS IoT works, see the Developer Guide.

Inheritance: AmazonServiceClient, IAmazonIoT
コード例 #1
0
ファイル: IotData.cs プロジェクト: aws/aws-sdk-net
        public static void Cleanup()
        {
            if (!string.IsNullOrEmpty(CREATED_THING_NAME))
            {
                using (var iotClient = new AmazonIoTClient())
                {
                    iotClient.DeleteThing(CREATED_THING_NAME);
                }
            }

            if (Client != null)
            {
                Client.Dispose();
            }
        }
コード例 #2
0
ファイル: IotData.cs プロジェクト: aws/aws-sdk-net
        public static void ClassInitialize(TestContext testContext)
        {
            Client = new AmazonIotDataClient("https://data.iot.us-east-1.amazonaws.com/");

            using (var iotClient = new AmazonIoTClient())
            {
                var things = iotClient.ListThings().Things;
                var firstThing = things.FirstOrDefault();
                if (firstThing == null)
                {
                    THING_NAME = "dotnettest" + DateTime.UtcNow.ToFileTime();
                    iotClient.CreateThing(new CreateThingRequest
                    {
                        ThingName = THING_NAME
                    });
                    CREATED_THING_NAME = THING_NAME;
                }
                else
                {
                    THING_NAME = firstThing.ThingName;
                }
            }
        }