ONE PHASE POWER METER (CS5464) SOLUTION

Similar documents
IC CARD AND ESAM OPERATION

ONE PHASE POWER METER (RN8209) SOLUTION

F²MC-8FX FAMILY MB95F370 SERIES ZIGBEE SOLUTION DEVELOPMENT GUI 8-BIT MICROCONTROLLER USER MANUAL

UnRegistered MB39C602 LED LIGHTING SYSTEM BULB 9W ZIGBEE CONTROL USER MANUAL. Fujitsu Semiconductor Design (Chengdu) Co. Ltd.

MB9AA30N SERIES BLUEMOON-EVB_LCD 32-BIT MICROCONTROLLER APPLICATION NOTE. Fujitsu Semiconductor Design (Chengdu) Co., Ltd.

STAND-ALONE PROGRAMMER

MB86R12 Emerald-P. Delta Sheet Differences between ES2 and ES3. Fujitsu Semiconductor Europe GmbH

ETHERNET_FLASH_LOADER

MB39C602 LED LIGHTING SYSTEM BULB 9W ZIGBEE CONTROL

DSU-FR EMULATOR LQFP-144P HEADER TYPE 9 MB E OPERATION MANUAL

The following document contains information on Cypress products.

FUJITSU SEMICONDUCTOR SUPPORT SYSTEM SS E DSU-FR EMULATOR LQFP-144P HEADER TYPE 4 MB OPERATION MANUAL

F²MC-16 FAMILY 16-BIT MICROCONTROLLER An Additional Manual for the Softune Linkage Kit

Evaluation board Manual

MB85R K (32 K 8) Bit. Memory FRAM DS E CMOS DESCRIPTIONS FEATURES PACKAGES FUJITSU SEMICONDUCTOR DATA SHEET

MB85R M Bit (128 K 8) Memory FRAM CMOS DS E DESCRIPTIONS FEATURES FUJITSU SEMICONDUCTOR DATA SHEET

MB9B610T SERIES 618S_NONOS_LWIP ETHERNET SOFTWARE 32-BIT MICROCONTROLLER USER MANUAL MCU-AN E-10

QUAD OPERATIONAL AMPLIFIER

FUJITSU SEMICONDUCTOR SUPPORT SYSTEM SS E DSU-FR EMULATOR F 2 MC-16FX EXPANSION TRACE BOARD MB E OPERATION MANUAL

New 8FX Family 8-bit MICROCONTROLLER BGM ADAPTOR MB E OPERATION MANUAL

DUAL REVERSIBLE MOTOR DRIVER MB3863

What Types of ECC Should Be Used on Flash Memory?

FM3 32-BIT MICROCONTROLLER MB9A310/110 Series FLASH PROGRAMMING MANUAL

Connecting Spansion SPI Serial Flash to Configure Altera FPGAs

Corporate names revised in the documents

The following document contains information on Cypress products.

32-BIT MICROCONTROLLER MB9A310K/110K Series FLASH PROGRAMMING MANUAL

CM E FUJITSU SEMICONDUCTOR CONTROLLER MANUAL F 2 MC-16L/16LX EMULATION POD MB HARDWARE MANUAL

Quick Guide to Common Flash Interface

FM3. MB9B500 Series 32-BIT MICROCONTROLLER FSS MB9BF506R EV-BOARD USER MANUAL APPLICATION NOTE FUJITSU SEMICONDUCTOR (SHANGHAI) LIMITED

FR-V/FR FAMILY SOFTUNE C/C++ CHECKER MANUAL for V5

F 2 MC-8FX Family LQFP-48P (0.5 mm pitch) HEADER BOARD MB OPERATION MANUAL

Wireless LAN Module MBH7WLZ16 Brief Datasheet. Rev. 1.38e. Dec 8, 2009 FUJITSU COMPONENT LIMITED

F²MC-8FX FAMILY MB95200H/210H SERIES FLASH MEMORY WITH SECRUITY 8-BIT MICROCONTROLLER APPLICATION NOTE

Printer Driver. Installation Guide. November 2014 Version Copyright FUJITSU LIMITED

DF10G7M1N DF10G7M1N. 1. Applications. 2. Packaging and Internal Circuit Rev.5.0. Start of commercial production

Old Company Name in Catalogs and Other Documents

3. Absolute Maximum Ratings (Note) (Unless otherwise specified, T a = 25 ) Symbol V ESD. P PK I PP T j T stg

FUJITSU Software PRIMECLUSTER GLS for Windows. GLS Setup Guide for Cluster Systems 4.4

MB9BF500 Series FLASH PROGRAMMING MANUAL

Setup Guide. FUJITSU Software. Serverview Infrastructure Manager Plug-in for. Microsoft System Center. Virtual Machine Manager 1.2

STARTER KIT MB E

Old Company Name in Catalogs and Other Documents

F 2 MC-8FX Family QFP-100P (0.65 mm pitch) HEADER BOARD MB OPERATION MANUAL

DF2S6.8FS DF2S6.8FS. 1. Applications. 2. Packaging and Internal Circuit Rev.5.0. Start of commercial production.

DF2B6M4SL DF2B6M4SL. 1. General. 2. Applications. 3. Features. 4. Packaging Rev.4.0. Start of commercial production

MF1 MOA4 S50. Contactless Chip Card Module Specification. This document gives specifications for the product MF1 MOA4 S50.

CDB5461AU Evaluation Board & Software

RN1601, RN1602, RN1603 RN1604, RN1605, RN1606

Old Company Name in Catalogs and Other Documents

TA75W393FU TA75W393FU. Dual Voltage Comparator. Features. Marking (Top View) Pin Connection (Top View)

Old Company Name in Catalogs and Other Documents

The following document contains information on Cypress products.

Evaluation Board for CS4398

BIPOLAR ANALOG INTEGRATED CIRCUIT

DF2S16FS DF2S16FS. 1. Applications. 2. Packaging and Internal Circuit Rev Toshiba Corporation

FUJITSU Software. Serverview Infrastructure Manager Plug-in for. Microsoft System Center. Operations Manager 1.2. Setup Guide. For Windows Server 2016

F²MC-8FX FAMILY MB95200 SERIES EASY KIT FMCDC-MB95260H-EK-01 8-BIT MICROCONTROLLER SETUP GUIDE FUJITSU MICROELECTRONICS SUPPORT SYSTEM

C120-E275-01ENZ2. Tape driver configuration tool 1.0. User s Guide

TOSHIBA CMOS Digital Integrated Circuit Silicon Monolithic TC7SGU04FU IN A GND

Evaluation Board for CS3308. Description CS Channel. Digitally Controlled Analog Volume Control. PC or External Serial Control Input

FUJITSU Software. Infrastructure Manager Plug-in for Microsoft. System Center. Operations Manager 1.2. Setup Guide. For Windows Server 2016 / 2019

DATA SHEET ZENER DIODES 1.0 W PLANAR TYPE 2-PIN SMALL POWER MINI MOLD. Parameter Symbol Ratings Unit Remarks

Dual PLL frequency synthesizer

GSM FUNCTION APPLIED IN WIRELESS SOLUTION

Old Company Name in Catalogs and Other Documents

CDB5532U Evaluation Board and Software

Copyright PFU LIMITED

MB85R1001A. 1 M Bit (128 K 8) Memory FRAM CMOS. DS v01-E DESCRIPTIONS FEATURES FUJITSU SEMICONDUCTOR DATA SHEET

UM1488 User manual. STPMC1 evaluation software. Introduction

Broadband system applications i.e. WCDMA, CATV, etc. General purpose Voltage Controlled Attenuators for high linearity applications

Ethernet1 Xplained Pro

PESD18VF1BL. 1. General description. 2. Features and benefits. 3. Applications. 4. Quick reference data. 5. Pinning information

PESD5V0C1USF. in portable electronics, communication, consumer and computing devices.

MMBZ16VAL. 1. General description. 2. Features and benefits. 3. Applications. 4. Quick reference data

High Resolution Digital Weigh-Scale Design Using Z8 Encore! Microcontrollers

74ABT General description. 2. Features and benefits. 3. Ordering information. Quad 2-input AND gate

Evaluation board Manual

UM1572 User manual. STEVAL-IPE020V1: ST energy meter application based on the Android platform. Introduction

TOSHIBA Schottky Barrier Rectifier Schottky Barrier Type CMS05

NCR402T. 1. General description. 2. Features and benefits. 3. Applications. 4. Quick reference data

OPERATIONAL AMPLIFIER

EVALUATION BOARD DATA SHEET EV142

MB85R1002A. 1 M Bit (64 K 16) Memory FRAM CMOS. DS v01-E DESCRIPTIONS FEATURES FUJITSU SEMICONDUCTOR DATA SHEET

S71GL-N Based MCPs. Data Sheet (Advance Information)

Old Company Name in Catalogs and Other Documents

Evaluation Board for CS5351

OPERATIONAL AMPLIFIER

RN1101MFV,RN1102MFV,RN1103MFV RN1104MFV,RN1105MFV,RN1106MFV

M32C/84, 85, 86, 87, 88 Group

Stepping motor driver

Fujitsu ScandAll PRO V2.1.5 README

MSM GENERAL DESCRIPTION FEATURES. Single Rail CODEC

PESD5V0X2UM. 1. General description. 2. Features and benefits. 3. Applications. 4. Quick reference data

PESD24VF1BSF. Table 1. Quick reference data Symbol Parameter Conditions Min Typ Max Unit C d diode capacitance f = 1 MHz; V R = 0 V

UM PCAL6524 demonstration board OM Document information

ESD NOISE CLIPPING DIODE NNCD2.0DA to NNCD39DA

Bidirectional ESD protection diode

Copyright PFU LIMITED

F²MC-8FX FAMILY 8-BIT MICROCONTROLLER MB95200H SERIES SPI SW REALIZATION USING GPIO APPLICATION NOTE

Transcription:

Fujitsu Semiconductor Design (Chengdu) Co., Ltd. Application Note MCU-AN-5000-E-0 F²MC-8FX FAMILY 8-BIT MICROCONTROLLER MB9540H/470H SERIES ONE PHASE POWER METER (CS5464) SOLUTION CS5464 OPERATION APPLICATION NOTE

Revision History Revision History Version Date Updated by Modifications.0.0 6//0 Funny Chen First Draft : Write the user manual of CS5464, and describe the energy measure function on Power Meter solution. This manual contains 4 pages. Specifications are subject to change without notice. For further information please contact each office. All Rights Reserved. The contents of this document are subject to change without notice. Customers are advised to consult with sales representatives before ordering. The information, such as descriptions of function and application circuit examples, in this document are presented solely for the purpose of reference to show examples of operations and uses of FUJITSU SEMICONDUCTOR device; FUJITSU SEMICONDUCTOR does not warrant proper operation of the device with respect to use based on such information. When you develop equipment incorporating the device based on such information, you must assume any responsibility arising out of such use of the information. FUJITSU SEMICONDUCTOR assumes no liability for any damages whatsoever arising out of the use of the information. Any information in this document, including descriptions of function and schematic diagrams, shall not be construed as license of the use or exercise of any intellectual property right, such as patent right or copyright, or any other right of FUJITSU SEMICONDUCTOR or any third party or does FUJITSU SEMICONDUCTOR warrant non-infringement of any third-party's intellectual property right or other right by using such information. FUJITSU SEMICONDUCTOR assumes no liability for any infringement of the intellectual property rights or other rights of third parties which would result from the use of information contained herein. The products described in this document are designed, developed and manufactured as contemplated for general use, including without limitation, ordinary industrial use, general office use, personal use, and household use, but are not designed, developed and manufactured as contemplated () for use accompanying fatal risks or dangers that, unless extremely high safety is secured, could have a serious effect to the public, and could lead directly to death, personal injury, severe physical damage or other loss (i.e., nuclear reaction control in nuclear facility, aircraft flight control, air traffic control, mass transport control, medical life support system, missile launch control in weapon system), or () for use requiring extremely high reliability (i.e., submersible repeater and artificial satellite). Please note that FUJITSU SEMICONDUCTOR will not be liable against you and/or any third party for any claims or damages arising in connection with above-mentioned uses of the products. Any semiconductor devices have an inherent chance of failure. You must protect against injury, damage or loss from such failures by incorporating safety design measures into your facility and equipment such as redundancy, fire protection, and prevention of over-current levels and other abnormal operating conditions. Exportation/release of any products described in this document may require necessary procedures in accordance with the regulations of the Foreign Exchange and Foreign Trade Control Law of Japan and/or US export control laws. The company names and brand names herein are the trademarks or registered trademarks of their respective owners. 0 Fujitsu Semiconductor Design (Chengdu) Co., Ltd. MCU-AN-5000-E-0 Page

Contents Contents REVISION HISTORY... CONTENTS... 3 INTRODUCTION... 4 BACKGROUND... 5. Overview... 5. Features of CS5464... 5.3 Function diagram... 6 3 HW DIAGRAM... 7 3. The HW diagram of energy measure... 7 4 HW REFERENCE SCH... 8 5 FW DIAGRAM... 9 5. SPI Communication Process... 9 5. Firmware System Diagram... 0 6 FW FUNCTION LIST... 6. API... 6. HAL... 7 ADDITIONAL INFORMATION... 3 8 APPENDIX... 4 8. List of Figures and Tables... 4 MCU-AN-5000-E-0 Page 3

Chapter Introduction Introduction This application note describes how to use One Phase Power Meter (CS5464) solution s energy measure chip-cs5464. Chapter explains the background of CS5464. Chapter 3 explains the HW diagram of energy measure function. Chapter 4 explains the HW reference SCH. Chapter 5 explains the FW diagram. Chapter 6 explains the FW function list. MCU-AN-5000-E-0 Page 4

Chapter Background Background Background of CS5464. Overview The CS5464 is an integrated power measurement device which combines three analog-to-digital converters, power calculation engine, energy-to-frequency converter, and a serial interface on a single chip. It is designed to accurately measure instantaneous current and voltage and calculate VRMS, IRMS, instantaneous power, active power, apparent power, and reactive power for high-performance power measurement applications. The CS5464 is optimized to interface to shunt resistors or current transformers for current measurement, and to resistive dividers or potential transformers for voltage measurement. The CS5464 features a tamper detection scheme that uses the larger of the active power measurements to register energy. Additional features include system-level calibration, temperature sensor, voltage sag & current fault detection, and phase compensation.. Features of CS5464 Energy Data Linearity: ±0.% of Reading over 000: Dynamic Range On-chip Functions: - Instantaneous Voltage, Current, and Power - IRMS and VRMS, Active, Reactive, and Apparent Power - Current Fault and Voltage Sag Detect - System Calibrations / Phase Compensation - Temperature Sensor - Energy-to-pulse Conversion - Positive-only Accumulation Mode Meets Accuracy Spec for IEC, ANSI, & JIS Low Power Consumption Tamper Detection in -Wire Distribution Systems GND-referenced Signals with Single Supply On-chip.5 V Reference (5 ppm/ C typ) Power Supply Monitor Simple Three-wire Digital Serial Interface Auto-boot Mode from Serial EPROM Power Supply Configurations: VA+ = +5 V; AGND = 0 V; VD+ = +3.3 V to +5 V MCU-AN-5000-E-0 Page 5

Chapter Background.3 Function diagram Figure -: The Function Diagram of CS5464 MCU-AN-5000-E-0 Page 6

Chapter 3 HW Diagram 3 HW Diagram Hardware diagram of energy measure system 3. The HW diagram of energy measure Voltage sample Load Current sample CS5464 MB95F48 Neutral Current sample Figure 3-: Hardware diagram MCU-AN-5000-E-0 Page 7

3 4 3 4 7 4 AGND DGND 3 4 3 4 3 VA+ VD+ 4 8 3 3 4 CS5464 Operation V.0.0 Chapter 4 HW Reference SCH 4 HW Reference SCH Hardware reference SCH of energy measure system +5V +5V R85 5.K R69 0K V_N J7 LA J8 NA R83 50K R90 50K R93 50K R8 R88 5.R C47 03 R89 C48 03 R7 R75 R86 50K R87 50K R94 50K R76 R77 50R 50R 00K 50R 50R R78 00KR79 50R C39 03 C40 03 C43 03 C45 03 C49 4700p C4 4700p C44 4700p MSE_V3P MSE_V3N MSE_VP MSE_VN MSE_VP MSE_VN C35 04 C36 04 U8 9 0 0 9 6 5 VIN+ IIN+ IIN- IIN- IIN+ VIN- VREFIN VREFOUT CS5464 R70 0R C37 04 PFMON CPUCLK XOUT XIN 8 8 MODE 3 RESET 7 CS 5 SCLK SDO 6 7 SDI 4 INT 5 E 6 E E3 3 TEST 4 TEST Y 4.096MHz R97 +5V R80 C46 R9 C5 R95 C5 K n K n K n R7 330R 330R +5V U9 PS50- +5V U0 PS50- VDD U PS50- U5 VDD PS50- MSE_RST R8 330R GND MSE_SCLK R9 330R GND MSE_SDI R98 R67 K C53 PS50- +5V U MSE_SDO R96 330R n GND C34 04 K MSE_PF GND 50R +5V R84 GND 330R U6 J4 PS50- PF CHECK Figure 4-: RCS5464 Reference SCH MCU-AN-5000-E-0 Page 8

Chapter 5 FW diagram 5 FW diagram Firmware system diagram of energy measure system 5. SPI Communication Process Figure 5-: SPI Write Process Figure 5-: SPI Read Process MCU-AN-5000-E-0 Page 9

Chapter 5 FW diagram 5. Firmware System Diagram Start Init Reg(CONFIG) Init Reg(CYCLECOUNT) Init Reg(PULSERATE) Capture Active Pulse Calc the energy based on the EC Light on the warning light Deduct the charge Balance <= 0? Y Balance < warning value? N Y N Turn off the relay End Figure 5-3: Firmware System Diagram MCU-AN-5000-E-0 Page 0

Chapter 6 FW Function List 6 FW Function List 6. API void CS5464_Reg_Init(void) void EnergyCount_Init(void) void AfeRefreshEnable(void) void AfeRefreshTask(void) Function Prototype void EnergyCount_Reset(void) void CurEnergyCount_Reset(void) void MeterKwhInc(void) void PowerEnergy(void) void GetMeterCurFwdEnergySum(INT8U *sumbuff) void GetMeterCurRevEnergySum(INT8U *sumbuff) void GetMeterCurAllEnergySum(INT8U *sumbuff) void ReadMeterRuntimeData(void) void SaveMeterRuntimeData(void) void ReadMeterConst(void) void ReadMeterClibData(void) void SaveMeterClibData(void) void LoadTimeSegInfo(void) Table 6-: FW API List void UpdateTimeSegTable(INT8U tableid, INT8U segcount, INT8U *segdata) INT8U FindTimeZoneSegTableSeriesId(INT8U idtype) INT8U FindTimeZoneSegTableId(INT8U idtype) INT8U FindTimeSegTariffId(INT8U hh, INT8U mm) void ValidateTimeZoneId(void) void ValidateTimeSegTableId(void) void SaveLastMonthAllEnergyCounter(void) void SaveLastMonthFwdEnergyCounter(void) void SaveLastMonthRevEnergyCounter(void) void SaveCurrentEnergyCounter(void) Description Initialize CS5464 register Initialize for energy counting AFE refresh enable Refresh AFE setup with a reset and reconfiguration Reset all meter energy data Reset current meter energy data Accumulate meter KWH with each pulse received Accumulate energy pulses & output calibration pulses Retrieve current sum of meter forward energy data Retrieve current sum of meter reverse energy data Retrieve current sum of meter total energy data Read meter energy data saved in EEPROM Save meter energy data to EEPROM Read meter constant from EEPROM Read meter clibration data from EEPROM Write meter calibration data to EEPROM Load or reset time-seg parameter in EEPROM Update time-seg table Find a time-zone series ID base on current calendar Find a time-zone-id and time-seg-table-id base on current calendar Find a time-seg tariff ID base on given time value hh(hour) & mm(minute) Validate time-zone ID base on current calendar Validate time-seg table ID base on current calendar Save last month's all energy counter value to EEPROM Save last month's forward energy counter value to EEPROM Save last month's reverse energy counter value to EEPROM Save current energy counter value base on MCU-AN-5000-E-0 Page

Chapter 6 FW Function List tariff ID void LoadEnergyCounter(void) void EnergyDirValidate(void) void GetTimeSegFwdEnergySum(INT8U *sum, INT8U monthid, INT8U segid) void GetTimeSegRevEnergySum(INT8U *sum, INT8U monthid, INT8U segid) void GetTimeSegAllEnergySum(INT8U *sum, INT8U monthid, INT8U segid) void UpdateTimeSegTariffId(void) INT3U GetVoltageRmsValue(void) INT3U GetLoadCurRmsValue(void) INT3U GetNeutralCurRmsValue(void) INT3U GetActivePowerValue(void) INT3U GetPowerFactorValue(void) void ResetEnergyParameter(void) void Read_I_V_Energy(void) void CS5464_StartConversion(INT8U mode) Load meter energy counter base on energy direction state Validate energy direction/state Get forward energy sum for a specific time segment Get reverse energy sum for a specific time segment Get energy forward+reversed sum for a specific time segment Update tariff ID based on current time segment Get scaled voltage reading Get scaled load current reading Get scaled neutral current reading Get scaled active power reading Get scaled power factor reading Reset energy parameters Read AFE I/V energy data CS5464 starts to conversion 6. HAL void SPIPortInit(void) Function Prototype Table 6-: FW HAL List Initialize SPI port Description void BcdEnergySumIntInc(INT8U *bcd) Increment a 4 byte BCD energy number by from integer part(bcd[]) void BcdEnergySumDecimalAcc(INT8U *bcd, INT8U accval) void CS5464_ReadRegister(INT8U page, INT8U regaddr, INT8U *buff) INT8U SPI_ReadByte(void) void CS5464_WriteRegister(INT8U page, INT8U regaddr, INT8U *buff) void SPI_SendByte(INT8U outdat) void CS5464_WaitForReady(void) INT8U CS5464_IsReady(void) void CS5464_SetRegPage(INT8U page) Accumulate a 4 byte BCD energy number Read CS5464 register value Byte in through SPI port Write CS5464 register value Byte out through SPI port CS5464 ready-status wait CS5464 ready-status check CS5464 set register page for read/write MCU-AN-5000-E-0 Page

Chapter 7 Additional Information 7 Additional Information For more Information on FUJITSU semiconductor products, visit the following websites: English version address: http://www.fujitsu.com/cn/fsp/services/mcu/mb95/application_notes.html Chinese version address: http://www.fujitsu.com/cn/fss/services/mcu/mb95/application_notes.html MCU-AN-5000-E-0 Page 3

Chapter 8 Appendix 8 Appendix 8. List of Figures and Tables Table 6-: FW API List... Table 6-: FW HAL List... Figure -: The Function Diagram of CS5464... 6 Figure 3-: Hardware diagram... 7 Figure 4-: RCS5464 Reference SCH... 8 Figure 5-: SPI Write Process... 9 Figure 5-: SPI Read Process... 9 Figure 5-3: Firmware System Diagram... 0 MCU-AN-5000-E-0 Page 4