Endoscope host system and method supporting hot plug of multi-channel camera

By implementing hardware detection, dynamic device tree configuration, and power timing management, combined with user space services, the endoscope host system achieves hot-swapping of multi-channel cameras, solving the problem that the RK3588 processor cannot adapt to camera modules with different numbers of channels, and realizing plug-and-play and efficient video stream switching.

CN120935440APending Publication Date: 2025-11-11DAICHUAN MEDICAL (SHENZHEN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202510939413.4
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-07-08
Publication Date
2025-11-11

AI Technical Summary

Technical Problem

In existing fully SoC integrated endoscope host solutions, the RK3588 processor cannot adapt to camera modules with different numbers of channels, resulting in low efficiency of equipment replacement and long image interruption time during examinations or surgeries.

Method used

The hardware detection module detects the camera module status through GPIO interrupts, the dynamic device tree configuration module reads EDID information and generates device tree fragments, the power timing management module outputs voltage and clock signals in stages, the user space hot-swap service module realizes the reconstruction of the video stream pipeline, and the GStreamer plugin is used for seamless switching.

Benefits of technology

It enables plug-and-play functionality for camera modules with different numbers of MIPI data channels, shortening equipment replacement time, improving equipment compatibility and efficiency, and ensuring the continuity of medical imaging.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120935440A_ABST
    Figure CN120935440A_ABST
Patent Text Reader

Abstract

The invention discloses an endoscope host system and method supporting multi-channel camera hot plug, the system comprises a hardware detection module used for detecting the physical connection state of a camera module through GPIO interruption, the physical connection state comprises a plug-in state and a pull-out state; the dynamic equipment tree configuration module is used for reading EDID information of an EDID register in the camera module and generating equipment tree fragments; the power supply time sequence management module is used for outputting an I / O voltage, a core voltage and an MIPI clock signal in stages through a PMIC chip according to the voltage requirement in the EDID information; and the user space hot plug service module is used for triggering a video stream pipeline reconstruction script through a UDEV rule, and realizing video seamless switching by using a dynamic pipe plug-in of GStreamer.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of endoscope host technology, and more specifically, to an endoscope host system and method that supports hot-swappable multi-channel cameras. Background Technology

[0002] Currently, there are two main types of endoscope main unit solutions commonly found on the market:

[0003] Option 1: SoC+FPGA Collaborative Architecture: The core chip uses an ARM processor such as Rockchip RK3568, RV1126, or RK3588, paired with an FPGA (such as E.L.C. or Xilinx) to achieve parallel image processing. The FPGA is responsible for low-latency processing such as image acquisition, real-time noise reduction, and edge enhancement; the ARM processor completes encoding, storage, human-computer interaction, and AI algorithms. This solution balances high performance and flexibility, supports complex algorithm expansion, and is suitable for high-end scenarios such as 4K / fluorescence endoscopy, but the cost is relatively high.

[0004] Option 2: Full SoC Integration Solution: Based on the Rockchip RK3588 chip, an ISP module is integrated to directly process camera signals. This solution is low-cost and low-power, suitable for portable devices, but its image processing capabilities are limited, relying on the chip's native ISP performance.

[0005] As can be seen from the above, although Solution 1 is powerful, it is also expensive. Solution 2 is cheaper, more widely used, and suitable for cost-effective occasions. However, because the RK3588 cannot adapt to camera modules with different numbers of MIPI data channels, the host needs to be restarted to switch to different camera modules. This results in low efficiency of equipment replacement and long image interruption time during examinations or surgeries. Summary of the Invention

[0006] To overcome the problem that the RK3588 processor in existing fully SoC integrated endoscope host solutions cannot adapt to camera modules with different numbers of channels, resulting in low equipment replacement efficiency and long image interruption time during examination or surgery, this invention provides an endoscope host system and method that supports hot-swapping of multi-channel cameras.

[0007] The technical solution of this invention is as follows:

[0008] In a first aspect, the present invention provides an endoscope host system supporting hot-swappable multi-channel cameras, comprising:

[0009] The hardware detection module is used to detect the physical connection status of the camera module through GPIO interrupts. The physical connection status includes the insertion status and the removal status.

[0010] The dynamic device tree configuration module is used to read the EDID information of the EDID register in the camera module and generate a device tree fragment;

[0011] The power timing management module is used to output I / O voltage, core voltage and MIPI clock signal in stages through the PMIC chip according to the voltage requirements in the EDID information.

[0012] The user-space hot-swappable service module is used to trigger video stream pipeline reconstruction scripts through UDEV rules and to achieve seamless video switching using GStreamer's dynamic pipelines plugin.

[0013] Furthermore, the hardware detection module includes:

[0014] Connector detection pins are used to sense the physical connection status of the camera module in real time;

[0015] The GPIO interrupt controller is used to convert level changes of connector detection pins into system interrupt events;

[0016] The debounce circuit is used to filter out mechanical vibration noise through an RC low-pass filter circuit.

[0017] Furthermore, when the camera module is inserted, the level of the connector detection pin changes from high to low, the falling edge of the GPIO interrupt controller triggers an interrupt, and the debounce circuit debounces the signal. After the debounce timer is triggered and confirmed, the current physical connection state is locked.

[0018] Furthermore, after confirming the physical connection status of the camera module, the dynamic device tree configuration module uses I... 2 The C bus reads the EDID information from the EDID register in the camera module and parses out the number of camera channels, maximum resolution, and power consumption level.

[0019] Furthermore, the dynamic device tree configuration module dynamically loads the pre-compiled device tree fragments through the kernel's configfs interface based on the parsed number of camera channels, and updates the MIPIDPHY channel configuration, VOP binding relationship and ISP processing parameters in real time.

[0020] Furthermore, in single-channel mode, the dynamic device tree configuration module loads a 1-lane MIPIDSI configuration and binds it to the VOP0 port, with a maximum output resolution of 720p@30fps; in dual-channel mode, it loads a 2-lane MIPIDSI configuration and binds it to the VOP0 port, extending the output resolution to 1080p@60fps.

[0021] Furthermore, the power timing management module includes:

[0022] A reverse current protection circuit is used to automatically cut off the power supply and discharge residual charge when the camera module is pulled out.

[0023] Secondly, the present invention provides a multi-channel camera hot-swappable adaptive method, applied to the aforementioned endoscope host system supporting multi-channel camera hot-swappability, comprising:

[0024] Step S1: Detect the physical connection status of the camera module through GPIO interrupt and trigger the de-shake timer to confirm that the physical connection is stable;

[0025] Step S2: Read the EDID information of the EDID register in the camera module and parse out the number of channels, maximum resolution and power consumption level;

[0026] Step S3: Dynamically generate a device tree fragment based on the EDID information;

[0027] Step S4: Call the fdtoverlay tool to hot-load the device tree fragment into the kernel, reset the CSI / DSI controller, and initialize the DMA buffer pool;

[0028] Step S5: Rebuild the video stream pipeline by notifying the application via DBus.

[0029] Furthermore, in step 3, based on the number of camera channels in the EDID information, a pre-compiled device tree fragment is dynamically loaded through the kernel's configfs interface to update the MIPIDPHY channel configuration, VOP binding relationship, and ISP processing parameters in real time. The data-lanes parameter of MIPIDPHY is set to the number of detected channels, and the VOP port output mode is configured as split-mode or single-mode.

[0030] Furthermore, in step S4, the DMA buffer pool pre-allocation strategy is as follows:

[0031] Allocate a 720p NV12 buffer for the single-channel camera module;

[0032] Allocate a 1080p NV12 buffer for the dual-channel camera module.

[0033] According to the above-described solution, the beneficial effects of this invention are as follows:

[0034] 1. Supports hot-swapping of camera modules with different numbers of MIPI data channels. Through hardware detection module, dynamic device tree configuration module, power timing management module and user space hot-swapping service module, it can automatically identify the number of channels (1-2 lanes), resolution and power requirements when the camera module is inserted, and complete device tree reload and video stream switching within 50ms. It effectively solves the technical problem of low equipment replacement efficiency and long image interruption time during examination or surgery caused by different numbers of camera channels in traditional endoscope host.

[0035] 2. Through real-time hardware detection, atomic updates of driver status, and seamless restart of user space services, plug-and-play intelligent interaction is achieved between the camera module and the endoscope host, significantly improving equipment compatibility and usage efficiency in medical scenarios while ensuring the product's high cost-effectiveness. Attached Figure Description

[0036] Figure 1 This is a schematic diagram of the architecture of the endoscope host system that supports hot-swapping of multi-channel cameras in this invention.

[0037] Figure 2 This is a hot-swap timing flowchart of the endoscope host system supporting hot-swap of multi-channel cameras in this invention;

[0038] Figure 3 This is a dynamic device tree configuration logic diagram of the endoscope host system supporting hot-swappable multi-channel cameras in this invention;

[0039] Figure 4 This is a flowchart of the multi-channel camera hot-swappable adaptive method in this invention. Detailed Implementation

[0040] To make the technical problems to be solved, the technical solutions, and the beneficial effects of the present invention clearer, the present invention will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.

[0041] It should be noted that the terms "comprising" and "having," and any variations thereof, in the specification and claims of this invention are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or device that includes a series of steps or units is not limited to the steps or units listed, but may optionally include steps or units not listed, or may optionally include other steps or units inherent to these processes, methods, products, or devices.

[0042] Please refer to Figures 1 to 3The embodiments of the present invention provide an endoscope host system that supports hot-swapping of multi-channel cameras, including a hardware detection module, a dynamic device tree configuration module, a power timing management module, and a user space hot-swapping service module.

[0043] The hardware detection module is used to detect the physical connection status of the camera module via GPIO interrupts. The physical connection status includes insertion and removal states. The hardware detection module includes a connector detection pin (CAM_DET#), a GPIO interrupt controller, and a debounce circuit. The connector detection pin is used to sense the physical connection status of the camera module in real time. When the camera module is inserted, the connector detection pin is grounded, and its level changes from high to low. When the camera module is removed, the connector detection pin remains high (pulled up by a pull-up resistor). The GPIO interrupt controller converts the level change of the connector detection pin into a system interrupt event. The debounce circuit filters out signal noise caused by mechanical jitter (i.e., mechanical jitter noise) using an RC low-pass filter. When the camera module is inserted, the level of the connector detection pin changes from high to low, triggering an interrupt on the falling edge of the GPIO interrupt controller. This interrupt is then debounced by the debounce circuit. After a debounce timer (e.g., 100ms) triggers confirmation, the current physical connection status is locked, ensuring the stability and reliability of the physical connection status detection and avoiding false detections caused by mechanical jitter.

[0044] The dynamic device tree configuration module is used to confirm the physical connection status of the camera module and then configure it via I... 2 The C-bus reads the EDID information from the EDID register in the camera module and parses key parameters such as the number of camera channels, maximum resolution, and power consumption level, providing accurate data support for subsequent device tree configuration. Then, based on the parsed number of camera channels, a pre-compiled device tree fragment (DTBO) is dynamically loaded through the kernel's configfs interface, updating the MIPIDPHY channel configuration, VOP binding relationships, and ISP processing parameters in real time. This allows the system to flexibly configure itself according to different camera module parameters, meeting the operational requirements of camera modules with varying numbers of channels and resolutions. The dynamic device tree configuration module also supports multi-channel loading, including single-channel and dual-channel modes. In single-channel mode, a 1-lane MIPIDSI configuration is loaded and bound to the VOP0 port, with a maximum output resolution of 720p@30fps. In dual-channel mode, a 2-lane MIPIDSI configuration is loaded and bound to the VOP0 port, extending the output resolution to 1080p@60fps. This achieves compatibility and adaptation for camera modules with different numbers of channels, improving the system's flexibility and adaptability.

[0045] The power timing management module, based on the voltage requirements in the EDID information, outputs I / O voltage, core voltage, and MIPI clock signals in stages via the PMIC chip, with a timing error ≤10μs, to effectively protect the hardware. The reasons for the staged power supply by the PMIC chip are as follows: Firstly, to prevent latch-up effects, if all voltages are applied simultaneously, the parasitic thyristors inside the CMOS device may be triggered by the voltage difference, leading to a short circuit and burnout; staged power-up allows each voltage domain to establish up slowly, avoiding instantaneous voltage differences. Secondly, to meet hardware timing requirements, i.e., the processor must first obtain I / O voltage (e.g., 1.8V) before configuring GPIO and I / O pins. 2 C, then through I 2 The C-bus controls the PMIC chip to output its core voltage (e.g., 3.3V). The power timing management module also includes a reverse current protection circuit. When the camera module is removed, the power timing management module automatically cuts off the power supply and discharges residual charge through the reverse current protection circuit. The reverse current is ≤1mA, which further improves the reliability of the system, prevents the reverse current from damaging the equipment, and ensures the safety of the system during the insertion and removal of the camera module.

[0046] The user space hot-swappable service module is used to trigger the video stream pipeline reconstruction script through UDEV rules and use GStreamer's dynamic pipelines plugin to achieve seamless video switching with a switching latency of ≤1 frame period, ensuring the continuity of medical images and avoiding image interruption caused by camera module switching, thus providing stable and continuous image support for medical workers.

[0047] GStreamer is an open-source multimedia processing framework based on a plugin architecture, widely used in scenarios such as audio and video acquisition, processing, encoding, decoding, and rendering. It adopts a modular design, allowing for the flexible construction of complex multimedia processing pipelines through the combination of different plugins. It boasts high scalability and cross-platform compatibility (supporting Linux, Windows, macOS, and other systems). The `dynamic pipelines` plugin in GStreamer is used for dynamically managing pipelines, primarily addressing the dynamic reconfiguration problem during pipeline runtime. It is particularly suitable for scenarios requiring real-time switching of video sources, resolutions, or processing flows (such as the hot-swappable camera scenario in this invention).

[0048] in, Figure 2This paper illustrates the hot-plug timing flow of an endoscope host system supporting multi-channel camera hot-plugging according to the present invention. It demonstrates the T0-T5 timing nodes from GPIO interrupt triggering to video stream recovery, including power stabilization time, device tree loading time, and video rendering latency. The hot-plug timing flow is as follows: GPIO interrupt is triggered at timing node T0; debouncing is confirmed at timing node T1; EDID reading and device tree loading are completed at timing node T2; DPHY reading and power readiness are completed at timing node T3; clock stabilization and pipeline reconstruction are triggered at timing node T4; and video stream recovery is achieved at timing node T5.

[0049] in, Figure 3 The dynamic device tree configuration logic of the endoscope host system supporting hot-swappable multi-channel cameras of the present invention is shown to compare the differences in device tree parameters and VOP port binding rules between single-channel and dual-channel modes.

[0050] This embodiment provides an endoscope host system that supports hot-swapping of multi-channel cameras. It supports hot-swapping of camera modules with different numbers of MIPI data channels. Through a hardware detection module, a dynamic device tree configuration module, a power timing management module, and a user space hot-swapping service module, it automatically identifies the number of channels (1-2 lanes), resolution, and power requirements when a camera module is inserted. It completes device tree reload and video stream switching within 50ms, effectively solving the technical problems of low equipment replacement efficiency and long image interruption times during examinations or surgeries caused by different numbers of camera channels in traditional endoscope host systems. Through real-time hardware detection, atomic updates of driver states, and seamless restart of user space services, it enables plug-and-play intelligent interaction between the camera module and the endoscope host, significantly improving equipment compatibility and usage efficiency in medical scenarios while ensuring high product cost-effectiveness.

[0051] Please see Figure 4 In one embodiment, the present invention provides a multi-channel camera hot-swappable adaptive method, applied to the above-mentioned endoscope host system supporting multi-channel camera hot-swappability, comprising the following steps:

[0052] Step S1: Detect the physical connection status of the camera module through GPIO interrupt and trigger the de-shake timer (e.g., 100ms) to confirm that the physical connection is stable.

[0053] In this step, the insertion and removal status of the camera module can be detected in real time through GPIO interrupt, ensuring that the system responds to hardware changes in a timely manner; by triggering the de-shake timer, the RC low-pass filter circuit is used to filter out signal noise caused by mechanical jitter, avoiding false detection caused by jitter, and ensuring the accuracy and stability of physical connection status detection.

[0054] Step S2, via I2 The C bus reads the EDID information from the EDID register in the camera module and parses out the number of channels, maximum resolution, and power consumption level.

[0055] In this step, through I 2 By reading the EDID information from the EDID register in the camera module via the C bus, key parameters such as the number of channels, maximum resolution, and power consumption level can be accurately obtained, providing a basis for subsequent configuration. The parsed parameters are the foundation for subsequent operations such as dynamically generating device tree segments, performing power management, and rebuilding the video stream pipeline, ensuring that the system can be accurately configured according to the actual situation of the camera module.

[0056] Step S3: Dynamically generate device tree fragments based on EDID information.

[0057] Specifically, based on the number of camera channels in the EDID information, a pre-compiled device tree fragment is dynamically loaded through the kernel's configfs interface to update the MIPIDPHY channel configuration, VOP binding relationship, and ISP processing parameters in real time, so that the hardware configuration matches the actual needs of the camera module. Among them, the data-lanes parameter of MIPIDPHY is set to the number of detected channels, and the VOP port output mode is configured as split-mode or single-mode, which realizes flexible support for single-channel (1Lane) and dual-channel (2Lane) modes to meet different resolution output requirements, such as a maximum output of 720p@30fps in single-channel mode and 1080p@60fps in dual-channel mode.

[0058] Step S4: Call the fdtoverlay tool to hot-load the device tree fragment into the kernel, reset the CSI / DSI controller and initialize the DMA buffer pool to ensure that the hardware controller is in the correct working state and to prepare for the transmission and processing of video data.

[0059] Specifically, the DMA buffer pool pre-allocation strategy is as follows: a 720p NV12 buffer is allocated for single-channel camera modules; and a 1080p NV12 buffer is allocated for dual-channel camera modules. This DMA buffer pool pre-allocation strategy allocates buffers of different specifications based on the number of camera channels, rationally optimizing memory resource usage and improving the efficiency of video data processing.

[0060] Step S5: The application is notified via DBus to rebuild the video stream pipeline, and the dynamicpipelines plugin of GStreamer is used to achieve seamless video switching with a switching delay of ≤1 frame period, ensuring the continuity of the video stream and avoiding image interruption caused by switching, thus providing stable image display for medical operations.

[0061] DBus is an inter-process communication (IPC) system originally developed by the GNOME project. It enables efficient communication between applications in Unix systems such as Linux, and also bridges the gap between applications and operating system services. Combining message bus, object system, and service discovery functionalities, it is a core component of modern Linux desktop environments and many embedded systems. Through structured communication, dynamic service discovery, and efficient signaling mechanisms, DBus provides real-time, flexible, and reliable support for the hot-swappable adaptive functionality of endoscope hosts. While maintaining cost-effectiveness, it significantly enhances the intelligent interaction capabilities of endoscope hosts, making it particularly suitable for surgical or examination scenarios requiring frequent camera module replacements.

[0062] The multi-channel camera hot-swappable adaptive method provided in this embodiment can complete the entire process from physical connection detection of the camera module to video stream recovery within 50ms. Compared with the traditional solution that requires restarting the host to switch camera modules, it significantly shortens the image interruption time when changing equipment and significantly improves the efficiency of equipment change during examination or surgery. Through the coordinated work of each step, intelligent interaction is achieved between the camera module and the endoscope host. It can automatically complete operations such as recognition, configuration and switching without manual intervention, truly achieving a plug-and-play effect. It can support hot-swapping of camera modules with different numbers of MIPI data channels (1-2 lanes), meeting the needs of different types of camera modules in medical scenarios and improving equipment compatibility. Without increasing costs too much, it solves the defects of traditional full SoC integrated solutions, achieving high performance hot-swappable adaptive function while ensuring high cost performance.

[0063] Those skilled in the art will understand that various aspects of the present invention can be implemented as systems, methods, or program products. Therefore, various aspects of the present invention can be specifically implemented in the following forms: entirely hardware implementations, entirely software implementations (including firmware, microcode, etc.), or implementations combining hardware and software aspects, collectively referred to herein as “circuits,” “modules,” or “systems.”

[0064] Any one or more of the modules, submodules, units, and subunits according to this embodiment, or at least part of the functions of any one or more of them, can be implemented in one module. Any one or more of the modules, submodules, units, and subunits according to this embodiment can be implemented by dividing them into multiple modules. Any one or more of the modules, submodules, units, and subunits according to this embodiment can be at least partially implemented as hardware circuits, such as field-programmable gate arrays (FPGAs), programmable logic arrays (PLAs), systems-on-a-chip, systems-on-a-substrate, systems-on-package, application-specific integrated circuits (ASICs), or implemented by hardware or firmware in any other reasonable manner by integrating or packaging circuits, or implemented in software, hardware, and firmware, or in any appropriate combination of any of these three implementation methods. Alternatively, one or more of the modules, submodules, units, and subunits according to this embodiment can be at least partially implemented as computer program modules, which, when run, can perform corresponding functions.

[0065] In one embodiment, the present invention provides an endoscope host device supporting hot-swappable multi-channel cameras, which may include at least one processor and at least one memory. The processor may be an RK3588 processor, which stores program code that, when executed by a processing unit, causes the processing unit to perform the steps in the multi-channel camera hot-swappable adaptive method according to various exemplary embodiments of the present invention described above. For example, the RK3588 processor can perform, for example... Figure 2 The flowchart illustrates the adaptive method for hot-swapping multi-channel cameras.

[0066] In one embodiment, the present invention provides a computer-readable medium storing computer-executable instructions for performing the steps of the multi-channel camera hot-plug adaptive method according to various exemplary embodiments of the present invention described above.

[0067] A readable medium can be a readable signal medium or a readable storage medium. A readable storage medium can be, for example—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. A readable signal medium can include data signals propagated in baseband or as part of a carrier wave, carrying readable program code. A readable signal medium can also be any readable medium other than a readable storage medium, capable of transmitting, propagating, or transmitting a program for use by or in conjunction with an instruction execution system, apparatus, or device. The program code contained on the readable medium can be transmitted using any suitable medium, including—but not limited to—wireless, wired, optical fiber, RF, etc., or any suitable combination thereof.

[0068] Furthermore, although the operations of the method of the present invention are described in a specific order in the accompanying drawings, this does not require or imply that these operations must be performed in that specific order, or that all the operations shown must be performed to achieve the desired result. Additionally or alternatively, certain steps may be omitted, multiple steps may be combined into one step, and / or one step may be broken down into multiple steps.

[0069] It should be understood that those skilled in the art can make improvements or modifications based on the above description, and all such improvements and modifications should fall within the protection scope of the appended claims.

[0070] The present invention has been described above with reference to the accompanying drawings. Obviously, the implementation of the present invention is not limited to the above-described manner. Any improvements made using the inventive concept and technical solution of the present invention, or the direct application of the inventive concept and technical solution of the present invention to other situations without modification, are all within the protection scope of the present invention.

Claims

1. An endoscope host system supporting hot-swappable multi-channel cameras, characterized in that, include: The hardware detection module is used to detect the physical connection status of the camera module through GPIO interrupts. The physical connection status includes the insertion status and the removal status. The dynamic device tree configuration module is used to read the EDID information of the EDID register in the camera module and generate a device tree fragment; The power timing management module is used to output I / O voltage, core voltage and MIPI clock signal in stages through the PMIC chip according to the voltage requirements in the EDID information. The user space hot-swappable service module is used to trigger video stream pipeline reconstruction scripts through UDEV rules and to achieve seamless video switching using GStreamer's dynamic pipelines plugin.

2. The endoscope host system supporting hot-swappable multi-channel cameras according to claim 1, characterized in that, The hardware detection module includes: Connector detection pins are used to sense the physical connection status of the camera module in real time; The GPIO interrupt controller is used to convert level changes of connector detection pins into system interrupt events; The debounce circuit is used to filter out mechanical vibration noise through an RC low-pass filter circuit.

3. The endoscope host system supporting hot-swappable multi-channel cameras according to claim 2, characterized in that, When the camera module is inserted, the level of the connector detection pin changes from high to low. The falling edge of the GPIO interrupt controller triggers an interrupt, and the debounce circuit debounces the signal. After the debounce timer is triggered and confirmed, the current physical connection state is locked.

4. The endoscope host system supporting hot-swappable multi-channel cameras according to claim 1, characterized in that, After the dynamic device tree configuration module confirms the physical connection status of the camera module, it uses I... 2 The C bus reads the EDID information from the EDID register in the camera module and parses out the number of camera channels, maximum resolution, and power consumption level.

5. The endoscope host system supporting hot-swappable multi-channel cameras according to claim 4, characterized in that, The dynamic device tree configuration module dynamically loads the pre-compiled device tree fragments through the kernel's configfs interface based on the parsed number of camera channels, and updates the MIPIDPHY channel configuration, VOP binding relationship and ISP processing parameters in real time.

6. The endoscope host system supporting hot-swappable multi-channel cameras according to claim 5, characterized in that, In single-channel mode, the dynamic device tree configuration module loads a 1-lane MIPIDSI configuration and binds it to the VOP0 port, with a maximum output resolution of 720p@30fps; in dual-channel mode, it loads a 2-lane MIPIDSI configuration and binds it to the VOP0 port, extending the output resolution to 1080p@60fps.

7. The endoscope host system supporting hot-swappable multi-channel cameras according to claim 1, characterized in that, The power timing management module includes: A reverse current protection circuit is used to automatically cut off the power supply and discharge residual charge when the camera module is pulled out.

8. A multi-channel camera hot-swappable adaptive method, applied to the endoscope host system supporting multi-channel camera hot-swappability as described in any one of claims 1-7, characterized in that, include: Step S1: Detect the physical connection status of the camera module through GPIO interrupt and trigger the de-shake timer to confirm that the physical connection is stable; Step S2: Read the EDID information of the EDID register in the camera module and parse out the number of channels, maximum resolution and power consumption level; Step S3: Dynamically generate a device tree fragment based on the EDID information; Step S4: Call the fdtoverlay tool to hot-load the device tree fragment into the kernel, reset the CSI / DSI controller, and initialize the DMA buffer pool; Step S5: Rebuild the video stream pipeline by notifying the application via DBus.

9. The multi-channel camera hot-swappable adaptive method according to claim 8, characterized in that, In step 3, based on the number of camera channels in the EDID information, a pre-compiled device tree fragment is dynamically loaded through the kernel's configfs interface to update the MIPIDPHY channel configuration, VOP binding relationship and ISP processing parameters in real time. The data-lanes parameter of MIPIDPHY is set to the number of detected channels, and the VOP port output mode is configured as split-mode or single-mode.

10. The multi-channel camera hot-swappable adaptive method according to claim 8, characterized in that, In step S4, the DMA buffer pool pre-allocation strategy is as follows: Allocate a 720p NV12 buffer for the single-channel camera module; Allocate a 1080p NV12 buffer for the dual-channel camera module.