In the process of developing embedded systems, serial bus protocol analysis has always been a headache for engineers. In the case of a logic analyzer, engineers need to set complex trigger conditions to capture the required data, which requires expensive equipment investment and a lot of time to set up the instrument. With the continuous development of oscilloscope technology, serial bus trigger and analysis functions have appeared in some high-end oscilloscopes and are popular among embedded engineers. However, the functions and performance of oscilloscopes from different manufacturers in serial bus analysis are very different.
Serial Bus Triggering Using an Oscilloscope
Ordinary oscilloscopes can only perform general edge triggering and pulse width triggering, making it difficult to capture complex serial bus waveforms. Using an oscilloscope with a serial bus trigger function can easily capture the required serial data. Yokogawa's DLM2000 series digital oscilloscopes support triggering of a variety of commonly used serial buses, including CAN/LIN/I2C/SPI/UART, and can even trigger non-standard serial buses defined by users. Depending on the structure of each bus, multiple trigger modes can be set. The more trigger modes, the stronger the ability to capture data.
In embedded systems, there are often two or more serial bus structures. For example, CAN and LIN buses are often used at the same time in automotive electronics, and it is often necessary to analyze whether there are any problems with the communication coordination of the two buses. However, most oscilloscopes with serial bus triggering functions can only trigger one bus at a time. To achieve simultaneous triggering of CAN and LIN buses, only two oscilloscopes can be used, and the synchronization problem of the two oscilloscopes is also difficult to solve. The dual-bus triggering function of the DLM2000 series oscilloscope can easily achieve combined triggering of any two serial buses.
Serial bus decoding analysis using an oscilloscope
After triggering the required serial data, engineers are still faced with the original waveform of the data. In order to conduct efficient bus analysis, the waveform needs to be decoded. At present, the decoding technologies used in digital oscilloscopes include software decoding and hardware decoding. Software decoding is to obtain the decoding result by calculating the waveform data through the software in the oscilloscope. Although it can reduce the hardware cost, it requires a high CPU computing speed. In practical applications, it takes several seconds or even more than ten seconds for an oscilloscope using software decoding to decode once. Such a decoding speed has lost the meaning of real-time analysis, because most of the data has been lost while waiting for decoding. A few high-end oscilloscopes use hardware decoding technology to solve this problem, making real-time decoding analysis possible.
While displaying the decoding results, the decoded list of all captured frames can also be displayed, which is very convenient for corresponding observation of waveforms and decoding results.
To obtain the correct decoding results, the oscilloscope needs to be set according to different bus parameters. Taking CAN bus analysis as an example, it is necessary to specify the bus type as CAN, set the channel corresponding to the CAN signal, trigger the CAN bus by adjusting the trigger level and time axis, and then adjust the bit rate, set the invisible level, etc. If it is an SPI bus, it is also necessary to specify a 3-wire or 4-wire system, specify the clock signal, and the chip select signal. This setting process needs to be very careful. If any of the settings are not appropriate, the decoding result may not come out. Especially for the bit rate setting, if there is a slight error, the decoding result may be wrong.
The complicated setting process wastes some debugging time and does not give full play to the role of the oscilloscope in improving development efficiency. The DLM2000 oscilloscope realizes the automatic setting of serial bus triggering and decoding analysis. Users only need to set the bus type and signal source channel, and the system can automatically adjust the bit rate, trigger level, invisible level and other settings. In just two seconds, the trigger waveform and decoding results can be displayed synchronously. This function makes the cumbersome serial bus setting very convenient and greatly improves the development efficiency of engineers.
The following introduces some techniques for using an oscilloscope to analyze serial buses for several commonly used serial buses.
Recording and analysis of CAN bus control process
When analyzing the CAN bus, engineers usually want the oscilloscope to capture a complete control process, such as the opening or closing process of a car window. These processes usually last for a few seconds or more than ten seconds. Recording data for such a long time requires the oscilloscope to have a large storage depth. However, the current 200MHz~500MHz bandwidth oscilloscope generally has a storage depth of less than 10Mpoints per channel, so it is difficult to record a few seconds of CAN bus waveform. DLM2000 can be expanded to 125Mpoints per channel, so that a control process of more than ten seconds or even longer can be fully recorded.
The most important thing for analyzing a process is the beginning and end of the process. After capturing a control process, the user can open a zoom window, move to the starting point of the process, and observe the details of the starting point. If you want to observe the details of the ending point at the same time, a general oscilloscope is powerless. The DLM2000 inherits the unique dual-window zoom function of the Yokogawa DL series oscilloscope, which can observe the waveform details of two positions at the same time and adjust the zoom ratio independently.
Capturing of occasional abnormal signals
When the time base Time/Div is adjusted to a relatively small value to observe waveform details, there may be some occasional abnormal signals or error frames. When the user wants to capture these waveforms, it is too late. If the historical storage function (also known as segmented storage technology) is used, this problem can be solved. DLM2000 can divide the large memory into several blocks evenly. The captured waveforms are not immediately overwritten, but stored in the historical memory. In this way, even if the abnormal signal is found not locked on the screen, as long as the user presses the acquisition stop button in time, the abnormal signal can be easily retrieved from the historical memory.
Simultaneous trigger analysis of CAN/LIN buses
In automotive electronic applications, the CAN bus is always used in conjunction with the LIN bus, so it is often necessary to analyze the CAN bus and the LIN bus at the same time. As mentioned earlier, the DLM2000 has a dual-bus trigger function that can simultaneously trigger the combination of the CAN and LIN buses. Not only that, the decoding analysis of the two buses can also be performed synchronously. As shown in Figure 3, the decoding result list of the two buses can be displayed on the screen at the same time, and the waveform details of the two buses can be observed separately using the dual-window magnification function. When a different decoding item is selected in the list, the waveform in the magnified window will automatically switch to the corresponding waveform, which is very convenient for observation.
CAN bus bit rate setting
The standard rate of the CAN bus is generally 250kbit/s or 500kbit/s. However, in the R&D stage, engineers often adjust the bit rate down or up for development and testing needs. If the bus parameters of the oscilloscope can only be set to 250kbit/s or 500kbit/s, the non-standard CAN bus cannot be decoded. The DLM2000 can flexibly set the bus bit rate. The CAN bus rate can be set arbitrarily in the range of 10.0kbit/s to 1.000Mbit/s in 0.1kbit/s steps.
Flexible use of filtering functions
In the actual test of the automotive electronics laboratory, the CAN bus signal will be interfered by factors such as motor ignition, making the captured waveform contain a lot of noise. If you want to obtain a clear bus signal, you need to filter out the noise. The general oscilloscope has only two low-pass filters at the lowest, 200MHz and 20MHz, which are powerless for noise below 20MHz. The DLM2000 standard configuration comes with 14 filters from 200MHz to 8kHz, which can effectively filter out various high-frequency noises.
If the built-in operation filter function is used, high-pass and low-pass filtering from 0.01Hz to full bandwidth can be achieved, which can not only filter out high-frequency noise, but also filter out the basic signal to observe high-frequency noise. In addition, by setting the appropriate cutoff frequency, the fundamental wave of the modulated signal can be easily obtained.
Serial bus applications are becoming more and more widespread, and specialized serial bus protocol analysis tools have emerged, generally including data acquisition hardware and PC-side software. This type of equipment can perform detailed parsing and analysis of serial bus protocols on the PC side, but its price is generally very expensive, and its functions are limited to total current protocol analysis. In addition, the sampling rate of the hardware part of this type of equipment is relatively limited, and the detailed analysis of the waveform cannot be compared with an oscilloscope. Bus errors caused by external noise interference will be difficult to detect. Oscilloscopes with powerful filtering functions can not only observe real physical waveforms, but also obtain clear bus signals through filtering functions.
With the rapid development of science and technology, serial bus technology is constantly being updated and applied more and more widely. In today's world where embedded development is very common, using a powerful oscilloscope for serial bus analysis can achieve twice the result with half the effort, simplify debugging methods, and improve development efficiency.
Previous article:Troubleshooting system-level issues with a mixed domain oscilloscope
Next article:Mainboard high-speed serial bus analysis and test requirements analysis oscilloscope
- Popular Resources
- Popular amplifiers
- Seizing the Opportunities in the Chinese Application Market: NI's Challenges and Answers
- Tektronix Launches Breakthrough Power Measurement Tools to Accelerate Innovation as Global Electrification Accelerates
- Not all oscilloscopes are created equal: Why ADCs and low noise floor matter
- Enable TekHSI high-speed interface function to accelerate the remote transmission of waveform data
- How to measure the quality of soft start thyristor
- How to use a multimeter to judge whether a soft starter is good or bad
- What are the advantages and disadvantages of non-contact temperature sensors?
- In what situations are non-contact temperature sensors widely used?
- How non-contact temperature sensors measure internal temperature
- LED chemical incompatibility test to see which chemicals LEDs can be used with
- Application of ARM9 hardware coprocessor on WinCE embedded motherboard
- What are the key points for selecting rotor flowmeter?
- LM317 high power charger circuit
- A brief analysis of Embest's application and development of embedded medical devices
- Single-phase RC protection circuit
- stm32 PVD programmable voltage monitor
- Introduction and measurement of edge trigger and level trigger of 51 single chip microcomputer
- Improved design of Linux system software shell protection technology
- What to do if the ABB robot protection device stops
- Wi-Fi 8 specification is on the way: 2.4/5/6GHz triple-band operation
- Wi-Fi 8 specification is on the way: 2.4/5/6GHz triple-band operation
- Vietnam's chip packaging and testing business is growing, and supply-side fragmentation is splitting the market
- Vietnam's chip packaging and testing business is growing, and supply-side fragmentation is splitting the market
- Three steps to govern hybrid multicloud environments
- Three steps to govern hybrid multicloud environments
- Microchip Accelerates Real-Time Edge AI Deployment with NVIDIA Holoscan Platform
- Microchip Accelerates Real-Time Edge AI Deployment with NVIDIA Holoscan Platform
- Melexis launches ultra-low power automotive contactless micro-power switch chip
- Melexis launches ultra-low power automotive contactless micro-power switch chip
- Q&A on Connectivity: Why Wi-Fi 6 Could Be Your Competitive Advantage
- Why do we need to learn transistor circuits when we already have integrated circuits?
- 2. Hardware Introduction and Development Environment Installation
- 【New Year's Festival Competition】+ Watching Lanterns on the Lantern Festival (multiple photos)
- 5G small base stations are under the spotlight: now is the eve of the outbreak
- 【CH579M-R1】+ PWM breathing light
- [Experience] [Free trial of Letuo USB oscilloscope] Comparison test of Letuo USB oscilloscope
- Wi-Fi 6E scarcity causes enterprises to delay upgrades until Wi-Fi 7 devices ship
- [RISC-V MCU CH32V103 Evaluation] W25Q16 Reading, Writing and Application
- 【GD32E231 DIY Contest】1. USART0