Implementation
The implementation steps are very similar to that we did in the previous chapter for the smart temperature sensor:
- Create a smart home skill.
- Create and configure a Lambda function to handle the requests from the smart home skill.
- Link the Amazon account to the skill and enable the skill.
- Create a thing in AWS IoT Core.
- Develop the Lambda function and test it.
- Develop the smart fan firmware.
- Test the smart fan with voice commands.
Since we have already examined this procedure in detail in Chapter 11, Connectivity Is Never Enough – Third-Party Integrations, I will fast-forward through them and discuss the application code more. Let's begin by creating the smart home skill.
Creating the skill
As of the time of writing this book, the AVS command-line tool (version 2.22.4) doesn't support smart home skills, so we will stick with the web GUI for the skill operations. Here are the steps to create a skill:
-
...