• Share
  • Email
  • Embed
  • Like
  • Save
  • Private Content
Cdp Gateway
 

Cdp Gateway

on

  • 1,313 views

Shows the CDP gateway for connecting two control systems over a remote low bandwidth link, for example a satellite link

Shows the CDP gateway for connecting two control systems over a remote low bandwidth link, for example a satellite link

Statistics

Views

Total Views
1,313
Views on SlideShare
1,308
Embed Views
5

Actions

Likes
0
Downloads
0
Comments
0

2 Embeds 5

http://www.linkedin.com 3
http://www.slideshare.net 2

Accessibility

Categories

Upload Details

Uploaded via as Microsoft PowerPoint

Usage Rights

© All Rights Reserved

Report content

Flagged as inappropriate Flag as inappropriate
Flag as inappropriate

Select your reason for flagging this presentation as inappropriate.

Cancel
  • Full Name Full Name Comment goes here.
    Are you sure you want to
    Your message goes here
    Processing…
Post Comment
Edit your comment

    Cdp Gateway Cdp Gateway Presentation Transcript

    • CDP2SQL and SQLLogger SQLLogger Component SQLLogger Component SQLLogger Component Application CDP Signals (events etc.)‏ SQLLogger Component SQLLogger Component SQLLogger Component DB DB DB
      • Agenda:
      • CDP2SQL add-on
      • SQLLogger component
      • UDP2SQLLogger application
      • CDP2SQL APIs
      • Database Engine
      CDP2SQL and SQLLogger
    • CDP2SQL add-on
      • SQLLogger component
      • CDP2SQL High-Level Database API
      • Generic Database Interface (DBI)‏
      • SQL database (SQLite3)‏
      SQLLogger Generic DBI SQL Database CDP System Operating System CDP2SQL
    • SQLLogger component
      • Logs a list of CDP signals periodically
      • Logs special event messages as received
      • Run queries
    • SQLLogger configuration
      • Database filename
      • Formats
            • Date (ISO-8601 string or Epoch double)‏
      • Buffering
      • Table limitations (Round-Robin)‏
      • InfoTable
    • UDP2SQLLogger application
      • Example CDP application demo
      • Logs signal data to SQLite3 database
      • Receives data by UDP packets
      • Data source is independent from CDP
    • UDP2SQLLogger (2)‏
    • UDP2SQLLogger demo
      • Demonstration:
        • Run UDP2SQLLogger
        • Start logging from Web interface
        • Send a handful UDP packets
        • Check result in an SQLite3 database browser
    • CDP2SQL APIs
      • CDPDatabase
        • High-level API; little SQL needed
        • For using CDP and database together
      • DatabaseHelper
        • High-level API; little SQL needed
        • No CDP dependancies.
      • Database
        • Generic Database interface classes (DBI)‏
        • Running SQL directly
        • Not tied to specific database engine
    • CDP2SQL::CDPDatabase
      • The work-horse of SQLLogger
      • Tied to CDP
      • Can be used without SQL knowledge
      CDP2SQL::CDPDatabase m_db; m_db.Open(xml.GetAttribute("DBName").c_str(), xml.GetAttribute("Type").c_str())‏ m_db.CreateSignalTable(CDPObject::ShortName(), logSignalsList); m_db.CreateEventTable()‏ m_db.LogSignals(m_signalBuf, m_nSignalBufferFlush); m_db.LogEvents(m_eventBuf, m_nEventBufferFlush);
    • CDP2SQL::DatabaseHelper
      • Generic database functions
      • Refactored out of CDPDatabase
      • No CDP dependancies
      CDP2SQL::DatabaseHelper db("mysqlite3databasefile.db", "sqlite3"); CDP2SQL::ColumnInfo colElements; colElements.Add("id", "INTEGER PRIMARY KEY"); colElements.Add("Name", "varchar(100)"); colElements.Add("Value", "varchar(300)"); db.CreateTable("mykeymap", colElements); db.Close();
    • CDP2SQL::Database
      • Connection to a database
      • Generic interface classes
      • Uses RAII pattern
        • Resource Acquisition Is Initialization
      using namespace CDP2SQL; try { Database db("sqlite3", "sqlite3databasefile.db"); db.Execute("INSERT INTO employee VALUES (99, 'John Doe');" ); db.ExecuteScalar("SELECT count(*) FROM employee;"); } catch (SQLException& e) { printf("Error occurred: %s ", e.Message()); } Transaction Query Database Holder Objects Statement Database
    • Database Engine
      • SQLite3 Database
        • http://www.sqlite.org/
        • “ self-contained, serverless, zero-configuration, transactional SQL database engine ”
        • “ source code [...] is in the public domain”
      • Possible to support other SQL compliant databases
      CDP2SQL Interface Classes CDP2SQLite CDP2OtherSQL SQLite C API Other C/C++ API
    • LogManager demo
      • ...
      LoggerApp LoggerOne LoggerTwo LogManagerApp LogManager Control signals/messages
    • Industrial Control Design AS www.icd.no Industrial Control Design AS www.icd.no icd@icd.no +47 70329230 Industrial Control Design AS www.icd.no [email_address] +47 70329230