Basic Concepts

  • VI device/pipe/channel
    • VI DEV

      The VI device supports multiple timing inputs and parses the timings.

    • VI PIPE
      • Physical VI pipe

        The VI pipe is bound to the back end of the VI device. It is responsible for the ISP_FE and ISP_BE of the image algorithm processing after device parsing. It performs pipeline processing on the image data, and outputs YUV images to the channel.

      • Virtual VI pipe

        The virtual pipe is not bound to any device. It reprocesses the data transmitted from other modules or users. It does not support ISP_FE in the pipe and starts from ISP_BE in the pipe.

    • VI CHN
      • Physical VI channel PHY_CHN

        The physical channel implements algorithm processing such as DIS and LDC using different hardware acceleration units, and outputs the processed data to the buffer. The following figure shows the functional block diagram of the channel.

        After the DIS and LDC functions are enabled, when hi_mpi_vi_set_chn_attr is called, an extra VB is allocated for each function. That is, the depth of the channel attribute needs to be increased by 1.

      • Extended VI channel EXT_CHN

        It is not supported by the current version.

  • Binding relationship
    To transmit the video streams of the front-end camera module to the VI module through the MIPI for processing, the binding relationship between the device and the MIPI device must be met on the board-level connection of the Ascend AI Processor. Besides, as the flexible scheduling and orchestration on the software side must be ensured, you can adjust the binding relationship between the device and pipe.
    • Binding relationship between the DEV and MIPI device

      The binding relationship between the VI device and the MIPI RX/SLVS-EC device is fixed and cannot be configured. The following table lists the mappings:

      Table 1 Binding relationship between the VI device and the MIPI RX/SLVS-EC interface

      VI DEV

      MIPI RX

      SLVS-EC

      0

      0

      0

      1

      1

      1

      2

      2

      X

      3

      3

      X

    • The binding relationship between a device and a pipe is as follows:
      • Each pipe can be bound to any device by calling hi_mpi_vi_set_dev_bind_pipe. The pipe must be bound before being created by calling hi_mpi_vi_create_pipe. The binding relationship cannot be dynamically modified.
      • In linear mode (non-WDR mode), one device requires only one physical pipe. In WDR mode, one device requires multiple physical pipes, and only the channel of the first physical pipe bound to the device has data output. For example, in 2-to-1 WDR mode, pipe 0 and pipe 1 should be bound to the same device Dev0. Only the channel of pipe 0 outputs data.
  • LDC

    Some low-end lenses are prone to image distortion. The images of these lenses need to be corrected based on the distortion degree.

  • DIS

    The DIS module compares the current image with the previous two frames, calculates the jitter offset vectors of the current image in each axis using multiple degrees of freedom (DOF) DIS algorithms, and corrects the current image based on the jitter offset vectors. In this way, the DIS effect is achieved.

  • Low delay

    After a specified number of lines of an image are written to the DDR, the VI module reports an interrupt and sends the image to the back-end module for processing. In this way, the delay is reduced, and the hardware mechanism ensures that the image is written first and then read so that no image reading error occurs. 3DNR, DIS, and LDC modules are connected to the ISP_BE and support the low-delay function.

  • Slave mode

    Some sensors need to work in slave mode. In this case, the information about horizontal/vertical synchronization exposure synchronization needs to be provided externally, requiring the VI slave mode module. Determine the slave mode module to be used based on the sensor pin connection and the following table. Select the corresponding physical pipe ID to create a physical pipe or there will be no data.

    Table 2 Mapping between slave modes and pipes

    Slave Mode No.

    Number of Connectable Sensors

    Pin Name

    Advised Pipe ID

    0

    2

    SENSOR_VS0

    SENSOR_HS0

    0, 1

    1

    2

    SENSOR_VS1

    SENSOR_HS1

    2, 3

  • The acronyms and abbreviations related to the VI function are as follows:
    Table 3 Acronyms and abbreviations

    Acronyms and Abbreviations

    Full Name

    Description

    VI

    Video Input

    Video input

    WDR

    Wide Dynamic Range

    Wide dynamic range (WDR)

    BE

    Backend

    FPN and the subsequent part in the ISP pipeline

    FE

    Frontend

    The part before the FPN algorithm in the ISP pipeline

    DIS

    Digital Image Stabilization

    Digital image stabilization

    GME

    Global Motion Estimation

    Global motion estimation

    GYRO

    Gyroscope

    Gyro

    LDC

    Lens Distortion Correction

    Lens distortion correction

    MIPI

    Mobile Industry Processor Interface

    Mobile industry processor interface

    LVDS

    Low-Voltage Differential Signal

    Low-voltage differential signal

    HISPI

    High-Speed Serial Pixel Interface

    High-speed serial pixel interface

    SLVS-EC

    Scalable Low-Voltage Signaling interface with an Embedded Clock

    Scalable low-voltage signaling interface with an embedded clock

    IPC

    IP camera

    Network camera

    DV

    Digital Visual

    Digital video recording

    PMF

    Perspective Mapping Function

    Perspective mapping function

    MPP

    Media Processing Platform

    Media processing platform

    ISP

    Image Signal Processor

    Image signal processing

    Gyro DIS

    Gyroscope Digital Image Stabilization

    Gyroscope digital image stabilization