Saturday, January 29, 2011
【 Weak current College 】 MCU hardware design experience 】
(1) in the components of the layout should be interrelated components to put close to some, for example, clock generator, crystal oscillator, CPU clock input noise is easy to produce, in place of time should bring them nearer. For those who are easy to produce noise of devices, low-current circuit, high-current circuit-switching circuits, etc., should, as far as possible away from the microprocessor logic control circuitry and memory (ROM, RAM), if possible, can be made of the circuit in addition to facilitate anti-interference circuit board, improve the reliability of the circuit.
(2) as far as key components, such as ROM, RAM and other chip decoupling capacitor is installed next. In fact, PCB wiring, wiring and connector pin and so may contain large inductive effect. Large inductance might Vcc alignment caused serious switching noise spikes. Prevent the Vcc alignment on switching noise Spike's unique approach, is in the VCC and power between the places a 0.1uF e decoupling capacitor. If the circuit board using surface mount components, you can use the sheet capacitance directly next to a symbol, fixed in the VCC PIN. It is best to use ceramic capacitors, this is because such capacitors with low electrostatic dissipation (ESL) and high-frequency impedance, this capacitor temperature and time media stability is also very good. Try not to use tantalum capacitor, because in the high frequency of impedance under it.
Seated decoupling capacitor, take note of the following:
· In printed circuit boards of power input crossover 100uF of electrolytic capacitors, if volume allows, electrical capacity larger is better.
· In principle each IC chip are placed next to one of the ceramic capacitor 0.01uF, if the Board of the gap is too small and placement, the can around every 10 chips, place a 1-10 of tantalum capacitor.
· For a antijamming ability weak, turn-off time current change large components and RAM, ROM, and other storage components, should be in the power cable (Vcc) and ground between access decoupling capacitor.
· Capacitor leads not too long, especially high-frequency bypass capacitor cannot lead.
(3) in the microcomputer control system, the ground of many kinds, systematically, shield and, logically, analog, and whether the layout is reasonable, the ground will determine PCB anti-interference ability. In the design of the ground and pick up spot, you should consider the following issues:
· Logic and analog to separate wiring, can not be combined, will their ground with appropriate power ground wire. At design time, simulation of the ground should be bold, and try to increase the leadout area of the grounding. In General, for input and output of analog signals, and microcontroller circuit between the best isolation through optical coupling.
· In the design of logic circuits for printed circuit board, its ground-loop form should constitute, improve circuit anti-interference ability.
· Ground should be as rough. If the ground is very thin, ground resistance will be larger, ground potential with current changes, causing the signal level instability, leading to the descent of anti-interference ability. In the wiring space permitting, to ensure that the main ground of the width of at least 2 ~ 3mm above symbol pin grounded around the 1.5mm.
· It is necessary to pay attention to the choice of receiving stations. When the signal frequency is lower than on the Board, because of the wiring 1MHz and components between electromagnetic induction to low impact, and earthing circuit formation in circulating on the interference of the larger, so you want to use a little grounding, so it does not form a loop. When the signal frequency is higher than on the Board, because of the wiring 10MHz inductance effect obvious, ground impedance becomes very large, ground circuit formation of circulation is no longer a major problem. So should adopt more grounded, minimize ground impedance.
· Power cable in addition to the layout according to the current size as far as possible, bold line width, the wiring, the power cable and the ground of alignment direction and data line alignment to the parties as agreed at the layout of the final, with ground wire to the back of the circuit board without alignment of fill, these methods will help to strengthen the capacity of anti-interference circuit.
· Data line width and wide as possible, to reduce resistance. Data line width at least not less than 0.3mm (12mil), if you use 0.46 ~ 0.5mm (18mil ~ 20mil) is more ideal.
· Due to circuit board of a through-hole will create about 10pF of capacitive effect, high frequency circuit, will introduce too much interference, wiring, you should minimize the number of the hole. Again, too many hole also reduces the mechanical strength of the Board.
A microcontroller hardware circuit design contains two parts: one is a system extension that SCM internal functional unit, such as RAM, ROM, I/O, timer/counter, interrupt system does not meet the requirements of the application system must be extended outside the movie, select the appropriate devices, appropriate circuit design. Second, the system's configuration, that is, in accordance with the system functional requirements configured peripherals such as keyboards, monitors, printers, A/D and D/A converters, etc., to design the appropriate interface circuit.
System extensions and configuration should observe the following principles:
1. Select a typical circuit as possible, and in accordance with the MCU general usage. For hardware system of standardization, and modularization and lay a good foundation.
2, system expansion and peripheral configuration level should fully meet the functional requirements of the application system, and have a proper room for secondary development.
3. hardware structure should be considered in conjunction with application software programmes. Hardware and software solutions will produce mutual influence, considering the principle is: the software can achieve the functions of the software as much as possible, the real threat to simplify hardware structure. But it is important to note that the software and hardware featuresThe general response time than hardware implementation is long, and CPU time.
4. the system of related devices to ensure performance to match. If you choose CMOS chip MCU low power systems, system all chip should as far as possible, choose a low-power products.
5, reliability, and anti-jamming design is an essential part of the hardware design, including chips, device choice, decoupling filter, PCB wiring, channel isolation, etc.
6, microcontroller peripheral circuits are more, you must consider its drive capability. Drive capacity is low, the system is not reliable, can be enhanced through the addition of line drive driving capability or reduce the power consumption to reduce bus load.
7. as far as possible towards the "monolithic" direction design hardware system. System device, the device also mutual interference between the stronger, the power consumption increases, also inevitably reduce the system's stability. With the single-chip integrated functionality more and more strong, a real on-chip SoC can implement the system, such as the newly launched ST company μ P S D 32 ¡á ¡á series product in a chip integrates 80C32 nuclear and large-capacity FLASH memory, SRAM, A/D, I/O, two serial ports, watchdog, power-on reset circuit and so on.
SCM system hardware commonly used method of practice in anti-jamming
Affect the safe operation of the single-chip system reliable factors comes mainly from the system of internal and external electrical interference and protected by the system structure and design, component selection, installation, the manufacturing process. These constitute the single-chip system, often causing interferenceSCM system disorders, ranging from affecting product quality and yield, to cause accidents that result in major economic loss.
Form the basic elements of disturbance are three: (1) the source of interference. Means of interfering components, equipment, or a signal, using a mathematical language description: du/dt and di/dt Grand place is the source of interference. For example: Thunder and lightning, relays, SCR, motor, high-frequency clock, etc can become the source of interference. (2) propagation path. Means interference from sources of interference to access sensitive devices or media. Typical interference propagation path through the wires of conduction and radiation in space. (3) sensitive devices. Means easily interfere with objects. Example: A/D and D/A Converters Microcontroller and digital ICS, weak signal amplifiers, etc. Interference category 1 interference category interference category has a good variety, can often be the cause of the noise, transmission mode, waveform characteristics etc for different categories. The causes can be divided into the discharge: noise, high frequency oscillation noise, surge noise. By the way: transmission can be divided into common mode noise and noise series mould. By: waveform can be divided into continuous sine wave, pulse voltage and pulse sequences, and so on. 2 interference of coupling interference interference signal is coupled through a certain channel is an impact on measurement and control system. Therefore, I have the need to look at the source of interference and noise passed between objects. Interference of coupling mode, simply through the conductor, space, public line and so on, broken down, there are the following: (1) direct coupling: this is the most direct way is also the most widely present in the system. Such as the interfering signal through the power line breaking into a system. (2) public impedance coupled: this is a common way of coupling, it often occurs in two circuit current common pathway. In order to prevent this kind of coupling, usually in circuit design to consider. The source of interference and tampering with no common impedance between objects. (3) capacitance coupling: also known as electric coupling or electrostatic discharge coupling. Because of the existence of the distribution capacity of the coupling. (4) electromagnetic coupling: also known as magnetic coupling. Is due to the distribution of coupling of electromagnetic induction. (5) leakage coupling: This coupling is purely resistive, insulation is not good when it happens.
Common hardware anti-interference technology for forming the three elements of disturbance, interference of the following methods. 1 interference suppression of interference is possible to reduce the interference source du/dt and di/dt. This is a antijamming design of the highest priority and the most important principle, often has a multiplier effect. Reduce interference sources du/dt, mainly through the interference source to achieve parallel capacitance at both ends. Reduce the interference of the di/dt is interference source loop inductance or resistance and increase continued flow diode. Suppression of interference sources of common measures are as follows: (1) relay coil increase continued flow diode, eliminating broken coil of back-EMF. Only with continued flow diode will enable relay disconnect time lag, increase the Zener diode rear relay in unit time action more often. (2) the ends of the relay contacts and add spark suppression circuit (typically RC series circuit, general elections a few K resistor to dozens of K, capacitors selected 0.01uF), decrease the EDM. (3) to the motor and filter circuit, capacitors, inductors leads to short. (4) the Board each IC to and received a 0.01 μ F ~ than 0 μ F high-frequency capacitors to reduce the effect of the power supply IC. Note the high-frequency capacitance of wiring, wiring should be close to the power supply side and short thick as possible, otherwise, equal to increase the capacitance of the equivalent series resistance, affect the filter effect. (5) wiring avoid 90 ° bend, reduce the high frequency noise emission. (6) thyristor suppression received on both sides and RC circuits, reduce the noise generated by Silicon controlled rectifier (this noise serious may be SCR breakdown). 2 cut off interference propagation path by interference propagation path can be divided into conducted interference and radiated interference. The so-called conducted interference is defined through the wire to sensitive devices. High-frequency interference noise and useful signal frequency bands, can lead to increase filter method for cutting high-frequency interference noise transmission, sometimes can also be combined with optical coupling isolation. Power noise hazards maximum, paying special attention to the process. The so-called radiated interference is propagated through space radiation sensitive devices. The general solution is to increase the interference sources and sensitive devices distance ground their isolation and in sensitive devices on the short hood. Cut the noise propagation path of common measures are as follows: (1) take full account of the power on microprocessor shadowRing. The power to do well, the entire circuit interference most of the settlement. Many of the microcontroller is sensitive to the power supply noise, to give single-chip power plus filter circuit or regulators to reduce power noise interference on the microcontroller. For example, you can use beads and capacitance constituted π-shaped filter circuit, course conditions requirements is also available in 100 Ω resistor substitute beads. (2) if the microcontroller I/O port used to control the motor noise, and the i/o port should be added between the noise source isolation (increase the π-filter). (3) Note Crystal wiring. Crystal oscillator and a microcomputer PIN as close as possible to that ground the clock district isolation, Crystal shell grounding and fixed. (4) reasonable partition, such as circuit boards, weak signal, digital and analog signals. As far as possible sources of interference (e.g. motors, relays) and sensitive components (such as SCM) away. (5) with a ground to digital and analog in isolation. Digital and analog to detach, point final in received power. A/D and D/A chip wiring also this principle. (6) MCU and high-power devices ground to separate ground to reduce interference. High-power devices in the circuit board edge as possible. (7) on-chip I/O port, power cables, printed circuit board connectors, and other key parts of the anti-jamming components such as beads, steepness, power filter, shielding enclosures, can significantly improve the performance of the circuit. 3 improve sensitive devices of anti-interference performance sensitive devices of anti-interference performance is from the sensitive devices here consider minimizing interference noise pickup, and never a normal status as soon as possible. Improve sensitive devices anti-interference performance of common measures are as follows: (1) wiring to minimize the loop area, central to reduce induced noise. (2) wiring, power and ground to rough. In addition to reduce pressure drop, and more importantly reduce coupling noise. (3) in the case of single-chip I/O port are idle, not vacant, to ground or power supply. Other IC free-without altering the system logic ground or power supply. (4) on-chip power monitoring and watchdog circuit, such as: IMP809, IMP706, IMP813, X5043, X5045, can greatly improve the performance of the entire circuit. (5) in speed to meet the requirements, minimize the use of Crystal and low-speed digital circuits. (6) IC devices try to direct welding at the Board, the use of IC socket. 4 other common anti-jamming measure AC side inductance capacitor filter: removes the high frequency pulse-frequency interference. Transformer-isolated measures: transformer primary input thread capacitance, primary and secondary coils shield and the primary contact between the capacitor Centre, secondary external geodetic shield received printed circuit board, this is a hardware key anti-jamming. Secondary plus low-pass filter: absorption of surge voltage transformer. Integrated DC regulated power supply: because of the over-current, over-voltage and over-temperature protection. I/O port using opto-electronic, magnetic, relays, while eliminating common ground. Communication wires twisted pair: exclude parallel mutual inductance. Lightning most effective with optical isolation. A/D conversion with isolation amplifier or on-site conversion: reducing errors. Shell geodetic: solve personal safety and prevention of external electromagnetic interference. Added reset voltage detecting circuit. Prevent reset is not sufficient, the CPU is working, in particular with EEPROM device, reset not fully will change the contents of the EEPROM. Printed circuit board Technics anti-interference: ① power cord bold, reasonable alignment, grounding, three bus separately to reduce mutual inductance oscillation. ② C P U, RAM, ROM, and so the main chip, between VCC and GND and received Electrolytic Capacitor ceramic capacitors, high-frequency interference removal. ③ independent system structure, reducing connector and wiring, increase reliability, reduce the failure rate. ④ manifold and socket access reliable, socket, it is best to use a closely integrated block direct welding in printed circuit board, prevent devices access to undesirable fault. ⑤ conditional using four layers above PCB, the middle two layers for power and ground.