S3A7 with Smart Energy Meter IoT Kit – Quick Start Guide

 

This tutorial will show you how to get started with the Smart Energy Meter IoT Kit which includes the Renesas RL78/I1C, Renesas S3A7 Fast Prototyping kit, Renesas IoT Sandbox services and IoT workflows.

What you need to get started:

  1. RL78/I1C MeasureIt! Kit
  2. S3A7 Fast Prototyping Kit
  3. Opto-isolation UART module
  4. WiFi Internet access
  5. Smart Meter Image (updated 10-3-16)

Recommended Reading:

 

Step 1: Program The Kit

Before you begin, flash both S3A7 kit with the Smart Meter Image  image using this guide: How to flash the S3A7 board

Step 2: Activate Kit in Renesas IoT Sandbox

Click here to activate the kit and complete the registration process to create a Renesas IoT Sandbox account preloaded with the SmartEM demo workflows.

Note: Be sure to use the activation link provided in this guide because it will create specific Renesas IoT Sandbox workflows for this demo.  If you already have a Renesas IoT Sandbox account, a new project will be added to your account for this demo.

Once activation is completed, you will receive an email with your account credentials needed to provision the kit and access the cloud portal.  

This will include:

  • Renesas IoT Sandbox web login
  • API Key
  • Device username and password

 

Step 3: Connect the S3A7 kit to the Cloud

Provision the Board for WiFi and Renesas IoT Sandbox API:

  • Power up the board by connecting the USB cable into J1 on the board and then either power with battery or by connecting to a USB port (i.e. on laptop).  Touch the screen within 10 seconds of powering up the board to boot it up in provisioning mode and the board will become a WiFi Access Point.

smartchef_connect_pic1

  • When you see the screen below, connect to the board from a computer via the WiFi network printed at the top of the screen.  This is a Wifi Access Point served by the board and is a unique SSID.  Note: keep a copy of your activation email readily available.  Once connected to the board’s Wifi Access Point, you will not have internet access on your computer
  • Note: Due to the small font size of the screen, the SSID and password could contain lower and upper case letters and numbers. Therefore, if you encounter a password mismatch, try both zero (0) and upper O (O) and also one (1) and lower L (l).

file_000-2

  • Once connected, open the provisioning page served by the board by going to  http://192.168.3.1 on your browser.  

  • On the provisioning page, enter the WiFi information from your home or office network (the router which will be linked to the board). You will need to specify the router’s WiFi authentication mode.  If you’re not sure, most Wifi routers use WPA2 so try that first.  The other possible Wifi authentication modes are Open (non secure), WEP with 40 or 128 key, and WPA.

screen-shot-2016-10-01-at-7-28-58-pm

  • Also enter the Renesas IoT Sandbox API credentials emailed to you when you activated the kit in Step 2.
  • After entering the information, click Connect.  This will automatically exit out of provision mode and you will see an error screen similar to the one below. This is expected because the board is no longer in provisioning mode.

smartchef_page_isnt_working

  • Next, you will need to power down the board by removing the USB cable to connect the Measure It! kit.

 

Step 4: Connect to the Smart Energy Meter

The UART module must first be connected to the RL78 Power Meter.

img_2892

pasted-image-at-2016_10_08-02_36-pm

Ensure the UART signal wires are brought safely out of the RL78 enclosure. Next connect the UART signals to the S3A7 board to port J6 of the S3A7 board.

Now connect your RL78 Power Meter to any electrical appliance or device.

The S3A7 board will acquire data every 10 seconds and send it to Renesas IoT Sandbox.  For a full list of the data collected refer to Appendix C.

 

Step 5: Configure Workflows

Let the board acquire data for several minutes.  After a few minutes, you can analyze the Greenhouse Gas emitted by the electrical appliance, as well as, the energy consumed using the two pre-built workflows in the Smart Energy Meter IoT kit.

screen-shot-2016-10-27-at-4-58-23-pm

 

The Greenhouse Gas workflow uses the following U.S. EPA carbon dioxide emission calculation: 7.03 × 10-4 metric tons CO2 / kWh

greenhouse-gas-workflow

 

 

The Time of Use workflow uses PG&E’s rate scale based on electricity usage during peak and off-peak hours during summer and winter.

time-of-use-workflow

 

Step 6: Reports

There is a wide variety of reports and dashboard visuals you can obtain about your electrical appliance/device.  You can view data in real-time such as Active Energy KW, Frequency Hz, and Active Power W.

fireshot-capture-16-m1-i-dashboard

Step 7: What’s Next

Congrats! You have just created an IoT Enabled Smart Energy Meter prototype! 

Next, we recommend you try this tutorial: Create A Workflow To Send Email Triggered By The Mobile App

The rest is up to your imagination.  Here are some advanced tutorials in the Appendix.

Appendix

A: Data Collection

The following tags are collected by the IoT Enabled Smart Energy Meter Kit (sent every 10 seconds):

Tag Name Description
error Error messages
ip_address WAN IP Address
socket1ActiveEnergyKWh Socket 1 Active Energy (kWh)
socket1PowerFactor Socket 1 Power Factor
socket1FrequencyHz Socket 1 Frequency (Hz)
socket1IRMSA Socket 1 Current (RMS-A)
socket1ActivePowerW Socket 1 Active Power (W)
socket1VRMSV Socket 1 Voltage (RMS-V)
socket1CostPerHour Socket 1 Cost / hour
socket2ActiveEnergyKWh Socket 2 Active Energy (kWh)
socket2PowerFactor Socket 2 Power Factor
socket2FrequencyHz Socket 2 Frequency (Hz)
socket2IRMSA Socket 2 Current (RMS-A)
socket2ActivePowerW Socket 2 Active Power (W)
socket2VRMSV Socket 2 Voltage (RMS-V)
socket2CostPerHour Socket 2 Cost / hour