STEVAL-IPE012V1 STMicroelectronics, STEVAL-IPE012V1 Datasheet - Page 36

no-image

STEVAL-IPE012V1

Manufacturer Part Number
STEVAL-IPE012V1
Description
EVAL BOARD ENERGY METER
Manufacturer
STMicroelectronics
Series
-r

Specifications of STEVAL-IPE012V1

Design Resources
STEVAL-IPE012V1 Schematic STEVAL-IPE012V1 BOM
Main Purpose
Power Management, Energy/Power Meter
Embedded
Yes, MCU, 8-Bit
Utilized Ic / Part
STPM10BTR, STM8L152
Primary Attributes
Single Phase with 1 Current Transformer & Shunt
Secondary Attributes
Tamper Detection
Lead Free Status / Rohs Status
Lead free / RoHS Compliant
Other names
497-11462
Theory of operation
7.22.1
7.23
36/51
Interfacing the standard 3-wire SPI with the STPM10 SPI
Due to the fact that a 2-wire SPI is implemented in the STPM10, it is clear that sending any
command from a standard 3-wire SPI would require a 3-wire to 2-wire interface, which
should produce a proper signal on SDA from host signals SDI, SDO and SYN. The need for
a single-gate 3-state buffer could be avoided through an emulation of SPI just to send some
commands. On a microcontroller this would be done by performing the following steps:
1. Disable the SPI module
2. Set the SDI pin, which is connected to SDA as an output
3. Activate SYN first, and then SCS
4. Apply a new bit value to SDI, and activate SCL
5. Deactivate SCL
6. Repeat the previous two steps seven times to complete a one byte transfer
7. Repeat the previous three steps for any remaining byte transfers
8. Set the SDI pin as an input
9. Deactivate SCS and SYN
10. Enable the SPI module
In case of a precharge command (0xFF), the emulation above is not necessary. Due to the
pull-up device on the SDA pin of the STPM10, the processor needs to perform the following
steps:
1. Activate SYN first in order to latch the results
2. After at least 1 µs, activate SCS
3. Write one byte to the transmitter of SPI (this produces 8 pulses on SCL with SDI=1)
4. Deactivate SYN
5. Optionally read the data records (the sequence of reading is altered)
6. Deactivate SCS
Energy calculation algorithm
Within the STPM10, the computing section of the measured active power uses a completely
new patented signal processing approach. This approach allows the device to reach high a
level of performance in terms of accuracy.
The signals, coming from the sensors, for the instantaneous voltage are calculated as
follows:
Equation 5
v(t) = V•sin
where V is the peak voltage and
The instantaneous current is calculated using:
Equation 6
i(t) = I • sin (
ω
ω
t
t +
ϕ
)
Doc ID 17728 Rev 3
ω
is related to the line frequency.
STPM10

Related parts for STEVAL-IPE012V1