Microchip® Advanced Software Framework

 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages
WINC1500 IoT Cloud Demo for SAMW25 XPlained Pro Documentation

Introduction

This example demonstrates the use of the SAM Xplained Pro with I/O1 Xplained Pro board to communicate with Atmel IoT Android app & PubNub cloud.
It uses the following hardware:

  • SAM Xplained Pro.
  • the WINC1500 module on EXT1.

Main Files

  • main.c : Initialize the SAM board and communicate with Android App & PubNub cloud.

Usage

  1. To connect the SAM board to the internet Access Point over Wi-Fi, the user must
  2. provide credentials (typically SSID and passphrase). To do so, the user must enter
  3. provisioning mode by holding SW0 button down for at least 3s. Led0 will start to
  4. blink fast as soon as provisioning mode is activated. Finally two methods are
  5. avalaible to input credentials:
  6. - Using provisioning web page (user must connect to AP name WINC1500:XX_XX and
  7. open a browser to atmelconfig.com)
  8. - Using Android application (user must click on AP name WINC1500:XX_XX and fill up
  9. the credential popup)
  10. Provisioning AP name, sensor name and pubnub channel are all configured as
  11. WINC1500:XX_XX where XX_XX is essentially the last four digits of the MAC address.
  12. WINC1500 MAC address is printed on the sticker on top of the module.
  13. Credentials need only to be provided once, as they are stored in non volatile
  14. memory inside the WINC1500. It is still possible to enter provisioning mode again
  15. to connect to another Access Point by holding down the SW0 button for 3s.
  16. Build the program and download it into the board.
  17. On the computer, open and configure a terminal application as the follows.
    * Baud Rate : 115200
    * Data : 8bit
    * Parity bit : none
    * Stop bit : 1bit
    * Flow control : none
    *
  18. Start the application.
  19. In the terminal window, the following text should appear:
    * -- IoT Cloud Demo --
    * -- SAMXXX_XPLAINED_PRO --
    * -- Compiled: xxx xx xxxx xx:xx:xx --
    *
  20. Once the Wi-Fi is provisioned with internet access connect to PubNub
  21. website http://www.pubnub.com and login with your account (free).
  22. Start the application. Go to your Admin Portal and click on Debug Console.
  23. From here:
  24. Enter Channel, Publish and Subscribe key as specified on the UART.
  25. Ensure SSL is enabled.
  26. Connect to the cloud by pressing the subscribe button.
  27. After reporting the first data to PubNub server, it is then possible to connect
  28. to https://freeboard.io to configure a dashboard and to show reported data.

Compilation Information

This software was written for the GNU GCC compiler using Atmel Studio 6.2 Other compilers may or may not work.

Contact Information

For further information, visit Microchip.