2010年2月1日星期一

196 Series MCU in the use of air conditioner inverter (part 1)

196 Series MCU in the use of air conditioner inverter (part 1)




0 Introduction



With the rapid development of the domestic economy, air-conditioned cars, luxury cars, has entered a new stage of development. Air conditioner inverter is a new and efficient non-polluting "green" energy, its application prospects are very bright.



SPWM power inverter air-conditioning technology is the major control technology, to generate SPWM pulse often used in two ways: first, from the analog circuit generation; second is generated by the microcontroller and other digital circuits. The former circuit complex, anti-jamming performance is poor, there is drift phenomenon, system reliability and consistency is low; digital real-time calculation methods are the use of computers, so that system-wide coherence is high, useless drift phenomenon, while debugging the workload greatly reduced. INTEL has introduced 16-bit microprocessor N87C196MC/MD is designed to set up low-cost microcontroller motor drag chips, chip integrates a three-phase waveform generator WFG (Wave Form Generator), the peripheral device greatly simplifies the generate SPWM waveform control software and external hardware to complete the entire control circuit is very simple.



1 N87C1 96MC-chip waveform generator Introduction



1.1 WFG's features



N87C196MC chip WFG has three synchronized PWM modules, each module contains a phase comparison register, a time of no signal generator, and a pair of programmable output, that is, WFG can produce three pairs of six independent PWM waveforms, which have a common carrier frequency, no signal timing and mode of operation. Once the working later, WFG only requires changing the PWM duty cycle of the microcontroller when WG COMPX register assignment can be changed.



SPWM waveforms generated WFG is under the control of the following special registers completed.



a. Two-way count register WG COUNT. 16-bit bi-directional counter is a 3 on the output signal time base generator. It is the oscillation frequency at a clock frequency of 2, each state change in a cycle of WG COUNT count. Users can register on the WG RELOAD write, and its value is periodically loaded into the counter.



b. Reload register WG RELOAD. The register actually contains a pair of 16-bit register, when read or write to the register, the access to the WG RELOAD register. Writes WG_RELOAD values were periodically (depending on the mode of operation) load to the second register. This latter is called a register counter compare register, which is WG_COUNT the time with which to compare the actual registers.



c. Phase comparison register WG_COMPx. A total of 3 (X = 1,2,3) can read and write buffer 16-bit phase comparison. Each buffer has an associated phase comparison comparison register, and its value WG_COUNT after each count compared. These registers can not be directly accessed by the user.



d. Control register WG_CON. WG_CON is a 16-bit register. Can control the counting method and production of three 10-bit non-signal time (deadtime). The use of non-signal time to re-load the registers can be changed at any time without the signal time.



e. Output control buffer register WG_OUT. Output pins can be used to select the output signal mode. Each pin can independently define a valid state.

1.2 WFG the basic working principles of



a. From the function, WFG can be divided into three parts: the time-base generator, phase-driven channel and control circuitry.



(1) the establishment of time-base generator for the PWM carrier cycle. The cycle of value depends on the value of WG_RELOAD;



(2) phase-driven decision-channel PWM waveform's duty cycle, a total of three separate phase-driven channels, each channel has a programmable output drive for each phase includes a programmable time of the non-signal generator;



(3) The control circuit contains a number used to determine the operating mode and other configuration information registers.



b. Time-base generator WG_COUNT are four kinds of work. Elected to pass waveform generator work, according to the choice of working methods, as a time base generator WG_COUNT continuous upward counting or up / down counting, counting each time, WG_COUNT content and count the value of compare register WG_RELOAD comparison, as the two match, according to the chosen way of working to produce operation.



We generally choose the first 0 kinds of operating modes, the center aligned PWM mode:



Carrier cycles Tc = (4 × WG RELOAD) / Fxtal (μ s)



No signal without regard to time, the output of "effective" time Toutput = (4 × WG_COMPx) / Fxtal (μ s).



No signal without regard to time, duty cycle = (WG COMPx / WG RELOAD) × 100%.



XTAL1 pin, which Fxtal the crystal frequency, MHz; WG COMPx for the 16-bit value, equal to or less than WG_RELOAD, if the value is greater than WG_RELOAD output duty cycle is 1.



We can see from the above equation, WG COMPX value of the change, changing the PWM duty cycle wave. The SPWM waveform is generated by the sine law of the data value has been assigned to WG COMPX calculated, and each interrupt is assigned to WG COMPX with a change in the value of the sine law, resulting in a series of pulse width ranging from SPWM wave.



c. WFG interrupts. With the waveform generator-related disruptions are two kinds: WFG interrupt and EXTINT interrupt. WFG interruption in the re-generated when loading WG COUNT. Approach 0 in WG_COUNT = WG_RELOAD generated when a WFG interrupt, each interrupt has produced a sinusoidally pulse wave, to form the SPWM wave.



EXTINT interrupt generated by the protection circuit. Programmable settings way is to generate interrupt edge triggered or level-triggered, when the control system detects over-current signal, microcontroller automatically blocked SPWM waveform, thus off IGBT, to protect the power electronic switching devices.



To learn more about power inverter, please visite http://www.szpowerinverter.com/ and http://www.bestekltd.com/, or mail to sale38@0102.cn.

没有评论:

发表评论