Design of a GMSL-based In-Vehicle Video Acquisition and Storage System (Part 1)
2.1 Introduction to GMSL Interface Technology
Currently, for the problem of transmitting large amounts of data in complex in-vehicle platforms, common design methods typically involve increasing parallel buses to boost bandwidth or raise frequency. However, as data volume increases, this places immense pressure on bus data transmission, and the drawbacks of parallel buses become apparent. Data transmission using buses requires strict timing consistency. Traditional parallel buses achieve high-speed, high-bandwidth data transmission by increasing frequency. However, excessively high frequencies can make it difficult for the data transmission frequency to match and remain consistent with the clock frequency. Furthermore, variations in layout and routing can affect the clock, making synchronization difficult, and excessively high frequencies can also cause mutual interference between signals. However, serial transmission can solve this problem because it uses only one signal line, eliminating timing and interference issues between signals, allowing for a reasonable increase in frequency for high-speed data stream transmission. Moreover, serial buses utilize differential line transmission technology, which makes data transmission more precise and reduces errors [20]. Currently, high-speed video data stream transmission predominantly employs serial transmission technology. Therefore, this paper proposes using GMSL technology for in-vehicle video data transmission, as it can effectively address high-speed and high-bandwidth data transmission challenges. GMSL technology refers to a transmission link composed of a serializer and a deserializer, known as Gigabit Multimedia Serial Links (GMSL). This serial link solution uses Maxim's MAX9291 and MAX9288 combined to form a serial link, which transmits video and audio data. When using 50-ohm coaxial cable or 100-ohm twisted pair cable, the transmission distance can reach up to 15 meters [21]. Its core technology is serializer/deserializer (SerDes) technology, which uses a serializer to convert parallel video data streams into serial data streams. These are then transmitted over twisted pair cables by increasing the data transmission clock frequency. Finally, a deserializer converts the serial data streams back into parallel data streams for the processor [22]. Additionally, the MAX9291 serializer integrates a bidirectional control channel, which can be used to configure the chip. A schematic diagram of GMSL interface technology transmission is shown in Figure 2.1.
2.2 GMSL Interface Communication Mechanism
In normal operating mode, when Seren=1 in the serializer program, video and control data are sent via the serial link. When Seren=0 in the serialization program, data transmission is disabled. The data transmission link requires a valid PCLK to operate. When PCLK is invalid, the link can be used to configure the serializer and deserializer [23]. The schematic diagram of GMSL technology communication is shown in Figure 2.2. A GMSL camera outputs captured image signals via the GMSL interface and transmits them to the MAX9291 serializer. The transmitted video data stream includes image pixel information, horizontal synchronization signals, and vertical synchronization signals. After receiving the data, the serializer processes it by serializing the information, organizing the data into packets, and then transmitting it via twisted pair or coaxial cable. In coaxial and twisted pair cables, data transmission occurs in two directions: a forward channel for transmitting data streams and a backward channel for receiving acknowledgment signals sent by the host. In this system, the video signal output by the GMSL interface is transmitted via the serial link to an FPGA processor, which performs temporal encoding on the received image data. After the FPGA completes encoding the image data, it transmits it to the DM8168 processor platform to perform SATA e-disk storage and compression encoding of the raw video data, and then sends the compressed and encoded video over the network.
The raw video images captured by the GMSL camera undergo image processing operations such as white balance, denoising, and color restoration at the application layer. After image processing at the application layer, the video images are transmitted to the packetization layer for data segmentation and reassembly, and then to the protocol layer. The GMSL interface protocol structure is shown in Figure 2.7. At the protocol layer, different packet headers and trailer checksum sequences are generated based on the data's type and content. Then, according to the channel management parameter settings, the packet header, data, and packet trailer are combined into a single data unit and allocated to each channel. Finally, the data undergoes digital-to-analog conversion and enters the physical layer for transmission. When the receiving end receives the data output from the physical layer, it unpacks the data in reverse order of the original packets to obtain the raw image data.
