Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Configure FrameworX's built-in historian to log process data, create trends, and analyze historical information. Set up data storage, retrieval, and visualization.

What You'll Learn

Historian: Store & Trend Data (Tutorial) teaches you to:

  • Configure historian storage
  • Select tags for logging
  • Create trend displays
  • Query historical data

Prerequisites:

In this page:

Table of Contents
maxLevel2
minLevel2
indent10px
excludeSteps
stylenone




Historian → Tutorial | Concept | How-to Guide | Reference



Configure Storage Location

configured in UNS
  • Understanding of data retention needs
  • Step 1: Configure Storage Location

    1. Optional (You can the default TagHistorian DB)
    1. Navigate to Historian → Storage
    2. Configure database:

    Default SQLite (Development):

    • Type: SQLite
    • Path: Default or custom
    • File Size: 1GB per file
    • Auto-create: Yes

    SQL Server (Production):

    • Type: SQL Server
    • Server: SQLServer\Instance
    • Database: FrameworX_History
    • Authentication: Windows/SQL
    Step 2:

    Create Historian Tables

    1. Go to Historian → Tables
    2. Create table:

    Process Data:

    • Name: ProcessData
    • Type: Continuous
    • Storage: 1 second resolution
    • Retention: 90 days
    • Compression: Deadband

    Production Counters:

    • Name: Production
    • Type: Counter
    • Storage: On change
    • Retention: 365 days
    Step 3:

    Configure Tags for Logging

    1. Navigate to Historian → Tags
    2. Add tags to log:

    Analog Value:

    • Tag: TagFarm/Tank1_/Temperature
    • Table: ProcessData
    • Deadband: 0.5
    • Rate: 10 seconds

    Digital Value:

    • Tag: Motor1_RunningTagFarm/Tank1/MotorRunning
    • Table: ProcessData
    • Log: On change only

    Production Count:

    • Tag: Units_Produced
    • Table: Production
    • Type: Counter/Totalizer
    Step 4:

    Create Trend Display

    1. Open Displays → New
    2. Add TrendChart control page
    3. Configure:

    Basic Setup:

    • Duration: 1 hour
    • Update: 1 second
    • X-Axis: Time
    • Y-Axis: Auto-scale

    Add Pens:

    • Pen 1: TankFarm/Tank1_/Temperature (Blue)
    • Pen 2: TankFarm/Tank1_/Pressure (Red)
    • Pen 3: Motor1_TankFarm/Motor/Running (Green, digital)
    Step 5:

    Configure Trend Features

    Time Navigation:

    • Enable pan and zoom
    • Add time selector
    • Quick ranges: 1hr, 8hr, 24hr, 7 days

    Analysis Tools:

    • Cursors for value reading
    • Min/Max/Average display
    • Export to CSV
    Step 6:

    Query Historical Data

    Using SQL queries:

    sql

    SELECT Timestamp, TagName, Value 
    FROM ProcessData
    WHERE TagName = 'Tank1_Temperature'
      AND Timestamp > DATEADD(day, -7, GETDATE())
    ORDER BY Timestamp

    Using Scripts:

    csharp

    DataTable history = @Historian.GetData(
        "Tank1_Temperature",
        DateTime.Now.AddDays(-7),
        DateTime.Now,
        1000  // Max points
    );

    Step 7: Create Reports

    1. Reports → New
    2. Add data source:
      • Type: Historian Query
      • Tags: Select multiple
      • Period: Shift/Day/Month
      • Aggregation: Average, Min, Max

    Step 8: Storage Management

    Configure data management:

    Compression:

  • Deadband: ±0.5% of range
  • Time deadband: 60 seconds
  • Compression deviation: 1%

    Archiving:

    • Archive after: 30 days
    • Archive location: Network path
    • Compression: ZIP

    Purging:

    • Auto-purge: After retention period
    • Manual purge: By date range
    Step 9:

    Test Historian

    1. Start Runtime
    2. Let run for few minutes
    3. Open trend display
    4. Verify:
      • Data logging active
      • Trends updating
      • Historical data visible
      • Zoom/pan working

    Performance Optimization

    • Log only necessary tags
    • Use appropriate deadbands
    • Consider table partitioningRegular index maintenancemultiple historian table with distinct triggers
    • Monitor disk space

    Best Practices

    • Plan retention requirements
    • Use multiple tables for different data types
    • Set appropriate logging rates
    • Regular backups
    • Document data retention policy

    Next Steps

    • [Create Dashboards] - Historical KPIs
    • [Reports Module] - Automated reports
    • [Datasets Module] - SQL analysis

    In this section...

    Page Tree
    root@parent
    spaces93DRAF