MCU MCU basic knowledge of finishing papers

1.MCU serial port different peripherals, plus level conversion chip, such as MAX232, SP3485 is the RS232 and RS485 interfaces.
2.RS485 differential negative logic signal, + 2 ~ + 6V represents 0, 1 denotes -6 to -2. There are two-wire and four-wire dual input, four-wire full-duplex communication, two-wire half-duplex communication. In general RS485 master-slave communication, i.e. a host with multiple slaves.
3.Modbus is a standard protocol, may support a variety of electrical interfaces, such as RS232, RS485, it may also be transmitted over a variety of media, such as twisted pair, fiber optic, wireless.
4. Many MCU's serial port are beginning to bring their own FIFO, send and receive FIFO mainly to solve the serial port transceiver interrupted too frequently resulting in CPU efficiency is not high. If there is no FIFO, the confiscation send a data processing should be interrupted once, with FIFO, an interrupt can be generated only after several data transceiver in a row (depending on the depth of the FIFO may be) to process the data, greatly improving efficiency.
5. Some engineers debug their systems when a system runaway occurs, immediately introduced a watchdog to solve the problem, but no idea why the program will run fly? Runaway may be a bug in the program itself, or it may be a hardware circuit the problem (is itself susceptible to interference or that he is the source of interference). Usually recommended when debugging your system, without first watchdog, and other debugging completely stable, and in the supplement (except for crisis product safety, personal safety).
6. How to distinguish between active and passive buzzer buzzer? Appearance, such as when the buzzer of two pins facing up, it can be seen that a green source circuit board beep , a circuit board is not sealed with a vinyl buzzer is active. Active buzzer directly connected rated power may be continuously sound, and the passive electromagnetic buzzer and a speaker as the need connected to the audio output circuit to the utterance.
7. Use of the voltage comparator and to produce mainly conversion, analog waveforms to digital interface circuit.
8. Low-power wake usual way: the processor enters a low-power stop after a lot of activity, when there is an interrupt can wake up the processor to return from low power mode to the normal operation mode. Therefore, before entering a low-power mode, you must configure the interrupt Monnet-chip peripherals, and allow it to continue to operate in low-power mode. If not, only the reset and power on again before the end of the low-power mode. After the first wake-up processor execute the interrupt service routine, and then execute the code in the main program after exit.
9. The touch screen features: 1) a transparent, directly affects the visual effect of the touch screen. From this point infrared touch screen technology, and surface acoustic wave touch panel due separated by only a layer of pure glass, visually. Many touch screen is a composite film of many layers, it is only transparent to summarize that the visual effect is not enough, may further include color distortion, reflective, clarity. Color distortion is the biggest color distortion figure, naturally the smaller the better. Mainly refers reflective light caused by specular reflection is generated due to the after image overlap, such as shadows. Most of existence reflective touchscreen provides another model, matte surface touch screen, also known as anti-glare type. 2) It is a touch screen coordinate system, that is, no matter under what circumstances, a stable output data of the same point, if unstable, it will positioning, the problem is most afraid of touch screen: drift. Those who can not guarantee the technical principles every time with the same sampling point touch touch screen data will inevitably drift, drift there are only a capacitive touch screen.
10. Registration interrupt service function: interrupt service routine has been written, but when an interrupt event occurs, CPU still can not find it, because we still lack the final step: Register interrupt service function. Register There are two ways: First, the direct use of registered interrupt function, the advantage of simple operation, portability is good, the disadvantage is due to remap the interrupt vector table and lead to the SRAM efficiency decline: there is a need to modify the startup files , the advantages of high efficiency, is determined not high portability.
11. The MCU provides many digital power VDD / GND and analog power supply VDDA / GNDA. Generally recommended is the use of two different 3.3V power supply. But in order to save costs, may be used single 3.3V supply, but VDDA / GNDA to be separated from the VDD / GND through the inductor. Usually GNDA GND and eventually to be connected together, are connected with a wirewound inductor is recommended and as close to the chip contacts (inductive preferably placed in the back PCB).

Guess you like

Origin blog.51cto.com/12931377/2410069