Overview

Skill Level: Any Skill Level

Basic Knowledge of Watson IoT Platform

In this recipe you will learn how to connect the Pressac EnOcean Gateway to the IBM Watson IoT Platform and visualize Pressac sensor data.

Ingredients

  1. A Pressac EnOcean device compatable with the Pressac EnOcean Gateway e.g. CO2, Temperature and Humidity Sensor (EnOcean Radio Protocol Version)
  2. Pressac EnOcean Gateway
  3. Ethernet Cable
  4. An IBM Bluemix account with a running instance of the Watson IoT service
  5. A suitable web browser to connect to both IBM Bluemix and the Pressac EnOcean Gateway configuration pages.
  • Detailed Information on how to register and manage your Bluemix account can be found here
  • A guide to getting started with the Watson IoT Platform can be found here

Step-by-step

  1. Introduction

    Pressac

    Pressac is a privately-owned UK based business with a 60-year history of expertise in the design and manufacture of electrical and electronic solutions for the IoT, industrial and telecommunications markets. Pressac offers its own range of market leading products for the telecoms and building management industries. Our proven expertise and continued success has led a number of blue chip companies to choose Pressac as their preferred development partner and supplier. Pressac’s cutting edge product design and manufacturing facilities are based at the company’s headquarters in Nottingham, UK.

    EnOcean

    EnOcean is a widely established and global technology, and has been installed in over 250,000 buildings worldwide. The EnOcean wireless standard is the first to be ratified as an international standard – ISO/IEC 14543-3-10: together with the EnOcean Equipment Profiles (EEPs) drawn up by the EnOcean Alliance, this international standard lays the foundation for fully interoperable, open wireless technology comparable to standards such as Bluetooth and WiFi. The standard can be downloaded from www.iso.org.

    IBM Watson IoT Platform

    The IBM Watson Internet of Things Platform is a fully managed, cloud-hosted service that makes it simple to derive value from Internet of Things (IoT) devices. When combined with the IBM Bluemix platform, Watson IoT Platform provides simple, but powerful application access to IoT devices and data. You can rapidly compose analytics applications, visualization dashboards, and mobile IoT apps. Create IoT applications that feed insights to your backend enterprise applications.

  2. Architecture

    This recipe consists of 3 main components, a Pressac EnOcean radio protocol device e.g. CO2 Temperature and Humidity Sensor, Pressac EnOcean Gateway and the Watson IoT platform. The Pressac EnOcean device is connected to the Pressac EnOcean Gateway via the EnOcean radio protocol, the Pressac EnOcean gateway facilitates the connection to the Watson IoT platform.

    Architecture-Master

    About the components

    Pressac EnOcean Radio Protocol CO2, Temperature and Humidity Sensor

    The Pressac Sensing wireless EnOcean CO2, Temperature and Humidity Sensor is designed to measure and report levels of Carbon Dioxide, ambient temperature and relative humidity in an internal environment. During normal operation, the sensor is powered from ambient room light: in prolonged low light environments, the security of battery back-up ensures continued operation for up to 10 years of maintenance free operation. This version of the sensor supports the open EnOcean standard (ISO/IEC 14543-3-10).

    For more details on this device and Pressacs other devices, visit http://www.pressac.com/

    Pressac EnOcean Gateway

    The Pressac EnOcean gateway serves as a bridge between the EnOcean radio protocol and a TCP/IP network. Availible in Ethernet only and Ethernet, LTE and WiFi varients the Pressac EnOcean gateway sends sensor data via MQTT along with facilitating direct integration to cloud platforms including IBM Watson IoT platform. With an easy to use web-interface the Pressac EnOcean gateway makes managing your devices and cloud connections easy.

  3. Step 1: Setting up the Pressac EnOcean Gateway

    Plug in one end of the Ethernet cable into your network point and plug the opposite end of the cable into the Ethernet port on the Pressac EnOcean gateway.

    Connect the EnOcean antenna along by screwing it onto the connection on the Pressac EnOcean Gateway taking care not to cross thread or bend. If your gateway supports LTE and WiFi attach the antennas for these aswell.

    Connect your Pressac EnOcean Gateway’s power supply, connecting the power supply will boot up the Pressac EnOcean Gateway and you will see the products LED start blinking. The Pressac EnOcean Gateway will take a few seconds to initialise.

    Next you need to find the IP Address of the Pressac EnOcean Gateway the most common way of doing this is to check your routers list of connected devices. If this is not possible the following alternative methods can be used.

    1. Windows: The Pressac EnOcean Gateway announces itself over Universal Plug and Play (UPnP) and can be found in the “Gateways” or “Other Devices” section of the Windows Network area to find this area click “Start” search for “Network” and click “View network connected computers and devices”. Double clicking a gateway from here will open up the web-ui.
    2. Mac: The Pressac EnOcean Gateway can be discovered using Bonjour. One of the easiest ways of using this method is to open “Safari” go to “Preferences” then “Advanced” and tick “Include Bonjour in the Bookmarks menu” close Preferences navigate to “Bookmarks” and you will now see all your networked Bonjour devices including the Pressac EnOcean Gateway.

    Now you have the IP Address you can use it to access the Pressac EnOcean Gateways web interface launch your chosen web browser and type http://<your-ip> e.g. http://192.168.1.188 This will display the Pressac EnOcean Gateway’s first boot wizard. Follow the steps on the wizard to set up your Pressac EnOcean Gateway for the first time.

    pressac-enocean-gateway-boot-wizard

  4. Step 2: Add a Device to the Pressac EnOcean Gateway

     

    To learn-in a new device click “– Add Devices” in the EnOcean sub-menu on the Pressac EnOcean Gateway web-interface and then click “Start” .

    pressac-enocean-gateway-add-device-1

    This will initiate a 60 second countdown, during these 60 seconds the Pressac EnOcean Gateway will listen for the learn telegrams of devices in range of the Pressac EnOcean Gateway. This process can be cancelled by clicking “Cancel” and re-started for another 60 second duration by clicking “Search” again.

    Ensure the Pressac EnOcean Gateway is listening for learn telegrams and press the “Learn” button on your Pressac device to locate the learn button for your device please consult your devices manual. In this example we will be using the Pressac CO2, Temperature and Humidity Sensor this devices learn button can be exposed by removing the CO2, Temperature and Humidity Sensor back plate as shown in the image below.

    CO2-Sensor-Learn-Button

     

     

    A new device entry will now appear in a table with the following columns

    Last Seen – The Date and Time the Pressac EnOcean Gateway last received a telegram from the device

    Device ID – The unique identification number of the device

    EEP – EnOcean Equipment Profile used by the device.

    Security – Security enabled on the device Yes / No

    dBm – Signasl strength of the device to the gateway

    Action – The action column contains a menu containing options to EDIT AND ADD and DELETE the device.

    pressac-enocean-gateway-add-device-device-edit-add

    Click on “Edit and add” from the menu under the Action column as shown in the above image to edit the device a new screen will appear as shown in the image below.

    pressac-enocean-gateway-add-device-edit-device

    The only required field is the device name this is the identifier which the IBM Watson platform will use for your device. It is advised to use a device name which resembles the function and location of the device. e.g. If your device is a CO2, Temperature and Humidity Sensor and it is situated in Classroom 1, your Device Name could be “Classroom1-CO2-Temperature-Humidity”.

    Other optional properties include the location of your physical device. Please note that only characters A-Z, numbers, ‘_’ and ‘-‘ are permitted to be used in any of these fields.

    Once you have specified your desired device name and any of the other optional properties click “Save” at the bottom of the screen to save the entry.

    You can now navigate to the Devices page and see the device along with its last state.

     

  5. Step 3: Configuring the IBM Watson IoT Platform

    Create Gateway Device Type

    Each Gateway connected to IBM Watson IoT Platform is associated with a device type. For the Pressac EnOcean Gateway to communicate with the IBM Watson IoT Platform we need to create its device type. Please follow the steps below for which you will need a Bluemix account with a running instance of the IBM Watson IoT platform.

    From the IBM Watson IoT Platform dashboard click “Devices” from the left menu then the “Device Types” tab then finally the “+ Create Type” button as shown in the image below.

    1-Watson-Create-Type-Device 

    You will now be presented with 2 options “Create device type” and “Create gateway type” as shown in the image below. Click on “Create gateway type

    2-Watson-Create-Device-Type-2

    The screen should now automatically proceed to the “General Information” screen as shown in the image below. In the “Name” field type “EnOcean” this will be the name of our Pressac EnOcean Gateway Device Type.

    3-Watson-Device-Type-Name

    Click “Next” located at the bottom right of the page you should now see the “Define Template” screen from here you can select attributes for the device type all attributes are optional and for the sake of this recipe we aren’t going to select any.

    4-Watson-Define-Template

    Click “Next” the Submit Information screen will now appear, if you defined any of this information in the previous step you can confirm it is correct at this point.

    5-Watson-Create-Gateway-Submit-Information

    Click “Next” the optional Metadata screen will now appear again we will not be defining any.

    6-Watson-Create-Device-Type-Optional-Meta-Data

    Now Click “Create” in the bottom right corner of the screen. You will now be taken back to the Devices Dashboard area of the IBM Watson IoT Platform witch should now have a confirmation message of our device type being successfully created and our new entry of “EnOcean” under “Device Types”.

    Watson-Create-Device-Type-Complete

    Add Pressac EnOcean Gateway to IBM Watson IoT Platform

    Once added Gateway devices can register new devices to the IBM Watson IoT Platform then facilitate the sending and receiving of data on behalf of devices connected to them such as our CO2, Temperature and Humidity Sensor. Register your Pressac EnOcean Gateway by following the below steps.

    From the IBM Watson IoT Platform dashboard click “Devices” from the left menu then the “Browse” tab then finally the “+ Add Device” button as shown in the image below.

    7-Watson-Add-Device-Gateway

    Select the “EnOcean” “Device Type” we made in the previous step and click “Next” in the bottom right corner of the screen.

    8-Watson-Choose-Device-Type

    A new screen will appear as shown in the image below asking for Device Info in the “Device ID” field put “EnOcean-Gateway” this will be the name of our Pressac EnOcean Gateway on the IBM Watson IoT Platform. Once complete click next in the bottom right corner of the screen.

    9-Watson-Add-Gateway-Device-ID

    Next is the Optional Metadata screen shown in the image below we leave this screen blank and click “Next”.

    10-Watson-Add-Gateway-Device-ID

    In the Security screen we are given the option to provide an authentication token if a token is not provided the IBM Watson IoT Platform will generate one for us. Leaving the field blank click “Next”.

    11-Watson-Add-Gateway-Device-Security

    Finally, we are shown a summary of the options we chose throughout the creation process Verify the details and Click “Add” in the bottom right corner of the screen.

    12-Watson-Add-Gateway-Device-Final-Screen

    The Gateway is now registered; on your screen, you will now see your registration details which need to be added to the Pressac EnOcean Gateway be sure to make a note of them once you are finished click the “X” in the top right corner to return to the IBM Watson IoT Dashboard.

    13-Watson-Device-Details

    You will now see the “EnOcean-Gateway“ in your list of devices as shown in the image below.

    At this point your “EnOcean-Gateway” device will be displaying a disconnected icon Watson-Disconnected this is because we are yet to connect it to our Pressac EnOcean Gateway.

    Watson-Gateway-Device-Final-Screen

  6. Step 4: Connecting the Pressac EnOcean Gateway

    Go back to the Pressac EnOcean Gateway web interface and click the “IBM Watson IoT” entry on the main menu under connections then from the dropdown at the side of “Connection” select “On” and input the IBM Watson IoT Platform registered gateway credentials we took a note of from the previous step and click “Save”.

    pressac-enocean-gateway-ibm-credentials

    Connection will now start if everything goes well you will see the state change to “Connected” your gateway is now ready to send events from your Pressac device to the IBM Watson IoT Platform. 

    Navigate back to your IBM Watson IoT Dashboard and select “Devices” from the left menu you will now see the “EnOcean-Gateway” shows as connected Watson-Connected and it has added our CO2, Temperature and Humidity Sensor as a device Watson-Device.

    14-Watson-Connected-Devices

  7. Step 5: Visualising Pressac Sensor Event Data on the IBM Watson IoT Platform

    On the IBM Watson IoT Platform dashboard click “Boards” on the menu then the “+ Create New Board” button as shown in the image below.

    15-Create-Board-Button-Click

    A pop up will appear asking you to give a name to your new board in the field marked “Board Name” type the name you want to give your board we have called ours “Classroom 1 CO2, Temperature and Humidity Sensor” click “Next”.

    16-Creating-a-new-board

    The next screen will ask you to define other members of the board (if any) to add another member to the board click “+ add user ID” once finished click “Create

    17-Create-New-Board-Members-1

    Now you will see your new board in the “your boards” section as shown in the image below to access your new board click on it.

    Your new board will be empty click on the “+ Add New Card” button at the upper right of the screen.

    18-Add-New-Card-Button

    You will now be asked to select a card type for this example we will be using a “Gauge

    19-Gauge-Board-Type-Select

    Select your device in this example we will select our CO2, Temperature and Humidity Sensor added previously once selected click “Next

    20-Create-Card-Select-CO2-Sensor

    Now click “Connect new data set” as shown in the image below

    21-Card-Create-Connect-New-Data-Set

    For this example, we are going to display the CO2, Temperature and Humidity Sensors concentration value to do this we defined the following field values. The field values required for your device may vary, if data is availible clicking into the fields will list availible options.

    Event – data
    Property – concentration.value
    Name – Classroom1 Concentration
    Type – Float
    Unit – ppm

    The Precision, Min and Max can be changed to suit your requirement for this instance we have left them as default. When finished click “Next

    22-Create-Guage-Card-Information

    Now select the size you want to display the Gauge we have selected “Large” once you have selected click “Next

    23-Card-Guage-Size-Selection

    Now we give our new card a title and select a colour we have gave ours the title of “Classroom 1 Concentration” and selected Blue as the colour once you are finished click “Submit

    24-Card-Create-Colour-and-Name

    You will now be taken back to the Board you created in the IBM Watson IoT Platform and can now see your newly created card showing the data from your Pressac device for our example we can see our concentration value of the CO2, Temperature and Humidity Sensor in a gauge format.

    25-Watson-Board-With-Concentration-Card

    These steps can be repeated to add other device data to your board for example we can display the additional Temperature and Humidity values availible from our CO2, Temperature and Humidity Sensor.

    If any of the properties for your devices are not being displayed it may be because the Watson IoT Platform has not yet received event data for the property. Once the device sends a telegram containing the required values they will be show.

    26-All-Cards-Watson-Board

Join The Discussion