Configuring mapp View Charts for Battery Sessions Guide

Brian Holt7 min read
B&R AutomationHMI ProgrammingTutorial / How-to
Licensed PE Working through this on a live machine? A Maine-licensed engineer can take it from here — included with IMD hardware, by the hour for everything else. Book an engineer

Use the Online Chart as the live operator display and treat the XY Chart as a bounded review or analysis display. Start a fresh capture when session started becomes true, drive the horizontal window from session duration, hold state of charge at 0–100%, and autoscale power independently. Do not solve a multi-week session by growing an unbounded browser-side array.

Reject the quick fixes first

The first quick fix is to place both values on one automatically scaled Y-axis. That makes the chart run, but the larger numeric range dominates. A power excursion can flatten the state-of-charge trace, while a quiet power period can make ordinary noise look significant.

The second quick fix is to select the XY Chart only because it exposes more appearance controls. An XY plot is useful when the application supplies explicit X/Y point sets, but retaining every live sample for sessions lasting from hours to weeks makes memory use and rendering time grow with the session. A larger array delays the failure rather than fixing the architecture.

The third quick fix is to fill the power series toward the bottom of the plot. That reference moves when the power axis autoscales, so the colored area no longer represents energy direction relative to 0 W. The fill must reference the zero baseline.

Need Preferred handling Reason
Continuous live trend Online Chart Fits streaming time-series data without building one session-sized X/Y array
Explicit point review or reconstructed session XY Chart Provides direct control of supplied coordinates
Weeks of history Bounded display plus retained historical data Keeps client memory and redraw work predictable

Before continuing, run a short live capture and confirm that the Online Chart accepts new samples without rebuilding the complete data set.

Start the plot at the session edge

Use the rising transition of session started, not its continuously true state, as the start event. If initialization executes every scan or every binding update while the value remains true, the chart can repeatedly clear, reset its origin, or fail to accumulate points.

  1. Detect the transition from false to true in the controller or application logic.
  2. Latch the session start time at that transition.
  3. Clear or replace the active display buffer once.
  4. Reset the displayed horizontal origin to zero.
  5. Begin accepting power and state-of-charge samples.
  6. Stop appending, or freeze the review window, when the session ends.

Keep acquisition state separate from page visibility. An operator changing screens must not silently restart the session clock or discard the active trend. If the chart widget owns only its visible buffer, retain the authoritative session data outside the page and reconnect the display when the page opens.

Prove this stage by starting one session, navigating away and back, and checking that elapsed time continues from the same origin. Then hold session started true and confirm that the trace does not clear a second time.

Drive the horizontal axis with elapsed time

Calculate each X coordinate from the current time minus the latched session start time, or bind the Online Chart to the equivalent elapsed-session value. Display that value as relative time in hh:mm. Do not feed time-of-day labels into a chart intended to restart at zero for each battery session.

session duration has two distinct jobs: it supplies the elapsed-time label and defines the visible horizontal extent. Do not confuse total elapsed duration with sample count. Sampling every update produces far more points than the display has horizontal pixels, especially across a multi-week session.

  1. Set the initial horizontal range to begin at zero when the session starts.
  2. Increase the upper bound as session duration increases.
  3. Format tick labels as elapsed hours and minutes.
  4. Apply a bounded retention or decimation policy before the display becomes point-dense.

Preserve short transients when reducing data. For each display interval, retaining minimum and maximum power generally protects charge and discharge peaks better than retaining only an average. Store full-resolution data in the system responsible for history if later energy analysis requires it; the chart should receive only the resolution needed for its current time span.

Prove the time setup with a controlled short session: the first plotted point must be at zero elapsed time, labels must advance as hh:mm, and widening the duration must not change the recorded timestamps.

Separate the power and state-of-charge scales

Assign power to the left Y-axis and state of charge to the right Y-axis. Fix the state-of-charge axis minimum at 0% and maximum at 100%. Leave the power axis on automatic scaling so charge and discharge excursions remain readable.

Autoscaling power needs a range that includes zero. Otherwise, a session containing only positive power can place zero outside the plot, and a session containing only negative power can do the same on the opposite side. Select a chart range mode that includes the zero reference while expanding for actual power values. If the installed widget cannot combine automatic range calculation with a forced zero, calculate symmetric or one-sided limits in the application from the retained power extrema.

Do not place percentages and watts on the same axis, and do not normalize both signals merely to make the lines visible. Normalization hides the engineering units the operator needs for diagnosis.

Prove the axes with three inputs: positive power, negative power, and zero power. The left scale must expand as required and continue to show zero; the right scale must remain exactly 0–100% throughout the test.

Anchor the power fill to 0 W

The area under the power curve must close against a horizontal value of 0 W, not against the X-axis or the current bottom of the plot. This distinction matters whenever the automatic power range is asymmetric.

  1. Configure the power series baseline, origin, or threshold property to 0 W if the widget exposes one.
  2. Use separate positive and negative visual regions if conditional coloring is available.
  3. Test a trace that crosses zero several times.
  4. Change the power-axis range and confirm that the fill still terminates at zero.

If the Online Chart cannot fill to a numeric baseline, keep it for acquisition and live trending rather than moving the entire job to an unbounded XY array. Use an unfilled power line, split power into positive and negative display series, overlay a compatible visualization, or build a custom visualization component. Choose the smallest workaround that preserves the correct zero reference.

Prove the fill by forcing both charge and discharge values into view. No colored region should cross the 0 W baseline except where the power trace itself crosses it.

Verify the complete session path

Run the same acceptance sequence used during commissioning, then leave the selected retention policy active long enough to expose redraw or memory problems.

  1. Open the display before the session starts and verify that stale data is absent or clearly identified.
  2. Change session started from false to true and verify one reset at zero elapsed time.
  3. Apply positive and negative power and confirm left-axis autoscaling around the visible 0 W reference.
  4. Move state of charge across a representative range and confirm that the right axis stays fixed at 0–100%.
  5. Extend session duration and confirm relative hh:mm labels and horizontal scaling.
  6. Navigate away and return without resetting the active session.
  7. End the session and confirm the required freeze, archival, or clearing behavior.
  8. Reopen a retained session, if review is required, and compare its timestamps and extrema with the stored records.

Watch point count, page response, redraw time, and gaps at time-range changes. A chart that looks correct for ten minutes but stalls after days has not passed commissioning.

FAQ

How do I choose between an Online Chart and an XY Chart in mapp View?

Use the Online Chart for continuously arriving battery data. Use the XY Chart when the application already owns a bounded X/Y data set for review or analysis.

How do I start a mapp View chart at zero session time?

Detect the false-to-true edge of session started, latch the start time, clear the active display once, and plot elapsed time from that origin. Do not reset while the signal remains true.

How do I show power and state of charge on one chart?

Put power on an automatically scaled left axis that includes 0 W. Put state of charge on a separate right axis fixed at 0–100%.

When should I stop configuring the chart and contact support?

Stop if the installed mapp View widget cannot provide independent Y-axes, an elapsed-time X-axis, or a fill referenced to 0 W, and those behaviors are mandatory. Record the runtime and engineering-software versions, widget configuration, a minimal reproducer, and screenshots, then escalate through official B&R support.

Back to blog