The advanced course of the practical route of circuit board hardware design

 Primary Practice


1. Welding. First look at the welding video of the predecessors.


When dragging and soldering, first align the chip, then fix one corner with tin, then fill the other side with tin, and finally fill the entire chip with tin. Pick up the board, tilt it about 30 degrees, heat it with a soldering iron, suck up the tin that has become liquid, and shake it off until all the tin is sucked away. The temperature of the soldering iron should be adjusted properly, I usually use 350 degrees Celsius.


The key point is to understand that when tin becomes liquid, it will flow down under the action of gravity like water. Also, the surface of the soldering iron tip has suction, so do not scrape the tin hard during the entire soldering process. If the operation is not smooth when welding, you can turn the board.


Regarding BGA soldering, manual operation is generally not recommended, because the success rate is not high, and a rework station is recommended. Let me talk about the operation process of BGA manual ball planting.


First use the universal tin-planting stencil (this is the most outdated tool, in addition to the tin-planting platform, but it is quite expensive), align it with the BGA, and then use adhesive tape to stick the BGA and the stencil to fix it. Add solder paste first, then blow with an air gun for a while (the wind speed and temperature of the air gun can be lowered a little), when the tin becomes brighter, use a scalpel to scrape away the excess tin. If the solder balls are uneven, repeat the previous step until the solder balls are uniform. Tear off the tape and pry the BGA up with a scalpel.


2. The use of instruments and meters. Multimeter: Why the name? Because for the master, the multimeter is almost omnipotent. It is also commonly used to measure voltage, current and resistance.


Oscilloscope: Digital oscilloscopes are used now, with an auto key, which can be easily done, and it also has the function of FFT, which can use frequency domain analysis method, which is a magic weapon that hardware engineers must master. The oscilloscope also has a niche function, which is the Lissajous diagram (used for phase difference and frequency measurement). In addition, learn to measure switching power supply ripple with an oscilloscope.


Digital bridge, also called LCR, LCZ tester: use it to measure inductance, capacitance, resistance, Q value, D value, etc., with higher accuracy than ordinary multimeters.


Signal generator, also called function signal generator: can output sine wave, square wave, triangle wave, modulated signal. The usage is relatively simple, but for the RF signal generator, you must pay attention to the impedance matching before outputting the signal, otherwise the signal generator may be damaged if the signal is reflected.


Frequency meter: The usage is relatively simple, so I won’t say more about it. Some signal generators also add the function of frequency meter.


Vector network analyzer, also called network analyzer: It is used to measure the S parameter matrix of the radio frequency circuit, and can also display the Smith chart. Calibrate the frequency points before each use.


There are also some niche instruments, such as leakage current testers, ammeters, etc.


3. Maintenance. First, visually inspect the board to see if there are any solder joints, short circuits or missing components. If there is, fix it, if not, go to the next step.


Then use a multimeter to test each group of power supplies to see if there is a short circuit. If there is, fix it, if not, go to the next step.


Power on the board to see if the power supply voltage of each group is normal. If there is, fix it, if not, go to the next step.


At this point, you must have a certain understanding of the overall design of the board, or you have to memorize the experience of your predecessors (those who memorize the experience often feel that the hardware is very mysterious, which I do not recommend), otherwise it will not be possible to fix it. First divide the functions of the board into modules, judge which module has a problem from the phenomenon, and disconnect the suspicious module to eliminate suspicious points (like a detective).


If there is a good board, it is easy to handle, and it can be solved by directly measuring the voltage of each component (or the resistance value to the ground). Using a multimeter can only solve some simple problems. If you want to fix it completely, you must have an oscilloscope at hand, because it is impossible to measure it with a multimeter if the crystal oscillator is disturbed.


4. Debugging. Debugging is generally a self-designed circuit that has not been verified and needs to be verified by yourself. This requires a solid theoretical foundation. Debugging is also one of the easiest and most valuable skills for hardware engineers to accumulate experience.


If you encounter difficult problems in the early stage, you can put them down for the time being, and then you will be able to solve them when your level is higher, so don't go into a dead end, it will only waste more time. Debugging skills need to be accumulated over a long period of time. Putting them in the front is for everyone to pay attention to.


There are various debugging methods, which depend on the situation and cannot be generalized. The author summarizes the following methods: a. Oscilloscope measurement. Of course, first of all, you have to know what kind of waveform the circuit you designed will produce, so that you can know whether the test is correct, that is to say, if the theory is not good, it cannot be debugged at all.


b. Compare the verified circuit. If you have a good board in hand, and the circuit that needs to be debugged happens to have a good board circuit, you can take the good board and fly a few wires to verify it and eliminate suspicious points. The method here is the same as the maintenance method.


c. Simulation. In fact, when designing a circuit, if it can be simulated, it should be simulated first. If there is still a problem with the actual product, it can also be simulated. Such as the parameters of the operational amplifier circuit, the series and parallel connection of uncertain resistors, and so on.


d. The tweezers are short-circuited. When you suspect that the clock is interfering with other signals, you can use tweezers to short-circuit the clock pin to the ground (as long as it is a weak signal, shorting it to the ground for a while will not burn the board, don't worry), to eliminate suspicious points. There is also the problem of reset, and this method can also be used.


e. Signal generation. For example, in an operational amplifier circuit, both the input and output are disturbed, then you can use a signal generator or a development board to output a clean signal, which can eliminate suspicious points.


f. Software debugging. If there is a CPU on the board, you can use the serial port to debug, and if you have the FPGA, you can use the embedded logic analyzer, so that you can determine whether the problem is internal or external to the chip.


g. Observe the phenomenon. The signals are all running on the board, which cannot be observed by direct observation. At this time, the signal line can be led out and connected to the observable device. For example: when debugging an audio amplifier, you can connect a signal to a ready-made and intact power amplifier, and observe the phenomenon by listening to the sound. Of course, you don't just think about power amplifiers, there are other observable devices or components, such as LED lights, monitors, and even radios, as long as they can be used.


Intermediate Practice


1. Use of simulation software. There are only a few commonly used simulation software, proteus, multisim, labview, pspice, ADS, etc., most of which use spice simulation models.


a. proteus. This software is very suitable for simulating single-chip microcomputers, and there are quite a lot of component libraries, but there is a fatal shortcoming, that is, it is too smart. The single-chip microcomputer can work normally without being connected to the power supply or the crystal oscillator, which is very different from the actual situation, so the author recommends learning the single-chip microcomputer, or using a development board.


b. multisim. This software is very suitable for simulating analog circuits. In fact, it is essentially a spice simulation, but the interface is much simpler and suitable for beginners. Although there is an 8051 library, it is not suitable for simulating single-chip microcomputers, and the simulation is very slow.


In fact, there are not many component libraries, such as the 0805 triode, which does not have it. At this time, we can only use other triodes (2N2222, etc.) to replace it, or we can make this component library by ourselves. Multisim can also be used in conjunction with ultiboard for actual board-level simulation (together with PCB, simulated together).


c. Labview. This software is very powerful, it can simulate analog and digital circuits, and can also be used as a host computer (such as: virtual instruments, etc.). The most distinctive feature is the graphical input, which can be simulated by dragging a few things with the mouse.


d. pspice. This software is a software in cadence or SPB development kit, which is usually called out in capture. It is very convenient to use capture without entering the point command of spice. Among them, the graph of pspice is better than that of multisim. For example, the voltage of several nodes can be seen clearly in a graph of pspice.


e. ADS. This ADS refers to Agilent's Advanced.Design.System, not the ARM compiler ADS1.2. ADS is an artifact of circuit simulation. It has very powerful functions. It is generally used to simulate high-frequency, radio frequency, and microwave circuits. Of course, lumped parameter circuits can also be simulated, but it is not suitable for beginners.


2. The use of circuit design software. There are three mainstream circuit design software: Altium Designer, PADS, Cadence, and of course some niche ones, like Eagle. Here are only three mainstream software.


Altium designer (referred to as AD), the previous version is protel 99se, protel DXP, the usage is similar, very suitable for beginners, 3D rendering effect is the best, and it is also the most taught software in schools.


However, many companies do not use this software, because if they use it to draw multi-layer boards, the computer will be very stuck, and if there are many people in the company who use it, they may receive a letter from Altium's lawyer. It can be used for FPGA development and board-level simulation. Suitable for small-scale PCBs.


PADS, the previous version is power PCB, divided into three components: logic (schematic diagram), layout (layout and setting rules), route (wiring), the most distinctive features are: use polar coordinates to place components and automatic routing (this Autorouting is not as bad as AD). It is suitable for small and medium-sized PCBs, but logic is quite difficult to use, so some people use orcad+PADS to make up for this shortcoming. Suitable for small and medium-sized PCBs.


Cadence (also called SPB) is a system-level suite. In addition to drawing schematics and PCBs, it can also draw layouts, simulate circuits, and simulate SI/PI. Cadence has acquired orcad. At present, capture (also called orcad) is used to draw schematic diagrams, allegro is used to draw PCBs, pspice (called from capture) is used to simulate circuits, and Sigrity is used to simulate SI/PI (need additional Install).


It is very cool to use capture to draw a schematic diagram. For example, to draw a schematic diagram of a chip, you can write it in excel (pin numbers and part of the pin names, like D0~D7, and it will come out after dragging the mouse), and then copy Go to capture and make a small amount of adjustments. However, it is more cumbersome to draw the package with allegro. It is necessary to draw the pads in advance before drawing the package. Suitable for medium and large PCBs.


3. Use of other software. AutoCAD for drawing board frames, solidworks or pro-e for drawing 3D packages, and MATLAB for scientific computing.


The basic usage of AutoCAD is relatively simple. It can be started in half an hour if someone teaches. For hardware engineers, just draw the board frame, save it in DXF format, and then import it into the PCB design software. At the same time, DXF is also a file format for hardware engineers to interact with structural engineers.


Compared with pro-e, solidworks is easier to learn and use. With these two softwares, you can draw the 3D packaging of the components, and then export the PCB to stp format and put it in solidworks. In this way, you can see the rendering of the whole machine before the board is printed.


Another advantage of learning 3D software is that it allows you to know more about the installation of the board, such as positioning holes, sockets, wiring, etc., so that the PCB designed in this way is not easy to fail to install due to structural problems, which is easily overlooked by many hardware engineers.


MATLAB, any calculation, can use it. Simple calculations, such as resistor voltage division, filter cut-off frequency, etc., and complex calculations, such as parameter calculation of directional couplers, modeling of complex operational amplifier circuits, etc., can be easily solved with MATLAB.


Advanced Intermediate Practice


1. Calculation, simulation and verification of basic circuit units. Indeed, no matter how complex a circuit board is, it can be divided into several modules according to its functions, and these modules can be further divided into numerous circuit units. Therefore, we must first master the design of the most basic circuit unit.


These circuit units can be learned from digital electronics, analog electronics, power electronics technology, high-frequency electronic circuits, single-chip microcomputers, and electronic measurement technology. First, understand the calculation, simulation, and verification of classic circuits in textbooks. Don't think that the formulas in the book are simple, but it is another matter to actually operate them.


For example, the inverting amplifier circuit in the book is a dual power supply. When using a single power supply, bias must be added, and bandwidth gain product, slew rate, etc. must also be considered. Here, it is advocated to calculate first, then simulate, and then operate the actual operation process. At the same time, this is also a process that requires long-term accumulation. 2. Master the microcontroller. You can refer to "How to Learn Single Chip Microcomputer" in this blog.


3. The use and interconnection of chips. Electronic professional English is not mentioned in the theoretical chapter, and professional English is used here. You can read English textbooks or use translation software. One point that must be mentioned here is: Those who cannot read the datasheet due to poor English cannot do circuit design.


Because you always have to use an unfamiliar chip, and there will always be situations where there are no Chinese materials. Basically, those who can understand the datasheet can use the chip. In fact, they also copied the reference circuit on the datasheet, and the rest is the chip interconnection.


Chip interconnection is the interface technology, which is also mentioned in the single-chip microcomputer. The 5V ADC is interconnected with the 3.3V microcontroller, which depends on the level and the transmission rate of the signal. The 3.3V single-chip microcomputer is interconnected with the MOS tube of the 12V turn-on voltage, and a triode is added to do level conversion. Two 3.3V single-chip IO ports push-pull output interconnection, a 100R resistor in series to prevent the IO port from being burned due to improper code operation.


In addition, you must also master the commonly used bus protocols. Such as RS232, RS485, SPI, IIC, CAN, LIN, zmodem, USB, PCIE, TCP/IP, etc.


Advanced Practice


Here, I believe that you have already familiarized yourself with some basic circuits, and you will also analyze some simple circuits. However, you will always encounter some weird phenomena.


That's right, it's time for you to consider SI, PI, EMC, EMI. Don't be intimidated by these seemingly high-end terms. After analysis, it is also the circuit principle learned earlier, but the problem is considered from a different angle.


1. SI, signal integrity. The content of this part has a great influence on the layout and wiring of PCB.


a. Use impedance matching to reduce the effects of overshoot, undershoot, and ringing (some radio frequency circuits also have requirements for impedance, such as antennas, etc.). b. Differential lines should be as close as possible to reduce differential mode interference. c. The decoupling capacitor should be as close as possible to the power pin of the chip. d. High-power devices such as relays should be kept away from easily disturbed components such as crystal oscillators. e. For important signal lines, cover the ground. f. Try to stay away from the clock line (the clock may also become a source of interference). g. The return path of the signal line should be as short as possible.


There are still many points to pay attention to in signal integrity. For details, please refer to "High-speed Circuit Design Practice" by Wang Jianyu.


2, PI, power integrity. To ensure the integrity of the power supply, it is to prevent the fluctuation of the power supply voltage. For details, please refer to "The Role of Decoupling Capacitors" in this blog.


3. EMC/EMI, electromagnetic compatibility and electromagnetic interference. These two nouns seem a bit lofty, but they are actually about not disturbing others and preventing being disturbed by others. The problem of EMC/EMI can be attributed to the problem of SI, but EMC has a set of verification standards, so it still has a different name.


Recommend "Cadence High Speed Circuit Design: Allegro Sigrity SI/PI/EMC Design Guide".


Summarize


1. Don't think that you have mastered magic skills by memorizing certain formulas as secrets. This is unrealistic. The early study must be based on theory, a small amount of practice to help understand the theory, and then you can gradually increase practice. Theory and practice complement each other and are indispensable.


2. When there is a problem with the hardware circuit, every step of the engineer's operation is guided by theory.


3. Don't be afraid of making mistakes and dare not make boards. Hardware engineers are constantly making mistakes, correcting, and summarizing, and then gradually mature and reduce the probability of making mistakes. If you don't know what's wrong, it also means that you can't accumulate experience.


4. This article does not mention production and testing issues, such as: wires, PCBA, BOM, jigsaw, test fixtures, polished chips, packaging (QC labels, fragile paper, manuals), etc.


5. Because most of the circuit functions are realized by the chip, drawing schematic diagrams is almost always copied from the datasheet, so the most valuable skills of hardware engineers are PCB and debugging ability.


6. Because hardware engineers often need to communicate with software engineers, in order to facilitate communication, you have to learn ARM, FPGA, DSP and other related knowledge, but the focus is different, otherwise it will bring some troubles to work .

评论