![Microchip Technology ATWINC 15x0 Скачать руководство пользователя страница 46](http://html1.mh-extra.com/html/microchip-technology/atwinc-15x0/atwinc-15x0_developers-manual_1785757046.webp)
5.6
AWS Lambda Setup
Lambda functions are needed to process the directives received from Alexa Skills. There are two Alexa
Skills for the Wi-Fi Smart Device Enablement Kit (Microchip Wi-Fi Smart Device Smart Home Skill and
Microchip Sensor Board Skill). Each Alexa Skill needs one Lambda function for processing the directives.
Details of the skills are described in
5.6.1
Lambda Setup for Microchip Wi-Fi Smart Device Smart Home Skill
Lambda function code for this Smart Home Skill is available in the
\lambda-function\alexa-
smart-home-skill
directory.
Perform the following steps to set up Lambda for Microchip Wi-Fi Smart Device Smart Home Skill:
1.
Go to AWS Lambda Console in AWS cloud
https://console.aws.amazon.com/lambda
.
2.
Click
Create Function
.
3.
Select "Author from scratch" and fill in the following:
3.1.
A name for the Lambda function. For example: “WiFi-Smart-Device-Kit-Smart-Home-Skill”.
3.2.
Select "Node.js 6.10" from the "Runtime" drop down.
4.
Select a role for the Lambda function from the “Roles” field (user can create a Role in IAM console,
the role must have "AWSLambdaFullAccess" and "CloudWatchLogsFullAccess" policy). The
following figure shows the “lambda_basic_execution” role.
5.
Go to IAM console, select “Roles” and select “lambda_basic_execution” role. Attach policy
"AWSLambdaFullAccess" and "CloudWatchLogsFullAccess".
Figure 5-31. Creating a Lambda Function
ATWINC15x0 Smart Device Kit
AWS Setup
©
2019 Microchip Technology Inc.
User Guide
DS50002885A-page 46