Implementation of A Low-Cost Three-Phase Electronic Watt-Hour Meter Using The MSP430F67641

Download as pdf or txt
Download as pdf or txt
You are on page 1of 59

Application Report

SLAA621C – March 2014 – Revised August 2015

Implementation of a Low-Cost Three-Phase Electronic


Watt-Hour Meter Using the MSP430F67641

Mekre Mesganaw and Stephen Underwood ............................................................... Metering Applications

ABSTRACT
This application report describes the implementation of a low-cost three-phase electronic electricity meter
using the Texas Instruments MSP430F67641 metering processor. This application report includes the
necessary information with regard to metrology software and hardware procedures for this single-chip
implementation.
The MSP430F67641 source code that is described in this application report can be downloaded from
http://www.ti.com/lit/zip/slaa621.
The MSP430F67641A source code can be downloaded from http://www.ti.com/tool/TIDM-3PH-ENERGY5-
ESD.
The design files for the EVM can be downloaded with the Class 0.5 Three-Phase Smart Meter Reference
Design (TIDM-THREEPHASEMETER-F67641).

WARNING
Failure to adhere to these steps and/or not heed the safety
requirements at each step may lead to shock, injury, and damage
to the hardware.

Contents
1 Introduction ................................................................................................................... 3
2 System Diagrams ............................................................................................................ 3
3 Hardware Implementation .................................................................................................. 5
4 Software Implementation ................................................................................................... 8
5 Energy Meter Demo........................................................................................................ 26
6 Results and Calibration .................................................................................................... 33
7 Schematics .................................................................................................................. 53

List of Figures
1 3-Phase 4-Wire Star Connection Using MSP430F67641 .............................................................. 4
2 Simple Capacitive Power Supply for the MSP430 Energy Meter ..................................................... 5
3 Switching-Based Power Supply for the MSP430 Energy Meter ....................................................... 6
4 Analog Front End for Voltage Inputs ...................................................................................... 7
5 Analog Front End for Current Inputs ...................................................................................... 7
6 Foreground Process ....................................................................................................... 10
7 Background Process ....................................................................................................... 14
8 ADC10 Triggering Process................................................................................................ 16
9 per_sample_dsp() .......................................................................................................... 18
10 Frequency Measurement .................................................................................................. 19

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 1
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com

11 Pulse Generation for Energy Indication ................................................................................. 20


12 Top View of the Three Phase Energy Meter EVM ..................................................................... 26
13 Top View of the EVM With Components Highlighted.................................................................. 27
14 Top View of the EVM With Test Setup Connections .................................................................. 28
15 Front View of the EVM With Test Setup Connections ................................................................. 29
16 Source Folder Structure ................................................................................................... 32
17 Toolkit Project Compilation................................................................................................ 32
18 Metrology Project Compilation ............................................................................................ 32
19 Application Project Compilation .......................................................................................... 32
20 Phase Symbols ............................................................................................................. 33
21 LCD Display ................................................................................................................. 35
22 ZigBee Radio ............................................................................................................... 35
23 TI Designed IHD430 ....................................................................................................... 37
24 GUI Config File Changed to Communicate With Meter ............................................................... 38
25 GUI Startup Window ....................................................................................................... 38
26 Results Window ............................................................................................................ 39
27 Meter Events and Consumption Window ............................................................................... 40
28 Calibration Factors Window ............................................................................................... 41
29 Manual Calibration Window ............................................................................................... 42
30 Calibration Factors Window ............................................................................................... 44
31 Meter Features Window ................................................................................................... 44
32 Cumulative Phase Active Energy Measurement Error ................................................................ 45
33 Cumulative Phase Reactive Energy Measurement Error ............................................................. 46
34 Phase A Active Energy Measurement Error ............................................................................ 47
35 Phase B Active Energy Measurement Error ............................................................................ 48
36 Phase C Active Energy Measurement Error ............................................................................ 49
37 Cumulative Active Energy Measurement Error, ±10% Nominal Voltage............................................ 50
38 Cumulative Active Energy Measurement Error, 100 V to 270 V, No EVM Modifications ......................... 51
39 Cumulative Active Energy Measurement Error, 100 V to 320 V, Varistors Removed ............................ 52
40 Schematics (1 of 4) ........................................................................................................ 53
41 Schematics (2 of 4) ........................................................................................................ 54
42 Schematics (3 of 4) ........................................................................................................ 55
43 Schematics (4 of 4) ........................................................................................................ 56

List of Tables
1 Header Names and Jumper Settings on the EVM430-F67641 ...................................................... 29
2 Displayed Parameters ..................................................................................................... 34
3 Cumulative Phase Active Energy Measurement Error (%) ........................................................... 45
4 Cumulative Phase Reactive Energy Measurement Error (%) ........................................................ 46
5 Phase A Active Energy Measurement Error ............................................................................ 47
6 Phase B Active Energy Measurement Error ............................................................................ 48
7 Phase C Active Energy Measurement Error ............................................................................ 49
8 Cumulative Active Energy Measurement Error, ±10% Nominal Voltage............................................ 50
9 Cumulative Active Energy Measurement Error, 100 V to 270 V, No EVM Modifications ......................... 51
10 Cumulative Active Energy Measurement Error, 100 V to 320 V, Varistors Removed ............................ 52

2 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Introduction

1 Introduction
The MSP430F67641 device is the latest metering system-on-chip (SoC) that belongs to the
MSP430F67xx family of devices. This family of devices belongs to the powerful 16-bit MSP430F6xx
platform, which brings in many new features and provides flexibility to support robust poly-phase
metrology solutions. These devices find their application in energy measurement and have the necessary
architecture to support them.
The F67641 has a powerful 25-MHz CPU with MSP430CPUX architecture. The analog front-end consists
of three 24-bit ΣΔ analog to digital converters (ADC) that are used for sensing current and a 10-bit SAR
ADC for sensing phase voltages. The ΣΔ ADCs are based on a second-order sigma-delta architecture and
they support differential inputs. The sigma-delta ADCs (ΣΔ24_B) operate independently and are capable
of 24-bit results. In addition, it also has an integrated gain stage to support gains up to 128 for
amplification of low-output current sensors In contrast, the 10-bit SAR supports single-ended inputs and
performs sequential sampling of the three different phase voltages, the integrated temperature sensor, the
voltage of the active supply powering the chip (VDSYS), and an additional optional auxiliary power supply
(selected by the AUXADCSELx bits). The ΣΔ24_B on the F67641 module has a trigger generator that
triggers the ADC10 to ensure that the timing between the ADC10 and ΣΔ modules are grouped and
synchronized.
A 32-bit x 32-bit hardware multiplier on this chip can be used to further accelerate math intensive
operations during energy computation. The software energy library supports calculation of various
parameters for up to three-phase energy measurement. The key parameters calculated during energy
measurements are: RMS current and voltage, active and reactive power and energies, power factor, and
frequency. The library also provides the option to obtain raw samples of voltages and currents for
advanced metering data such as harmonic analysis and total harmonic distortion (THD).
Complete metrology source code is provided. The MSP430F67641-based software can be downloaded
from http://www.ti.com/lit/zip/slaa621. The MSP430F67641A-based software can be downloaded from
http://www.ti.com/tool/TIDM-3PH-ENERGY5-ESD.

2 System Diagrams
Figure 1 shows a block diagram of the high level interface used for a three-phase energy meter
application using the F67641. A three-phase four-wire star connection to the AC mains is shown in this
case. Current sensors are connected to each of the current channels and a simple voltage divider is used
for corresponding voltages. The CT has an associated burden resistor that must be connected at all times
to protect the measuring device. The choice of the CT and the burden resistor is done based on the
manufacturer and current range required for energy measurements. The CTs can be easily replaced by
Rogowski coils with minimal changes to the front-end.
The trigger generator of the ΣΔ is used to trigger the ADC10 to perform conversions, thereby
synchronizing it with the ΣΔ converter's timings. For the voltage sensor, a combination of a voltage divider
and level shifter are used to ensure that the input voltage to the ADC fits within the single-ended voltage
range of operation. The range of operation is determined by the chosen reference voltage source of the
SAR ADCs. The choice of voltage divider resistors for the voltage channel is selected to ensure the mains
voltage is divided down to the normal input ranges that are valid for the SAR ADC, based on the selected
reference voltage. See the MSP430x5xx and MSP430x6xx Family User's Guide (SLAU208) and the
device-specific data sheet for these values.

MSP430 is a trademark of Texas Instruments.


IAR Embedded Workbench is a trademark of IAR Systems.
All other trademarks are the property of their respective owners.

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 3
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
System Diagrams www.ti.com

Load +
A
B
-
TOTAL kWh
Phase C
Phase A
VCC Sx,COMx
Neutral

Phase B
RST MSP430F67641
VSS

+
CT I1 6' Modulator
- Px.x
STATUS LEDs

+ Px.x
CT I2 6' Modulator
-

XIN
+
CT I3 6' Modulator
-
XOUT
32,768 Hz

Level 6' Trigger


Shifted Generator
USCIA0 UART for PC Comms
Voltage
V1
Sampling Trigger
Divider

Level
Shifted USCIA1 UART/SPI for Wired Comms
Voltage
Divider V2 ADC10
Channels
Level USCIA2 UART/SPI for Wireless Comms
Shifted
Voltage
V3
Divider
USCIB0 SPI/I2C for External Memory
Neutral

Analog to Digital Conversion


Phase B

Phase A
Phase C

Source
Figure 1. 3-Phase 4-Wire Star Connection Using MSP430F67641

4 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Hardware Implementation

3 Hardware Implementation
This section describes the hardware for the design of a working three-phase energy meter that uses the
F67641.

3.1 Power Supply


The MSP430™ family of devices comprises ultra-low-power microcontrollers from Texas Instruments.
These devices support a number of low-power modes and also have low-power consumption during active
mode when the CPU and other peripherals are active. The low-power feature of this device family allows
design of the power supply to be simple and inexpensive. The power supply allows the operation of the
energy meter powered directly from the mains. The next sections describe the various power supply
options that are available to users to support their design.

3.1.1 Resistor Capacitor (RC) Power Supply


Figure 2 shows a capacitor power supply that provides a single output voltage of 3.3 V directly from the
mains of 120/230 V RMS AC at 50/60 Hz.

Figure 2. Simple Capacitive Power Supply for the MSP430 Energy Meter

Appropriate values of resistors (R92, R93, and R94) and capacitors (C39, C46, and C50) are chosen
based on the required output current drive of the power supply. Voltage from mains is directly fed to a RC
based circuit followed by a rectification circuit to provide a dc voltage for the operation of the MSP430.
This dc voltage is regulated to 3.3 V for full-speed operation of the MSP430. The design equations for the
power supply are given in the application report Improved Load Current Capability for Cap-Drop Off-Line
Power Supply for E-Meter (SLVA491). The above configuration allows all three phases to contribute to the
current drive, which is approximately three times the drive available from only one phase. If even higher
output drive is required, the same circuitry can be used followed by an NPN output buffer. Another option
would be to replace the above circuitry with a transformer-based or switching-based power supply.

3.1.2 Switching Power Supply


Figure 3 shows a switching-based power supply that provides a single output voltage of 3.3 V directly from
the AC mains at 100 V to 230 V RMS. In the configuration shown, the meter is powered as long as there
is AC voltage on Phase C, corresponding to LINE 3 on the schematic and board. The internal circuitry of a
switching power supply is omitted from this application report. For the drive of the power supply, refer to
the documentation of the power supply module.

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 5
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Hardware Implementation www.ti.com

Figure 3. Switching-Based Power Supply for the MSP430 Energy Meter

3.2 Analog Inputs


The MSP430F6741 has a 10-bit SAR ADC (ADC10_A), three ΣΔ ADCs, and a mechanism to synchronize
these two types of converters. Since the magnitude of the current waveform varies more than the
magnitude of the voltage waveform, the higher accuracy ADCs should always be used to sense current.
As a result, the three ΣΔ ADCs should be used for measuring the phase currents. For measuring phase
voltages, the SAR ADC could be used.
The ΣΔ ADC is differential and requires that the input voltages at the pins do not exceed ±920 mV
(gain = 1). To meet this specification, the current inputs must be divided down. In addition, the ΣΔ24
allows a maximum negative voltage of -1 V. Therefore, the AC current signal from mains can be directly
interfaced without the need for level shifters.
In contrast, the ADC10_A module has single-ended inputs. Therefore the ADC10_A requires that the
sensed voltage is between 0-VREF Volts, with the VREF source/voltage being selectable in software. As a
result, after Mains voltage is divided down for sensing, the voltage front-end circuitry requires a level
shifter to properly interface to the ADC10_A module.
The following sections describe the analog front end used for voltage and current channels.

3.2.1 Voltage Inputs


The voltage from the mains is usually 230 V or 120 V and must be brought down to within VREF volts.
The analog front end for voltage consists of spike protection varistors followed by a voltage divider/shifter
network, and a RC low-pass filter that acts like an anti-alias filter.

6 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Hardware Implementation

Figure 4. Analog Front End for Voltage Inputs

Figure 4 shows the analog front end for the voltage inputs for a mains voltage of 230 V. The voltage is
brought down to a range within VREF volts, where VREF is selected to be the 2.0 V reference produced
by the chip's reference module. The maximum voltage that is fed to the ADC is usually a certain margin
below the maximum VREF voltage. As an example, when the 2.0 V reference is selected, the front-end
may be built to produce a maximum voltage of 1.4-1.6 V when the maximum Mains voltage is applied.
This margin helps prevents ADC clipping when the meter is exposed to harmonics or an over-voltage
condition.

3.2.2 Current Inputs


The analog front-end for current inputs is different from the analog front end for the voltage inputs.
Figure 5 shows the analog front end used for a current channel.

Figure 5. Analog Front End for Current Inputs

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 7
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Software Implementation www.ti.com

Resistor R24 is the burden resistor that is selected based on the current range used and the turns ratio
specification of the CT. The value of the burden resistor for this design is 12.4 Ω. The antialiasing circuitry,
consisting of resistors and capacitors, follows the burden resistor. The input signal to the converter is a
fully differential input with a voltage swing of ±877 mV maximum when the maximum current rating of the
meter (100 A) is applied.

4 Software Implementation
The software has three projects: one for mathematical routines, another primarily for metrology (including
calculation of voltage, current, and power), and an application wrapper that deals mainly with application-
processor functionality (such as communication, RTC, and LCD display). The separation of the metrology
and application processor enables easy porting from TI's EVM to a customer's board with minimal
changes to the metrology code. Also, if it is desired to get the readings of the metrology parameters to
make any further additions to the code, the "metrology-readings.h" file could be used to view the different
functions that could be called from the application project to retrieve the newest set of metrology
parameters. Refer to "metrology-types.h" to see the associated units of these returned metrology
parameters.
In the following subsections, the software for the implementation of three-phase metrology is described.
The first subsection describes the setup of various peripherals of the MSP430. Subsequently, the entire
metrology software is described as two major processes: the foreground process and background
process.

4.1 Peripherals Setup


The major peripherals are the 24-bit sigma delta (ΣΔ24_B) ADC, the 10-bit SAR ADC (ADC10_A),
auxiliary power supply module (AUX), clock system, real-time clock (RTC), and LCD.

4.1.1 ΣΔ24 Setup


The F67641 has three sigma delta data converters, which are used to measure the three currents in a
three-phase system. In addition, it has a trigger generator module that is used to trigger the ADC10, which
is used to sense the corresponding three voltages of the three-phase system. The code that accompanies
this application report is designed for the metrology of a three-phase system with limited anti-tampering
features. The clock to the ΣΔ24 ADCs and trigger generator (fM) is derived from system clock, which is
configured to run at 25 MHz. The sampling frequency is defined as fs = fM/OSR, where the OSR is chosen
to be 256 and the modulation frequency fM is chosen as 1.048576 MHz. This results in a sampling
frequency of 4.096 ksps for the converters and a triggering frequency of 4096 Hz for the trigger generator.
At every sampling instance, the ΣΔ24s are configured to generate regular interrupts.
The following are the ΣΔ channels associations:
A0.0+ and A0.0- → Current I1
A1.0+ and A1.0- → Current I2
A2.0+ and A2.0- → Current I3

4.1.2 ADC10_A Setup


The ADC10 is used to sample the three Mains voltages and is triggered by the ΣΔ's trigger generator.
When triggered by the ΣΔ, the ADC10 enters autoscan mode and samples all of its 16 ADC channels
once. In the software, the clock to the ADC10 is set to 4MHz. The sample and hold time for each
converter is 8 cycles and the conversion time is 12 cycles, which results in a total of approximately 20
cycles (approximately 5 µs) delay between conversion results of adjacent converters. In addition, the
ADC10_A uses the 2.0 V reference from the REF module and is configured to output 10-bit results that
are scaled to 16-bit two's complement numbers (ADC10DF = 1). This allows the ADC results from the
ADC10 to be treated as a 16-bit signed number when performing mathematical operations.

8 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Software Implementation

The following are the relevant ADC10 channel associations:


A12 (internal channel) → (AUXADC Voltage)/3, where AUXADC is selected to be DVCC
A11 (internal channel) → (VDSYS Voltage)/2
A10 (internal channel) → Temperature Sensor
A5 → Voltage V1
A4 → Voltage V2
A3 → Voltage V3

4.1.3 AUX Module


To ensure that the 32-kHz oscillator is powered, AUXVCC3 must be powered. This is done in software by
powering it internally from DVCC using AUXVCC3's internal charger. Also, the ability to use the ADC10 to
measure the primary or an auxiliary supply is enabled. In this software, the ADC10 is set to measure
DVCC.
The AUX module is set so that hardware switching is enabled for DVCC, AUXVCC1, and AUXVCC2. In
the software, the SVSMH voltage is set to level 4 (see data sheet for the range of exact voltages that
corresponds to a particular level). When VDSYS, the supply selected to power the chip, falls below this
SVSMH level it would trigger for VDSYS to switch to another supply as long as the supply to switch to is
above a user-defined threshold. The OK-voltage threshold for AUXVCC1 (AUX1LVL) and
AUXVCC2(AUX2LVL) is level 5. The OK-voltage level for DVCC (AUX0LVL) is level 6. Note that if DVCC
was previously not declared OK, but is later declared OK, the AUX module switches to DVCC even if
VDSYS is not below the SVSMH level. This auto-switch behavior is only true for DVCC and is not
applicable for AUXVCC1 or AUXVCC2. For more information about the AUX module, see the
MSP430x5xx and MSP430x6xx Family User's Guide (SLAU208).

4.1.4 Real-Time Clock (RTC_C)


The RTC_C is a real-time clock module that is configured to give precise 1 second interrupts. Based on
these 1‑second interrupts, the time and date are updated in software, as necessary. RTC temperature and
offset compensation are also implemented. In the software, a base offset of 118 ppm is applied, which is
based on RTC errors observed on samples of this EVM. For temperature compensation, a temperature
error of -34 ppm/(°C2) is used. This temperature error coefficient is taken from the data sheet of the
crystal used on this EVM.

4.1.5 LCD Controller


The LCD controller on the MSP430F67641 can support up to 8-mux displays and 320 segments. It is also
equipped with an internal charge pump that can be used for good contrast. In the current design, the LCD
controller is configured to work in 4-mux mode using 160 segments with a refresh rate set to 512 Hz. For
information, about the parameters that are displayed on the LCD, see Section 6.1.

4.2 Foreground Process


The foreground process includes the initial setup of the MSP430 hardware and software immediately after
a device RESET. Figure 6 shows the flowchart for this process.

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 9
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Software Implementation www.ti.com

RESET

HW setup:
Clock, AUX, SD24_B, Port pins, RTC_C,
eUSCI, LCD

DLT645 frame reception management

1 second of Energy accumulated NN


for any phase? Wait for
acknowledgement from
Background process

YY

oµoš‰Z[ušŒ}o}PÇŒ]vP

LCD management

Figure 6. Foreground Process

The initialization routines involve the setup of the analog to digital converter, clock system, auxiliary supply
system, general purpose input/output (port) pins, RTC module for clock functionality, LCD, and the
USCI_A0 for UART functionality. In addition, if ZigBee™ communication is enabled, USCI_A2 is
configured.
After the hardware is setup, any received frames from the GUI are processed. Subsequently, the
foreground process checks whether the background process has notified it to calculate new metering
parameters. This notification is done through the assertion of the "PHASE_STATUS_NEW_LOG" status
flag whenever a frame of data is available for processing. The data frame consists of the processed dot
products that were accumulated for one second in the background process. This is equivalent to
accumulation of 50 or 60 cycles of data synchronized to the incoming voltage signal. In addition, a sample
counter keeps track of how many samples have been accumulated over this frame period. This count can
vary as the software synchronizes with the incoming mains frequency.

10 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Software Implementation

The processed dot products include the VRMS, IRMS, active power, and reactive power. These dot
products are used by the foreground process to calculate the corresponding metrology readings in real-
world units. Processed voltage dot products are accumulated in 48-bit registers. In contrast, processed
current dot products, active energy dot products, and reactive energy dot products are accumulated in
separate 64-bit registers to further process and obtain the RMS and mean values. Using the foreground's
calculated values of active and reactive power, the apparent power is calculated. The frequency (in Hertz)
and power factor are also calculated using parameters calculated by the background process using the
formulas in Section 4.2.1.
The foreground process also takes care of updating the LCD. The LCD display item is changed every two
seconds. For more information, about the different items displayed on the LCD, see Section 6.1.

4.2.1 Computation Formulas


This section briefly describes the formulas used for the voltage, current, energy, and temperature
calculations.

4.2.1.1 RMS Voltage and Current


As described in the previous sections, voltage and current samples are obtained from the ADC10 and ΣΔ
converters at a sampling rate of 4096 Hz. All of the samples that are taken in one second are kept and
used to obtain the RMS values for voltage and current for each phase. The RMS values are obtained by
the following formulas:
Sample
count

¦v
n 1
ph (n) * v ph (n)
VRMS, ph K v, ph  v offset , ph
Sample count

Sample
count

¦i
n 1
ph (n) * i ph (n)
I RMS, ph K i, ph  i offset , ph
Sample count
where
• ph = Phase whose parameters are being calculated [that is, Phase A(=1), B(=2), or C(=3)]
• vph(n) = Voltage sample at a sample instant n
• voffset,ph = Offset used to subtract effects of the Additive White Gaussian Noise from the voltage converter
• iph(n) = Each current sample at a sample instant n
• ioffset,ph = Offset used to subtract effects of the Additive White Gaussian Noise from the current converter
• Sample count = Number of samples in one second
• Kv,ph = Scaling factor for voltage
• Ki,ph = Scaling factor for each current (1)

4.2.1.2 Power and Energy


Power and energy are calculated for one frame's worth of active and reactive energy samples. These
samples are phase corrected and passed on to the foreground process, which uses the number of
samples (sample count) to calculate phase active and reactive powers by the formulas in Equation 2.

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 11
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Software Implementation www.ti.com

Sample
count

¦ v(n) u i
n 1
ph (n)
PACT, ph K ACT, ph
Sample count
Sample
count

¦v
n 1
90 (n) u i ph (n)
PREACT, ph K REACT, ph
Sample count
where
• v90,ph (n) = Voltage sample at a sample instant n shifted by 90 degrees
• KACT,ph = Scaling factor for active power
• KREACT,ph = Scaling factor for reactive power (2)
For reactive power, the 90° phase shift approach is used for two reasons:
• It allows accurate measurement of the reactive power for very small currents.
• It conforms to the international specified measurement method.
The calculated mains frequency is used to calculate the 90 degrees-shifted voltage sample. Because the
frequency of the mains varies, it is important to first measure the mains frequency accurately to phase
shift the voltage samples accordingly (see Section 4.2.1.3).
To get an exact 90° phase shift, interpolation is used between two samples. For these two samples, a
voltage sample slightly more than 90 degrees before the current sample and a voltage sample slightly less
than 90 degrees before the current sample are used. The application's phase shift implementation
consists of an integer part and a fractional part. The integer part is realized by providing an N samples
delay. The fractional part is realized by a one-tap FIR filter. In the software, a lookup table provides the
filter coefficients that are used to create the fractional delays.
After calculating the active and reactive power, each phase's apparent power is calculated by the following
formula:
2 2
PAPP, ph PACT, ph  PREACT, ph (3)
In addition to calculating the per-phase active, reactive and apparent powers, the cumulative sum of these
parameters are calculated by the below equations:
3
PACT, Cumulative ¦P
ph 1
ACT, ph

3
PREACT, Cumulative ¦P
ph 1
REACT, ph

3
PAPP, Cumulative ¦P
ph 1
APP, ph
(4)
The calculated powers for each phase are then converted to energy by the following equations:
E ACT, ph PACT, ph u Samplecount
E REACT, ph PREACT, ph u Samplecount
E APP ph PAPP ph u Samplecount (5)
From there, they are also accumulated to calculate the cumulative energies, as shown by the below
equations:

12 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Software Implementation
3
EACT, Cumulative ¦E
ph 1
ACT, ph

3
EREACT, Cumulativel ¦E
ph -1
REACT, ph

3
E APP, Cumulativel ¦E
ph -1
APP, ph
(6)
The calculated energies are then accumulated into buffers that store the total amount of energy consumed
since meter reset. Note that these energy are different from the working variables used to accumulate
energy for outputting energy pulses. There are four sets of buffers that are available: one for each phase
and one for the cumulative of the phases. Within each set of buffers, the following energies are
accumulated:
1. Active import energy (active energy when active energy ≥ 0)
2. Active export energy (active energy when active energy < 0)
3. Reactive Quad I energy (reactive energy when reactive energy ≥ 0 and active power ≥ 0; inductive
load)
4. Reactive Quad II energy (reactive energy when reactive energy ≥ 0 and active power < 0; capacitive
generator)
5. Reactive Quad III energy (reactive energy when reactive energy < 0 and active power < 0; inductive
generator)
6. Reactive Quad IV energy (reactive energy when reactive energy < 0 and active power ≥ 0; capacitive
load)
7. Apparent import energy (apparent energy when active energy ≥ 0)
8. Apparent export energy (apparent energy when active energy < 0)

4.2.1.3 Frequency (Hz)


The background process calculates the frequency in terms of samples per mains cycle. The foreground
process then converts this to Hertz by Equation 7.
Sampling Rate (samples/second)
Frequency (Hz) =
Frequency (samples/cycle) (7)

4.2.1.4 Power Factor


After the active power and apparent power have been calculated, the absolute value of the power factor is
calculated. In the meter's internal representation of power factor, a positive power factor corresponds to a
capacitive load/generator and a negative power factor corresponds to an inductive load/generator. The
sign of the internal representation of power factor is determined based on the sign of the active and
reactive power. Therefore, the internal representation of power factor is calculated by the following
formula:
­ | PAct |
°P , if capacitive load/generator
° Apparent
Internal Representation of Power Factor ®
° | PAct | , if inducitive load/generator
°¯ PApparent
(8)

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 13
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Software Implementation www.ti.com

4.2.1.5 Temperature
Temperature is calculated using the TLV entries on the F67641. The measured values for 30°C ±3°C and
85°C ±3°C for the 2.0 V reference are used for calculating temperature. The exact formula that is used to
calculate temperature is shown below:
§ 85  30 ·
Temp ( ADC (raw)  CAL _ ADC _ 20T 30) u ¨¨ ¸¸  30
© CAL _ ADC _ 20T 85  CAL _ ADC _ 20T 30 ¹
(9)
The temperature is measured in units of Celsius. More information on this method of calculating
temperature could be found in the User's Guide.

4.3 Background Process


The background function deals mainly with timing critical events in software. It uses the ΣΔ interrupt as a
trigger to collect voltage and current samples. The ΣΔ interrupt is generated either when a new current
sample is ready or when the trigger generator of the ΣΔ triggers the ADC10. Once the trigger to the ADC
is generated, sample processing is done on the previously obtained voltage and current samples. This
sample processing is done by the "per_sample_dsp()" function. After sample processing, the background
process uses the "per_sample_energy_pulse_processing()" for the calculation and output of energy-
proportional pulses. Figure 7 shows the flowchart for this process.

SD24_B Interrupt

YY N
N
Trigger to ADC10 generated?

Retrieve previous DMA results for


Retrieve any new current samples
utilized ADC10 channels

Retrieve any new current samples

per_sample_dsp()

per_sample_energy_pulse_processing()

Retrieve any new current samples

Return from Interrupt

Figure 7. Background Process

14 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Software Implementation

When a trigger is generated, the next set of ADC10 conversions occur in parallel to the activity in the
background process. This parallel activity is shown in Figure 8, where the green items represent items that
are done automatically by the configuration of the ADC10, DMA, and ΣΔ modules. For these green items,
CPU intervention is not required.
As is represented in the Figure 8, whenever the ADC10 is triggered, the ADC10 enters autoscan mode
and samples all of its 16 ADC channels once. After each channel has a conversion result, the DMA
automatically places these results in memory and the next channel's conversion is automatically started.
For each converter, there is a memory location that stores the conversion results for that particular
converter. The procedure of sampling a converter and storing the results in memory is repeated until the
last converter (ADC10INCH=0) is sampled. Since the clock to the ADC10 is set to 4MHz, the sample and
hold time for each converter is 8 cycles, and the conversion time is 12 cycles, there is a total of
approximately 20 cycles (approximately 5 µs) delay between conversion results of adjacent converters.
To sense the internal temperature sensor using the ADC10, a recommended sample period of at least 30
µs must be used. As a result, the temperature reading measured in the autoscan mode may be invalid
since the sample time used is not sufficient. To mitigate this, a single conversion of the ADC10
temperature channel is triggered. This is triggered in the DMA ISR when all of the autoscan ADC results
have been placed in the proper memory locations. After a temperature reading has been received, the
ADC10 ISR is triggered. In this ISR, the temperature reading is stored and the ADC10 settings are then
reset to support autoscan mode. The ADC10 enters autoscan mode again at the next trigger from the ΣΔ's
trigger generator.

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 15
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Software Implementation www.ti.com

N
N

Trigger to ADC10 generated?

YY

Sample and convert selected ADC10


channel

Conversion completed

DMA transfers the ADC10 results into


the selected element in the DMA result
buffer. Update the selected element
for the DMA result index and the
selected ADC10 channel.

N
N
All ADC10 channels sampled?

YY

Trigger
Trigger temperature
temperature conversion
conversion

Sample and convert temperature


channel

Temperature conversion completed

Store
Store temperature
temperature reading
reading and
and re-
re-
initialize
initialize ADC10
ADC10 for
for autoscan
autoscan mode
mode

Figure 8. ADC10 Triggering Process

16 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Software Implementation

4.3.1 per_sample_dsp()
The flowchart for the per_sample_dsp function is shown in Figure 9. In this function, the per_sample_dsp
function is used to calculate intermediate dot product results that are fed into the foreground process for
the calculation of metrology readings. The ADC10 is configured to represent the 10-bit voltage results as a
16-bit signed result. Because 16-bit voltage samples are used, the voltage samples are further processed
and accumulated in dedicated 48-bit registers. In contrast, since 24-bit current samples are used, the
current samples are processed and accumulated in dedicated 64-bit registers. Per-phase active power
and reactive power are also accumulated in 64-bit registers.
After sufficient samples (approximately one second's worth) have been accumulated, then the foreground
function is triggered to calculate the final values of VRMS, IRMS, active, reactive, and apparent powers,
active, reactive, and apparent energy, frequency, temperature, and power factor. In the software, there are
two sets of dot products: at any given time, one is used by the foreground for calculation and the other
used as the working set by the background. After the background process has sufficient samples, it swaps
the two dot products so that the foreground uses the newly acquired dot products that the background
process just calculated and the background process uses a new empty set to calculate the next set of dot
products.
Whenever there is a leading-edge zero-crossing (- to + voltage transition) on a voltage channel, the
per_sample_dsp functhion is also responsible for updating the corresponding phase's frequency (in
samples/cycle) and voltage sag/swell conditions. For the sag conditions, whenever the RMS voltage is
below a certain user-defined threshold percentage, the number of Mains cycles where this condition
persists is logged as the sag duration. The number of periods in time where there was a sag condition is
logged as the sag events count. Note that the sag duration corresponds to the total number of cycles in a
sag condition since reset, and is therefore, not cleared for every sag event. Also, when the RMS voltage is
above a certain threshold percentage, swell events and duration are logged in a similar way.

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 17
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Software Implementation www.ti.com

Select new phase

Zu}ÀŒ]µo(}Œ‰Z[À}ošPšZv
µ‰š‰Z[sRMS dot product

Zu}ÀŒ]µo(}Œ‰Z[µŒŒvššZv
µ‰ššZ‰Z[}š‰Œ}µš(}Œ/ZD^, active
power, and reactive power

N
N
Leading-edge zero-crossing
on voltage channel?

YY
Voltage Sag/Swell Detection

Update frequency estimation

N
N
All three phases done?

YY
N
N
1 second of energy calculated
for any of the phases?

YY

Swap dot products between foreground and


bacground then notify foreground process.

Return

Figure 9. per_sample_dsp()

The following sections describe the various elements of electricity measurement in the per_sample_dsp
function.

4.3.1.1 Voltage and Current Signals


The output of each ΣΔ and ADC10 converter is a signed integer and any stray dc or offset value on these
converters are removed using a dc tracking filter. Separate dc estimates for all voltages and currents are
obtained using the filter and voltage and current samples, respectively. These estimates are then
subtracted from each voltage and current sample.

18 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Software Implementation

The resulting instantaneous voltage and current samples are used to generate the following intermediate
dot product results:
• Accumulated squared values of voltages and currents, which is used for VRMS and IRMS calculations,
respectively.
• Accumulated energy samples to calculate active energies.
• Accumulated energy samples using current and 90° phase shifted voltage to calculate reactive
energies.
These accumulated values are processed by the foreground process.

4.3.1.2 Frequency Measurement and Cycle Tracking


The instantaneous voltage of each phase is accumulated in 48-bit registers. In contrast, the instantaneous
current, active power, and reactive power are accumulated in 64-bit registers. A cycle tracking counter and
sample counter keep track of the number of samples accumulated. When approximately one second's
worth of samples have been accumulated, the background process switches the foreground and
background then notifies the foreground process to produce the average results such as RMS and power
values. Cycle boundaries are used to trigger the foreground averaging process since it produces very
stable results.
For frequency measurements, a straight line interpolation is used between the zero crossing voltage
samples. Figure 10 shows the samples near a zero cross and the process of linear interpolation.

noise corrupted samples

good samples

linear interpolation

Figure 10. Frequency Measurement

Because noise spikes can also cause errors, the application uses a rate of change check to filter out the
possible erroneous signals and make sure that the two points are interpolated from are genuine zero
crossing points. For example, with two negative samples, a noise spike can make one of them positive,
and therefore, make the negative and positive pair looks as if there is a zero crossing.
The resultant cycle-to-cycle timing goes through a weak low-pass filter to further smooth out cycle-to-cycle
variations. This results in a stable and accurate frequency measurement that is tolerant of noise.

4.3.2 LED Pulse Generation (per_sample_energy_pulse_processing)


In electricity meters, the active energy consumed is normally measured in fraction of kilowatt-hour (kWh)
pulses. This information can be used to calibrate any meter for accurate measurement. Typically, the
measuring element (the MSP430 microcontroller) is responsible to generate pulses proportional to the
energy consumed. To serve both these tasks efficiently, pulse generation must be accurate with relatively
little jitter. Although, time jitters are not an indication of bad accuracy, they give a negative indication on
the overall accuracy of the meter. Hence the jitter must be averaged out.

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 19
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Software Implementation www.ti.com

This application uses average power to generate these energy pulses. The average power (calculated by
the foreground process) is accumulated every ΣΔ interrupt, thereby spreading the accumulated energy
from the previous 1 second time frame evenly for each interrupt in the current 1 second time frame. This is
equivalent to converting it to energy. When the accumulated energy crosses a threshold, a pulse is
generated. The amount of energy above this threshold is kept and new energy value is added on top of it
in the next interrupt cycle. Because the average power tends to be a stable value, this way of generating
energy pulses are very steady and free of jitter.
The threshold determines the energy "tick" specified by meter manufacturers and is a constant. It is
usually defined in pulses per kWh or just in kWh. One pulse is generated for every energy "tick". For
example, in this application, the number of pulses generated per kWh is set to 1600 for active and reactive
energies. The energy "tick" in this case is 1 kWh/1600. Energy pulses are generated and available on a
header and also via LEDs on the board. General-purpose I/O (port) pins are used to produce the pulses.
In the EVM, the LEDs that are labeled "Phase 1", "Phase 2", "Phase 3", and "Active" correspond to the
active energy consumption for phase A, phase B, phase C, and the cumulative three-phase sum,
respectively. "Reactive" corresponds to the cumulative three-phase reactive energy sum. The number of
pulses per kWh and each pulse duration can be configured in software. Figure 11 shows the flow diagram
for pulse generation. This flow diagram is valid for pulse generation of individual or accumulative phase
active, reactive, and apparent energy.

SD interrupts at
4096 Hz

Energy
Accumulator+=
Average Power

N Energy Accumulator >


1 tick?

Energy Accumulator =
Energy Accumulator ±
1 tick

Generate 1
pulse

Proceed to other
tasks

Figure 11. Pulse Generation for Energy Indication

The average power is in units of 0.001 W and the 1 kWh threshold is defined as:
1 kWh threshold = (1 / 0.001) × 1 kW × (number of interrupts per second) × (number of seconds in one
hour) = 1000000× 4096 × 3600 = 0xD693A400000

20 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Software Implementation

4.3.3 Phase Compensation


When a current transformer (CT) is used as a sensor, it introduces additional phase shift on the current
signals. Also, the voltage and current input circuit's passive components may introduce additional phase
shift. Another source of phase shift is the sequential sampling on the voltage channel. The relative phase
shift between voltage and current samples must be compensated to ensure accurate measurements. The
ΣΔ converters have programmable delay registers (SD24PREx) that can be applied to any current. This
built-in feature (PRELOAD) is used to provide the phase compensation required.
The fractional delay resolution of the preload register is a function of input frequency (fIN), OSR, and the
sampling frequency (fS).
360 o u f IN 360 o u f IN
Delay resolutionDeg
OSR u f S fM (10)
In this application, for input frequency of 60 Hz, OSR of 256, and sampling frequency of 4096, the
resolution for every bit in the preload register is approximately 0.02° with a maximum of 5.25° (maximum
of 255 steps). When using CTs that provide a larger phase shift than this maximum, sample delays along
with fractional delay must be provided. This phase compensation can also be modified while the
application is running to accommodate temperature drifts in CTs, but conversions on the ΣΔ must be
stopped while changes are made to the phase compensation.

4.4 Energy Meter Configuration


Include files are used to initialize and configure the energy meter to perform several metrology functions.
This section describes the user-configurable options. The main user-configurable options are within the
following three files: metrology-calibration-template.h, metrology-template.h, and emter-template.h. Note
that some options are dependent on other options. Therefore, some options may automatically be enabled
if a particular option is selected. Many of the option associations are listed in the meterology-interactions.h
file.

4.4.1 metrology-calibration-template.h
The metrology-calibration-template file contains the default calibration values that are first programmed
into a meter before calibration. This file is located within the "emeter-metrology\emeter-metrology-67641"
directory.
In the project settings, the calibration factors are set so that they are automatically deleted and set to the
default calibration values whenever the meter firmware is reflashed. If it is desired to reflash the meter and
maintain the same calibration values, the project settings could be changed so that only main memory is
erased and information memory is retained. Alternatively, the default calibration values could be replaced
with the meter's current calibration values. The relevant calibration factor macros are described below:
1. CALADC10_20V_30C: This macro references the TLV structure to obtain the necessary information to
calculate temperature. This particularly refers to the temperature calibration data when the ADC10
uses a reference voltage of 2.0 V and the temperature is 30°C±3°C. For higher precision
measurements, an external temperature sensor could be used instead.
2. CALADC10_20V_85C: This macro references the TLV structure to obtain the necessary information to
calculate temperature. This particularly refers to the temperature calibration data when the ADC10
uses a reference voltage of 2.0 V and the temperature is 85°C±3°C. For higher precision
measurements, an external temperature sensor could be used instead.
3. DEFAULT_V_RMS_SCALE_FACTOR_A: This macro holds the scaling factor for voltage at phase A.
Set this factor to an approximately correct value, and it will be fine tuned during calibration.
4. DEFAULT_V_DC_ESTIMATE_A : This macro holds an estimate for the dc level of the voltage channel
of phase A. Using this estimate helps reduce the initial settling time of the dc voltage filter for phase A.
5. DEFAULT_V_AC_OFFSET_A: This macro removes the effect of the Additive White Gaussian Noise
from the voltage ADC of phase A. Additive White Gaussian Noise is orthogonal to everything except
itself. This results in the noise squaring when performing calculations for RMS voltage. When
performing calculations for RMS voltage, this macro is subtracted out from the mean-squared voltage
before its square root is taken to produce RMS voltage. Set this factor to an approximately correct
value, and it will be fine tuned during calibration.

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 21
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Software Implementation www.ti.com

6. DEFAULT_V_RMS_SCALE_FACTOR_B: This macro holds the scaling factor for voltage at phase B.
Set this factor to an approximately correct value, and it will be fine tuned during calibration.
7. DEFAULT_V_DC_ESTIMATE_B: This macro holds an estimate for the dc level of the voltage channel
of phase B. Using this estimate helps reduce the initial settling time of the dc voltage filter for phase B.
8. DEFAULT_V_AC_OFFSET_B: This macro removes the effect of the Additive White Gaussian Noise
from the voltage ADC of phase B. Additive White Gaussian Noise is orthogonal to everything except
itself. This results in the noise squaring when performing calculations for RMS voltage. When
performing calculations for RMS voltage, this macro is subtracted out from the mean-squared voltage
before its square root is taken to produce RMS voltage. Set this factor to an approximately correct
value, and it will be fine tuned during calibration.
9. DEFAULT_V_RMS_SCALE_FACTOR_C: This macro holds the scaling factor for voltage at phase C.
Set this factor to an approximately correct value, and it will be fine tuned during calibration.
10. DEFAULT_V_DC_ESTIMATE_C: This macro holds an estimate for the dc level of the voltage channel
of phase C. Using this estimate helps reduce the initial settling time of the dc voltage filter for phase C.
11. DEFAULT_V_AC_OFFSET_C: This macro removes the effect of the Additive White Gaussian Noise
from the voltage ADC of phase C. Additive White Gaussian Noise is orthogonal to everything except
itself. This results in the noise squaring when performing calculations for RMS voltage. When
performing calculations for RMS voltage, this macro is subtracted out from the mean-squared voltage
before its square root is taken to produce RMS voltage. Set this factor to an approximately correct
value, and it will be fine tuned during calibration.
12. DEFAULT_I_RMS_SCALE_FACTOR_A: This macro holds the scaling factor for current at phase A.
Set this factor to an approximately correct value, and it will be fine tuned during calibration.
13. DEFAULT_I_DC_ESTIMATE_A : This macro holds an estimate for the dc level of the current channel
of phase A. Using this estimate helps reduce the initial settling time of the dc current filter for phase A.
14. DEFAULT_I_AC_OFFSET_A: This macro removes the effect of the Additive White Gaussian Noise
from the current ADC of phase A. Additive White Gaussian Noise is orthogonal to everything except
itself. This results in the noise squaring when performing calculations for RMS current. When
performing calculations for RMS current, this macro is subtracted out from the mean-squared current
before its square root is taken to produce RMS current. Set this factor to an approximately correct
value, and it will be fine tuned during calibration.
15. DEFAULT_I_RMS_SCALE_FACTOR_B: This macro holds the scaling factor for current at phase B.
Set this factor to an approximately correct value, and it will be fine tuned during calibration.
16. DEFAULT_I_DC_ESTIMATE_B: This macro holds an estimate for the dc level of the current channel
of phase B. Using this estimate helps reduce the initial settling time of the dc current filter for phase B.
17. DEFAULT_I_AC_OFFSET_B: This macro removes the effect of the Additive White Gaussian Noise
from the current ADC of phase B. Additive White Gaussian Noise is orthogonal to everything except
itself. This results in the noise squaring when performing calculations for RMS current. When
performing calculations for RMS current, this macro is subtracted out from the mean-squared current
before its square root is taken to produce RMS current. Set this factor to an approximately correct
value, and it will be fine tuned during calibration.
18. DEFAULT_I_RMS_SCALE_FACTOR_C: This macro holds the scaling factor for current at phase C.
Set this factor to an approximately correct value, and it will be fine tuned during calibration.
19. DEFAULT_I_DC_ESTIMATE_C: This macro holds an estimate for the dc level of the current channel
of phase C. Using this estimate helps reduce the initial settling time of the dc current filter for phase C.
20. DEFAULT_I_AC_OFFSET_C: This macro removes the effect of the Additive White Gaussian Noise
from the current ADC of phase C. Additive White Gaussian Noise is orthogonal to everything except
itself. This results in the noise squaring when performing calculations for RMS current. When
performing calculations for RMS current, this macro is subtracted out from the mean-squared current
before its square root is taken to produce RMS current. Set this factor to an approximately correct
value, and it will be fine tuned during calibration.
21. DEFAULT_P_SCALE_FACTOR_A: This macro holds the scaling factor for active power at phase A.
Set this factor to an approximately correct value, and it will be fine tuned during calibration.
22. DEFAULT_P_SCALE_FACTOR_B This macro holds the scaling factor for active power at phase B.
Set this factor to an approximately correct value, and it will be fine tuned during calibration.

22 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Software Implementation

23. DEFAULT_P_SCALE_FACTOR_C: This macro holds the scaling factor for active power at phase C.
Set this factor to an approximately correct value, and it will be fine tuned during calibration
24. DEFAULT_BASE_PHASE_A_CORRECTION: This macro holds the value for phase correction to
compensate for delay due to the current transformer/front-end circuitry at phase A. This can be set to a
value that is in fairly acceptable range, and it will be fine tuned under phase correction during
calibration.
25. DEFAULT_BASE_PHASE_B_CORRECTION: This macro holds the value for phase correction to
compensate for delay due to the current transformer/front-end circuitry at phase B. This can be set to a
value that is in fairly acceptable range, and it will be fine tuned under phase correction during
calibration.
26. DEFAULT_BASE_PHASE_C_CORRECTION: This macro holds the value for phase correction to
compensate for delay due to the current transformer/front-end circuitry at phase C. This can be set to a
value that is in fairly acceptable range, and it will be fine tuned under phase correction during
calibration.

4.4.2 metrology-template.h
The metrology-template file contains the different user-configurable metrology-related options. This file is
located within the "emeter-metrology\emeter-metrology-67641" directory. The relevant user-configurable
options are below:
1. NUM_PHASES: This selects the maximum number of phases that the EVM supports. This value
should be left at the default value of 3. It should not be changed.
2. TWENTYFOUR_BIT: This selects the resolution of the current channels. If it is defined, 24-bit samples
are used for current. If it is not defined, 16-bits are used for voltage. Since there is no benefit in using a
smaller resolution, this macro should be left defined and not be disabled.
3. PHASE_1_CURRENT_ADC_CHANNEL: This defines the Sigma Delta converter number that
corresponds to Phase 1 (phase A).
4. PHASE_1_VOLTAGE_ADC_CHANNEL: This defines the ADC10 channel that is associated with
phase 1 (phase A).
5. PHASE_2_CURRENT_ADC_CHANNEL: This defines the Sigma Delta converter number that
corresponds to Phase 2(phase B).
6. PHASE_2_VOLTAGE_ADC_CHANNEL: This defines the ADC10 channel that is associated with
phase 2 (phase B).
7. PHASE_3_CURRENT_ADC_CHANNEL : This defines the Sigma Delta converter number that
corresponds to Phase 3 (phase C).
8. PHASE_3_VOLTAGE_ADC_CHANNEL: This defines the ADC10 channel that is associated with
phase 3 (phase C).
9. SD_LIVE_CURRENT_GAIN: This macro defines the gain of the ΣΔ24_B's internal programmable gain
amplifier (PGA) for all the three currents. In this application it is set to 1.
10. SD_CLOCK_DIVISION: This defines the ratio of the ADC clock source's frequency and the ADC clock
frequency. Since a 25 MHz clock is used to produce a modulation clock of approximately 1 MHz, the
division factor is 24. This macro could only have a value of 8, 16, 20, or 24 and it should not be
changed if the software's default clock frequency is used.
11. MAINS_NOMINAL_FREQUENCY: The nominal mains frequency, in Hz that is used to prime the
mains frequency filter to make it settle more quickly.
12. MAINS_NOMINAL_VOLTAGE: This selects the nominal voltage used for sag/swell detection.
13. VCC_MEASURE_SUPPORT: Defining this macro supports the storing of the VDSYS/2 reading into
the "vcc" variable.
14. MAINS_BASIS_CURRENT: This selects the basis current.
15. MAINS_MAXIMUM_CURRENT: This selects the maximum operating current.
16. IEC_THD_SUPPORT: This selects support for IEC style THD readings. If this is not defined, IEEE
style readings will be produced for any THD readings.
17. MAINS_FREQUENCY_SUPPORT: The macro configures the meter to measure the frequency of the
AC mains.
SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 23
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Software Implementation www.ti.com

18. VRMS_SUPPORT: This macro is used to configure the meter to calculate VRMS from the voltage
samples.
19. SAG_SWELL_SUPPORT: This selects support for sag and swell detection.
20. SAG_SWELL_WINDOW_LEN: This selects the number of mains cycles over which sag and swell
detection works.
21. SAG_THRESHOLD: This selects the percentage fall from the nominal voltage for sag detection.
22. SWELL_THRESHOLD: This selects the percentage rise above the nominal voltage for swell detection.
23. FUNDAMENTAL_VRMS_SUPPORT: This selects support for fundamental RMS voltage
measurement.
24. VOLTAGE_THD_SUPPORT: This selects support for measuring the THD in the voltage waveform.
25. IRMS_SUPPORT: This macro is used to configure the meter to calculate IRMS from the current
samples.
26. FUNDAMENTAL_IRMS_SUPPORT: This selects support for fundamental RMS current measurement.
27. CURRENT_THD_SUPPORT: This selects support for measuring the THD in the current waveform.
28. FUNDAMENTAL_ACTIVE_POWER_SUPPORT: This selects support for fundamental active power
measurement.
29. REACTIVE_POWER_SUPPORT: This selects support for reactive power measurement.
30. REACTIVE_POWER_BY_QUADRATURE_SUPPORT: This selects support for reactive power
measurement through quadrature processing. This is only effective when
REACTIVE_POWER_SUPPORT is enabled.
31. FUNDAMENTAL_REACTIVE_POWER_SUPPORT: This selects support for fundamental reactive
power measurement.
32. APPARENT_POWER_SUPPORT: The selects support for apparent or VA power measurement.
33. POWER_FACTOR_SUPPORT: This macro is used to configure the meter to calculate the power
factor for both lead and lag. A frequency independent method, based on the ratio of scalar dot
products, is used.
34. RESIDUAL_POWER_CUTOFF: Tiny power levels should not record energy at all, as they may just be
rounding errors, noise, or the consumption of the meter itself. This value is the cutoff level in milliwatts
(this is the cutoff per phase).
35. TOTAL_RESIDUAL_POWER_CUTOFF: Tiny power levels should not record at all, as they may just
be rounding errors, noise, or the consumption of the meter itself. This value is the cutoff level, in 0.01W
increments (this is the cutoff for the aggregate power).
36. ACTIVE_ENERGY_SUPPORT: This switch selects support for measuring the active energy
consumption on a phase by phase basis. This will allow the GUI to display each phase's active energy
consumption in kWh.
37. ACTIVE_ENERGY_PULSES_PER_KW_HOUR: This macro defined the total number of pulses per
1 kWh of active energy at each phase. In this application it is defined to 1600 if pulses generation for
each individual phase has been enabled. If the value of this macro is increased, it may be necessary to
decrease the pulse duration.
38. REACTIVE_ENERGY_SUPPORT: This switch selects support for measuring the reactive energy
consumption on a phase by phase basis. This will allow the GUI to display each phase's reactive
energy consumption in kvarh.
39. APPARENT_ENERGY_SUPPORT: This switch selects support for measuring the apparent energy
consumption on a phase by phase basis. This will allow the GUI to display each phase's apparent
energy consumption in kVA.
40. TOTAL_ACTIVE_ENERGY_SUPPORT: This switch selects support for measuring the total active
energy consumption. This will allow the GUI to display the cumulative phase's active energy
consumption in kWh.
41. TOTAL_REACTIVE_ENERGY_SUPPORT: This switch selects support for measuring the total reactive
energy consumption. This will allow the GUI to display the cumulative phase's reactive energy
consumption in kvarh.

24 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Software Implementation

42. TOTAL_APPARENT_ENERGY_SUPPORT: This switch selects support for measuring the total
apparent energy consumption. This will allow the GUI to display the cumulative phase's apparent
energy consumption in kVA.
43. TOTAL_ACTIVE_ENERGY_PULSES_PER_KW_HOUR: This sets the number of pulses per kilo-watt
hour the meter will produce at its total active energy pulse. It does not affect the energy accumulation
process. The default setting for this macro is 1600.
44. TOTAL_REACTIVE_ENERGY_PULSES_PER_KVAR_HOUR: This sets the number of pulses per kilo-
var hour the meter will produce at its total reactive energy pulse. It does not affect the energy
accumulation process. The default setting for this macro is 1600.
45. ENERGY_PULSE_DURATION: The duration of the LED on time for an energy pulse. This is
measured in ADC samples (that is, increments 1/4096s). The maximum allowed is 255, giving a pulse
of about 62ms. The default value for this macro is 80. For higher pulses/kwh constants, the value for
this macro may need to be reduced.
46. TEMPERATURE_SUPPORT: This switch enables use of the MSP430's internal temperature diode to
measure the meter's temperature.
47. PRECALCULATED_PARAMETER_SUPPORT: Normally the meter software only calculates the
properly scaled values for voltage, current, etc. as these values are needed. This define enables
additional global parameters, which are regularly updated with all the metrics gathered by the meter.
This is generally less efficient, as it means calculating things more often than necessary. However,
some may find this easier to use, so it is offered as a choice for the meter designer.
48. custom_adc_interrupt():This is called every ADC interrupt, after the main DSP work has finished. It
can be used for things like custom keypad operations. It is important this is a very short routine, as it is
called from the main ADC interrupt.

4.4.3 emeter-template.h
The emeter-template file contains the different user-configurable application-related options. This file is
located within the "emeter-app\emeter-app-67641" directory. The relevant user-configurable options are
below
1. SERIAL_CALIBRATION_SUPPORT: This switch, in combination with the calibrator switch, enables
calibration with the meter cooperating with an external reference, through a UART port.
2. SERIAL_CALIBRATION_REF_SUPPORT: This switch enables the sending of the current readings,
through a UART port, for use in cooperative calibration with other meters.
3. RTC_SUPPORT: This selects real time clock support.
4. IHD430_SUPPORT: This macro allows ZigBee communication to an IHD430 in-home display. A
CC2530 transmitter must be placed in the EVM's RF connector to enable this. For more information,
see Section 6.2.
5. DLT645_SUPPORT: This macro enables DLT645 communciation.
6. custom_active_energy_pulse_start: This macro defines the command used to turn on the active energy
LED for a pulse.
7. custom_active_energy_pulse_end: This macro defines the command used to turn off the active energy
LED for a pulse.
8. custom_reactive_energy_pulse_start: This macro defines the command used to turn on the reactive
energy LED for a pulse.
9. custom_reactive_energy_pulse_end: This macro defines the command used to turn off the reactive
energy LED for a pulse.
10. OUTPUT_RTCCLK: If this macro is defined, the active pulse capability is disabled and the RTCCLK,
which is used for calibration, is output on the header normally used for active power pulses.
In addition to the above macros, there are also various macros for defining the display properties of the
EVM's LCD and the values of the LCD display registers. Also there are macros that are used to initialize
the values of the DIR, SEL, OUT, and REN registers of each port. In the software, these values are set to
values to correspond to the hardware of this EVM.

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 25
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Energy Meter Demo www.ti.com

5 Energy Meter Demo


The energy meter evaluation module (EVM) associated with this application report has the
MSP430F67641 and demonstrates energy measurements. The complete demonstration platform consists
of the EVM that can be easily hooked to any test system, metrology software and a PC GUI, which is
used to view results and perform calibration.

5.1 EVM Overview


The following figures of the EVM show the hardware. Figure 12 is the top view of the energy meter.
Figure 13 shows the location of various pieces of the EVM based on functionality.

Figure 12. Top View of the Three Phase Energy Meter EVM

26 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Energy Meter Demo

Figure 13. Top View of the EVM With Components Highlighted

Danger High Voltage Electric shock possible when connecting board to live wires. Board should be
handed with care by a professional.
For safety, use of isolated test equipment with overvoltage and overcurrent
protection is highly recommended.

5.1.1 Connections to the Test Setup or AC Voltages

CAUTION
Do note leave EVM powered when unattended.

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 27
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Energy Meter Demo www.ti.com

AC voltage or currents can be applied to the board for testing purposes at these points:
• Pad LINE_1 corresponds to the line connection for phase A.
• Pad LINE_2 corresponds to the line connection for phase B.
• Pad LINE_3 corresponds to the line connection for phase C.
• Pad NEUTRAL corresponds to the Neutral voltage.
The voltage between any of the three line connections to the neutral connection can be up to 230 V AC at
50/60 Hz.
• I1+ and I1- are the current inputs after the sensors for phase A. When a current sensor is used, make
sure that the voltage across I1+ and I1- does not exceed 920 mV. THIS IS CURRENTLY
CONNECTED TO A CT ON THE EVM.
• I2+ and I2- are the current inputs after the sensors for phase B. When a current sensor is used, make
sure that the voltage across I2+ and I2- does not exceed 920 mV. THIS IS CURRENTLY
CONNECTED TO A CT ON THE EVM.
• I3+ and I3- are the current inputs after the sensors for phase C. When a current sensor is used, make
sure that the voltage across I3+ and I3- does not exceed 920 mV. THIS IS CURRENTLY
CONNECTED TO A CT ON THE EVM.
Figure 14 and Figure 15 show the various connections that need to be made to the test setup for proper
functionality of the EVM.
When a test AC source needs to be connected, the connections must be made according to the EVM
design. Figure 14 shows the connections from the top view. VA+ , VB+, and VC+ corresponds to the line
voltage for phases A, B, and C, respectively. VN corresponds to the neutral voltage from the test AC
source.

Figure 14. Top View of the EVM With Test Setup Connections

28 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Energy Meter Demo

Figure 15 shows the connections from the front view. IA+ and IA- correspond to the current inputs for
phase A, IB+ and IB- correspond to the current inputs for phase B, and IC+ and IC- correspond to the
current inputs for phase C. VN corresponds to the neutral voltage from the test setup.

Figure 15. Front View of the EVM With Test Setup Connections

5.1.2 Power Supply Options and Jumper Settings


The EVM can be configured to operate with different sources of power. The entire board can be powered
by a single dc voltage rail (DVCC), which can be derived either via JTAG, external power, or AC mains
through either the capacitive or switching power supplies. Various jumper headers and jumper settings are
present to add to the flexibility to the board. Some of these headers require that jumpers be placed
appropriately for the board to correctly function. Table 1 describes the functionality of each jumper on the
board and the associated functionality.

Table 1. Header Names and Jumper Settings on the EVM430-F67641


Header,
Main
Header Option Type Valid Use Case Comments
Functionality
Name
Probe between here and ground for This header is not isolated from AC
cumulative three-phase active energy voltage, so do not connect measuring
Active Energy pulses. Alternatively, enable port equipments unless isolators external to
ACT/RTCCLK
2-pin Pulses/RTC mapping to connect this pin instead to the EVM are available. See the
(Not isolated,
Header Calibration RTCCLK. When connected to RTCCLK, ISOLATED ACT header, instead. Note
do not probe)
(WARNING) probe here to measure the frequency of that by default this pin is configured for
RTCCLK, which is used for calibrating outputting active pulses. The software
the RTC. must be modified to output RTCCLK.
Place a jumper here to connect AUXVCC1 to GND. This jumper must be present if
AUXVCC1 AUXVCC1 is not used as a backup power supply. Alternatively, it can be used to
AUXVCC1 (Not
2-pin Selection and provide a backup power supply to the MSP430. To do so, connect the alternative
isolated, do not
Header External Power power supply to this header. In addition, on the bottom of the board, an optional
probe)
(WARNING) super capacitor has been added. If this super capacitor is not desired for the user's
selected AUX configuration, it should be removed.
AUXVCC2
Place a jumper here to connect AUXVCC2 to GND. This jumper must be present if
AUXVCC2 (Not 2-pin selection;
AUXVCC2 is not used as a backup power supply. Alternatively, it can be used to
isolated, do not Jumper AUXVCC2
provide a backup power supply to the MSP430. To do so, simply connect the
probe) Header External Power
alternative power supply to this header.
(WARNING)
To power the RTC externally regardless of whether or not DVCC is available,
provide external voltage at AUXVCC3, disable the internal AUXVCC3 charger in
software, and do not connect a jumper at this header.
3-pin AUXVCC3 Alternatively, place a jumper at the "VDSYS" option to connect AUXVCC3 to
AUXVCC3 (Not
Jumper Selection and VDSYS so that it is powered from whichever supply (DVCC, AUXVCC1, or
isolated, do not
Header External Power AUXVCC2) is powering the chip. If this jumper is placed, disable the internal
probe)/JP15
Option (WARNING) charger in software.
To power the RTC externally only when DVCC is not available, enable the internal
charger, place a jumper at the "Diode" option, and apply external voltage at the
VBAT header.

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter Using 29
Submit Documentation Feedback the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Energy Meter Demo www.ti.com

Table 1. Header Names and Jumper Settings on the EVM430-F67641 (continued)


Header,
Main
Header Option Type Valid Use Case Comments
Functionality
Name
Do not probe if board is powered from
Ground Not a jumper header, probe here for
DGND (Not AC mains, unless the AC mains are
Voltage GND voltage. Connect negative terminal
isolated, do not Header isolated. This voltage can be hot or
Header of bench or external power supply when
probe) neutral if AC wall plug is connected to
(WARNING) powering the board externally.
the meter
Not a jumper header, probe here for
DVCC (Not VCC Voltage Do not probe if board is powered from
VCC voltage. Connect positive terminal
isolated, do not Header Header AC mains, unless the AC mains are
of bench or external power supply when
probe) (WARNING) isolated.
powering the board externally.
DVCC
EXTERNAL
(Do not JTAG External
This jumper option and the DVCC
connect JTAG Jumper Power Place a jumper at this header option to
INTERNAL jumper option comprise one
if AC mains is Header Selection select external voltage for JTAG
three-pin header used to select the
the power Option Option programming.
voltage source for JTAG programming.
source Isolated (WARNING)
JTAG or supply
is fine)
DVCC
JTAG Internal
INTERNAL (Do Place a jumper at this header option to This Jumper option and the DVCC
Jumper Power
not connect power the board using JTAG and to EXTERNAL jumper option comprise one
Header Selection
JTAG if AC select the voltage from the USB FET for three-pin header used to select the
Option Option
mains is the JTAG programming. voltage source for JTAG programming.
(WARNING)
power source).
Place a jumper only if AC mains voltage
is needed to power the DVCC rail. This
DVCC
Jumper Switching- Place a jumper at this header position to header option and the DVCC VCC_PL
VCC_ISO (Not
Header Mode Supply power the board via AC mains using the header option comprise one three-pin
isolated, do not
Option Select switching power supply header that selects a capacitive power
probe)
supply, a switching-mode power supply,
or neither.
Place a jumper only if AC mains voltage
is needed to power the DVCC rail. Do
not debug using JTAG unless AC source
DVCC Capacitor
Jumper Place a jumper at this header position to is isolated or JTAG is isolated. This
VCC_PL (Not Power Supply
Header power the board via AC mains using the header option and the DVCC VCC_ISO
isolated, do not Select
Option capacitor power supply header option comprise one three-pin
probe) (WARNING)
header that selects a capacitive power
supply, a switching-mode power supply,
or neither.
This header is isolated from AC voltage
Not a jumper header, probe between
ISOLATED 1-pin Isolated Active so it is safe to connect to scope or other
here and ground for cumulative three-
ACT Header Energy Pulses measuring equipment since isolators are
phase active energy pulses
already present.
This header is isolated from AC voltage
Isolate Not a jumper header, probe between
ISOLATED 1-pin so it is safe to connect to scope or other
Reactive here and ground for cumulative three-
REACT Header measuring equipment since isolators are
Energy Pulses phase reactive energy pulses
already present.
There are six headers that jumpers must
be placed at to select a JTAG
J (Do not communication option. Each of these six
4-wire JTAG
connect JTAG Jumper Place jumpers at the J header options of headers have a J option and an S option
Programming
if AC mains is Header all of the six JTAG communication to select either 4-wire JTAG or SBW. To
Option
the power Option headers to select 4-wire JTAG. enable 4-wire JTAG, configure all of
(WARNING)
source) these headers for the J option. To
enable SBW, configure all of the
headers for the S option.

30 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter Using SLAA621C – March 2014 – Revised August 2015
the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Energy Meter Demo

Table 1. Header Names and Jumper Settings on the EVM430-F67641 (continued)


Header,
Main
Header Option Type Valid Use Case Comments
Functionality
Name
When the BTN1 option is selected,
Place a jumper at the "BTN1" option to pressing BTN1 makes P1.7 LOW. When
connect P1.7 of the MSP430 to the the button is not pressed, P1.7 is HIGH.
Jumper MSP430 P1.7
EVM's "BTN1" button. Place a jumper at When the "RF_VREG_EN" is selected,
JP1 Header Connection
the "RF_VREG_EN" option, to connect the "MSP430" option must be selected
Option Selection
P1.7 of the MSP430 to the "MSP430" from JP17 to connect P1.7 to the
option of JP17(RF_VREG_EN section). "RF_VREG_EN" of the radio module
connected to the board's RF connectors.
RF Connector Place a jumper here to enable
Jumper
JP13 Transmit transmission to the radio module
Header
Enable connected to the EVM's RF connectors.
RF Connector Place a jumper here to enable receiving
Jumper
JP14 Receiver from the radio connected to the EVM's
Header
Enable RF connectors
Place a jumper between DVCC and
RF_VREG_EN to connect the RF
Jumper
connector's RF_VREG_EN connection
Header
RF Connector's to DVCC. Place a jumper between GND When the "MSP430" option is selected,
Option
RF_VREG_EN and RF_VREG_EN to connect the RF the "RF_VREG_EN" option must be
(Connect
JP17 Connection connector's RF_VREG_EN connection selected from JP1 to connect P1.7 to the
only one
Selection to Ground. Place a jumper between "RF_VREG_EN" of the radio module
option to
(WARNING) DVCC and RF_VREG_EN to connect connected to the board's RF connectors.
RF_VREG
the RF connector's RF_VREG_EN
_EN)
connection to the "RF_VREG_EN"
option of the JP1 header.
This header is not isolated from AC
REACT (Not Reactive Not a jumper header, probe between voltage so do not connect measuring
1-pin
isolated, do not Energy Pulses here and ground for cumulative three- equipments unless isolators external to
Header
probe) (WARNING) phase reactive energy pulses the EVM are available. See the
ISOLATED REACT header, instead.
Jumper RS-232 Place a jumper here to enable receiving
RX_EN
Header Receive enable characters using RS-232.
There are six headers where jumpers
must be placed at to select a JTAG
communication mode. Each of these six
S (Do not
SBW JTAG headers that have a J option and an S
connect JTAG Jumper Place jumpers at the S header options
Programming option to select either 4-wire JTAG or
if AC mains is Header of all of the six JTAG communication
Option SBW. To enable 4-wire JTAG, all of
the power Option headers to select SBW
(WARNING) these headers must be configured for
source)
the J option. To enable SBW, all of the
headers must be configured for the S
option.
I2C/EEPROM
SCL (Not 1-pin
SCL probe
isolated, do not Jumper Probe here to probe I2C SCL line Probe only when AC mains is isolated.
point
probe) Header
(WARNING)
I2C/EEPROM
SDA (Not 1-pin
SDA probe
isolated, do not Jumper Probe here to probe I2C SDA line Probe only when AC mains is isolated.
point
probe) Header
(WARNING)
RS-232
Jumper Place a jumper here to enable RS-232
TX_EN Transmit
Header transmissions.
Enable
AUXVCC3
2-pin External Power
When the "Diode" option is selected for AUXVCC3, apply voltage at this header so
Jumper For AUXVCC3
that the RTC can still be powered when the voltage at DVCC is removed.
Header “Diode” Option
(WARNING)

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 31
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Energy Meter Demo www.ti.com

5.2 Loading the Example Code


The source code is developed in the IAR Embedded Workbench™ environment using IAR version 5.60.7
for the MSP430 IDE and version 6.6.4.2867 for the IAR Embedded Workbench common components. The
current version of IAR can be viewed from the "Product Info" option in the Help menu.
There are four main parts to the energy metrology software:
• The toolkit that contains a library of mostly mathematics routines
• The metrology code that is used for calculating metrology parameters
• The application code that is used for the host-processor functionality of the meter (for example,
communication, LCD display, and RTC setup)
• The GUI that is used for calibration

5.2.1 Opening the Project


Figure 16 shows the contents of the Source folder.

Figure 16. Source Folder Structure

Within the emeter-app-67641 folder in the emeter-app folder, the emeter-app-67641.ewp project
corresponds to the application code. Similarly, within the emeter-metrology-67641 folder in the emeter-
metrology folder, the emeter-metrology-67641.ewp project corresponds to the portion of the code for
metrology. Additionally, the folder emeter-toolkit-67641 within emeter-toolkit has the corresponding toolkit
project file emeter-toolkit-67641.ewp. For first time use, it is recommended that all three projects be
completely rebuild by performing the following steps:
1. Open the IAR IDE.
2. Open the F67641 workspace, which is located in the "Source" folder.
3. Within IAR's workspace window, click the "Overview" tab to have a list view of all the projects.
4. Right-click the "emeter-toolkit-67641" option in the workspace window and select Rebuild All, as shown
in Figure 17.
5. Right-click the "emeter-metrology-67641" option in the workspace window and select Rebuild All, as
shown in Figure 18.
6. Within IAR's workspace window, click the "emeter-app-67641" tab.
7. Within the workspace window, select "emeter-app-67641", click Rebuild All as shown in Figure 19, and
then download this project onto the MSP430F67641.

NOTE: If any changes are made to any of the files in the toolkit project and the project is compiled,
the metrology project must be recompiled. After recompiling the metrology project, the
application project must then be recompiled. Similarly, if any changes are made to any of the
files in the metrology project and the project is compiled, the application project must then be
recompiled.

32 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Results and Calibration

Figure 17. Toolkit Project Figure 18. Metrology Project Figure 19. Application Project
Compilation Compilation Compilation

6 Results and Calibration

6.1 Viewing Results on the LCD


The LCD display scrolls between metering parameters every two seconds. For each metering parameter
that is displayed on the LCD, three items are usually displayed on the screen: a symbol used to denote
the phase of the parameter, text to denote which parameter is being displayed, and the actual value of the
parameter. The phase symbol is displayed at the top of the LCD and denoted by a triangle shape. The
orientation of the symbol determines the corresponding phase. Figure 20 shows the mapping between the
different orientations of the triangle and the phase descriptor:

Phase A Phase B Phase C


Figure 20. Phase Symbols

Aggregate results (such as cumulative active and reactive power) and parameters that are independent of
phase (such as time and date) are denoted by clearing all of the phase symbols on the LCD.
The bottom line of the LCD is used to denote the value of the parameter being displayed. The text to
denote the parameter being shown is displayed on the top line of the LCD. Table 2 shows the different
metering parameters that are displayed on the LCD and the associated units in which they are displayed.
The "Designation" column shows which characters correspond to which metering parameter.

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 33
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Results and Calibration www.ti.com

Table 2. Displayed Parameters


Parameter
Designation Units Comments
Name

This parameter is displayed for each phase. The aggregate


Active Power Watt (W)
active power is also displayed.

Reactive Volt-Ampere Reactive This parameter is displayed for each phase. The aggregate
Power (var) reactive power is also displayed.

Apparent
Volt-Ampere (VA) This parameter is displayed for each phase.
Power

Constant between 0
Power Factor This parameter is displayed for each phase.
and 1

Voltage Volts (V) This parameter is displayed for each phase.

Current Amps (A) This parameter is displayed for each phase.

Frequency Hertz (Hz) This parameter is displayed for each phase.

Total
Consumed kWh This parameter is displayed for each phase.
Active Energy

Total
Consumed This parameter is displayed for each phase. This displays the
kVarh
Reactive sum of the reactive energy in quadrant 1 and quadrant 4.
Energy

This parameter is only displayed when the sequence of


Time Hour:Minute:Second aggregate readings is displayed. It is not displayed once
per phase.

This parameter is only displayed when the aggregate readings


Date Year:Month:Day
are displayed. It is not displayed once per phase.

34 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Results and Calibration

Figure 21 shows an example of phase A's measured frequency of 49.99 Hz displayed on the LCD.

Figure 21. LCD Display

6.2 View Results Using RF Technology (ZigBee™)


The CC2530 Evaluation Module (EM) (CC2530EMK) is an add-on (plug-in) daughter card that can be
purchased separately for ZigBee (IEEE Std 802.15.4) RF applications in the 2.4-GHz unlicensed ISM
band. The communication interface to any host or application processor is by UART. The instantaneous
power consumption is sent periodically to the ZigBee module for wireless transmission.

Figure 22. ZigBee Radio

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 35
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Results and Calibration www.ti.com

This ZigBee module is connected by the UART, which is configured to 115.2 kbaud to the MSP430F67641
on the transmit portion and the MSP430F4618 on the receive portion (IHD430).

36 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Results and Calibration

6.2.1 In-Home Display (IHD)


Most IHDs have their own setup mechanism and all of them tend to join the ZigBee network when they
are turned on. In this section, it is assumed that TI's IHD430 (http://www.ti.com/tool/TIDM-LOWEND-IHD_)
is used as the in-home display. The IHD430 has a MSP430F461x as an application and host processor.

Figure 23. TI Designed IHD430

6.2.1.1 View cumulative three-phase active power readings on the IHD430


Place a CC2530 module in the RF connector socket of the meter (EVM430-F67641). Make sure that it is
properly oriented. This CC2530 should be flashed with code to act as a transmitter. The IHD430 also has
a corresponding CC2530 flashed to act as a receiver.

6.2.1.2 Initialize the IHD430


Power must be provided by two AAA batteries or by an external supply. The power source is selected by
configuring jumpers on VCC and BATT headers and the power is supplied to the on-board MSP430 by
placing a jumper on PWR1 header. The power setup options are:
• Jumper settings to provide Battery power are:
– Place a jumper on the BATT header.
– Place a jumper on the PWR1 header.
• Jumper settings to provide Flash emulation tool power are:
– Place a jumper on pins [1-2] on VCC 3-pin header.
– Place a jumper on the PWR1 header.
• Jumper settings to provide External power are:
– Place a jumper on pins [2-3] on the VCC 3-pin header.
– Place a jumper on the PWR1 header.
• Place a jumper on the RF_PWR header, which enables or disables power to CC2530.
For the MSP430F67641 software to communicate the cumulative three-phase active power to the IHD430,
the IHD430_SUPPORT macro must be defined in the emeter-template.h file. When this macro is enabled,
the cumulate three-phase active power reading is sent to the on-board CC2530 transmitter via 8N1 UART
communication at a rate of 115.2 kbaud. The CC2530 then sends the data to the CC2530 receiver.
IHD430 receives the active power readings and displays them on the LCD. Note that the transmitter
(meter) must be turned on before the receiver to ensure proper ZigBee communication. In addition,
modifications can be made to MSP430F67641 software to send different parameters for display onto the
IHD430.

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 37
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Results and Calibration www.ti.com

6.3 Calibrate and View Results With a PC

6.3.1 GUI Execution


To run the GUI:
1. Connect the EVM to a PC via an RS-232 cable.
2. Open the /Source/GUI folder and open calibration-config.xml in a text editor.
3. Change the "port name" field within the "meter" tag to the COM port connected to the meter. In
Figure 24, this field is changed to COM7.

Figure 24. GUI Config File Changed to Communicate With Meter

4. Run calibrator.exe in the /Source/GUI folder. If the COM port in calibration-config.xml was changed in
the previous step to the com port connected to the EVM, the GUI opens (see Figure 25).
If the GUI connects properly to the EVM, the top left button is green. If there are problems with
connections or if the code is not configured correctly, the button is red. Click the green button to view
the results.

Figure 25. GUI Startup Window

38 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Results and Calibration

6.3.2 View Results


When you click on the green button, the results window opens (see Figure 26). Note that there is a trailing
"L" or "C" on the Power factor values to indicate an inductive or capacitive load, respectively.

Figure 26. Results Window

From the results window, the total-energy consumption readings and sag/swell logs can be viewed by
pressing the "Meter Consumption" button. When this button is pressed, the meter events and consumption
window opens (see Figure 27).

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 39
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Results and Calibration www.ti.com

Figure 27. Meter Events and Consumption Window

6.3.3 Calibration
Calibration is key to any meter's performance, and it is absolutely necessary for every meter to go through
this process. Initially, every meter exhibits different accuracies due to silicon-to-silicon differences, sensor
accuracies, and other passive tolerances. To nullify the effects of these differences, every meter must be
calibrated. For calibration to be performed accurately, an accurate AC test source and a reference meter
must be available. The source should be able to generate any desired voltage, current, and phase shift
(between V and I). To calculate errors in measurement, the reference meter acts as an interface between
the source and the meter that is being calibrated. This section describes a simple and effective method of
calibration of this three-phase EVM.
The GUI that is used for viewing results can also be used to calibrate the EVM. During calibration,
parameters called calibration factors are modified in software to give least error in measurement. For this
meter, there are six main calibration factors for each phase: voltage scaling factor, voltage AC offset,
current scaling factor, current AC offset, power scaling factor, and the phase compensation factor. The
voltage, current, and power scaling factors translate measured quantities in metrology software to real-
world values represented in volts, amps, and watts, respectively. The voltage AC offset and current AC
offset are used to eliminate the effect of Additive White Gaussian Noise associated with each channel.
This noise is orthogonal to everything except itself. As a result, it is present only when calculating RMS
voltages and currents. The last calibration factor is the phase compensation factor, which is used to
compensate any phase shifts introduced by the current sensors and other passives. Note that the voltage,
current, and power calibration factors are independent of each other. Therefore, calibrating voltage does
not affect the readings for RMS current or power.
When the meter software is flashed with the code (available in the zip file), default calibration factors are
loaded into these calibration factors (see Section 4.4.1 for the macros associated with each calibration
factor). These values will be modified via the GUI during calibration. The calibration factors are stored in
INFO_MEM, and therefore, would remain the same if the meter is restarted. However, if code is re-flashed
during debug, the calibration factors will be replaced and the meter must be recalibrated. One way to save
the calibration values is by clicking on the "Meter calibration factors" button shown in Figure 28. The meter

40 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Results and Calibration

calibration factors window displays the latest values and this could be used to directly replace the macro
definition of these factors in the source code. The "Voltage" , "Voltage AC off" , "Current", "Current AC
offset", and "Active Power" calibration factors shown in the calibration factors window could be copied
directly into the corresponding macros in the source code. However, for phase correction, a conversion
must be made from microseconds to register units since the software's phase correction parameters are in
units of modulation clock cycles instead of microseconds. To convert the value displayed by the GUI into a
value that can be used by the associated macro in emeter-template, multiply the "Phase correction"
variable on the GUI by 8.338608, round the resulting number to the nearest integer, and then right-shift
by 3.

Figure 28. Calibration Factors Window

Calibrating any of the scaling factors is referred to as gain correction. Calibrating any of the phase
compensation factors is referred to as phase correction. Calibrating the offset is referred to as offset
calibration. For the entire calibration process, the AC test source must be on, meter connections must be
made as shown in Section 5.1.1, and the energy pulses must be connected to the reference meter.

6.3.3.1 Gain Calibration


Usually gain correction for voltage and current can be done simultaneously for all phases. However,
energy accuracy (%) from the reference meter for each individual phase is needed for gain correction for
active power. Also, when performing active power calibration for any given phase, the other two phases
must be turned off. Typically, switching off only the currents is good enough to disable a phase.

6.3.3.1.1 Voltage and Current Gain Calibration


To calibrate the voltage and current readings:
1. Connect the GUI to view results for voltage, current, active power, and the other metering parameters.
2. Configure the test source to supply the desired voltage and current for all phases. Make sure that
these are the voltage and current calibration points with a zero-degree phase shift between each
phase's voltage and current. For example: 230V, 10A, 0° (PF = 1). Typically, these values are the
same for every phase.
3. Click the Manual cal. button in the Results window (see Figure 26) to open the window shown in
Figure 29.

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 41
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Results and Calibration www.ti.com

Figure 29. Manual Calibration Window

4. Calculate the correction values for each voltage and current. The correction values that need to be
entered for the voltage and current fields are calculated by:
§ value observed ·
Correction (%) ¨¨  1 ¸¸ u 100
© value desired ¹
where
• valueobserved is the value measured by the TI meter
• valuedesired is the calibration point configured in the AC test source (11)
5. After calculating Correction(%) for all voltages and currents, input these values as is (±) for the fields
"Voltage" and "Current" for the corresponding phases.
6. Click Update meter and the observed values for the voltages and currents on the GUI settle to the
desired voltages and currents.

6.3.3.1.2 Active Power Gain Calibration


Note that this example is for one phase. Repeat these steps for other phases.
After performing gain correction for voltage and current, gain correction for active power must be done.
Gain correction for active power is different from voltage and current correction. Although, conceptually,
calculating Correction(%) using Step 4 with Active power readings (displayed on the AC test source) can
be done, it is not the most accurate method and should be avoided.
The best option to find the Correction(%) is directly from the reference meter's measurement error of the
active power. This error is obtained by feeding energy pulses to the reference meter. This error must be
recorded for each phase individually with the other phases disabled.
To perform active power calibration:
1. Turn off the meter and connect the meter's energy pulse output to the reference meter. Configure the
reference meter to measure the active power error based on these pulse inputs.
2. Turn on the AC test source.
3. Repeat Steps 1 to 3 from Section 6.3.3.1.1 with the identical voltages, currents, and 0° phase shifts
that were used for the voltage and current gain calibration.
4. Disable the other phases that are not currently being calibrated by setting the current of these phases
to 0 A.
5. Obtain the % error in measurement from the reference meter. Note that this value may be negative.
42 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Results and Calibration

6. Enter the error obtained in the above step into the "Active" field under the corresponding phase in the
GUI window. This error is already the Correction(%) value and does not need to be calculated.
7. Click Update meter and the error values on the reference meter settle to a value close to zero.

6.3.3.2 Phase Correction


Note that this example is for a given phase. Repeat these steps for other phases.
After performing power gain correction, phase calibration must be performed. Similar to active power gain
calibration, to perform phase correction on one phase, the other phases must be disabled. To perform
phase correction calibration, perform the following steps:
1. If the AC test source has been turned OFF or reconfigured, perform steps 1-3 from the voltage and
current gain section using the identical voltages and currents used in that section.
2. Disable all other phases that are not currently being calibrated by setting the current of these phases to
0 A.
3. Modify only the phase-shift of the calibrated phase to a non-zero value; typically, +60° is chosen. The
reference meter will now display a different % error for active power measurement. Note that this value
may be negative.
4. Using the % error readings provided by your reference meter (denoted as %error below), the phase shift
supplied by your source meter (denoted as φdesired below), and the line frequency fed into the meter
(denoted as fMains below), calculate the correction factor (in units of microseconds) by using the below
equations. For these equations, note that φdesired and φerror must be in units of degrees while fMains
must be in units of Hertz.
§§ % · ·
Merror arccos¨¨ ¨ error  1¸*cos(M desired ) ¸¸  M desired
© © 100 ¹ ¹

 Merror u106
correction
f Mains u 360 (12)
5. Enter the calculated correction into the "Phase" field for the phase that is being calibrated.
6. Click Update meter.
7. If this error is not close to zero, or is unacceptable, fine-tune the phase correction by following these
steps:
(a) Enter a small value as an update for the "Phase" field for the phase that is being calibrated.
Usually, a small positive or negative integer should be entered to bring the error close to zero.
Additionally, for a phase shift greater than 0 (for example, +60°), a positive (negative) error would
require a positive (negative) number as correction.
(b) Click Update meter and monitor the error values on the reference meter.
(c) If this measurement error (%) is not accurate enough, fine tune by incrementing or decrementing by
a value of 1 based on Step 4a and 4b. Note: When the error is very close to zero, changing the
fine-tuning value by 1 can result in the error oscillating on either side of zero. Select the value that
has the smallest absolute error.
(d) Change the phase to -60° and check if this error is still acceptable. Ideally, errors should be
symmetric for same phase shift on lag and lead conditions.
After performing phase correction, calibration is complete for one phase. Note that the gain calibration
and phase calibration are completed in sequence for each phase before moving on to other
phases. These two procedures must be repeated for each phase, unlike voltage and current
calibration.
This completes calibration of voltage, current, and power for all three phases. View the new calibration
factors by clicking the Meter Calibration factors button of the GUI metering results window (see Figure 30).

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 43
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Results and Calibration www.ti.com

Figure 30. Calibration Factors Window

The configuration of the meter can also be viewed by clicking Meter features to open the screen shown in
Figure 31 (this is only an example).

Figure 31. Meter Features Window

44 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Results and Calibration

6.3.4 Metrology Results


In this section, metrology results are shown for the cumulative three-phase active energy, cumulative
three-phase reactive energy, and individual active energy. Figure 32 shows the cumulative active energy
results over a current dynamic range of 2000:1. Table 3 shows the values for the error. Similarly,
Figure 33 shows the cumulative reactive energy results over a current dynamic range of 2000:1, and
Table 4 shows the values for the error.
1

0.8

0.6

0.4

0.2

0
Error (%)

-0.2

-0.4

-0.6

-0.8

-1
0 10 20 30 40 50 60 70 80 90 100
Current (A)

0 degrees 60 Degrees -60 degrees

Figure 32. Cumulative Phase Active Energy Measurement Error

Table 3. Cumulative Phase Active Energy


Measurement Error (%)
Current
0° 60° -60°
(A)
0.05 -0.04 0.005 -0.08
0.1 -0.004 0.043 -0.06
0.25 -0.003 0.044 -0.055
0.5 -0.008 0.051 -0.05
1 -0.002 0.053 -0.033
2 -0.00533 0.071667 -0.053
5 -0.00533 0.018333 -0.02333
10 0.002 0.008333 0.01
20 -0.00967 -0.048 0.029667
30 -0.00767 -0.08267 0.065
40 -0.004 -0.106 0.107667
50 -0.00733 -0.14667 0.125
60 -0.00367 -0.15967 0.14
70 0.000333 -0.16233 0.155667
80 -0.00133 -0.17033 0.161333
90 0.001333 -0.17367 0.179333
100 -0.00033 -0.17067 0.172

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 45
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Results and Calibration www.ti.com

Figure 33. Cumulative Phase Reactive Energy Measurement Error

Table 4. Cumulative Phase Reactive Energy


Measurement Error (%)
Current
60° -60°
(A)
0.05 -0.114 0.006
0.1 -0.089 -0.004
0.25 -0.0945 0.006
0.5 -0.083 -0.018
1 -0.079 -0.0085
2 -0.0845 -0.016
5 -0.0735 -0.028
10 -0.0545 -0.043
20 -0.0525 -0.04
30 -0.034 -0.019
40 -0.027 -0.06
50 -0.026 -0.069
60 -0.02 -0.0655
70 -0.0147 -0.0707
80 -0.0147 -0.0717
90 -0.0105 -0.0733
100 -0.003 -0.089

46 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Results and Calibration

Figure 34, Figure 35, and Figure 36 show the active error over a current dynamic range of 2000:1 for
phases A, B, and C, respectively. Table 5, Table 6, and Table 7 show the corresponding error for phases
A, B, and C, respectively.
1

0.8

0.6

0.4

0.2

0
Error (%)

-0.2

-0.4

-0.6

-0.8

-1
0 10 20 30 40 50 60 70 80 90 100
Current (A)
0 degrees 60 Degrees -60 degrees

Figure 34. Phase A Active Energy Measurement Error

Table 5. Phase A Active Energy Measurement Error


Current
0° 60° -60°
(A)
0.05 -0.038 -0.153 -0.051
0.1 -0.019 -0.038 -0.019
0.25 0 -0.006 -0.032
0.5 -0.032 -0.025 -0.013
1 -0.019 -0.019 -0.019
2 -0.01467 -0.021 0.015
5 -0.02667 -0.05333 0.021333
10 -0.00567 -0.06533 0.045333
20 -0.00633 -0.083 0.091667
30 0.005333 -0.104 0.109333
40 -0.001 -0.12567 0.132667
50 -0.00767 -0.166 0.153667
60 -0.01133 -0.17367 0.163
70 -0.00767 -0.18533 0.166333
80 0 -0.2 0.183667
90 -0.003 -0.17533 0.183333
100 0.001667 -0.19467 0.186667

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 47
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Results and Calibration www.ti.com

0.8

0.6

0.4

0.2

0
Error (%)

-0.2

-0.4

-0.6

-0.8

-1
0 10 20 30 40 50 60 70 80 90 100
Current (A)
0 degrees 60 Degrees -60 degrees

Figure 35. Phase B Active Energy Measurement Error

Table 6. Phase B Active Energy Measurement Error


Current
0° 60° -60°
(A)
0.05 -0.019 -0.038 -0.141
0.1 0.019 -0.019 -0.051
0.25 0 0.019 -0.006
0.5 0.007 0 -0.025
1 0.013 0.013 0.007
2 -0.021 0.017333 -0.00833
5 0.004333 -0.01267 0.013
10 0.015 -0.02767 0.050333
20 -0.00433 -0.06133 0.066667
30 -0.00067 -0.104 0.104
40 0.004667 -0.12333 0.119333
50 -0.01067 -0.163 0.150333
60 -0.00133 -0.171 0.167667
70 -0.00233 -0.19033 0.173333
80 -0.001 -0.17667 0.179333
90 -0.00333 -0.18533 0.187333
100 0.002667 -0.195 0.191

48 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Results and Calibration

0.8

0.6

0.4

0.2

0
Error (%)

-0.2

-0.4

-0.6

-0.8

-1
0 10 20 30 40 50 60 70 80 90 100
Current (A)
0 degrees 60 Degrees -60 degrees

Figure 36. Phase C Active Energy Measurement Error

Table 7. Phase C Active Energy Measurement Error


Current
0° 60° -60°
(A)
0.05 -0.047 -0.072 -0.205
0.1 -0.032 0.02 -0.069
0.25 -0.015 0.028 -0.103
0.5 -0.008 0.058 -0.085
1 -0.008 0.08 -0.064
2 -0.011 0.059667 -0.075
5 -0.002 0.041 -0.03633
10 0.003 0.009667 -0.01767
20 -0.00633 -0.019 0.007
30 -0.005 -0.05333 0.045333
40 -0.00633 -0.07867 0.066333
50 0.003 -0.09767 0.101
60 0.002 -0.106 0.111667
70 0.005667 -0.11133 0.114
80 0.004667 -0.12233 0.128333
90 0.007333 -0.121 0.127667
100 0.005 -0.129 0.126

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 49
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Results and Calibration www.ti.com

Figure 37 shows the cumulative active energy results when varying the 230-V nominal voltage by ±10% at
different currents and power factors. Table 8 shows the corresponding error.

Figure 37. Cumulative Active Energy Measurement Error, ±10% Nominal Voltage

Table 8. Cumulative Active Energy Measurement Error, ±10% Nominal Voltage


Voltage (V) 0°, 15 A 60°, 15 A 300°, 15 A 0°, 1.5 A 60°, 1.5 A 300°, 1.5 A
207 0.005 0.004 0.0165 -0.0063 0.0205 -0.035
230 0.002 -0.0055 0.0095 -0.018 0.01 -0.0305
253 -0.0123 -0.025 -0.0113 -0.0277 0.009 -0.063

50 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Results and Calibration

Figure 38 shows the active energy results from 100 V to 270 V, and Table 9 shows the corresponding
errors. Note that no changes were made to the EVM to produce these results. Figure 39 shows the active
energy results from 100 V to 320 V, and Table 10 shows its corresponding error.
In comparison to the results in Figure 38 and Table 9, the results for Figure 39 and Table 10 were
generated with one change made to the hardware. Because 275-V varistors are used in the EVM's voltage
front end, these varistors were removed to allow testing beyond 275 V. Other than removing these
varistors, no other changes were made to the EVM for generating the results in Figure 39 and Table 10.

Figure 38. Cumulative Active Energy Measurement Error, 100 V to 270 V, No EVM Modifications

Table 9. Cumulative Active Energy Measurement Error,


100 V to 270 V, No EVM Modifications
Voltage (V) Error (%)
100 -0.032
110 0.0455
120 0.033
150 0.0395
180 0.021
210 -0.0035
220 -0.011
230 0.002
240 -0.0173
250 -0.025
260 -0.0293
265 -0.0257
270 -0.019

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter 51
Submit Documentation Feedback Using the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Results and Calibration www.ti.com

Figure 39. Cumulative Active Energy Measurement Error, 100 V to 320 V, Varistors Removed

Table 10. Cumulative Active Energy Measurement


Error, 100 V to 320 V, Varistors Removed
Voltage (V) Error (%)
100 -0.0315
110 0.0323
120 0.016
150 0.0463
180 0.018
210 0.0035
220 -0.008
230 -0.008
240 -0.0243
260 -0.031
280 -0.0323
300 -0.0287
320 -0.0217

52 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter SLAA621C – March 2014 – Revised August 2015
Using the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Schematics

7 Schematics
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16

A Analog Power Digital Power User Buttons ACT/Phase LEDs A

DVCC DVCC DVCC DVCC DVCC DVCC DVCC

AUXVCC1

AUXVCC2

VDSYS

DVCC
AVCC

VCORE
VASYS

VREF

R58

LED_PHASE_1R22

LED_PHASE_2R57

LED_PHASE_3R21

LED_REACT R20
100

100

100

100

100
100K

100K
R49

R50
B B
R36
DVCC
10R

LED_ACT
C29 C31 C32 C28 C30 C4 C5 C6 C7 C14 C15 C16 C17 C33 BTN1 BTN2
4.7uF 100nF 4.7uF 100nF 100nF 4.7uF 100nF 4.7uF 100nF 4.7uF 100nF 4.7uF 100nF 470nF

BTN1

BTN2
2

LED_PHASE_1

LED_PHASE_2

LED_PHASE_3

REACT
ACT
1

1
C GND C
GND GND
GND GND

AUXVCC Headers DVCC / DGND Headers LCD


0.1uF
C18

D D
GND

3 VDSYS
2 AUXVCC3 DVCC
VDSYS

REACT
1 4 3 AUXVCC2 LCD1
GND

ACT
S19
S20
S21
S22
S23
S24
S25
S26
S27
S28
S29
S30
S31
S32
S33
S34
S35
S36
S37
S38
S39
JP15 2 1 AUXVCC1
D37 1 1 S39 44 1 S0
HD1 JP16 2 2 S38 S1

C63
+
43 2

1F
2 3 3 S37 42 3 S2
DVSS 75
DVSYS 74
P6.0/S19 73
P5.7/S20 72
P5.6/S21 71
P5.5/S22 70
P5.4/S23 69
P5.3/S24 68
P5.2/S25 67
P5.1/S26 66
P5.0/S27 65
P4.7/S28 64
P4.6/S29 63
P4.5/S30 62
P4.4/S31 61
P4.3/S32 60
P4.2/S33 59
P4.1/S34 58
P4.0/S35 57
P3.7/PM_SD2DIO/S3656
P3.6/PM_SD1DIO/S3755
P3.5/PM_SD0DIO/S3854
P3.4/PM_SDCLK/S3953
P3.3/PM_TA0.2 52
P3.2/PM_TACLK/PM_RTCCLK51
1 4 4 S36 41 4 S3
E S35 40 5 S4 E
DVCC DGND S34 39 6 S5
GND GND GND GND S33 38 7 S6
S32 37 8 S7
S31 36 9 S8
S30 35 10 S9
S29 34 11 S10
S28 33 12 S11
S27 32 13 S12
I2C Pullups Watch Crystal S26 31 14 S13
F S25 30 15 S14 F
S24 29 16 S15
76 DVCC
S18 P6.1/S18 P3.1/PM_TA2.1/S30/BSL_RX50 RF_GPIO2 COM0 COM0 17 S16
S17 77 P6.2/S17 P3.0/PM_TA2.0/S31/BSL_TX49 RF_GPIO1 12pF COM1 COM1 18 S17
S16 78 P6.3/S16 P2.7/PM_TA1.1/S32 48 RF_RESETCC XIN COM2 COM2 19 S18
S15 79 P6.4/S15 P2.6/PM_TA1.0/S33 47 IR_SD COM3 COM3 20 S19
S14 80 P2.5/PM_UCA2CLK/S3446 RF_CLK C37 S23 S20

XT1
P6.5/S14 24 21
S13 81 P2.4/PM_UCA1CLK/S3545 RF_CS 12pF S22 S21

R40

R41
10K

10K
P6.6/S13 23 22
S12 82 P6.7/S12 P2.3/PM_UCA2TXD/PM_UCA2SIMO/S36 44 RF_SIMO XOUT
S11 83 P7.0/S11 P2.2/PM_UCA2RXD/PM_UCA2SOMI/S37 43 RF_SOMI
G S10 84 P7.1/S10 P9.0/TACLK/RTCCLK42 RF_SFD SCL 1 JP2 C40 G
S9 85 U4 41 RF_CCA SDA 2 GND DNP
P7.2/S9 P8.7/TA2.1
S8 86 P7.3/S8 P8.6/TA2.0 40 LED_PHASE_1
S7 87 P7.4/S7 P2.1/PM_UCB0SIMO/PM_UCB0SDA/COM7/S38 39 SDA
S6 88 P7.5/S6 P2.0/PM_UCB0SOMI/PM_UCB0SCL/COM6/S39 38 SCL
S5 89 P7.6/S5 P1.7/PM_UCB0CLK/COM537 BTN1/RF_VREG_EN
S4 90 P7.7/S4 P1.6/PM_UCA0CLK/COM436 BTN2
S3 91 P8.0/S3 COM3 35 COM3
S2
S1
92
93
P8.1/S2
P8.2/S1
MSP430F67641_PZ_100 COM2 34
COM1 33
COM2
COM1 Voltage Monitor Temp Monitor JTAG H
H S0 94 P8.3/S0 COM0 32 COM0
TEST/SBWTCK 95 P8.5/TA1.1 31 LED_PHASE_3
P1.3/PM_UCA0TXD/PM_UCA0SIMO/R03

1 JP10
TEST/SBWTCK
P1.2/PM_UCA0RXD/PM_UCA0SOMI/A0

DTDO 96 DVCC DVCC


PJ.0/SMCLK/TDO P8.4/TA1.0 30 LED_PHASE_2
DTDI 97 PJ.1/MCLK/TDI/TCLK LCDCAP/R33 29

2
3
DTMS 98 PJ.2/ADC10CLK/TMS P1.5/PM_UCA1TXD/PM_UCA1SIMO/R23 28 IR_TXD
DTCK 99 27 IR_RXD C49 Vsupply DVCC
PJ.3/ACLK/TCK P1.4/PM_UCA1RXD/PM_UCA1SOMI/LCDREF/R13
DRESET 100 *RST/NMI/SBWTDIO AUXVCC3 26 AUXVCC3 TDO 1 2 INT
4.7uF
P1.1/PM_TA0.1/VEREF+/A1

TDI 3 4 EXT

R51
47K
P1.0/PM_TA0.0/VEREF-/A2

TMS 5 6
TCK 7 8 TEST/SBWTCK
9 10
DNP

I GND I
R45

R19
10K
11 12
RESET 13 14
VSENSE VTEMP

1
10K Thermistor

RESET
0.1uF JTAG
AUXVCC2
AUXVCC1

DVSS_2
P9.1/A5
P9.2/A4
P9.3/A3

VCORE
VDSYS
VASYS
SD0N0

SD1N0

SD2N0

C53
SD0P0

SD1P0

SD2P0

2
DNP

RTH
DVCC

XOUT

R44
AVCC
VREF

R48
AVSS

TCK
XIN

Jumper Config 330 1 JP4


12 - SBW GND GND 2
K
10

12
13
14
15
16
17
18
19
20
21
22
23
24
25
11
1
2
3
4
5
6
7
8
9

23 - JTAG TEST/SBWTCK 3 K
GND GND
RS232_RXD
RS232_TXD
AUXVCC2
AUXVCC1
VSENSE
VTEMP

VCORE
VDSYS
VASYS

DVCC
I1+_IN
I2+_IN
I3+_IN

V1_IN
V2_IN
VREF
AVCC

V3_IN

XOUT

TDO 1 JP5 1 JP6 1 JP7 1 JP8 1 JP9


I1-_IN
I2-_IN
I3-_IN
GND

GND
XIN

DRESET 2 DTCK 2 DTMS 2 DTDI 2 DTDO 2


RESET 3 TCK 3 TMS 3 TDI 3 TDO 3

TIDM-THREEPHASEMETER-F67641
L

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16

Figure 40. Schematics (1 of 4)


SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter Using 53
Submit Documentation Feedback the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Schematics www.ti.com

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16

A A

Analog Front-End (Current) Analog Front-End (Voltage)


AVCC
L1 R4 R14 R15 R32 R99 R100 R101 LINE_V1
B LINE_1 EXCML20A B
1M 1M 1M 1M 1M 1M 1M
D28 R102 R103 R104 R105 R106 R107 R108
PMLL4148 L3 LINE_V2
LINE_2 EXCML20A 1M 1M 1M 1M 1M 1M 1M
D3
PMLL4148 0 R26 R109 R110 R111 R112 R113 R114 R115
I1+_IN L5 LINE_V3
I1+ LINE_3 EXCML20A
AVCC R/L9 1K 1M 1M 1M 1M 1M 1M 1M
D11 C19

SMAJ5.0CA
C C
PMLL4148

S20K275

S20K275

S20K275
47p

TVS2
D29 C23

12.4
R24
D30 PMLL4148

R1

R2

R3
PMLL4148 GND 15n
D4 GND L6 EXCML20A
PMLL4148 NEUTRAL
0 R27
I1- I1-_IN
R/L10 1K GND D
D D12 C20 AVCC
PMLL4148
47p
D31
PMLL4148 D44
GND GND 1N4148DO35-7
AVCC AVCC
GND LINE_V1 R116 V1_IN
R117 R118 1K
E D6 10 20K D45 E
PMLL4148 C8 C1 1N4148DO35-7
R119
D1 10uF 100nF 10K
PMLL4148 0 R6
I2+ I2+_IN
AVCC R/L1 1K C2
D2 GND GND GND GND
SMAJ5.0CA

PMLL4148
47p
TVS1

F D7 C10 F
12.4
R5

D8 PMLL4148
PMLL4148 GND 15n AVCC

D5 GND
PMLL4148 0 R7 I2-_IN D46
I2- 1N4148DO35-7
R/L2 1K
D10 C3 AVCC
PMLL4148 LINE_V2 R120 V2_IN
G 47p G
R123 R121 1K
D9
PMLL4148 10 20K D47
GND GND C36 C9 1N4148DO35-7
AVCC R122
GND 10uF 100nF 10K

D16
PMLL4148 GND GND GND GND H
H
D13
PMLL4148 0 R9
I3+ I3+_IN
AVCC
AVCC R/L3 1K C11
D14
SMAJ5.0CA

PMLL4148
47p
D48
TVS3

D32 C13
12.4

1N4148DO35-7
R8

D33 PMLL4148
I PMLL4148 GND 15n AVCC I
LINE_V3 R124 V3_IN
D15 GND R127 R125 1K
PMLL4148 0 R10 I3-_IN 10 20K D49
I3- C43 C38 1N4148DO35-7
R/L4 1K
D35 C12 R126
PMLL4148 10uF 100nF 10K
47p
K
D34
PMLL4148 K
GND GND GND GND GND GND
GND

TIDM-THREEPHASEMETER-F67641
L

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16

Figure 41. Schematics (2 of 4)

54 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter Using SLAA621C – March 2014 – Revised August 2015
the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Schematics

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16

A A

Resistor Capacitor (RC) Power Supply

B B

0.1uF
C47
1mH
C39 R92 VCC_PL
LINE_1 0.22uF/305VAC D18
Vsupply L7
100 1N4007 U3 C62

B160
0.22uF/305VAC C46 R93 TPS54060_DGQ_10

D23
C LINE_2 D20 C

100 1N4007 47uF


C50 1 10

51.1
R96
LINE_3 0.22uF/305VAC R94 BOOT PH
D22 2 9

100uF/100V
VIN GND
100 D21 1N4007 3 EN COMP 8
4 7
1N4757A SS/TR VSENSE

C102
C48 5 6 GND

R35
RT/CLK PWRGD

22.1K
1M
D19

R95
1N4757A
2.2uF
1N4757A D17
R39 D
D NEUTRAL
0 C60 C61

33.2K

31.6K
GND C45

R37

R38

R97
1M
.056uF 100pF
0.01uF

GND GND GND GND

E E

R98
10K
GND

F F

Switching Power Supply DVCC Select


DVCC

JP3
LINE_3 L L 26 26

3
2
1
NEUTRAL N N VCC_PL G
G C100 4.7u/400V
22 22 VCC_ISO

VO+ VO+ VCC_ISO


0.1uF
150uF
C101
+

C42

ZD3

SMAJ5.0ABCT
NC VO- H
H NC VO-

GND

I I

K
K

TIDM-THREEPHASEMETER-F67641
L

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16

Figure 42. Schematics (3 of 4)

SLAA621C – March 2014 – Revised August 2015 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter Using 55
Submit Documentation Feedback the MSP430F67641
Copyright © 2014–2015, Texas Instruments Incorporated
Schematics www.ti.com

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16

A A

B B

Isolated RS232 Communication IRDA Act / React


DVCC VCC
OPTO2
VCC2 DVCC 1 4 2
C 1 C
IR_TXD

R47
47
TXD R72
IR_RXD RXD ACT 2 3 ACT
LL103A IR_SD SD JP121 1K
C51 VCC1 TIL191
2

R78
D26 4.7uF C52
GND VCC

1K
DVCC LL103A IRDA
DB9_+12V 0.1uF GND OPTO1
U2 1 4 2
8 2 D25 1
R68 DVCC 2

LL103A
7 C55 3 D
D
R71 GND GND GND REACT REACT

D27
C57 6 1K
10uF G2 JP111 TIL191
2.2K
0.1uF 5 3 DB9_GND 5 9 2
4 8
DNP
RX_EN

R70

PS8802 C56 3 7
DGND GND 2 6 EEPROM GND

0.1uF
10uF 1

C54
2
1

RS232_RXD D24 G1
UART_RX DB9_-12V RS1 DVCC
E E

0.1uF
LL103A

C41
DVCC
U1

R63
10K
R65 2 8
7 R66 IC1 GND

8
68 R62
6 DNP Q1 SCL 6 SCL VCC

EEPROM
BC857BSMD 7
TX_EN

1K WP
3 5
F 3 SDA 5 SDA F

Array
A2
PS8802 2 A1
R69
2
1

RS232_TXD UART_TX Q2 1

R64
A0

220
BC857BSMD GND
2.2K

4
R67 24C02CSN

1.5K
GND GND GND

G G

RF Daughter Card
JP13

JP14

DVCC
2
1

2
1

10uF
C58

H
H RF_FIFO RF_SIMO
RF_FIFOP RF_SOMI
DVCC
0.1uF
C59

6 5 RF_VREG_EN
1 2 1 2 4 3
RF_VREG_EN R74 0 3 4 3 4 0 R73 2 1
RF_RESETCC R76 0 5 6 0 R75 RF_FIFO 5 6 0 R77
I RF_FIFO R80 0 7 8 0 R81 RF_FIFOP R79 0 7 8 GND JP17 I
RF_FIFOP R82 0 9 10 0 R83 RF_CCA 9 10
11 12 0 R84 RF_SFD 11 12 GND 3
13 14 0 R85 RF_CS 13 14 2 BTN1/RF_VREG_EN
15 16 0 R86 RF_CLK RF_RESETCC R87 0 15 16 1 BTN1
17 18 0 R88 RF_SIMO 17 18 0 R89 RF_GPIO2 JP1
19 20 0 R91 RF_SOMI RF_GPIO1 R90 0 19 20

RF2 RF1
K
GND
K

TIDM-THREEPHASEMETER-F67641
L

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16

Figure 43. Schematics (4 of 4)

56 Implementation of a Low-Cost Three-Phase Electronic Watt-Hour Meter Using SLAA621C – March 2014 – Revised August 2015
the MSP430F67641 Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
www.ti.com Revision History

Revision History

Changes from B Revision (September 2014) to C Revision .......................................................................................... Page

• Updated links and descriptions for associated source code ......................................................................... 1


• Updated links to source code ............................................................................................................ 3

NOTE: Page numbers for previous revisions may differ from page numbers in the current version.

SLAA621C – March 2014 – Revised August 2015 Revision History 57


Submit Documentation Feedback
Copyright © 2014–2015, Texas Instruments Incorporated
General Texas Instruments High Voltage Evaluation (TI HV EVM) User Safety Guidelines

WARNING

Always follow TI's setup and application instructions, including use of all interface components within their
recommended electrical rated voltage and power limits. Always use electrical safety precautions to help
ensure your personal safety and those working around you. Contact TI's Product Information Center
http://support/ti./com for further information.
Save all warnings and instructions for future reference.
Failure to follow warnings and instructions may result in personal injury, property damage, or
death due to electrical shock and burn hazards.
The term TI HV EVM refers to an electronic device typically provided as an open-framed unenclosed
printed circuit board assembly. It is intended strictly for use in development laboratory environments,
solely for qualified professional users having training, expertise, and knowledge of electrical
safety risks in development and application of high voltage electrical circuits. Any other use
and/or application are strictly prohibited by Texas Instruments. If you are not suitably qualified, you
should immediately stop from further use of the HV EVM.
1. Work Area Safety
(a) Keep work area clean and orderly.
(b) Qualified observer(s) must be present anytime circuits are energized.
(c) Effective barriers and signage must be present in the area where the TI HV EVM and its interface
electronics are energized, indicating operation of accessible high voltages may be present, for the
purpose of protecting inadvertent access.
(d) All interface circuits, power supplies, evaluation modules, instruments, meters, scopes and other
related apparatus used in a development environment exceeding 50Vrms/75VDC must be
electrically located within a protected Emergency Power Off EPO protected power strip.
(e) Use stable and nonconductive work surface.
(f) Use adequately insulated clamps and wires to attach measurement probes and instruments. No
freehand testing whenever possible.
2. Electrical Safety
As a precautionary measure, it is always a good engineering practice to assume that the entire EVM
may have fully accessible and active high voltages.
(a) De-energize the TI HV EVM and all its inputs, outputs and electrical loads before performing any
electrical or other diagnostic measurements. Revalidate that TI HV EVM power has been safely de-
energized.
(b) With the EVM confirmed de-energized, proceed with required electrical circuit configurations,
wiring, measurement equipment connection, and other application needs, while still assuming the
EVM circuit and measuring instruments are electrically live.
(c) After EVM readiness is complete, energize the EVM as intended.
WARNING: WHILE THE EVM IS ENERGIZED, NEVER TOUCH THE EVM OR ITS ELECTRICAL
CIRCUITS AS THEY COULD BE AT HIGH VOLTAGES CAPABLE OF CAUSING ELECTRICAL
SHOCK HAZARD.
3. Personal Safety
(a) Wear personal protective equipment (for example, latex gloves or safety glasses with side shields)
or protect the EVM in an adequate lucent plastic box with interlocks to protect from accidental
touch.
Limitation for safe use:
EVMs are not to be used as all or part of a production unit.
IMPORTANT NOTICE

Texas Instruments Incorporated and its subsidiaries (TI) reserve the right to make corrections, enhancements, improvements and other
changes to its semiconductor products and services per JESD46, latest issue, and to discontinue any product or service per JESD48, latest
issue. Buyers should obtain the latest relevant information before placing orders and should verify that such information is current and
complete. All semiconductor products (also referred to herein as “components”) are sold subject to TI’s terms and conditions of sale
supplied at the time of order acknowledgment.
TI warrants performance of its components to the specifications applicable at the time of sale, in accordance with the warranty in TI’s terms
and conditions of sale of semiconductor products. Testing and other quality control techniques are used to the extent TI deems necessary
to support this warranty. Except where mandated by applicable law, testing of all parameters of each component is not necessarily
performed.
TI assumes no liability for applications assistance or the design of Buyers’ products. Buyers are responsible for their products and
applications using TI components. To minimize the risks associated with Buyers’ products and applications, Buyers should provide
adequate design and operating safeguards.
TI does not warrant or represent that any license, either express or implied, is granted under any patent right, copyright, mask work right, or
other intellectual property right relating to any combination, machine, or process in which TI components or services are used. Information
published by TI regarding third-party products or services does not constitute a license to use such products or services or a warranty or
endorsement thereof. Use of such information may require a license from a third party under the patents or other intellectual property of the
third party, or a license from TI under the patents or other intellectual property of TI.
Reproduction of significant portions of TI information in TI data books or data sheets is permissible only if reproduction is without alteration
and is accompanied by all associated warranties, conditions, limitations, and notices. TI is not responsible or liable for such altered
documentation. Information of third parties may be subject to additional restrictions.
Resale of TI components or services with statements different from or beyond the parameters stated by TI for that component or service
voids all express and any implied warranties for the associated TI component or service and is an unfair and deceptive business practice.
TI is not responsible or liable for any such statements.
Buyer acknowledges and agrees that it is solely responsible for compliance with all legal, regulatory and safety-related requirements
concerning its products, and any use of TI components in its applications, notwithstanding any applications-related information or support
that may be provided by TI. Buyer represents and agrees that it has all the necessary expertise to create and implement safeguards which
anticipate dangerous consequences of failures, monitor failures and their consequences, lessen the likelihood of failures that might cause
harm and take appropriate remedial actions. Buyer will fully indemnify TI and its representatives against any damages arising out of the use
of any TI components in safety-critical applications.
In some cases, TI components may be promoted specifically to facilitate safety-related applications. With such components, TI’s goal is to
help enable customers to design and create their own end-product solutions that meet applicable functional safety standards and
requirements. Nonetheless, such components are subject to these terms.
No TI components are authorized for use in FDA Class III (or similar life-critical medical equipment) unless authorized officers of the parties
have executed a special agreement specifically governing such use.
Only those TI components which TI has specifically designated as military grade or “enhanced plastic” are designed and intended for use in
military/aerospace applications or environments. Buyer acknowledges and agrees that any military or aerospace use of TI components
which have not been so designated is solely at the Buyer's risk, and that Buyer is solely responsible for compliance with all legal and
regulatory requirements in connection with such use.
TI has specifically designated certain components as meeting ISO/TS16949 requirements, mainly for automotive use. In any case of use of
non-designated products, TI will not be responsible for any failure to meet ISO/TS16949.

Products Applications
Audio www.ti.com/audio Automotive and Transportation www.ti.com/automotive
Amplifiers amplifier.ti.com Communications and Telecom www.ti.com/communications
Data Converters dataconverter.ti.com Computers and Peripherals www.ti.com/computers
DLP® Products www.dlp.com Consumer Electronics www.ti.com/consumer-apps
DSP dsp.ti.com Energy and Lighting www.ti.com/energy
Clocks and Timers www.ti.com/clocks Industrial www.ti.com/industrial
Interface interface.ti.com Medical www.ti.com/medical
Logic logic.ti.com Security www.ti.com/security
Power Mgmt power.ti.com Space, Avionics and Defense www.ti.com/space-avionics-defense
Microcontrollers microcontroller.ti.com Video and Imaging www.ti.com/video
RFID www.ti-rfid.com
OMAP Applications Processors www.ti.com/omap TI E2E Community e2e.ti.com
Wireless Connectivity www.ti.com/wirelessconnectivity

Mailing Address: Texas Instruments, Post Office Box 655303, Dallas, Texas 75265
Copyright © 2015, Texas Instruments Incorporated

You might also like