esp-idf/examples/protocols/aws_iot/thing_shadow
Roland Dobai 27a63c492f Examples: Demonstrate the usage of esp_err_to_name 2018-03-13 14:27:00 +01:00
..
main Examples: Demonstrate the usage of esp_err_to_name 2018-03-13 14:27:00 +01:00
Makefile
README.md
sdkconfig.defaults

README.md

Amazon Web Services IoT Thing Shadow Example

This is an adaptation of the AWS IoT C SDK "shadow_sample" example for ESP-IDF.

Provisioning/Configuration

See the README.md in the parent directory for information about configuring the AWS IoT examples.

After following those steps, there is one additional step for this exmaple:

Set Thing Name

For this example, you will need to set a Thing Name under make menuconfig -> Example Configuration -> AWS IoT Thing Name.

The Thing Name should match a Thing that you created while following the Getting Started guide (to check the Things you have registered, go t othe AWS IoT console web interface, click Registry and then click Things).

Monitoring Thing Status

After flashing the example to your ESP32, it should connect to Amazon and start updating the example Thing's shadow.

In the ESP32's serial output, you should see the message "Update accepted" logged every couple of seconds.

You can monitor the Thing status from the AWS IoT console web interface:

  • On the left-hand toolbar, click Registry and then click Things.
  • Click on the "Thing" you set up for the example.
  • Click on the "Shadow" sidebar link. You should see the Thing Shadow updating regularly.
  • Click on the "Activity" sidebar link to see all Thing Shadow updates in a list. You can examine each update individually.

Troubleshooting

If you're having problems with the AWS IoT connection itself, check the Troubleshooting section of the README in the parent directory.

  • If your Thing is connecting and appears to be successfully updating, but you don't see any updates in the AWS IoT console, then check that the Thing Name in the Example Configuration under menuconfig matches exactly the thing name in AWS IoT console (including case).