The first thing we will do is to set up the AWS to create a Lambda Function. To know more about the lambda function go here. Log in to your AWS account and go to My Account
Lo primero que haremos sera configurar los AWS para crear la funcion Lambda. Para saber mas acerca de la función lambda, hacer click aquí. Entra a tu cuenta de Amazon Web Services e ir a Mi cuenta
Then in the AWS Services type Lambda.
Después en el campo de AWS Services teclea Lambda
In the top right part of the screen, make sure that the selected city is N. Virginia.
Hay que asegurarnos que en la parte superior derecha, la ciudad seleccionada sea N. Virginia
After that we will click on create create function.
Después haremos click en create function.
To create the function please select Author from scratch. Then in Name choose the name for your app, then on Runtime, select Node.js 4.3, then in Role select Choose an existing role, then in Role select service-role/lambda_basic_execution.
Para crear la función select Author from scratch, luego en Nombre teclea el nombre de tu applicación, en Runtime selecciona Node.js 4.3, en Role selecciona Choose an existing Role y por último en Role selecciona service-role/lambda_basic_execution.
Once created, we need to drag the Alexa Skills Kit the Add triggers from the list to the left dotted box.
Una vez creada, necesitamos arrastrar la opción de Alexa SKills Kit al cuadro punteado que dice Add triggers from the list to the left dotted box.
Once we drag it we need to press save.
Una vez que arrastremos el Kit de Alexa Skills presionamos guardar.
I am basing myself on the project Alexa, turn on the light by Esther Jun Kim. From her tutorial I got 3 files that we will be uploading and modifying. We must download and adding them to a zip file from here.
Me estoy basando en el proyecto de hackster Alexa, turn on the light de Esther Jun Kim. De este tutorial, ocuparemos 3 archivos que estaremos subiendo y modificando. Debemos descargarlos y comprimirlos a un archivo zip desde esta liga.
Before zipping those files, we must update the file named index.js with some of our own values. The variables that we will be updating are PARTICLE_DEVICE_ID and PARTICLE_ACCESS_TOKEN.
Antes de agregar los archivos al .zip, hay que actualizar unas variables con nuestra información. Las variables que estaremos actualizando son PARTICLE_DEVICE_ID and PARTICLE_ACCESS_TOKEN
To get your Particle values, we go to build.particle.io. Then we go to the device section, and select the device that is online, there will be a cyan circle breathing next to the device name, then we expand the details and we will find the device.
Para obtener el ID del dispositivo, hay que ir a build.particle.io, despues navegamos a la seccion de dispositivos, y de ahí seleccionamos el que esté en linea, lo podremos identificar porque es el que tendrá el círculo color cyan enseguida del nombre. Después expandimos los detalles del dispositivo y ahí encontraremos el ID.
To get you Access Token we navigate to the settings section and we will find the token there.
Para obtener el access token, navemaos a la sección de settings, y de ahí podremos obtener el Access Token.
After getting the files in 1 zip file, we click on the main box in our function and scroll down until we find the part were all the code is, and from the Code entry type, we select Upload zip file, and upload the file we just did.
Después de descargar los archivos y tenerlos listos en un archivo zip, damos click en la caja principal de nuestra función y bajamos un poco en la ventana hasta qeu encontremos la sección de código de la función, de ahi vamos a buscar la parte de Code Entry Type y seleccionaremos la opción de Upload Zip File, y subiremos nuestro archivo zip.
If by any chance later on we want to modify the code (which we will) we can change in the Code Entry Type to Edit Code LIne and it will take us to a part were we will be able to modifiy the files.
Si por alguna razón queremos modificar el código después (que lo haremos), podemos cambiar en Code Entry Type la opción a Edit Code Inline y eso nos llevará a un editor donde podremos moficiar el código.
With this we finish the first part, which is the creation of the lambda function. We have to take note of the function that appears in the upper right corner of the screen.
Con esto terminamos la primera parte, que es la creación de la función lambda. Hay que tomar nota de la función que aparece en la parte superior derecha de la pantalla
The next part is to set up the Alexa Skill set, to do that you go here.
El siguiente paso es configurar el set de Skills de Alexa, para hacer eso da click aquí.
Then we got to Alexa Skill Kit, getting started and then select Alexa Skill Kit.
Después vamo a Alexa Skill Kit, getting started and then select Alexa Skill Kit
Comments