Skip to content

Run Demo

benpoon-microchip edited this page Aug 29, 2018 · 3 revisions

To run the demo, below steps are include:

  • Create User Account and Configure the Board
  • Network Provision
  • Set up Alexa on Amazon Echo Dot
  • Enable Skill
  • Control and Monitor the Secure WiFi Board Using Voice Commands With Your Echo Dot

Create User Account and Configure the Board

  1. Open command prompt in Windows, navigate to the directory of the Java PC Application secure-wifi-board-java-desktop-app/

  2. Run the following command: Java -jar Secure-WiFi-Board-CognitoUI-1.0-jar-with-dependencies.jar Below screen is shown:

  3. Before signing in, a new user will need to sign up an account by clicking the Sign-Up Button, UI show the Sign-Up Form as below

  4. Fill in the User name, Password (8 characters min), email and phone number. Click Sign Up Button. (Phone number must start with a plus (+) sign, followed immediately by the country code, for example, +14325551212.)

  5. OTP code will be send to the email. Input the OTP in below UI. “OTP validation is successful” is shown if the OTP code is correct

  6. After you have successfully signed up, click the close button (X) in the upper right corner

  7. Input Username and Password, click Sign-in button to login account.

  8. The application will now show the account UUID and the sensor board AWS IoT Thing ID that is registered to the account. Since you have only just signed up for the account, there should be not be any Thing IDs shown as no sensor board has been registered to the account yet. (In this stage, the application scans a table in AWS DynamoDB. As this is the first time you login, there is no Thing ID record in the DynamoDB table and the application do not show Thing ID in the window. After you register the board Thing ID by performing step 9 to 11, the board Thing ID will be stored in the table in AWS DynamoDB. The application will show the Thing ID in the window)

    Note: A thing is a representation of a specific device in AWS IoT. Thing ID is the name of the thing, which is unique for each device.

  9. Connect the secure Wi-Fi board to PC with USB port

  10. Power on the Secure Wi-Fi board, LD2 on the board blink in blue color and then blink in green color. Windows detect HID USB Input Device.

  11. Click Register Board button
    (PC GUI runs a python script in the background and communicates with the sensor board over USB to get the Thing ID)

  12. The application shows registration success and the Secure Wi-Fi Board Thing ID is now displayed in the window

Network Provision

To set the Secure Wi-Fi board to connect to the Access Point, user can connect the secure Wi-Fi board to PC with USB port, and run below python scripts:
python kit_set_wifi.py --ssid wifi-name --password wifi-password
Where wifi-name = SSID and wifi-password = PASSWORD of your Wi-Fi access point.
Access Point need to operate in WPA2 personal security mode
When the network provisioning is done, LD2 on the board blinks red. The board needs to be rebooted for the new Wi-Fi settings to take effect.

Set up Alexa on Amazon Echo Dot

  1. Install Alexa mobile APP.
    Android devices: https://play.google.com/store/apps/details?id=com.amazon.dee.app&hl=zh_HK
    IOS devices: https://itunes.apple.com/us/app/amazon-alexa/id944011620?mt=8

  2. Create an Alexa account and sign in the Alexa mobile APP

  3. Refer below link to set up Echo Dot:
    https://www.amazon.com/gp/help/customer/display.html?nodeId=201994280

Enable Skill

  1. Launch Alexa mobile APP, Tap ”≡” in the upper left hand cornet

  2. Select Skills

  3. Type “sensor” in the search bar, tap “Microchip Sensor Skill”

  4. Tap ENABLE

  5. Input Secure Wi-Fi Board user account Username and Password that created in Section C. Tap Sign in

  6. The App will now show that the Microchip Sensor Skill has been successfully linked

Control and Monitor the Secure WiFi Board Using Voice Commands With Your Echo Dot

NOTE: You only need to say “Alexa” to prefix opening the sensor board. This opens a session and you don’t need to prefix the command with “Alexa” after you’ve opened the session.

User: Alexa, open sensor board
Echo Dot: Welcome to Microchip Sensor Board Skill. This skill is used to control and get the sensor data from WINC1500 Secure Wi-Fi Board showed in Microchip Master workshop
User: What is the temperature?
Echo Dot: The temperature is 93.70 degrees Fahrenheit, please provide other command.
User: What are the button status?
Echo Dot: The button states are, button1 is up, button2 is up, button3 is up, please provide other command.
User: Turn the light Blue
Echo Dot: The Sensor board light is blue (LD2 on the board turn to blue color), please provide other command.
User: Set Port A 17
Echo Dot: PORT A 17 will be set, please provide other command (PortA 17 on the board is set to high)
User: Clear Port A 17
Echo Dot: PORT A 17 will be clear, please provide other command (PortA 17 on the board is set to low)
User: Stop
Echo Dot: Thank you for using Microchip Sensor board demo. Have a nice day!\

Voice Command List