Signal and encoding

Source: Internet
Author: User

Signal and encoding

Analog Signal and modulation method, baud rate

In the circuit, signal transmission is a waveform in terms of time at the receiving end. The sender generates the waveform based on the data, and the receiver obtains the waveform to analyze the data. The whole process is actually the coding and decoding from data to radio waves. The carrier in the middle is the circuit and cable.

The actual analog signal is a continuous curve over time. This curve is similar to a sine wave with amplitude, ripple and valley, and frequency. We usually use its changes to represent data, which is the modulation method. Frequency changes are used to represent frequency modulation, while amplitude changes are used to represent amplitude modulation.

The baud rate (baud rate) refers to the changes in the unit time after the signal is modulated, that is, the number of times the carrier parameter changes within the unit time. It is a measure of the symbol transmission rate. 1 port refers to the transmission of 1 Symbol per second.

Digital signal and sampling theorem

The actual data is discrete, and the data we can express is also discrete. How can we express such a continuous analog signal? The answer is discretization and sampling. Collect enough discrete information points, and then concatenate these points to restore the waveform. Intuitively, the more points are collected, the closer the restored waveform is to the actual situation. This discrete data is a digital signal.

In general, for example, we use the wave top to represent data 1 and the valley to represent DATA 0. In this case, for example, 4 points are collected in each peak, or 5 points are added at a point. The data represented by this waveform can be restored. However, it is not possible to collect only one point. For example, all points near the X axis are collected, and the waveforms connected by all the sampling points are similar to a straight line.

The sampling theorem tells us that when the sampling frequency fs is used for analog/digital signal conversion. max is twice the maximum fmax frequency in the signal (FS. max> = 2 fmax). After sampling, the digital signal completely retains the information in the original signal. Generally, in actual application, the sampling frequency is 5 ~ of the highest signal frequency ~ 10 times; the sampling theorem is also called the nequest theorem.

Pulse Signal and pulse Coding Modulation

A pulse signal is a discrete signal with various shapes. Compared with a common analog signal (such as a sine wave), the waveform is not consecutive in the timeline (there is a significant gap between the waveform and the waveform) but it has a certain periodicity. The most common pulse wave is a Rectangular Wave (that is, a square wave ). Pulse signals can be used to represent information or as carriers, such as pulse coding modulation (PCM) and pulse width modulation (PWM) in pulse modulation, it can also be used as clock signals for various digital circuits and high-performance chips.

Pulse coding modulation (pulse codemodulation) is a digital sampling technique for analog signals. It converts analog speech signals into digital signal encoding methods, especially for audio signals. For example, PCM samples the signal 8000 times per second. Each sample is 8 digits, with a total of 64 Kbps.

Pulse coding modulation mainly goes through three processes: sampling, quantization, and coding. The sampling process changes the continuous time analog signal into a discrete time, continuous amplitude sampling signal, and the quantization process changes the sampling signal into a discrete time, discrete amplitude digital signal, the encoding process encodes the quantified signal into a binary code group output.

The so-called quantization means to discretize the instantaneous values obtained after sampling, that is, to use a set of defined levels to encode the instantaneous sampling values in the nearest way, A set of binary code groups is used to represent each quantified value with a fixed level.

(The above section is mainly from Baidu encyclopedia)

Clock signal and clock frequency

The clock signal can be seen as a reference of the pulse signal. Based on the clock frequency, the data in the pulse signal can be separated by frequency period. See the following Manchester encoding.

In a communication network, the receiver needs to recover the clock information from the received data to ensure synchronization. This requires that the binary code streams transmitted in the line have enough hops, that is, there cannot be too many consecutive high or low levels; otherwise, the clock information cannot be extracted. If there is no reference, two consecutive low levels and two consecutive high levels are the same and undistinguished as one low level and one high level. Moreover, for the isolating capacitor in the circuit, multiple consecutive high levels may lead to DC, and the subsequent part will be directly truncated.

 

Manchester Coding and differential Manchester Coding

Manchester encoding is a combination of clock signals and digital signals. In this way, the synchronous clock is directly added to the signal, so that each code element indicating the data bit has at least one hop, that is, at most two consecutive high or low levels (this is very important ). The disadvantage is that each code dollar is changed to two digits, and the data transmission rate is only half of the original bit rate.

The encoding method is to change the jump from high to low to 1 in the middle of each cycle, and from low to high to 0. The fourth line indicates the reverse Manchester encoding.

The differential Manchester encoding is the same as the Manchester encoding, and the middle part of each cycle changes. Only a small change is made. If there is a beating at the beginning of each cycle, it indicates 0; otherwise, it indicates 1. This is not directly related to increase or decrease.

 

4b/5b Encoding

To solve the problem that Manchester encoding only has half of the transmission speed, 4B \ 5B encoding (similar to base64) appeared under relaxed constraints ).

The principle is roughly as follows. Four bits can represent 16 different combinations, and five bits can represent 32 combinations. 16 relatively even combinations are extracted from 32 different combinations, it is one-to-one correspondence with the 16 situations represented in the original 4-bit representation. In this way, all data bytes (8 bits) are divided into 4 bits at the high level and 4 bits at the low level, and each 4 bits is expressed as 5 bits according to the comparison table. The generated signal levels are relatively balanced, with a maximum of 7 consecutive 1 (0x7f) and 3 consecutive 0 (0x21 ).

Although its uniformity is not as good as that of Manchester encoding, its transmission efficiency is changed from 4 to 5, and the efficiency is 80%, which is 30% higher than that of Manchester encoding.

 

Simple cross-encoding: 1001 Encoding

Sometimes we find that the signal is weak when multiple consecutive high levels appear. At this time, the Manchester United report is very effective. In fact, we can simply simplify the encoding.

The method is as follows:

  1. All data is binary, such as 11000110...
  2. Add a 0 after each 1, and add a 1 after each 0
  3. The preceding data becomes1010010101101001...
    Black indicates the original data, and blue indicates the supplementary data.
  4. When decoding data, the bitwise operation removes the data in the even bits and the obtained data is the binary representation of the original data.
  5. You can perform parity checks on the original data and the parity. If one data error occurs, you can restore the data from another part.

 

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.