Early Warning of Electric Characteristic Parameters on Electric Power System Based on Embedded System

In order to avoid the operation accidents of power system caused by the influences of various artificial or nature factors, the paper explored the early warning of characteristic parameters on power system based on embedded system. In the paper, it taken a 110kV substation as an example, studied on the related algorithm of the electric characteristic parameters, constructed the hardware and software platform based on embedded microprocessor, and designed the hardware circuit and software control program. The commissioning test demonstrated that it could accurately judge the latent fault of related devices, and send correctly the trip command to make the isolation between the fault device and the power system so as to protect the system from being damaged. The experiment results show that it is effective and available to early warning of power system.


INTRODUCTION
Once the power system is suffered from the influences of various artificial or nature factors, it probably comes into the abnormal running state, and leads to the decrease of the quality of power supply and user outage or device damage, even all kinds of unexpected accidents such as life or personal injury and so on. If it can in advance be detected to the characteristic parameters of the system operation state, when it deviated from its normal running condition, the early warning or tripping command can be sent out to make the fault device automatically be isolated from power system, then the power system can be protected from damage. This means that it first must conduct the operation parameter measurement, followed by the logic judgement of electrical characteristic parameters, and the last is how to make the execution. If it runs in the status of abnormal warning or tripping, then it must isolate the fault, so the relay protection device owns the important significant. In power system, the electrical characteristic parameter measurement is the most important. (ZHOU Jiaping, 2006) has carried out comprehensive research on this, and a number of research achievements have been obtained in the online detection and calculation (LIU Yamei, HUI Jin, YANG Honggeng, 2012. MEI Fei, 2014.). In order to improve the degree of intelligence and network of relay protection device, combined with the engineering practice based on embedded Linux system, the following explores the related topics briefly

ALGORITHM OF SYSTEM CHARACTERISTIC PARAMETER
In the field measurement, the actual sampling is always the instantaneous value, for how to calculate the the actual parameters from instantaneous value, there is a variety of algorithms. Here, it only adopts twopoint product algorithm and recursive fast Fourier algorithm as an example to illustrate the calculation principle briefly

TWO-POINT PRODUCT ALGORITHM
Taking the voltage calculation as an example, ω, T is respectively the angular frequency and cycle, the sampling value separated by π / 2 at sampling time n 1 and n 2 is u 1 and u 2 respectively, namely ωT (n 2 -n 1 ) = π / 2. From the above, it can deduce the effective value of the voltage U and the initial phase α 0 ν.
It is to say that if the instantaneous value of the sinusoidal quantity of two separated π / 2 is known, then the effective values and phases can be calculated.
If the voltage and current u 1 , i 1 , u 2 and i 2 at sampling time n 1 and n 2 can be measured simultaneously, it can find the effective value I of the current and the phase angle α 11 at sampling time n 1 . Therefore, the mode z and angle α z of the complex impedance can be obtained.
The above calculation is based on sine wave, and the algorithm itself is obviously not related with the sampling frequency. Due to the grid can't be pure sine wave signal, so it must be used together with digital filter, so the sampling frequency is determined by chosen filter commonly. It is worth pointing out that the length of data window can be arbitrarily selected, the two sampling points don't have to be separated by π / 2, but the calculation is a little more complicated.

RECURSIVE FAST FOURIER ALGORITHM
Because the calculation workload is relatively small, the algorithm application is more in the LCD real-time display calculation, because of its order according to measurement data, with the aid of recursion method it can modify the original valuation, and its valuation correction and the data sampling is simultaneous (WANG Jianze, YANG Mei, JI Yancha, 2003.). If x(n) (n = 0, 1, …, N-1) is the corresponding sampling discrete time signal, Discrete Fourier transform is defined as the following.
According to the same way, the sampling point x(n) (n = 1, 2, …, N) moves one data back, by using the definition, the following is available.
The above is the Fourier transform of sampling point x(n) after a sampling point moved back, and through the comparison, the final expression can be obtained.
From the final expression, it can be seen that it only needs the addition of one complex number and one real number and the two complex number multiplications, so the operand of the recursive fast Fourier algorithm is significantly reduced.

HARDWARE PLATFORM DESIGN
Taking a 110kV microcomputer line protection system as an example, the hardware platform of the embedded electrical parameter monitoring system is shown in figure  1. Among them, with the aid of data communication, the man-machine control circuit and microprocessor will send the relay operation parameters and the electrical data to the LCD display. In addition, the upper computer PC can conduct direct data interaction between the main circuit and protection monitoring system.   When the input signal is sent to the main module by the transformation of low voltage signal, then through the sampling, operation, analysis and processing of MCF5282 microprocessor, if the protected object status is judged as the abnormal, then it sends up a tripping signals, and by means of data communication way, the protection action information will be directly sent into the upper computer PC and management templates so as to record and save the data and make early warning. Due to the embedded platform is versatile, although the protection object (such as transformer, motor or other control devices) are not identical, as long as its corresponding software is changed then it can complete the protection functions. MCF5282 is a 32-bit RISC microprocessor. In order to reduce the peripheral components of MCF5282 and improve the reliability of the main template, also it can conduct the exchange information by means of the I/O port or functional port.

ANALOG INPUT CIRCUIT
In analog input circuit, the voltage square wave form circuit is used to detect the voltage frequency, frequency difference and phase difference. In order to get better signal to the analog input channel, aimed at the AC/DC, it respectively adopts the configuration of the RC and RLC passive filter circuit.

SWITCH I/O CIRCUIT
The signal input and output signals are designed on the main template. Among them, the switch signal input is sent to MCF5282 I/O port via the optical isolation chip TLP521. The output signal from the MCF5282 microprocessor controls the relay action in the output template by the driver.

MAN-MACHINE INTERFACE MODULE
This module includes data communication, keyboard, LCD, USB, print interface, etc. In the design, it adopts LPC2294 of ARM7 kernel to implement the data exchange. LPC2294 is a 16/32 micro-controller of ARM7TDMI-S, if the code size is strictly controlled, the 16-bit Thumb model can be used to reduce the code size by less than 30% when the performance loss is minimal. Figure 3 shows the main frame of the software system (HONG Yan, 2007). As long as the corresponding subfunction module is called, the relevant function module task can be completed. After the power reset on the system, the working conditions are first set. In turn, the inside and outside of the "guard dog" is initialized. Secondly, to determine sampling interrupt time for analog samples, after completing analog sampling, and then it conducts the electrical parameter calculation and judgment, such as abnormal operation, the warning or fault handler. In fact, as shown in figure 3, not all operations must be executed every time, and the exchange and read of related data is completed by the interrupt program. Figure 4 is the interrupt processing flow of each electrical parameter A/D conversion. Taking some substation as an example, there are 8 DC channels and 16 AC channels in 24 channels. After completion of the conversion, the channel A/D conversion is started by the timer cycle. Counter pointl is used to hold the sampling number when the parameters of a complete cycle 24 points have been measured, after the completion of a complete cycle sampling, the logo adflag is 2, and its pointl count is 24, it shows that the main program can invoke its measurement parameters calculation subroutine. What is particularly noteworthy here is that in figure 4, the new A/D sample values are saved only when the adflag is 1. When after calculating the measurement parameters of a cycle, the main program will automatically set as adflag1, it shows that a cycle measurement parameter calculation has been completed, and the counter pointl will reset so as to hold the next cycle of A/D conversion result. Executing interruption program time is as short as possible, to facilitate the CPU more time to deal with other tasks, therefore in programming, point2 sampling number is used for statistical parameters. When it's been the odd number time sampling, it calls protection judge subroutine so as to calculate and save the protection parameters. When it is sampled even, the system is actually idle. After a period, the point2 is automatically cleared. During this period, the program does not process any measurement data.

MAN-MACHINE INTERFACE PROGRAM
As mentioned above, man-machine interface module functions (such as printing processing, keyboard processing, LCD display, etc.) are mainly completed by the ARM7 kernel LPC2294. Here, it is worth noting that the data communication between each other is completed by means of execution interruption, and its humanmachine interface program is shown in figure 5.  Figure 5 Man-machine interface program

CONCLUSIONS
Electric characteristic parameters is the premise to judge the safe and stable operation of the power system, and it is developing towards to comprehensive automation, network and intelligence of the parameter measurement. The above takes a 110 kV microcomputer line protection system as an example, explored the electric characteristic parameter algorithm, designed the hardware platform of embedded system and main body framework of software, and gave the relevant procedure block diagram. The online experiment of the above designed system shows that it can realize the early warning of electrical characteristic parameters, and correctly control the operation of the system, and the operation speed is fast and the error is not more than 0.1%. When the sampling points are selected as 24 points on a weekly wave, its fast response protection time is within 1.67ms, so that the fault device can be quickly isolated, thus protecting the power system from damage.