基于加密IC卡的多用户三相电能计量系统的设计【毕业作品】
智能三相表计量模块设计及实现
在国家一带一路政策发展鼓励下袁电网等企业逐 步走向世界袁与世界接轨袁这对智能电能表的要求更 加严格袁尤其是对电能表的准确计量性[1]遥 传统的电能 表计量误差偏大尧不准确袁这将严重影响电网企业等 的利益曰其次是计量模块运行时抗干扰能力差袁通讯 能力差[2]遥 本文采用的计量芯片 HT7038 计量更加准 确袁抗干扰能力强袁功耗低袁而且集成了其他功能袁如 用电信息存储和处理尧信息交互尧实时监控等功3;12 V
BAT1 CR_P2
SM4007
CP3 0.1 滋F
EP1 +
CP1
220 滋F/16 V 0.1 滋F
UP2 1
Vin
3 Vout HT7540
CP2 0.1 滋F
DP2 VDD3
QP1 MMBT2907A
SM4007 EP2 + 470 滋F/10 V
VEMU
检测技术与数据处理
DOI院10.19557/ki.1001-9944.2019.09.014
智能三相表计量模块设计及实现
张俊婷袁纪志坚
渊青岛大学 自动化学院袁青岛 266071冤
摘要院该文的智能三相表计量模块主要是基于芯片HT7038进行设计袁属于多功能高精度三
相电能专用计量芯片袁该计量模块计量准确袁运行时抗干扰能力强袁电路设计简单遥 该文主
1 电源单元设计及介绍
1.1 电源芯片 HT7540 简介 HT7540 是合泰的一款三端低功耗电源芯片袁
输出电流可达到 100 mA袁允许输入的电压高达 30 V遥 内部结构如图 1 所示[3]遥
VIN
VOL
Vref +
GND
图 1 HT7540 内部结构图 Fig.1 HT7540 internal structure
基排版于SA9904B的三相功率电能表设计论文(精)
基排版于SA9904B的三相功率电能表设计论文导读:本论文是一篇关于基排版于SA9904B的三相功率电能表设计的优秀论文范文,对正在写有关于电能表论文的写作者有一定的参考和指导作用,论文片段:也大大提升。
目前,在电能表测试方面,世界各个强大的IC公司都出产了许多他们自己设计的电能计量芯片,像ADE775X系列产品就是由ADI公司出产的,Climislogi则展示了他们的CS5460的杰作,这些电子式的电能表是以芯片为骨干组合构造起来的,当下已经通过了具体实践的检验,并且投入使用。
当前这种"专用的芯片十MCU"的双核结构的多功能摘要 3第一章绪论 1第二章多功能电能表研究现状及发展趋势 2第三章课题研究背景及意义 4第四章基于SA9904B的三相功率电能表设计 54.1三相功率电能表硬件设计 54.2电力参数采集模块的设计和实现 64.2.1三相电力参数采集芯片SA9904B 74.2.2 SA9904B外围电路设计 84.2.3电参数处理 114.3 GPRS通信模块的设计和实现 154.4 实时时间电路 174.4.1 DS12887时钟芯片介绍 174.4.2 DSI2887时钟管脚定义 184.5看门狗模块 194.6 LON主控模块的设计和实现 19总结 20参考文献 23摘要本文在前人设计的基础上,对三相多用户多功能电能表做了进一步深入的研究,并提出了一种新型的,即一个测量芯片和两个CPU的双核数据处理模式,不仅提高了电能参数的测量精度同时也使系统的稳定性得到进一步加强。
在以上各章节中给出了各主一入要部分的硬件设计原理图及软件实现流程图,并对造成计量误差的原因进行了详细的分析同时提出了相应的补偿方案,通过对该设计的电能表进行综合通电检测,基本达到了预期的设计目标。
(1)对电能表的发展状况做了全面而且细致的调查论证工作,并且通过到实际生产现场和用户使用现场的调研,获得了珍贵的技术资料及现场经验。
IC卡电度表控制电路设计毕业设计论文
IC卡电度表控制电路设计摘要飞速发展的电力工业对电能的计量与管理提出了更高的要求:先付费、后用电,实施分时电价,实现自动抄表和收费等。
IC卡预付费电子电能表应运而生,能够满足上述要求。
本论文在大量文献查阅和市场调研的基础上,论述了IC卡预付费电子电能表的工作原理及采用的标准,IC卡的主要技术,论述了电能表的方案设计、电能测量电路芯片的选型及电表控制程序设计中应该考虑的具体技术问题。
售电管理系统软件不仅能实现对IC卡和电费的管理,还能实现对生活小区住户及其它各种费用的综合管理,论文详细地说明了售电管理系统的功能分析、模块划分、程序的总体结构、输入输出以及接口设计、数据结构的设计等,并说明了几个主要模块关键技术的实现。
因此,预付费电子电能表系统具有广泛的应用前景。
关键字:电子电能表;IC卡;预付费;单片机;交流采样IABSTRACTThe electric industry has been developed at very fast speed, it brings forward higher requires to the electricity management. It hopes that the user can prepay electricity before using it,time-sharing electrovalence, copying the data’s from watt-hour meters and charging can be cayyied out automatically .In these cases the full electronic watt-hour meter of prepayment of IC card emerges, it can be meet the demands of the management above.Based on consulting a lot of literature and investigating,the paper discussed the principle of the full electronic watt-hour meter of prepayment of IC card, the standard and the technology of IC card. It also discussed the design of the watt-hour meter, the type of the energy measurement chips and the technique problems of the control program.The software of selling electricity management system can carry out not only the management to the IC card, but also the comprehensive management of various fees. The paper explained the analysis of function, module partition, program structure, input and output, interface and structure design of the software in detail. It stressed the critical technology of each module.Therefore the system of the full electronic watt-hour meter of prepayment has widely application prospect.Key word s:The full electronic watt-hour meter;IC card;Prepayment;Single chip computer; Ac sampling目录摘要 (I)ABSTRACT (II)第1章绪论 (1)1.1 IC卡概况 (1)1.2 IC卡的分类 (2)1.3 IC卡预付费电度表 (3)1.4 近几年IC卡预付费电度表发展状态 (4)1.5 IC卡在预付费电度表中的功能 (5)第2章IC卡电度表原理分析 (6)2.1 预付费电表原理和常识 (6)2.2 市场上常见预付费电表及其比较 (6)2.3 IC卡电度表的组成框图 (7)第3章硬件电路设计 (9)3.1 主控芯片的选用 (9)3.1.1 AT89C52的封装引脚 (9)3.1.2 AT89C52的内部特性 (9)3.1.3 AT89C52方框图 (10)3.1.4 各引脚功能说明 (11)3.1.5 振荡器特性 (13)3.1.6 空闲模式 (13)3.1.7 掉电模式 (14)3.2 接口电路的设计 (14)III3.2.1 信号检测与传感电路的设计 (14)3.2.2 A/D转换通道的设计 (15)3.2.3 外部存储器的扩展设计 (19)3.2.4 掉电检测及看门狗电路的电路设计 (20)3.2.5 键盘及显示电路的设计 (21)3.2.6 串行通信接口的设计 (21)3.2.7 压电源的设计[11] (24)3.2.8 警电路的设计 (25)3.2.9 硬件系统总框图 (25)3.3 硬件地址的确定 (25)第4章系统软件的设计 (27)4.1 主控程序的设计 (27)4.1.1 中断源及中断优先级的安排 (27)4.1.2 存储器的分配 (27)4.2 模块部分的设计 (28)4.2.1 掉电中断子程序的设计 (28)4.2.2 数据采集中断子程序的设计 (28)4.2.3 键盘中断子程序的设计 (29)4.2.4 串行口中断子程序的设计 (31)4.2.5 显示子程序的设计 (32)4.2.6 声光报警子程序的设计 (32)4.2.7 数字滤波的设计 (32)4.2.8 系统主流程图 (35)4.3 软件程序清单见附录2 (35)第5章结束语 (36)5.1 设计历程 (36)5.2 设计特点 (36)5.3 展望和体会 (37)致谢 (38)参考文献(主要及公开发表的文献) (39)附录1 IC卡家用电度表硬件框图 (40)附录2 软件程序清单 (1)V第1章绪论1.1 IC卡概况IC卡是集成电路卡(Integrated Circuit Card)的英文简称,在有些国家也称之为灵巧卡(Smart Cart)、智慧卡(Intelligent Card)、微芯片卡(Microchip Card)等。
一种基于单片机的新型三相多费率电能表的设计外文文献及翻译
always adopts mechanical tinplate to measure. There are some shortcomings that the measurement precision falls with machine abrasion, single time period setting and strong manpower [2]. In this paper, we propose a novel multi-rate three-phase watt-hour meter based on AT89LV52. This multi-rate three-phasewatt-hour meter adopts AD7752 for measurement. It has the characteristics which are time-sharing measurement, accurate measurement, LCD display, automatic meter reading, flexible time period setting, timely emendation, low cost and novel design.II. STRUCTURE AND WORKING PRINCIPLEThe novel multi-rate three-phase watt-hour meter proposed in this paper is based upon AT89LV52 singlechip [3]. AT89LV52 has the flash memorizer with 8k bytes, cryptographical program memorizer with third class, RAM with 256 bytes, 32 programmable I/O lines, three time/ counter with 16 bits and a two classhalt with six vectors. The interface circuit adopts I2C bus unit which is a 8 bits singlechip with good performance and suitable price. The system structure diagram is shown in figure 1.Figure 1. System structure diagramThe principle of this multi-rate watt-hour meter is reading in themulti-rate time segments using RS485 bus and noting in X25045 then take over correctional clock with RS485 bus and write in clock CMOS chip S3530A. The three-phase AC voltage and electric current pass through potentiometer and mutual inductance instrument respectively so as to produce small signal which is sent to AD7752 to complete measurement. The clock CMOS chip S3530A gives clock information per second in the course of automatic move and analyze this clock belongs to which period of time according to advance periods of time set in X25045 then save the electrical energy in RAM memorizeraccording to corresponding period of time. We write it to corresponding address of X25045 when the electrical energy achieves one degree in order to make the multi-rate measurement come true. This watt-hour meter hasfunctions of clear LCD display, missing phase detection, burthen control, halt electricity check and storage, automatic meter reading and so on.III. THE DESIGH OF HARDWARE CIRCUITA. Electrical energy measurementThe three-phase electrical energy measurement is realized by the low consume CMOS chip AD7752 of ADI company. The inside of AD7752 adopts digital circuit besides ADC, filter and multiplication circuit which can eliminate noises effectively. The sampling course of voltage and electric current in three-phase AC power supply loop is shown in figure 2 in which IA stands for voltage sampling of A phase. The sampling circuits of B phase and C phase are similar to A phase. The power after integral is transformed to electrical pulse for output. The pulse of fan-out CF enters intointerregnum INT0 of AT89LV52 through photoelectricity insulation 4N25. CPU measures the electrical energy [4]. We adjust the pulse number of CF by combining the state of S1 and S2. The connection of electrical energy and pulse is W = M C . In which, W is the electrical energy with the unit of kilowatt-hour, M is the total pulse number, C is the pulse number of ammeter. We choose C equals to 3000 that is to say every kilowatt-hour is 3000pulses.Figure 2. Circuit schematic diagramof watt-hour meterB. LCD displayThe LCD display [6] adopts HT1621 CMOS chip of HOLTEK Company toachieve twelve bits digital display. HT1621 is the LCD drivers with 128 segments (32× 4) inner memorizer. The interior of HT1621 consists ofcontrol and time circuits, RAM, LCD drive and watch timer. It hasthe merits of small volume and low cost so that it is suit to watt-hour meter. We use serial interface which only has four lines between HT1621 and AT89LV52. The detailed connection is shown in figure 3. P20, P21, P22 and P23 of AT89LV52 connect to CS, RD, WR and DATA respectively with the use to refurbish the display of RAM. HT1621 drive CMOS chip has 48 nodes in which COM0, COM1, COM2,COM3 connect to the communal end and drive output of LCD and SG0, SG1, SG2, SG3 connect to drive output of every segment respectively. In addition, an adjustable resistance of 20kΩ is put between VDD and VLCD to adjust the display contrast of LCD. Experiment shows that the contrast is better withVDD=5V and VLCD=4V.C. Serial memorizerSerial memorizer adopts low power consumption chip X25045 of XICORcompany .It has three functions which are watchdog timer WTD, voltage supervision and serial memorizer E2PROM with 512 bytes. WTD can be set 200ms, 600ms and 1400ms time intervals. The software program is read into X25045. During the normal running of program, WTD receives the trigger signal in time intervals in order to ensure the normal running of program. X25045 will output a high potential through RESET line if WTD does not receive trigger signal in time intervals. The trigger watt-hour meter reset in order to prevent program flying away. As the serial memorizer chip, 512 bytes of X25045 are used to storage the watt-hour meter code, multi-rate periods of time, the apex electricity, smooth electricity, vale electricity and total electricity of last month and this month. Storage can be divided into two same areas. One is used as data storage. The other is used for backup. The number of storage can be revised 100,000 times. Data can be stored for 100 years. It is connected with AT89LV52 by SPI agreement bus. The connection is shown in figure 3.D. Clock circuitThe clock circuit is completed by S3530A chip. It is a low powerconsumption clock chip that supports I2C Bus. It sets the clock and calendar according to the data received by CUP communicating with RS485. At the same time, it continues to walk time by its own oscillation. The crystaloscillator of 32.768 kHz is put between Xin and Xout of S3530A which is connected with CPU through latching. SDA foot and SCL foot connect to P1.6 and P1.7 of AT89LV52 respectively. There are two interrupt alarming foots can be set as second output or minute output synchronizing pulse which supply interrupt signal to AT89LV52 with one second period. Single-chip system will readout the current time through I2C communication interface according to this signal and calculate the period of time that this moment belongs to so as to realize the electrical energy measurement in different periods of time [5]. This clock circuit has spare lithium battery. The powersupply VCC supply power in normal wiring and electrified for lithium battery of 3.6V. When there is power off, the system will automatically convert lithium battery to clock circuit for power supply. The clock will still running accurately even the power is off.Figure 3. Partial circuit figure of watt-hour meterE. RS485 CommunicationMAX485 chip can implement RS485 communication control ofmulti-rate watt-hour meter. MAX485 chip has RS485 communication protocol. It can take 128 hypogenous computers. Its transmission distance is greater than1km and its transfer rate is up to 250kb per second. The watt-hour meter connects with the unit controller through the RS485 bus. Each unit has a cell controller can manage 128 multi-rate watt-hour meter. The cell controller connects to power management computer. Each watt-hour meter has one and only meter number with eight bits of hex. The electrician should write the user’s information and meter number and then import to the power management computer for initial installation so ad to complete the connection of user and management computer. Management computer sends setting of period of time and clock information with the manner of broadcast communication without address information. PC uploads information by the way of calling address.F. Lack Phase detection and relay controlIt can achieve relay control [7] with P27 of AT89LV52. P27 cancontrol relays using 4N25 photoelectricity isolator so as to complete powersupply and power control. Lack Phase detection gets the signal from fan-out of the relay and connects to 1 foot of photoelectricity isolator after passing a 75K resistance, the diode half-wave rectifier and capacitivefiltering respectively. We detect the 4 foot of isolator to determine whether there is the lack of phase. If there is lack of phase, we detect again after 2 seconds overtime. We break off the power immediately if there is lack of power after the twice confirmation. In power protection circuit, it uses the INT1 interrupt foot of AT89LV52 to detect signal.When there is a sudden power off, INT1 jumps into a low voltage and the INT1 interrupt enters to the power protection program relying on the energy storage capacitor to save data. In the system, pulse output of AD7752, relay control port and the inputs of lack phase detection all use photoelectric isolator4N25. It sends electrical signal by light coupling which can enhance theability of anti-jamming.IV. THE DESIGN OF SOFTWAREA.The distribution of resourceThe software program includes main program, X25045 read and write program,RS485 serial communication program, interrupt serve program, timer handling program, HT1621 display control program, electrical energy measurement in different period of time and power down protection program, and system self-checking and anti-interference handling program. Interrupt resourcedistribution of system is: INT0 interrupt is used as AD7752 pulse measurement, INT1 as synchronization detecting, timer T0 as 100 ms timing, T1 as 1ms timing, and T2 as baud rate generator for serial communication program. RS485 asynchronous communication is set to receiveinterrupt and check information for sending.B. Module desighThe flow chart of main program is shown in figure 4. The watt-hourmeter should be able to initialize at each power up time. The initializing program includes setting working mode of timers, serial stomata and interrupts for AT89LV52, writing control word into X25045, S3530A and HT1621. This system sets three periods of time. The singlechip reads clock value from S3530A per second then analyze this clock belongs to which period of time according to advance periods of time set in X25045 then save the electrical energy in RAM memorizer according to corresponding period of time. We write it to corresponding address of X25045 when the electrical energy achieves one degree. The LCD display with 16 bits shows period of time and electrical energy information in turn. Figure 4. Flow chart of main programV. TESTING RESULTError measurement and running test have been made in Zibo Billion Electron Co., Ltd. The epigenous computer completes the setting of time management. There arethree-rate period of time. The first period of time is vale electricity from 00 point 00 minute to 06 point 30 minutes. The second period of time is apex electricity from 06 point 30 minutes to 22 point 30 minutes. The third period of time is smooth electricity from 22 point 30 minutes to 24 point 00 minute. The setting of rate period of time is sent to computer management system by electric power company according to national policy and saved in X25045. The apex electricity, smooth electricity, vale electricity and total electricity per month read saved in electrical energy meter and sent to epigenous computer through cell controller. The communication baud rate is 9600 bits per second. The checkout platform of 0.1 grade standard electronic power meter is used as standard meter and the multi-rate watt-hour meter is the tested meter. Billion Electron Company has carried out testing according to different load running. The measured data is shown in table 1 with the burthen of 30kW.TABLE I. COMPARE OF NORMAL METER AND TESTING METERThe testing result indicates that the error of this multi-ratewatt-hour meter is less than 1%, belongs to 1.0 grade. The return reading of electrical energy is precision and the emendation of time is timely and right. By testing, the method of decreasing errors for electricity metering can be obtained. Firstly, adjust the sampling resistance of AD7752 to accurate value. Secondly, the value of this resistance is needed less varying with temperature. Thirdly, during electricity metering progress, when mantissa portion of electricity is less than 0.01, the remaining pulse should be accessed together, thus cumulative error caused by lack of 0.01degree energy loss could be avoided.VI. CONCLUSION AND EXPECTATIONThe multi-rate watt-hour meter achieves electrical energycomputation in different time according to different time setting. It adopts RS485 for serial communication and realizes automatic meter reading and real-time emendation. The results of production in Billion Electron Company showthat the multi-rate three-phase watt-hour meter proposed in this paper has the characteristics of novel design technique, accurate measurement, and flexible time period setting. Various technical indexes achieve the technique standard for national intelligent card watt-hour meter. Therefore, it has wide application.REFERENCES[1] Bu Zhengliang, Yin Xianggen, Tu Guangyu. “Development of HV Watt-hour meter.” Automation of Electric Power Systems, 2006, 30(19): 89-93.[2] Kosukegawa M., Sakumoto Y. “Traceability system of electric energy standard and tendency in static watthour meter development in Japan.” Sixth International Conference on Metering Apparatus and Tariffs for Electricity Supply, 1990,4: 259-263.[3] Xuehai Li. Applied tutorial of singlechip. Electronic industry publishing company, 2003.[4] Al-Khateeb Tarik, Blundel Martin. “An electronic meter for measuring the saving in electrical power.” The Ninth Arab International Conference on Solar Energy (AICSE-9), Kingdom of Bahrain, 2007,4 (209):328-333.[5] Liu Ying, Liu Qingyu. “Development of a self-calibration precision electrical measuring meter.” Proceedings of the 1998 Conference Precision Electromagnetic Measurements, 1998,7:276.[6] Gao Yun-Peng, Teng Zhao-Sheng, Liu Peng. “Design of three-phase multi-functional harmonic energy meter.” Journal of Hunan University Natural Sciences, 2008, 35(9): 53-57.[7] Qu Qingchang. “Key technology to three-phase electric meter and high voltage electric power measurement.” Acta Metrologica Sinica, 2007, vol28: 25-30.一种基于单片机的新型三相多费率电能表的设计Jishun Jiang Lanlan YuSchool of Electric and Electronic Engineering School of Electric and Electronic Engineering Shandong University of Technology Shandong University of Technology Zibo, 255091, China Zibo, 255091, China摘要:随着社会的发展,对电力的需求变得越来越大。
毕业设计(论文)-学生公寓多用户电能计量控制系统设计[管理资料]
摘要目前用于学生宿舍、公寓的电能计量控制系统在全国大部分高校中已普遍使用,但大部分采用以房间为单位计费,然后均分到个人的计费方法,该方法不能实现对学生个人用电计费,收费困难,易造成学生间的矛盾,因此如何科学合理地对学生公寓进行电能管理是一个亟待解决的重要课题。
本课题分析了当前国内居民小区和学生宿舍电能计量管理的现状,根据学生公寓用电管理的实际情况,设计了一种带身份识别的学生公寓电能计量控制系统。
该系统由现场级和管理级两级组成,本文详细阐述了现场级模块的软硬件设计方案。
现场级以专用电能计量芯片AD7755和带有A/D转换功能的微处理器80C196KB以及身份识别电路(IC卡预付电费电路)为核心,实现个人用电计量、类阻性发热负载识别、公寓用电情况的监视等,并通过RS-485与上层管理级通信,完成对公寓用电情况的统计和管理。
本文的创新点在于先刷卡识别身份再用电的管理模式。
设计中给宿舍内的用户每人分配一条用电支路,用电时用户先刷卡,通过身份识别后,该用户的用电支路接通(通过继电器控制通断),其电源插座可插接电器,然后系统将对其用电情况进行计量与控制。
当用户超过一定的时间未用电时,系统将自动关断该用电支路,以达到节电、安全用电,并防止其他用户窃电的目的。
本系统解决了电费均分难、恶性负载识别难、用电情况实时监测等问题,实现了学生公寓用电的现代化和自动化管理。
关键词:电量计量;身份识别;恶性负载识别;IC卡AbstractUniversity student hostels currently prevailing own apartment management, how scientific and reasonable for students villas Energy management is to be resolved into one of the important topics.This paper analyzes the domestic civilian and Area Energy Management System based on the status of student apartments and electricity management in the actual situation, A design with the identification of student apartments intelligent power management system. The system can spot and the management level two components. Field level through a dedicated power measurement and AD7755 chip with A/D conversion function of 80C196 embedded microprocessor KB and the identification circuit (IC circuit prepaid electricity) as the core personal consumption data measurement, Real-time dynamic type identification resistive heating load for the right side of the apartment monitor, investigate unusual electricity, thereby effectively limiting the use of students, such as faster heat, furnace son, incandescent easy use of fire appliances, Communication through the completion of the apartment's electricity consumption statistics and published; The upper management level PC at the core. through telephone lines or LAN communications at any time acquisition bottom PC data resources, through the completion of various statistical database, analysis, can be kept informed of the entire campus apartment Finally, the harmonic grid data Energy and complete clearing business.This paper elaborates on the module-level design of software and hardware, anti-interference, IC card prepaid electricity circuit, Communication Protocol and vicious load identification theory, users must have the money to be put aside a certain amount of electricity to electricity, avoid the tariff arrears, when calculating the balance of the customer or have insufficient Arrearage. SCM is this balance of power failure or lack of alarm control; The system also has a card to restore function, When the user less than the balance remaining tariffs, first alarm, and when users balance of a serious shortage of electricity, power outages to the user. Credit cards can be conducted at this time to restore electricity, and only credit once.Adoption of this study successfully resolved the difficult tariff equalization, vicious load identification difficult. electricity consumption to real-time monitoring, andother problems that the student dormitories modernization and automation Energy Management Program.Key words:Electric Power Measurement;Identity Recognition;Malignant load identification;IC card目录第1章绪论 (1)电能计量、管理概述 (1)电能计量装置 (1)集中式电能计量、管理 (2)课题的背景及意义 (3)本课题的设计任务与要求 (4)第2章方案设计与论证 (5)电能计量系统方案设计 (5)身份识别(预付费)系统方案设计 (7)第3章系统总体设计 (9)总体设计思想 (9)系统的总体结构及原理方框图 (9)第4章系统硬件电路及工作原理 (11)单片机及外围电路设计 (11)CPU的选择 (11)系统存储器的扩展 (12)电能计量电路的设计 (14)电能计量的基本原理 (14)电能计量芯片ADE7755 (15)电能计量的硬件电路 (19)电能存储器 (19)身份识别电路的设计 (20)MF RC500的特性 (20)MF RC500的内部结构 (21)MF RC500与单片机的接口 (22)MF RC500与天线接口设计 (23)智能开关的设计 (24)负载识别模块的设计 (25)设计原理 (25)具体实现 (27)其他电路的设计 (28)报警电路 (28)键盘电路 (28)显示电路 (29)串行通讯 (31)up监控电路 (32)工作电源 (33)第5章系统软件设计说明 (35)总体软件设计 (35)各主要模块程序流程 (35)第6章经济效益分析 (43)第7章总结 (44)参考文献 (45)致谢 (47)附录Ⅰ (48)附录Ⅱ (60)附录Ⅲ (64)第1章绪论1.1电能计量、管理概述随着电力市场的发展,电力改革的深入,电力系统已经开始由计划经济向市场经济转变,这对电能的计量及管理提出了新的要求。
多用户电能表的应用设计课程设计报告
多用户电能表的应用设计课程设计报告专业:电气工程及其自动化摘要电子式电能表是通过对用户供电电压和电流实时采样,采用专用的电能表集成电路,对采样电压电流信号进行处理并相乘转换成与电能成正比的脉冲输出,通过计度器或数字显示器显示用户使用的电量。
本文将设计一个以C8051F360芯片为核心,配有电能转换模块、LED显示模块、掉电存储模块等功能模块,实现对八户的用电状况进行采集检测。
本次设计用户数为八户,即实现八位用户循环显示电能量。
同时,基于E2PROM 24C16芯片实现单片机的掉电数据保护,基于74HC165芯片实现单片机的清零。
基于AD7755芯片实现电能脉冲的发生;应用单片机C8051F360编制程序完成脉冲的读取、计数、计算、存储、送显示等功能;应用74HC164及八段译码显示器完成数据的显示;应用74HC165及键盘控制对脉冲清零;应用E2PROM 24C16完成数据的定时写入以防停电时数据丢失。
关键词:8用户电能表;AD7755;24C16;C8051F360ABSTRACTElectrical meter is through user power supply voltage and current real-time sampling, using special integrated circuit of electric energy meter, the sampling voltage current signal processing and multiplication convert to electric proportional to the pulse output, through the JiDuQi or digital display shows users with the use of the power. This paper will design a C8051F360 chips as the core, equipped with electric energy conversion module, LED display module, power lost storage module function module, realizes to eight of the power consumption and the collection detection.The design for the eight users at home, which realize the eight users cyclic display electric energy. At the same time, based on the single chip microcomputer chip realize 24 y E2PROM chips was the power lost data protection, based on the 74 HC165 chip microcontroller cleared of realization.Based on AD7755 chip realize the energy pulsing occur; C8051F360 single chip microcomputer application program to complete pulse to read, counting, computation, storage, send display function; Application HC164 and eight section 74 decoding display finish data display; 74 HC165 keyboard control and application of pulse reset; Application E2PROM chips was complete data of the timing 24 y write in case of power data is lost.Keywords:electric energy meter;8 the user watt-hour meter;AD7755;24C16;C8051F360目录1 设计目的及要求 (1)1.1设计目的 (1)1.2设计要求 (1)2 设计容 (1)2.1设计系统方案 (1)2.2设计系统框图 (2)3 硬件电路设计 (2)3.124C16功能介绍 (2)3.2六段数码管显示电路 (3)3.3C8051F360功能介绍 (4)3.45V稳压电源的设计 (5)3.5光电隔离电路 (5)3.6AD7755电路设计 (6)4 软件电路设计 (12)4.1主程序流程图设计 (12)4.2显示用户及相应电能子程序框图 (13)4.3读24C16子程序框图 (14)4.4写24C16子程序流程图 (15)4.5查询键盘流程图 (16)4.6中断子程序流程图 (17)5 结束语 (18)致: (18)参考文献 (19)附录 (20)1 设计目的及要求1.1设计目的设计多用户电能表,掌握单片机在电力系统中的应用,并且可以通过计算机的编程实现对户的用电状况进行显示,进一步熟练单片机编程,了解24C16的功能实用。
基于IC卡的集中式电量计量系统设计
目录摘要 (III)ABSTRACT (IV)前言 (1)第一章电能计量系统方案论证 (2)1.1方案一机械电子式 (2)1.2方案二模数转换式 (2)1.3方案三功率累加式 (3)1.4方案选择 (3)第二章硬件设计 (4)2.1主控模块设计 (4)2.1.1 AT89S52介绍 (4)2.1.2 看门狗定时器 (5)2.1.3 WDT的使用 (5)2.2功率计量原理 (6)2.3电能计量 (7)2.3.1 AD7755工作原理 (7)2.3.2 AD7755引脚介绍 (8)2.3.3 由AD7755构成的原理图 (10)2.3.4 AD7755供电部分 (13)2.4开关控制部分 (14)2.4.1 BH3023介绍及原理 (14)2.516户用户进行检测与控制的硬件实现 (15)2.5.1 16户用户通断电的控制方法 (15)2.5.2 16户电能检测的方法与实现 (17)2.5.3 延时电路 (18)2.6读写模块 (19)2.6.1 MFRC530介绍 (19)2.6.2 MFRC530的内部结构 (19)2.6.3 MFRC530的管脚功能 (20)2.6.4读写天线的设计 (22)2.6.5 MFRC530与MCU接口电路 (22)2.7电能存储器 (23)2.7.1 24C08介绍及硬件连接图 (23)2.8显示电路 (24)2.8.1 MAX7219介绍及硬件连接图 (24)2.9MCU电源模块 (26)2.10掉电检测电路 (26)2.11报警电路 (27)第三章软件设计 (28)3.1电能计量系统主程序 (28)3.2电能计量程序 (30)3.3电能计量存储程序 (33)3.3.1 I²C通信原理 (33)3.3.2 24C08工作原理 (34)3.4电能计量显示程序 (39)3.5报警程序 (45)结论 (46)参考文献 (47)致谢 (48)附录A IC卡检测及读写程序 (49)附录B 元器件清单列表 (53)附录C 基于IC卡的集中式电量计量系统整机电路图 (54)附录D 基于IC卡的集中式电量计量系统的软件流程图 (54)基于IC卡的集中式电量计量系统的设计摘要本设计是基于IC卡的集中式电量计量系统,涉及电能计量、电能存储、电能显示、射频卡读写这四大部分。
基于ATT7022E的高精度三相电能计量仪软件设计_段双明
参考文献:
[1]李保玮.智能电表简介总体框架
[2]钜泉光电科技(上海)股份有限公司.ATT7022E/26E/28E 用户手册
3 软件实现
(P73-13-45),2012.
针对电能计量仪的功能,本部分主要介绍 STM32F103 初始化程序、 [3]意法半导体(中国)投资有限公司.STM32F10xxx 参考手册 _V10_CN
为 320ns。 3.2 ATT7022E 接口程序设计 STM32F103 通 过 SPI 接 口 控 制 ATT7022E 工 作 。 设 置
STM32F103 的 SPI 工 作 为 主 SPI, 产 生 同 步 信 号 。 SPI 时 钟 由 STM32F103 外设产生,设置通用输入输出引脚工作在 SPI 模式,使能 SPI 功 能 , 使 能 SPI 接 收 中 断 。 STM32F103 发 送 命 令 初 始 化 ATT7022E,ATT7022E 完成芯片初始化功能,开始数据采集和计算。 STM32F103 发送读取命令,ATT7022E 将电压、电流、频率、相位和功 率等信息发送到 STM32F103。
基于单片机的三相电能表的设计
摘要本文以智能计量总表为研究对象,采用计量芯片ADE7758和AT89$52设计三相电能表,介绍了计量电路原理、系统结构特点以及分段计量的软件设计与实现。
针对10—35kV输配电网正常负荷和超低负荷两种情况下的精确计量,提出按功率额度实时分段计量的电能表设计方案;为了调整电力负荷曲线,针对用电量的时间不均衡问题,提出复费率分时段计量方案。
采用双变比电流传感器进行信号的检测采样,当负荷电流低于额定电流的20%时,单片机通过检测功率,自动切换到低负荷计量回路,即小电流比计量回路,最大限度降低了电流传感器低负荷运行时造成的信号检测误差,提高电能计量精度。
单片机通过对瞬时有功功率的检测,实现了计量回路的实时选通切换和功率分段计量:通过对时间参数的检测,实现了定时存储和分时段计量。
根据电能表参数配置进行ADE7758初始化参数计算。
为了评估电能表计量数据的真实性和有效性,对模拟信号输入电路进行试验设计,应用ME300B单片机开发系统进行在线仿真调试。
以功率参数为性能指标,通过仿真试验,对功率参数的理论值和电能表的显示值两组数据进行分析比较,得出电能表计量数据是真实有效的结论。
采用双变比电流传感器进行电能表设计,扩大了负荷计量范围,提高了电能计量精度,且计量回路切换无需进行人工干预。
该方案有望实现全量程的精度均衡和精确计量,为具有实时分段计量功能的三相电能表设计提供一种可行的方案。
目前,已完成样表的设计与测试工作。
基于精确的试验平台,完成对电能表的增益和偏差校准,即可进行现场试验和数据采集,具有良好的市场应用前景。
关键词:三相电能表,实时分段,精确计量,仿真试验,ME300B,ADE7758,AT89S52符号约定及其说明一、变量定义及显示代码(斜体时表示变量,正体时表示显示代码)RO 总的无功电量ED 总的有功电量EJ 分时段有功电量(00:00~12:00)E2 分时段有功电量(12:00~00:00)E3 按负荷功率分段小负荷计量时有功电量E4 按负荷功率分段正常负荷计量有功电量P 瞬时有功功率V 瞬时无功功率H1 断相事件次数H2 单相过流事件次数H3 单相过压事件次数二、按键功能说明K1 手工复位K2 分时段电量参数查询显示K3 按功率分段电量参数查询显示K4 瞬时有功、无功功率参数查询显示三、电能表参数MC 电能表脉冲常数PO 有功功率分段参考Imax 满足计量精度的负荷额定最大电流Vn 负荷额定电压值Vf ADE7758电流、电压通道信号输入Ifullscal ADE775 8电流通道满刻度输入对应的负荷电流Vfullscale ADE7758电压通道满刻度输入对应的负荷电压Wh/LSB ADE7758有功能量寄存器最低有效值VARh/LSB ADE7758无功能量寄存器最低有效值第一章绪论电能表技术正向着复费率、多功能、网络化的方向发展。
基于STM32的三相多功能电能表解决方案
1 n 2 uk n k 1
u k —电压采样值
式中:U-电压有效值,n-每周期采样点数,
电流测量(有效值)计算式: I
1 n 2 ik n k 1
式中:I-电流有效值,n-每周期采样点数, ik -电流采样值 在得到的电流电压有效值基础上计算出总功率 S(即视在功率),通过对时间积分的电流电压积得到有 功功率 P,无功功率 Q 是总功率 S 与有功功率 P 之差,功率因数是有功功率 P 与总功率 S 的比。 对于单器件和三相四线星形负载的有功功率和无功功率的计算汇总如下: 单元件有功功率计算式: P
图4
AD73360 与 STM32 的接口电路
与滤波网络 由 STM32 的 GPIO 控制 AD73360 的 SE 和 RESET,并用一个外部中断输入脚来监听帧同步信号,这样 才可以用程序来保证数据帧内容的字节对应关系。 在 STM32 的硬件设置程序中,需要关闭 SPI 的所有中断,设置 SPI 为从模式,并选取一个 DMA 通道 与之协同工作,自动将 SPI 从模式收到的数据保存在指定的内存地址。为了令 AD73360 正确采集数据,还 必须根据使用要求配置 AD73360 的内部寄存器, 令 AD73360 处于数据模式并主动向 STM32 发送采样数据。 三、主要电能参量的计算
AD73360 是固定周期采集,我们使用的是 150Hz 或 160Hz,即每周期采集 150/160 点,为此 AD73360 采用的时钟是 6.000MHz 或 16.384MHz, 系统中对 AD73360 的配置为 DMCLK 分频因子为 2048。 AD73360 是差分采集,很方便进行过零点检测和直流分量调节,以保证信号幅度对称,从而减小系统误差。 电压测量(有效值)计算式: U
多用户电能表课程设计报告
多用户电能表的应用设计课程设计报告姓名:张建伟学号:200901100832专业:电气工程及其自动化班级:09-2班邮箱:1031639421@ 指导教师:公茂法2012年6月28日摘要本文主要涉及一个多用户电子式单相电能表,以C8051F360单片机为核心,具有电能变换、LED显示、掉电存储、按键清零等功能模块,通过对用户供电电压和电流实时采样,并采用专用的电能表集成电路,对采样电压电流信号进行处理并相乘转换成与电能成正比的脉冲输出,再经过计数器和LED显示器实现对8用户的用电情况进行集中检测、循环显示、掉电存储等功能。
各户的用电量可以就地读取,有效地提高了电能计量的准确性,而且整机电路简单,可靠性高,另外在多用户电子式电能表的前面有6位LED数码管,前两位为分户号,后四位为分户用电量,所显示的用电量与分户号相对应。
设计中采用了查找资料、protel 画原理图、软件编程调试等方法,最终实现了在数码管上8用户电量集中循环显示的功能。
关键词:8用户电能表;AD7755;C8051F360ABSTRACTThis paper mainly involves more than a user electronic single-phase watt-hour meter, to C8051F360 microcontroller as the core, with power transformation, the LED display, power lost storage, buttons and reset function modules, through user power supply voltage and current real-time sampling, and the use of a special electric energy meter integrated circuits, the sampled voltage current signal processing multiplication convert to electric proportional to the pulse output, and by the counter and LED display to realize the power of the users are 8 concentrated check, circulation, the display of power lost storage etc. Function. Each of the electricity consumption can read in situ, effectively improve the accuracy of electric power measure, and the circuit is simple, high reliability, high in many other users of the electrical meter in front of six LED digital tube, the top two for no. Of the individual, after four for the individual power consumption, shows power consumption and corresponding to the number of the individual. Design with the search for material, draw principle diagram and software protel programming commissioning method, and finally achieved in digital tube power users on 8 cyclic display function.Keywords:8 user watt-hour meter;AD7755;C8051F360目录绪论 (4)1 设计任务与要求 (5)1.1 设计目的 (5)1.1.1 硬件设计 (5)1.1.2 软件设计 (5)1.1.3 已知参数 (5)1.1.4 设计要求 (5)2 设计原理 (6)2.1 设计系统方案 (6)2.2 设计方案框图 (6)3 硬件电路设计 (7)3.1硬件设计综述 (7)3.2稳压电源设计 (7)3.3 AD7755电能转换设计 (8)3.3.1 AD7755电能转换设计原理 (9)3.3.2 AD7755参数分析及计算 (10)3.3.3 AD7755通道一输入电路设计及参数分析 (11)3.3.4 AD7755通道一输入电路设计及参数分析 (12)3.3.5 AD7755外围电路设计 (14)3.4 单片机控制电路设计 (14)3.4.1 C8051F360单片机部分 (14)3.4.2 AT24C16掉电存储部分 (15)3.4.3 74HC164数码管显示部分 (16)3.4.4 74HC165按键清零部分 (16)3.4.5 光电隔离部分 (17)4 软件电路设计 (18)4.1 流程图设计 (18)4.1.1 主函数流程图 (18)4.1.2 读AT24C16函数流程图 (19)4.1.3 写AT24C16函数流程图 (20)4.1.4 中断函数流程图 (21)4.1.5 按键扫描函数流程图 (22)4.2 程序设计清单 (22)5 心得体会 (23)6 致谢 (24)参考文献 (25)附录一 (26)附录二 (27)绪论随着电子技术的发展与进步,电子式电能表无论在价格、功能、精度、可靠性等方面都优越于传统感应式电能表,电子式电能表所具有的强大功能及特点,越来越受到广大使用者的认同与青睐。
推荐-三相多功能电表的设计与总结报告 精品 精品
山东省大学生“高教社&XILINX杯”电子设计竞赛三相多功能电表的设计与总结报告参赛题目:三相多功能电表所属单位:曲阜师范大学物理工程学院摘要系统是基于ATMEGA16单片机和ATT7028A专门计量芯片为核心器件的三相多功能电表。
采用电压互感器与电流互感器对三相电网取样,ATT7028A根据取样信号能够测量出各相以及合相的有功功率、有功电能、各相电流电压有效值、功率因数、相角、频率等数据,数据送入ATMEGA16单片机。
用户可以通过单片机提供的丰富的用户界面读取相应的数据,并可以通过标准RS-485通讯来实现远程有线测量和标准USART通讯来实现远程无线测量。
本系统很好的完成了题目要求的基本及发挥要求,并进行了进一步的扩展。
关键词:ATMEGA16 ATT7028A 三相多功能电表远程测量A bstractThis system is a three-phase multi-function power meter, which the core device is based on ATEMGA16 and ATT7028A. It samples on Drehstromnetz with the use of the Voltage Transformer and Current Transformer. According to the sample signals accquired, ATT7028A works out the active power and total active power, active electrical power, RMS current and voltage of each phase, Power Factor, Phase angle, and Frequency. When the above data are inputted into ATEMGA16, users can read the corresponding data by means of the rich user interface provided by ATMEGA16; they can realize remote cable measurement through standard RS-485 munication; and then they can achieve remote wireless measurement by standard USART munication. The design achieved and even exceeded all the technical indexes with better accuracy and control.Keywords: ATMEGA16;ATT7028A;three-phase;multi-function power meter ;distance measurement目录摘要 (1)1 设计要求 (1)1.1 基本要求1.2 发挥部分2 方案设计与论证 (1)2.1 整体方案的设计与论2.2 控制部分MCU的选择2.3 取样电路2.4 显示电路2.5 远程通信单元2.6 垵键电路2.7 软件部分方案3 理论分析与计算 (4)3.1 三相有功功率,有功电能、无功功率、功率因数、无功电能的计算3.2 电压和电流有效值的测量3.3 三相有功功率和有功电能的计算3.4 功率因数的测量3.5 相序检测4 测试方法与数据,测试结果及分析 (6)4.1 测试仪器4.2 校表方法4.3 测试数据4.4 测试结果分析5 总结 (8)5.1 基本功能5.2 发挥部分5.3 功能扩展部分5.4 比赛总结6 附录 (9)6.1 参考文献6.2 ATT7028A外部引脚与内部框图6.3 主要元件清单6.4 电路图6.4.1 5v 电源6.4.2 按键功能对应表与键盘简略电路图6.4.3 Atmega16单片机外围电路图6.4.4 ATT7028A外围电路图6.4.5 电流互感器与电压互感器电路图6.5 程序框图及部分程序6.5.1 框图6.5.2 部分程序1设计要求1.1基本要求(1)测量功能及技术参数A.三相额定交流相电压:100V/220V/380V,过载能力:持续1.2倍、瞬时电流10倍/5秒;B.三相额定交流电流:1A,过载能力:持续1.2倍、瞬时电压2倍/1秒;C.三相三线或者四线任意选择;D.实现电压和电流相序检测功能(2)准确度: 测量精度:1级。
基于ATT7022E的高精度三相电能计量仪软件设计
基于ATT7022E的高精度三相电能计量仪软件设计基于电量采集芯片ATT7022E,设计一款高精度电能计量装置,该装置采用意法半导体STM32F103为控制器,完成对ATT7022E的控制。
通過读取ATT7022E的测量值,完成三相电压、电流、功率、功率因数和谐波等参数的测量。
主要完成测量装置的软件设计,包括ATT7022E的初始化,与ATT7022E之间通信和RS485通信等。
标签:STM32F103;ATT7022E;液晶显示;RS485通信1 概述电力工业的发展和人们生活生产用电量的增加,使得电能计量装置得到快速发展。
传统的机械是电表只能满足电能计量功能,不能实现远程抄表和电能质量分析等功能。
为了满足智能用电需求,电能计量芯片得到发展并快速应用于电能测量和管理。
这些电能计量芯片可以完成单相或者三相电的电量测量和电能质量分析,测量精度完全满足国家标准规定。
本文在由STM32F103和ATT7022E组成的电能测量装置硬件平台上,编写软件程序,完成三相电的电流、电压、功率、功率因数和电能质量的测量。
2 整体设计电能计量仪软件采用模块化设计方法,将各功能模块用子程序实现。
图1所示为电能计量仪软件结构框图,由时间管理程序、通信程序、计量管理程序和显示程序组成。
时间管理程序实现软件定时功能,为各个操作提供统一时标,由定时器实现时间管理功能。
通信程序包含RS485通信和CAN通信两个子程序,采用STM32F103内部集成的串口通信和CAN通信模块,完成电能计量仪和上位机通信的功能以及电能计量仪和其他装置通信的功能。
图1 高精度三相电能计量仪总体框架3 软件实现针对电能计量仪的功能,本部分主要介绍STM32F103初始化程序、定时器程序、STM32F103和ATT7022E接口程序以及通信程序设计。
3.1 TIM2定时程序设计设置STM32F103通用定时器Time2工作在定时器模式,计数方式为从低至高,数据载入方式为16位自动重装载,使能定时器溢出中断,20ms中断一次。
基于dsPIC30F3013的三相多功能电表前端设计
基于dsPIC30F3013的三相多功能电表前端设计1. 引言基于模拟器件采样的多功能电表由于受模拟器件性能上的限制,无论在功能上还是线性度上以及校准手段上都存在着比较大的缺陷。
如今,随着芯片技术和数字信号采样处理方法和精度的巨大进步,基于微处理器的数字化测量方法逐渐取代传统的测量方法。
这种方法利用ADC 采样把模拟信号转变成数字信号,然后在微处理器中对采样的数字信号进行处理。
利用微处理器强大的数据处理能力,不仅能够测量电压、电流等常规参数,还能计算出有功功率、无功功率、功率因素、电能以及谐波和畸变率等重要参数。
另一方面,可以利用软件技术进行测量参数的校准和补偿,从而有效地减少了硬件电路所引起的测量误差。
因此数字化测量方法成为当前电表参数测量的重要方法和发展趋势。
2. 系统结构整个设计的框图如下电压和电流输入信号分别采用电流型的互感器连接到测量模块,电压互感器(PT)采用北京星格测控技术公司的SPT204B,非线性度小于0.1%,额定输入/输出2mA/2mA。
电流互感器(CT)采用SCT220B,额定输入/输出为20A/2mA,非线性度小于0.1%,线性范围0-80A。
由电压电流传感器输出的信号,经过信号调理电路被整体抬高2.5V,这是因为在AD 转换芯片的Vref 参考电压的值为2.5V。
然后这六路信号输入到AD73360 进行ADC 转换。
AD73360 是一款6 通道AD 转换芯片,6 个通道同步采样,这样就保证了三相电压电流采样数据的同步性,采样后的数据在微控制器中可以方便地区分分相电压电流的相位差。
本设计采用同步采样方法进行参数测量,AD73360 输出的标准参考电压2.5V,输入到射极跟随器,输出的2.5V 电压作为抬高信号的参考源。
这样6 路信号同步输入AD73360 后进行AD 转换,AD 转换后的数字信号通过标准SPI 接口从模式和dsPIC30F3013 相连,把6 路数字信号实时同步输入到dsPIC30F3013。
一种基于单片机的新型三相多费率电能表的设计外文文献及翻译
always adopts mechanical tinplate to measure. There are some shortcomings that the measurement precision falls with machine abrasion, single time period setting and strong manpower [2]. In this paper, we propose a novel multi-rate three-phase watt-hour meter based on AT89LV52. This multi-rate three-phase watt-hour meter adopts AD7752 for measurement. It has the characteristics which are time-sharing measurement, accurate measurement, LCD display, automatic meter reading, flexible time period setting, timely emendation, low cost and novel design.II. STRUCTURE AND WORKING PRINCIPLEThe novel multi-rate three-phase watt-hour meter proposed in this paper is based upon AT89LV52 singlechip [3]. AT89LV52 has the flash memorizer with 8k bytes, cryptographical program memorizer with third class, RAM with 256 bytes, 32 programmable I/O lines, three time/ counter with 16 bits and a two class halt with six vectors. The interface circuit adopts I2C bus unit which is a 8 bits singlechip with good performance and suitable price. The system structure diagram is shown in figure 1.Figure 1. System structure diagramThe principle of this multi-rate watt-hour meter is reading in themulti-rate time segments using RS485 bus and noting in X25045 then take over correctional clock with RS485 bus and write in clock CMOS chip S3530A. Thethree-phase AC voltage and electric current pass through potentiometer and mutual inductance instrument respectively so as to produce small signal which is sent to AD7752 to complete measurement. The clock CMOS chip S3530A gives clock information per second in the course of automatic move and analyze this clock belongs to which period of time according to advance periods of time set in X25045 then save the electrical energy in RAM memorizeraccording to corresponding period of time. We write it to corresponding address of X25045 when the electrical energy achieves one degree in order to make the multi-rate measurement come true. This watt-hour meter hasfunctions of clear LCD display, missing phase detection, burthen control, halt electricity check and storage, automatic meter reading and so on.III. THE DESIGH OF HARDWARE CIRCUITA. Electrical energy measurementThe three-phase electrical energy measurement is realized by the low consume CMOS chip AD7752 of ADI company. The inside of AD7752 adopts digital circuit besides ADC, filter and multiplication circuit which can eliminate noises effectively. The sampling course of voltage and electric current in three-phase AC power supply loop is shown in figure 2 in which IA stands for voltage sampling of A phase. The sampling circuits of B phase and C phase are similar to A phase. The power after integral is transformed to electrical pulse for output. The pulse of fan-out CF enters into interregnum INT0 of AT89LV52 through photoelectricity insulation 4N25. CPU measures the electrical energy [4]. We adjust the pulse number of CF by combining the state of S1 and S2. The connection of electrical energy and pulse is W = M C . In which, W is the electrical energy with the unit of kilowatt-hour, M is the total pulse number, C is the pulse number of ammeter. We choose C equals to 3000 that is to say every kilowatt-hour is 3000pulses.Figure 2. Circuit schematic diagramof watt-hour meterB. LCD displayThe LCD display [6] adopts HT1621 CMOS chip of HOLTEK Company toachieve twelve bits digital display. HT1621 is the LCD drivers with 128 segments (32× 4) inner memorizer. The interior of HT1621 consists ofcontrol and time circuits, RAM, LCD drive and watch timer. It hasthe merits of small volume and low cost so that it is suit to watt-hour meter. We use serial interface which only has four lines between HT1621 and AT89LV52. The detailed connection is shown in figure 3. P20, P21, P22 and P23 of AT89LV52 connect to CS, RD, WR and DATA respectively with the use to refurbish the display of RAM. HT1621 drive CMOS chip has 48 nodes in which COM0, COM1, COM2, COM3 connect to the communal end and drive output of LCD and SG0, SG1, SG2, SG3 connect to drive output of every segment respectively. In addition, an adjustable resistance of 20kΩ isput between VDD and VLCD to adjust the display contrast of LCD. Experiment shows that the contrast is better with VDD=5V and VLCD=4V.C. Serial memorizerSerial memorizer adopts low power consumption chip X25045 of XICORcompany .It has three functions which are watchdog timer WTD, voltage supervision and serial memorizer E2PROM with 512 bytes. WTD can be set 200ms, 600ms and 1400ms time intervals. The software program is read into X25045. During the normal running of program, WTD receives the trigger signal in time intervals in order to ensure the normal running of program. X25045 will output a high potential through RESET line if WTD does not receive trigger signal in time intervals. The trigger watt-hour meter reset in order to prevent program flying away. As the serial memorizer chip, 512 bytes of X25045 are used to storage the watt-hour meter code, multi-rate periods of time, the apex electricity, smooth electricity, vale electricity and total electricity of last month and this month. Storage can be divided into two same areas. One is used as data storage. The other is used for backup. The number of storage can be revised 100,000 times. Data can be stored for 100 years. It is connected with AT89LV52 by SPI agreement bus. The connection is shown in figure 3.D. Clock circuitThe clock circuit is completed by S3530A chip. It is a low powerconsumption clock chip that supports I2C Bus. It sets the clock and calendar according to the data received by CUP communicating with RS485. At the same time, it continues to walk time by its own oscillation. The crystaloscillator of 32.768 kHz is put between Xin and Xout of S3530A which is connected with CPU through latching. SDA foot and SCL foot connect to P1.6 and P1.7 of AT89LV52 respectively. There are two interrupt alarming foots can be set as second output or minute output synchronizing pulse which supply interrupt signal to AT89LV52 with one second period. Single-chip system will readout the current time through I2Ccommunication interface according to this signal and calculate the period of time that this moment belongs to so as to realize the electrical energy measurement in different periods of time [5]. This clock circuit has spare lithium battery. The powersupply VCC supply power in normal wiring and electrified for lithium battery of 3.6V. When there is power off, the system will automatically convert lithium battery to clock circuit for power supply. The clock will still running accurately even the power is off.Figure 3. Partial circuit figure of watt-hour meterE. RS485 CommunicationMAX485 chip can implement RS485 communication control ofmulti-rate watt-hour meter. MAX485 chip has RS485 communication protocol. It can take 128 hypogenous computers. Its transmission distance is greater than 1km and its transfer rate is up to 250kb per second. The watt-hour meter connects with the unit controller through the RS485 bus. Each unit has a cell controller can manage 128 multi-rate watt-hour meter. The cell controller connects to power management computer. Each watt-hour meter has one and only meter number with eight bits of hex.The electrician should write the user’s information and meter number and then import to the power management computer for initial installation so ad to complete the connection of user and management computer. Management computer sends setting of period of time and clock information with the manner of broadcast communication without address information. PC uploads information by the way of calling address. F. Lack Phase detection and relay controlIt can achieve relay control [7] with P27 of AT89LV52. P27 cancontrol relays using 4N25 photoelectricity isolator so as to complete powersupply and power control. Lack Phase detection gets the signal from fan-out of the relay and connects to 1 foot of photoelectricity isolator after passing a 75K resistance, the diode half-wave rectifier and capacitive filtering respectively. We detect the 4 foot of isolator to determine whether there is the lack of phase. If there is lack of phase, we detect again after 2 seconds overtime. We break off the power immediately if there is lack of power after the twice confirmation. In power protection circuit, it uses the INT1 interrupt foot of AT89LV52 to detect signal.When there is a sudden power off, INT1 jumps into a low voltage and the INT1 interrupt enters to the power protection program relying on the energy storage capacitor to save data. In the system, pulse output of AD7752, relay control port and the inputs of lack phase detection all use photoelectric isolator 4N25. It sends electrical signal by light coupling which can enhance the ability of anti-jamming.IV. THE DESIGN OF SOFTWAREA.The distribution of resourceThe software program includes main program, X25045 read and write program, RS485 serial communication program, interrupt serve program, timer handling program, HT1621 display control program, electrical energy measurement in different period of time and power down protection program, and system self-checking andanti-interference handling program. Interrupt resource distribution of system is:INT0 interrupt is used as AD7752 pulse measurement, INT1 as synchronization detecting, timer T0 as 100 ms timing, T1 as 1ms timing, and T2 as baud rate generator for serial communication program. RS485 asynchronous communication is set to receive interrupt and check information for sending.B. Module desighThe flow chart of main program is shown in figure 4. The watt-hourmeter should be able to initialize at each power up time. The initializing program includes setting working mode of timers, serial stomata and interrupts for AT89LV52, writing control word into X25045, S3530A and HT1621. This system sets three periods of time. The singlechip reads clock value from S3530A per second then analyze this clock belongs to which period of time according to advance periods of time set in X25045 then save the electrical energy in RAM memorizer according to corresponding period of time. We write it to corresponding address of X25045 when the electrical energy achieves one degree. The LCD display with 16 bits shows period of time and electrical energy information in turn.Figure 4. Flow chart of main programV. TESTING RESULTError measurement and running test have been made in Zibo Billion Electron Co., Ltd. The epigenous computer completes the setting of time management. There are three-rate period of time. The first period of time is vale electricity from 00 point 00 minute to 06 point 30 minutes. The second period of time is apex electricity from 06 point 30 minutes to 22 point 30 minutes. The third period of time is smooth electricity from 22 point 30 minutes to 24 point 00 minute. The setting of rate period of time is sent to computer management system by electric power company according to national policy and saved in X25045. The apex electricity, smooth electricity, vale electricity and total electricity per month read saved in electrical energy meter and sent to epigenous computer through cell controller. The communication baud rate is 9600 bits per second. Thecheckout platform of 0.1 grade standard electronic power meter is used as standard meter and the multi-rate watt-hour meter is the testedmeter. Billion Electron Company has carried out testing according to different load running. The measured data is shown in table 1 with the burthen of 30kW.TABLE I. COMPARE OF NORMAL METER AND TESTING METERThe testing result indicates that the error of this multi-ratewatt-hour meter is less than 1%, belongs to 1.0 grade. The return reading of electrical energy is precision and the emendation of time is timely and right. By testing, the method of decreasing errors for electricity metering can be obtained.Firstly, adjust the sampling resistance of AD7752 to accurate value. Secondly, the value of this resistance is needed less varying with temperature. Thirdly, during electricity metering progress, when mantissa portion of electricity is less than 0.01, the remaining pulse should be accessed together, thus cumulative error caused by lack of 0.01degree energy loss could be avoided.VI. CONCLUSION AND EXPECTATIONThe multi-rate watt-hour meter achieves electrical energycomputation in different time according to different time setting. It adopts RS485 for serial communication and realizes automatic meter reading and real-time emendation. The results of production in Billion Electron Company showthat the multi-rate three-phase watt-hour meter proposed in this paper has the characteristics of novel design technique, accurate measurement, and flexible time period setting. Various technical indexes achieve the technique standard for national intelligent card watt-hour meter. Therefore, it has wide application. REFERENCES[1] Bu Zhengliang, Yin Xianggen, TuGuangyu. “Development of HV Watt-hour meter.”Automation of Electric Power Systems, 2006, 30(19): 89-93.[2] Kosukegawa M., Sakumoto Y. “Traceability system of electric energy standard and tendency in static watthour meter development in Japan.” Sixth International Conference on Metering Apparatus and Tariffs for Electricity Supply, 1990,4: 259-263.[3] Xuehai Li. Applied tutorial of singlechip. Electronic industry publishing company, 2003.[4] Al-Khateeb Tarik, Blundel Martin. “An electronic meter for measuring the saving in electrical power.” The Ninth Arab International Conference on Solar Energy (AICSE-9), Kingdom of Bahrain, 2007,4 (209):328-333.[5] Liu Ying, Liu Qingyu. “Development of a self-calibration precision electrical measuring meter.” Proceedings of the 1998 Conference Precision Electromagnetic Measurements, 1998,7:276.[6] Gao Yun-Peng, Teng Zhao-Sheng, Liu Peng. “Design of three-phasemulti-functional harmonic energy meter.” Journal of Hunan University Natural Sciences, 2008, 35(9): 53-57.[7] QuQingchang. “Key technology to three-phase electric meter and high voltage electric power measurement.” ActaMetrologicaSinica, 2007, vol28: 25-30.一种基于单片机的新型三相多费率电能表的设计Jishun Jiang Lanlan YuSchool of Electric and Electronic Engineering School of Electric and Electronic Engineering Shandong University of Technology Shandong University of Technology Zibo, 255091, China Zibo, 255091, Chinayulanlan124@摘要:随着社会的发展,对电力的需求变得越来越大。
基于ADE9000的三相电能计量与质量分析系统的设计
基于ADE9000的三相电能计量与质量分析系统的设计黄艺璇;罗利文【摘要】根据国家电网对智能电能高精度、多功能和网络化的要求,文中介绍了一种基于ADE 9000的三相电能计量与质量分析系统的设计方案.ADE 9000是一款高度集成的三相模拟前端,内部集成高精度24位ADC和DSP内核,实现了多种电能参量的高精度计量.在STM32主控芯片的管理下,结合LabVIEW上位机实现电能计量和谐波分析的功能.文章详细介绍了系统总体框架,硬件电路及软件程序设计的具体方法,在多个设计环节体现出对高精度和网络实时性的要求.【期刊名称】《电测与仪表》【年(卷),期】2018(055)023【总页数】6页(P1-6)【关键词】电能计量;高精度;谐波分析;ADE9000;STM32【作者】黄艺璇;罗利文【作者单位】上海交通大学电子信息与电气工程学院,上海200240;上海交通大学电子信息与电气工程学院,上海200240【正文语种】中文【中图分类】TM9330 引言随着智能电能网发展的趋势,国家电网公司推出的Q/GDW 356-2009《三相智能电能表型式规范》[1]等相关企业标准,对智能电能表提出了更高的技术要求。
智能电能表从普通功能型向长生命周期、高测量精度、分时段计量计费、多功能、网络化等高科技含量和高附加值的方向发展。
智能电能表在电能计量方面的准确性,直接关系到电力系统发电量,供电量,用电量等各项技术经济指标的计算。
同时越来越多的电子设备接入电网,系统中产生的大量谐波,降低了电能质量,所以在保证电能表精确计量电量的同时,不能忽视谐波计量和分析的重要性。
1 系统总体设计设计了一种电能计量与质量分析系统,可以准确计量电能参数,快速进行谐波分析。
总体设计如图1所示。
该系统选用STM32F401RET6为主控芯片,32位的ARM CortexTM-M4内核完成外围芯片控制、数据传输和上位机通信控制。
选用某公司一款高集成度的三相模拟前端ADE 9000实现电能计量,该芯片集成七路高性能的和一个DSP内核,可实现三相电压电流及中线电流信号每周期128个采样点的输出。
三相多功能电能表 A设计方案
三相多功能电能表摘要:本设计以ATMEGAL16单片机作为核心控制器件,采用高精度三相电能计量芯片ATT7022B对三相交流电压电流信号进行采样处理,处理后数据送至单片机进行进一步校正处理,得到三相电流、三相电压、三相有功功率、三相有功电能等参数,并在液晶12864上按键选择实时显示,并打印。
系统同时具有RS485远程数据传输、红外通信、掉电保护、密码保护、相序检测等功能。
经测试,系统功能齐全,测量精度,过载能力等均达到设计要求。
关键词:三相电能计量; ATT7022B一、方案设计与论证1.题目分析题目要求设计并制作一个多功能三相电表。
综合分析,本作品的设计可以细分为以下几个模块:电源模块,控制器模块,键盘及显示模块,数据采集与存储模块,RS485通信模块,红外通信模块。
2.方案比较与选择(1) 控制器模块方案一:采用采用Atmel公司的A T89S52单片机。
AT89S52低功耗,高性能, 但其本身功能较少,需要增加较多的外围电路来实现功能。
方案二:采用A VR系列单片机的Megal16.。
Megal16单片机是16位MCU,运算处理速度快,抗干扰能力强,稳定性高,同时A VR 单片机内部有EEPROM,可以监控MCUCSR寄存器来发现掉电和复位情况,通过外围掉电检测电路就可以实现掉电存储保护。
考虑到本系统要求较高的运算处理能力以及抗干扰能力,最终选择方案二。
(2)采样电路选择现有测量芯片无法直接对高电压、大电流进行测量,故需要对这两个量进行采样。
方案一:采用电阻分压对电压电流进行采样。
这种方法简单易行,电路结构简单,但对电阻精度要求高,浪费在分压电阻上的能量多,不符合节能要求;同时这样对电流采样会改变原有电流参数。
方案二:采用互感器对电压电流进行采样。
这种方法稍微复杂,但优点很多。
一方面互感器对电流参数采样能够最大程度减少对原电路特性的改变。
另一方面,互感器有一定隔离作用,对独立处理后级电路有益。
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
B I YE SHE JI(20届)基于加密IC卡的多用户三相电能计量系统的设计所在学院专业班级自动化学生姓名学号指导教师职称完成日期年月摘要本设计是一个基于加密IC卡的多用户三相电能计量系统,对用户的用电量进行计量。
用户通过到相关部门买电,把所购买的电量存入IC卡内,通过本系统就能实现“谁插卡,谁用电”的功能。
在过去很长的一段时间里,由于科学、资金等因素的限制,电力部门一直都在使用机械式的电能表,后来经过长时间的发展有了石英式的,但是它们都存在着严重的不足,因为它们都是依靠人工进行数据的抄读,不管是在时间性或者准确度等方面都是达不到要求的。
而且这些都是依靠机械电气的原理来制成的,从其构造来看,电表的放置角度、机械磨损、温度等原因都会产生很多误差,为了解决这一系列的问题,电能表的发展在人类的智慧下不断前进。
设计一个电能计量系统,以STC单片机技术为核心,采用SLE4442加密IC卡芯片与单片机相连实现掉电卡内数据存储,可以存储20户以上信息,而且存储年限可达十年以上。
电能测量电路则以AD7752芯片为核心,进行三相电能的计量,采用HT1621液晶显示用户用电量及加密IC卡的余额。
同时用单片机接口接入声光报警电路,当IC卡内余额不足时LED灯闪烁,蜂鸣器响起以提醒用户买电。
而在卡内余额为零的时候通过继电器控制电路进行断电操作,这样就能通过调节计量显示精度等方法解决电能计量过程中出现的很多问题,推动电能计量的不断发展。
关键词:电能计量,单片机,IC卡IAbstractThe design is a three-phase energy metering IC card-based multi-user system, the power consumption of the user of the measurement. Users to the relevant departments to purchase electricity from the purchase of electricity stored in the IC card, "Who card, who is electricity," the function of the system can be achieved.In the past for a long period of time, due to the limitations of science, capital and other factors, the power sector has been in the use of mechanical energy meter, and later after a long period of development have quartz type, but they are there are serious deficiencies because they rely on manual data copy read, whether it is in time, accuracy and other aspects are not. These are made to rely on the principle of mechanical and electrical, from its structure, the meter placed the point of view, mechanical wear, temperature and other reasons will produce many errors, in order to solve the problem in this series, the energy meter in the human the wisdom to continue moving forward.Design an energy metering system, STC SCM technology as the core, using SLE4442 IC card chip with a microcontroller connected to the data stored in the power-down card, you can store more than 20, and the storage life of up to ten years. Power measurement circuit while the AD7752 chip as the core three-phase power measurement using the HT1621 LCD user with the balance of power and encrypted IC card. MCU interface to access the sound and light alarm circuit, when the IC card balance is less than the LED flashes, the buzzer sounded to alert the user to purchase electricity. The card balance is zero when the relay control circuit power, so that we can solve many problems in the energy metering process by adjusting the metering display precision, to promote the continuous development of the energy metering. Keywords: energy metering, microcontroller, IC cardII目录摘要 (I)ABSTACT ........................................................................................................................................... I I 目录 (III)第一章绪论 (1)1.1 课题研究背景 (1)1.2 电能表发展现状 (2)1.3 课题研究意义 (3)1.4 设计内容及要求 (4)1.4.1系统的硬件设计模块 (4)1.4.2系统的软件设计模块 (4)1.4.3主要设计技术指标与参数 (4)1.5课题实现功能及系统原理框图 (4)第二章课题关键技术 (6)2.1加密IC卡简介 (6)2.1.1加密IC卡概述 (6)2.1.2 SLE4442芯片功能 (6)2.1.3 SLE4442工作原理 (6)2.2 SLE4442引脚说明 (7)2.3 IC卡的掉电存储 (8)2.4电能计量精度的提高 (9)第三章系统硬件设计 (11)3.1 STC12C5A60S2芯片 (11)3.1.1 STC12C5A60S2的主要功能 (11)3.1.2 外部管脚说明 (11)3.2电能计量电路 (15)3.2.1 AD7752芯片 (15)3.2.2 AD7752的工作原理 (16)3.3显示电路 (18)3.3.1 HT1621特性简介 (19)3.3.2 HT1621驱动原理 (19)3.3.3 HT1621管脚说明 (20)3.4 电源电路 (22)3.5 继电器控制电路 (23)3.6 声光报警电路 (24)第四章系统软件设计 (26)4.1 系统资源分配 (26)4.2 初始化程序 (26)III4.3 主程序流程图 (26)4.4 子程序流程图 (28)4.4.1 电能计量模块程序流程图 (28)4.4.2 显示模块程序流程图 (29)4.4.3 IC卡读写处理流程 (30)第五章调试与误差分析 (31)5.1 电能计量装置常见问题 (31)5.2 误差分析 (32)总结 (33)致谢 (34)参考文献 (35)附录 (36)IV第一章绪论1.1 课题研究背景随着社会生活的发展,居民的生活越来越离不开电,自然对用电的需求量就会日益增长,与此同时,牵涉到电能的交易也变得越来越常见。
而电能表又是确定使用的电能量的多少的工具,所以对电能表的技术要求就会很高,要在保证检测准确的同时,做到使系统长期稳定可靠。
18世纪80年代,伟大的科学家爱迪生通过对电能表的工作原理的进一步研究扩展,终于制成了安培计。
80年代末,匈牙利的一位著名的德国人布勒造出了通过感应原理计数的电能表,但是不足之处是它的总重量高达36.5kg。
从此以后,靠感应原理工作的电能表就在应用中占据了重要的位置。
靠感应原理工作的电能表具有很多优点,它构造简单、价格很低、检修容易、最重要的是它操作风险小;但与此同时它也存在很多的缺点,就像功能很少、使用频率范围不够宽、精度低等。
随后,18世纪80年代中后期,发现了交流电,并得到进一步的广泛应用,这就给电能表的发展提出了更高的要求,相关的交流式电能表也就在此时应运而生。
在后来的时间里,电能表的发展主要着力于体积的进一步减小和各种性能的改善等方面。
当时,国外电能表受负载大于可承受的范围的性能已经高达600%,它们还所用了两种宝石所制成的轴承和通过磁力原理得到的轴承,使得电能表的寿命可以延长到15-30年[1]。
以微型电子技术为基础的电子行业空前发展,这就要求电能的检测和累计精度越高越好。
因为以机械工业为基础的电能表的使动线圈存在频率带范围比较小的缺点,对于除了最低阶波以外的各个阶次的谐波功率信号难以将其转换成相同比例的力矩去供给各种系统,这就致使以感应特性制成的电能表对具有冲击性的负载的累加和计算存在很多问题。
而以机械性能为基础的电表又存在误差大、无法扩展各种功能等诸多缺点,这就导致以感应性能为基础的电能表的发展原地停止不前。
以电子性能为基础制成的电能表也因此诞生,而且其优越性显得更加重要。
后来,电能表逐渐发展,实现了容易实现多功能、误差小、抄表方便自动化、具有当前最高级的通讯接口等功能。
这样在促使各种高技术- 1 -电能表得到飞速发展的同时,机电一体化的电能表也迅速发展起来。
如:分开不同时段计费而且是多种不同收费比率的电表、多条支路的能实现最大需求量的电表、可以输出脉冲的电表、可以确定电能数量的机器和能实现先付费买电再用电以电卡为媒介的电表,它们在研究机电一体式电表的基础上经过扩展而制成的。