IRF2000 IWL3000 SRC1000 Application Note - Apps with OSGi - Condition Monitoring with WWH push



Similar documents
IRF2000 IWL3000 SRC1000 Application Note - Develop your own Apps with OSGi - getting started

Step by Step. Use the Cloud Login Website

Cloud Tools Reference Guide. Version: GA

How do I Install and Configure MS Remote Desktop for the Haas Terminal Server on my Mac?

Document From MAXIMUM BUSINESS INFORMATION TECHNOLOGY ON A. OwnCloud User Manual. TO I Cafe`

How do I Install and Configure MS Remote Desktop for the Haas Terminal Server on my Mac?

Link and Sync Guide for Hosted QuickBooks Files

Using LifeSize systems with Microsoft Office Communications Server Server Setup

Site Monitor. Version 5.3

Dell SupportAssist Version 2.0 for Dell OpenManage Essentials Quick Start Guide

USING MYWEBSQL FIGURE 1: FIRST AUTHENTICATION LAYER (ENTER YOUR REGULAR SIMMONS USERNAME AND PASSWORD)

Dynamic DNS How-To Guide

Guide to the LBaaS plugin ver for Fuel

Integration Client Guide

Initial Setup of Microsoft Outlook with Google Apps Sync for Windows 7. Initial Setup of Microsoft Outlook with Google Apps Sync for Windows 7

NAS 221 Remote Access Using Cloud Connect TM

Configuration Guide. BES12 Cloud

SOS SO S O n O lin n e lin e Bac Ba kup cku ck p u USER MANUAL

Sophos Mobile Control Super administrator guide. Product version: 3

WinSCP for Windows: Using SFTP to upload files to a server

LifeSize UVC Manager TM Deployment Guide

How to Setup PPTP VPN Between a Windows PPTP Client and the DIR-130.

Enterprise Data Integration (EDI)

QUANTIFY INSTALLATION GUIDE

PHP Language Binding Guide For The Connection Cloud Web Services

How To Integrate An Ipm With Airwatch With Big Ip On A Server With A Network (F5) On A Network With A Pb (Fiv) On An Ip Server On A Cloud (Fv) On Your Computer Or Ip

Using SQL Server Management Studio

CIMHT_006 How to Configure the Database Logger Proficy HMI/SCADA CIMPLICITY

SourceAnywhere Service Configurator can be launched from Start -> All Programs -> Dynamsoft SourceAnywhere Server.

P-660R-T1 v3 QUICK START GUIDE. ADSL2+ Access Router DEFAULT LOGIN DETAILS. Firmware v3.40 Edition 1, 09/2008. IP Address:

How To Set Up Ops Cser.Com (Pros) For A Pc Or Mac) With A Microsoft Powerbook (Proos) (Prosecco) (Powerbook) (Pros) And Powerbook.Com/

Installation Instructions

How do I share a file with a friend or trusted associate?

Phone Inventory 1.0 (1000) Installation and Administration Guide

Copyright 2013, 3CX Ltd.

DIPLOMA IN WEBDEVELOPMENT

Installation and Configuration Manual

The data between TC Monitor and remote devices is exchanged using HTTP protocol. Monitored devices operate either as server or client mode.

4cast Server Specification and Installation

Lab 4.4.8a Configure a Cisco GRE over IPSec Tunnel using SDM

Outlook Web Access Tipsheets

InHand Device Cloud Service DN 4.0 Quick Start Guide

BroadSoft BroadWorks ver. 17 SIP Configuration Guide

Rev 7 06-OCT Site Manager Installation Guide

AkrutoSync 4.0 User Guide

3rd Party VoIP Phone Setup Guide (Panasonic UT )

The SyncBack Management System

Capture Pro Software FTP Server System Output

How to connect to the University of Exeter VPN service

Initial Setup of Microsoft Outlook 2011 with IMAP for OS X Lion

LAB 6: Code Generation with Visual Paradigm for UML and JDBC Integration

NAS 224 Remote Access Manual Configuration

Accessing the Media General SSL VPN

ODBC Client Driver Help Kepware, Inc.

Preparing for GO!Enterprise MDM On-Demand Service

Administrator s Guide for the Polycom Video Control Application (VCA)

PaaS Operation Manual

Introduction to Mobile Access Gateway Installation

BlackBerry Enterprise Service 10. Version: Configuration Guide

Moving the TRITON Reporting Databases

Virtual Data Centre. User Guide

REMOTE ACCESS DDNS CONFIGURATION MANUAL

IIS, FTP Server and Windows

DESLock+ Basic Setup Guide Version 1.20, rev: June 9th 2014

AJ Matrix V5. Installation Manual

EMR Link Server Interface Installation

Defender Token Deployment System Quick Start Guide

End User Configuration

INTRODUCTION: SQL SERVER ACCESS / LOGIN ACCOUNT INFO:

The full setup includes the server itself, the server control panel, Firebird Database Server, and three sample applications with source code.

How to setup PPTP VPN connection with DI-804HV or DI-808HV using Windows PPTP client

Active Directory Authentication Integration

Novell ZENworks Asset Management 7.5

Sophos Mobile Control Installation guide. Product version: 3.6

SSH access to databases at DIMDI

Monitoring System Status

EASRestoreService. Manual

Cox Managed CPE Services. RADIUS Authentication for AnyConnect VPN Version 1.3 [Draft]

MySQL Quick Start Guide

Sophos Mobile Control Installation guide

Client applications are available for PC and Mac computers and ios and Android mobile devices. Internet

Cloud Services ADM. Agent Deployment Guide

Protected Trust Setup Guide for Brother MFC Devices

DIGIPASS Authentication for GajShield GS Series

Network Monitoring with SNMP

Acrolinx IQ. Acrolinx IQ Plug-in for Adobe CQ Rich Text Editor Installation Guide Version: 2.9

Mobile Device Management Version 8. Last updated:

A table is a collection of related data entries and it consists of columns and rows.

Xopero Backup Build your private cloud backup environment. Getting started

CSCI110 Exercise 4: Database - MySQL

Accessing the FTP Server - User Manual

qliqdirect Active Directory Guide

DEPLOYMENT GUIDE Version 1.1. Deploying the BIG-IP LTM v10 with Citrix Presentation Server 4.5

NMS300 Network Management System

Multi-Homing Security Gateway

SIP Trunking using the EdgeMarc Network Services Gateway and the Mitel 3300 ICP IP-PBX

Configuring Avaya Aura Communication Manager and Avaya Call Management System Release 16.3 with Avaya Contact Center Control Manager Issue 1.

Create a Database Driven Application

Welcome to PowerClaim Net Services!

Transcription:

Version 2.0 Original-Application Note ads-tec GmbH IRF2000 IWL3000 SRC1000 Application Note - Apps with OSGi - Condition Monitoring with WWH push Stand: 28.10.2014 ads-tec GmbH 2014

IRF2000 IWL3000 SRC1000 2 Document History 1.0 01/02/2014 Initial Version 1.1 28/04/2014 Updated 2.0 28/10/2014 New adress Table of Contents Introduction... 3 Getting started... 4 1.1 Create a table... 4 1.2 Use WWH push inside an OSGi bundle... 7 1.3 Deploy the bundle... 9 1.4 Read from the database... 11

IRF2000 IWL3000 SRC1000 3 Introduction Condition monitoring and distributed data collection are one of the main aspects of today s buzz words like Industrie 4.0, The Internet of Things or Big-Data. This guide will lead you through an example of how to use the Big-LinX Distributed Condition Monitoring with WWH Data Push together with a custom OSGi Java Application on the IRF2000. Since the storage on all embedded devices is always limited and since data transfers especially over mobile networks is expensive this is a great method to filter and preselect the data before transmitting them to central databases. With the WorldWideHeartbeat push functionality any OSGi app can send data to the database inside the Big-LinX cloud easily. Therefore a Big-LinX routercard with a PIN is needed to provide a highly secure and authenticated connection. In this Application note the WWH push from an OSGi app will be discussed. Furthermore an outlook on reading the data will be given.

IRF2000 IWL3000 SRC1000 4 Getting started It is recommended to read the OSGi getting started Application note. Also an active Big-LinX connection for the ads-tec embedded device and the user PC is required. Instead of a second Big-LinX user card there is also the possiblity to connect the user PC via an ads-tec Site2Site Router (conact sales for further information about Site2Stite routing). The following pictures show the topology of all involved devices. Central database WWH link to Big-LinX ads-tec embedded device with Big-LinX router card Standard PC with Big-LinX user card 1.1 Create a table First step is to create a table in which the pushed data will be stored. This step requires an existing Big-LinX connection between the PC and the Big-LinX cloud. Now with the help of a browser a connection to the database can be made. Open a browser and go to: https://gatewayip/phpmyadmin Replace the GATEWAYIP with the correct IP address which can be found in the information from ads-tec containing also the user credentials for the database.

IRF2000 IWL3000 SRC1000 5 Note: the GATEWAYIP can also be determined by examing the routing table of the PC. Take the VPN IP from the Big-LinX client window e.g. 10.x.y.z And look for a matching line in the output of the command route print The GATEWAYIP is the first IP in the network. In this example 10.1.0.1. Now login with username and password

IRF2000 IWL3000 SRC1000 6 Click on create table in the left section of the window. In the dialog describe your table. For example enter columns ads shown in the picture below. As you can see we create a quite simple table named TEST with three rows. ID: will hold a unique identifier for the data source time: will hold a timestamp of the record value: a single simple numeric value Of course you will most likely add many more rows or many different tables in a real world setup.

IRF2000 IWL3000 SRC1000 7 It is also possible to use a mysql client and connect directly to the server with the GATEWAYIP and the port 3306. To add a table the SQL statement could look like this: CREATE TABLE `TEST` ( `ID` bigint(20) NOT NULL AUTO_INCREMENT, `time` timestamp NULL DEFAULT NULL, `Value` int(11) NOT NULL, PRIMARY KEY (`ID`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 1.2 Use WWH push inside an OSGi bundle Pushing data out of an OSGi bundle is a simple task. Every WWH push consits of one table name (e.g. TEST ) and some data. Each row of data will be inserted into one row of the table. The first element of the data row will be inserted into column number 1. So for our TEST table the JSON Object could look like this: { } "table":"test", "data":[ [ null, "1394529351", 1234 ], [ ] ] Note that } the data object could have more than one row if needed. Regarding bandwidth and protocol overhead it is much better to transmit an array of 10 records every 10 minutes instead of one record every minute!

IRF2000 IWL3000 SRC1000 8 The folowing Java code shows how to create this JSON Object and how to send it via WWH push to the central Big-LinX database. /* * build the following json request { "table":"test", "data":[ [ * null, "1394529351", 1234 ], ]} */ Date now = new java.util.date(); java.text.simpledateformat sdf = new java.text.simpledateformat("yyyy-mm-dd HH:mm:ss"); String timestamp = sdf.format(now); List<Object> values = new ArrayList<Object>(); List<Object> value = new ArrayList<Object>(); Map<String, Object> vars_push = new HashMap<String, Object>(); value.add("null"); // Auto increment value.add(timestamp ); // timestamp value.add(counter); //sample data: counter values.add(value); vars_push.put("table", "TEST"); //tablename vars_push.put("data", values); JSONRPC2Request request = new JSONRPC2Request("call", 1); List<Object> params = new ArrayList<Object>(); params.add(activator.sid); params.add("wwh"); // JsonRpc method params.add("push"); // JsonRpc action params.add(vars_push); request.setpositionalparams(params); try { JSONRPC2Response response = Activator.RPCSession.send(request); if (response.indicatessuccess()) { Activator.eventlog.log(LogService.LOG_ERROR, "Successfully pushed data"); counter++; } else { Activator.eventlog.log(LogService.LOG_WARNING, "Error while pushing data: " + response.geterror().getmessage()); } } catch (JSONRPC2SessionException je) { Activator.eventlog.log(LogService.LOG_ERROR, "Could not send JSON RPC", je); }

IRF2000 IWL3000 SRC1000 9 1.3 Deploy the bundle Use eclipse to wirte bundles. This is eplained in another application note which should be considered before reading this chapter. First export the bundle by rightclicking it Then select Deployable plug-ins and fragments Press Next and and then the Finish Button. Second step is to upload the bundle to the taret plattform. To achieve this point your browser to the webinterface of the ads-tec embedded device (e.g. http://192.168.0.254) Then navigate to the bundle upload page

IRF2000 IWL3000 SRC1000 10 And select the bundle on your computer. With a click on Upload OSGi bundle the upload begins To check if the bundle is running start a SSH client program for example putty. Then enter the IP address of the ads-tec embedded device e.g. 192.168.0.254. Make sure that the connection type is SSH Press Open and enter osgi as username and password. With the lb command all installed bundles can be listed. In this example the WWH push bundle has the number 103 and is running. In the next chapter it is shown how to read the pushed data back from the database.

IRF2000 IWL3000 SRC1000 11 1.4 Read from the database To read the data back from the database every mysql client can be used. The following SQL statement reads all rows from the table TEST. SELECT * FROM `TEST`; For example the values can be shown using phpmyadmin and executing the SQL statement. The result is shown in the picture below. Please note that in a real world setup you will now not only have to read the data but also delete is after you have copied them to your own companies ERP system or data analysis software.