Control method, device, and program product for monitoring equipment

By using a magnetic encoder disk and a magnetic chip to collect magnetic field data in a spherical camera, and combining this with a neural network model to adjust the correction strategy, the problems of low correction accuracy and frequent correction in spherical cameras are solved, achieving high-precision and low-cost automatic correction control.

CN120475142BActive Publication Date: 2026-06-05CHINA TOWER CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
CHINA TOWER CO LTD
Filing Date
2025-07-15
Publication Date
2026-06-05

AI Technical Summary

Technical Problem

Existing methods for correcting the polarization of spherical cameras suffer from low accuracy, frequent corrections, and high costs, failing to effectively address the problem of poor polarization correction performance.

Method used

By acquiring the rotation angle and magnetic field data of the target motor, magnetic field data is collected using a magnetic encoder disk and a magnetic chip. Combined with the magnetic field angle mapping relationship, the actual rotation angle of the motor is calculated, and correction control is performed based on the angle difference. A neural network model is used to adaptively adjust the preset difference threshold and generate a reverse pulse sequence for correction.

Benefits of technology

It improves the correction accuracy of spherical cameras, reduces correction costs, achieves efficient automatic correction control, and reduces equipment power consumption and frequent correction phenomena.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120475142B_ABST
    Figure CN120475142B_ABST
Patent Text Reader

Abstract

The application discloses a kind of control method, device and program product of monitoring equipment.It relates to the field of video monitoring.The method comprises: obtaining the rotation angle of the recorded target motor at the current time, to obtain the first rotation angle, wherein the target motor is deployed in monitoring equipment, for driving monitoring equipment to rotate;Collecting the magnetic field data of monitoring equipment, to obtain target magnetic field data;Based on target magnetic field data, determine the second rotation angle, wherein the second rotation angle includes: the actual rotation angle of the target motor at the current time;Based on the first rotation angle and the second rotation angle, the target motor is controlled to correct deviation.The present application solves the technical problem of poor correction effect of the related art for correcting spherical camera.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of video surveillance, and more specifically, to a control method, device, and program product for surveillance equipment. Background Technology

[0002] In related technologies, the correction methods used by PTZ cameras (i.e., dome cameras) with active correction function are mainly pneumatic active correction, electro-hydraulic combined correction, and intelligent video analysis. However, the accuracy of pneumatic active correction and electro-hydraulic combined correction is generally low, the development cost of intelligent video analysis is too high, and there is frequent correction phenomenon. Moreover, the standby power consumption is far higher than that of ordinary threshold correction PTZ cameras.

[0003] There is currently no effective solution to the problem of poor correction performance when using spherical cameras for image correction. Summary of the Invention

[0004] The main objective of this application is to provide a control method, device, and program product for monitoring equipment to solve the problem of poor correction effect when correcting the deviation of spherical cameras in related technologies.

[0005] To achieve the above objectives, according to one aspect of this application, a control method for a monitoring device is provided. The method includes: acquiring a recorded rotation angle of a target motor at a current moment to obtain a first rotation angle, wherein the target motor is deployed in the monitoring device to drive the monitoring device to rotate; collecting magnetic field data of the monitoring device to obtain target magnetic field data; determining a second rotation angle based on the target magnetic field data, wherein the second rotation angle includes the actual rotation angle of the target motor at the current moment; and performing correction control on the target motor based on the first rotation angle and the second rotation angle.

[0006] Further, the target magnetic field data includes: magnetic field data of the magnetic field generated by the magnetic encoder disk, wherein the magnetic encoder disk is deployed at the end of the shaft of the target motor. Determining the second rotation angle based on the target magnetic field data includes: acquiring a magnetic field angle mapping relationship, wherein the magnetic field angle mapping relationship includes: a mapping relationship between the magnetic field data of the magnetic encoder disk and the actual rotation angle of the target motor, and the magnetic field angle mapping relationship is calibrated once every preset time interval; and determining the second rotation angle based on the target magnetic field data and the magnetic field angle mapping relationship.

[0007] Further, based on the first rotation angle and the second rotation angle, the target motor is subjected to correction control, including: calculating the difference between the first rotation angle and the second rotation angle to obtain an angle difference; comparing the angle difference with a preset difference threshold to obtain a comparison result, and determining whether the target motor has an offset based on the comparison result; and performing correction control on the target motor if the target motor has an offset.

[0008] Further, the preset difference threshold is determined by: obtaining target parameters, wherein the target parameters include at least one of the following: environmental parameters of the environment in which the target motor is located, and operating parameters of the target motor, wherein the operating parameters include at least one of the following: running time, load weight; inputting the target parameters and the angle difference into the target model, and outputting the preset difference threshold, wherein the target model includes: a neural network model trained based on the correction records of the target motor over a historical time period.

[0009] Furthermore, in the event of a deviation in the target motor, the target motor is subjected to correction control, which includes: generating a reverse pulse sequence based on the angle difference when the target motor is deviated, wherein the reverse pulse sequence is used to drive the target motor to rotate; and performing correction control on the target motor based on the reverse pulse sequence.

[0010] Further, after performing correction control on the target motor based on the reverse pulse sequence, the method includes: obtaining the number of consecutive corrections, wherein the number of consecutive corrections includes the number of times the target motor has been continuously corrected; comparing the number of consecutive corrections with a preset number threshold; if the number of consecutive corrections is greater than the preset number threshold, performing correction control on the target motor using a target correction mode and generating fault prompt information, wherein the target correction mode includes: directly controlling the target motor to rotate when the difference between the recorded rotation angle of the target motor and the actual rotation angle of the target motor is greater than a preset difference threshold.

[0011] To achieve the above objectives, according to another aspect of this application, a control device for a monitoring device is provided. The control device is used to execute the control method for the monitoring device, and includes: a target motor for driving the monitoring device to rotate; a magnetic encoder deployed at the tail of the target motor for collecting magnetic field data of the monitoring device to obtain target magnetic field data; and a target chip connected to the magnetic encoder for recording a first rotation angle of the target motor, determining a second rotation angle based on the target magnetic field data, and performing correction control on the target motor based on the first rotation angle and the second rotation angle, wherein the second rotation angle includes the actual rotation angle of the target motor at the current moment.

[0012] Furthermore, the magnetic encoder also includes: a magnetic encoder disk deployed at the end of the shaft of the target motor, which generates different magnetic fields as the target motor rotates; and a magnetic chip for acquiring the target magnetic field data, wherein the target magnetic field data includes: magnetic field data of the magnetic field generated by the magnetic encoder disk at the current moment.

[0013] Furthermore, the monitoring device also includes: a driven shaft for controlling the rotation of the monitoring device; a gear set including a first synchronous pulley and a second synchronous pulley, the first synchronous pulley being connected to the output shaft of the target motor, and the second synchronous pulley being connected to the driven shaft, the gear set being made of copper; a belt connecting the first synchronous pulley and the second synchronous pulley, for controlling the rotation of the monitoring device by using the target motor to drive the driven shaft to rotate based on the gear set; and a tensioning pulley for controlling the tension of the belt.

[0014] According to another aspect of this application, a computer-readable storage medium is provided, the computer-readable storage medium including a stored executable program, wherein, when the executable program is executed, it controls the device where the computer-readable storage medium is located to perform the control method of the monitoring device.

[0015] According to another aspect of this application, an electronic device is provided, comprising: a memory storing an executable program; and a processor for running the program, wherein the program executes a control method for the monitoring device during runtime.

[0016] According to another aspect of this application, a computer program product is provided, including computer instructions that, when executed by a processor, implement the steps of the control method for the monitoring device.

[0017] In this embodiment, the rotation angle of the target motor at the current moment is obtained to obtain a first rotation angle. The target motor is deployed in the monitoring equipment to drive the rotation of the monitoring equipment. Magnetic field data of the monitoring equipment is collected to obtain target magnetic field data. Based on the target magnetic field data, a second rotation angle is determined, where the second rotation angle includes the actual rotation angle of the target motor at the current moment. Based on the first and second rotation angles, the target motor is subjected to correction control, thereby solving the technical problem of poor correction effect for spherical cameras in related technologies. In this application, the correction control of the target motor in the monitoring equipment based on magnetic field data avoids the low correction accuracy of pneumatic active correction methods and electro-hydraulic combined correction methods in related technologies, thus achieving the technical effect of improving the correction accuracy of spherical cameras. Attached Figure Description

[0018] The accompanying drawings, which form part of this application, are used to provide a further understanding of this application. The illustrative embodiments and descriptions of this application are used to explain this application and do not constitute an undue limitation of this application. In the drawings:

[0019] Figure 1 A hardware structure block diagram of a computer terminal for implementing a control method for monitoring equipment is shown.

[0020] Figure 2 This is a flowchart of a control method for a monitoring device provided according to an embodiment of this application;

[0021] Figure 3 This is a schematic diagram of a control device for a monitoring equipment according to an embodiment of this application. Figure 1 ;

[0022] Figure 4 This is a schematic diagram of a control device for a monitoring equipment according to an embodiment of this application. Figure 2 ;

[0023] Figure 5 This is a schematic diagram of a control device for a monitoring equipment according to an embodiment of this application. Figure 3 ;

[0024] Figure 6 This is a structural block diagram of an electronic device according to an embodiment of this application. Detailed Implementation

[0025] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort should fall within the scope of protection of the present application.

[0026] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.

[0027] It should be noted that the information collected in this application (including but not limited to user device information, user personal information, etc.) and data (including but not limited to data used for display, data used for analysis, etc.) are information and data authorized by the user or fully authorized by all parties. Furthermore, the collection, storage, use, processing, transmission, provision, disclosure, and application of this data all comply with relevant laws, regulations, and standards, necessary confidentiality measures have been taken, and they do not violate public order and good morals. Corresponding access points are provided for users to choose to authorize or refuse. For example, interfaces are set up between this system and relevant users or organizations, providing users with corresponding access points to choose to agree to or refuse automated decision-making results; if the user chooses to refuse, the process proceeds to the expert decision-making stage.

[0028] Example 1

[0029] According to an embodiment of this application, a method embodiment for controlling a monitoring device is also provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.

[0030] The method embodiment provided in Embodiment 1 of this application can be executed on a mobile terminal, computer terminal, or similar computing device. Figure 1A hardware block diagram of a computer terminal (or mobile device) for implementing a control method for monitoring equipment is shown. Figure 1 As shown, the computer terminal 10 (or mobile device) may include one or more processors 102 (shown as 102a, 102b, ..., 102n in the figure) 102 (processor 102 may include, but is not limited to, a microprocessor MCU or a programmable logic device FPGA, etc.), a memory 104 for storing data, and a transmission device 106 for communication functions. In addition, it may also include: a display, an input / output interface (I / O interface), a universal serial bus (USB) port (which may be included as one of the ports of a BUS bus), a network interface, a power supply, and / or a camera. Those skilled in the art will understand that... Figure 1 The structure shown is for illustrative purposes only and does not limit the structure of the aforementioned electronic device. For example, computer terminal 10 may also include... Figure 1 The more or fewer components shown, or having the same Figure 1 The different configurations shown.

[0031] It should be noted that the aforementioned one or more processors 102 and / or other data processing circuits are generally referred to herein as "data processing circuits". These data processing circuits may be embodied, in whole or in part, in software, hardware, firmware, or any other combination thereof. Furthermore, the data processing circuits may be a single, independent processing module, or may be integrated, in whole or in part, into any other element within the computer terminal 10 (or mobile device). As involved in the embodiments of this application, the data processing circuits serve as a processor control mechanism (e.g., selection of a variable resistor termination path connected to an interface).

[0032] The memory 104 can be used to store software programs and modules of application software, such as the program instructions / data storage device corresponding to the control method of the monitoring device in this embodiment. The processor 102 executes various functional applications and data processing by running the software programs and modules stored in the memory 104, thereby realizing the aforementioned control method of the monitoring device. The memory 104 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 104 may further include memory remotely located relative to the processor 102, and these remote memories can be connected to the computer terminal 10 via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.

[0033] The transmission device 106 is used to receive or send data via a network. Specific examples of the network described above may include a wireless network provided by the communication provider of the computer terminal 10. In one example, the transmission device 106 includes a Network Interface Controller (NIC), which can connect to other network devices via a base station to communicate with the Internet. In another example, the transmission device 106 may be a Radio Frequency (RF) module, used for wireless communication with the Internet.

[0034] The display can be, for example, a touchscreen liquid crystal display (LCD), which allows the user to interact with the user interface of the computer terminal 10 (or mobile device).

[0035] Under the aforementioned operating environment, this application provides the following: Figure 2 The control method of the monitoring equipment shown. Figure 2 This is a flowchart of a control method for a monitoring device according to Embodiment 1 of this application.

[0036] Step S201: Obtain the recorded rotation angle of the target motor at the current moment to obtain the first rotation angle, wherein the target motor is deployed in the monitoring equipment to drive the monitoring equipment to rotate.

[0037] The target motor can be a stepper motor, the monitoring device can be a spherical camera (PTZ camera), and the first rotation angle can be the rotation angle of the target motor recorded by the monitoring device at the current moment. For example, the main control chip in the monitoring device can record the theoretical number of steps of the target motor (e.g., each pulse corresponds to 0.01° rotation angle), and the first rotation angle can be stored in the main control chip as the theoretical position value P1.

[0038] Step S202: Collect the magnetic field data of the monitoring equipment to obtain the target magnetic field data.

[0039] To avoid the poor performance of pneumatic active correction methods, electro-hydraulic combined correction methods, and intelligent video analysis, this embodiment utilizes a monitoring device that generates magnetic fields of varying intensities depending on the target motor's angle. For example, a magnetic encoder disk can be integrated into the monitoring device. This magnetic field, which varies with the rotation angle, can be collected to obtain the target magnetic field data, facilitating the subsequent determination of the target motor's actual rotation angle. For instance, the magnetic field strength of the encoder disk (i.e., the target magnetic field data) can be collected in real-time using a magnetic chip within the encoder, with a sampling frequency of 1Hz.

[0040] Step S203: Based on the target magnetic field data, determine the second rotation angle, wherein the second rotation angle includes the actual rotation angle of the target motor at the current moment.

[0041] In this embodiment, the target magnetic field data can be converted into the actual rotation angle of the target motor through the magnetic field angle mapping relationship (e.g., a preset magnetic field-angle mapping table (used for calibration data)), which can be recorded as the actual position value P2 (corresponding to the second rotation angle).

[0042] Step S204: Based on the first rotation angle and the second rotation angle, perform correction control on the target motor.

[0043] Based on the difference between the first rotation angle and the second rotation angle, it can be determined whether the target motor has a deviation. If a deviation exists, the target motor can be corrected. If no deviation exists, no correction control is required.

[0044] In this embodiment, through the above steps, the target motor in the monitoring equipment is controlled for correction based on magnetic field data. This avoids the low correction accuracy of pneumatic active correction methods and electro-hydraulic combined correction methods in related technologies, thereby improving the correction accuracy of the spherical camera. This solves the technical problem of poor correction effect when correcting spherical cameras in related technologies.

[0045] Optionally, in the control method of the monitoring device provided in Embodiment 1 of this application, the target magnetic field data includes: magnetic field data of the magnetic field generated by the magnetic encoder disk, wherein the magnetic encoder disk is deployed at the end of the shaft of the target motor. Determining the second rotation angle based on the target magnetic field data includes: obtaining a magnetic field angle mapping relationship, wherein the magnetic field angle mapping relationship includes: a mapping relationship between the magnetic field data of the magnetic encoder disk and the actual rotation angle of the target motor, and the magnetic field angle mapping relationship is calibrated once every preset time interval; and determining the second rotation angle based on the target magnetic field data and the magnetic field angle mapping relationship.

[0046] In monitoring equipment, magnetic fields of different intensities can be generated as the angle of the target motor changes. For example, a magnetic encoder disk can be built into the monitoring equipment. The magnetic encoder disk can be a special encoder that generates a specific magnetic field distribution when it rotates on the shaft of the target motor. This magnetic field distribution has a direct correspondence with the rotation angle of the shaft, that is, different rotation angles correspond to different magnetic field data.

[0047] The aforementioned magnetic field angle mapping relationship can be a table or function relating the magnetic field data of the magnetic encoder disk to the actual rotation angle of the target motor. During initialization or periodic calibration, a series of magnetic field data can be collected, and the corresponding rotation angle of the motor can be recorded, thereby establishing a mapping relationship between the magnetic field data and the actual angle. This relationship can be a dataset obtained through experiments or a functional expression obtained through mathematical modeling.

[0048] In this embodiment, the magnetic field angle mapping relationship can be acquired or updated. The magnetic field angle mapping relationship can be calibrated when the monitoring device is started or at a preset time (e.g., daily, weekly, etc.) to ensure that the mapping between the magnetic field data and the actual angle is up-to-date and can reflect any possible environmental changes (such as temperature, magnetic field interference, etc.). For example, a self-calibration process can be performed every 24 hours, such as driving the motor to rotate 360° and recording the magnetic field data for the entire circumference (e.g., the magnetic field data of the magnetic encoder disk collected by the magnetic chip), and updating the magnetic field-angle mapping table (i.e., the magnetic field angle mapping relationship).

[0049] In the magnetic field angle mapping relationship, the target magnetic field data can be converted into the actual rotation angle by searching or calculating to obtain the second rotation angle.

[0050] By combining magnetic field data with angle mapping, the actual rotation state of the target motor can be monitored in real time, thereby improving the angle control accuracy of monitoring equipment or other automated equipment.

[0051] Optionally, in the control method of the monitoring device provided in Embodiment 1 of this application, the target motor is subjected to correction control based on the first rotation angle and the second rotation angle, including: calculating the difference between the first rotation angle and the second rotation angle to obtain the angle difference; comparing the angle difference with a preset difference threshold to obtain a comparison result, and determining whether the target motor has an offset based on the comparison result; and performing correction control on the target motor if the target motor has an offset.

[0052] In this embodiment, the difference between the first rotation angle and the second rotation angle, i.e., the angle difference, can be calculated. The angle difference is the deviation between the actual position of the target motor and the recorded theoretical position, used to assess whether the motor has accurately reached the predetermined position. The angle difference can then be compared with a preset difference threshold. The difference threshold can be an allowable deviation range used to determine whether the motor's offset is within an acceptable range. If the absolute value of the angle difference exceeds the preset difference threshold, it indicates a significant deviation between the actual rotation angle of the target motor and the recorded theoretical rotation angle, and it can be determined that the target motor is offset. If the absolute value of the angle difference is less than or equal to the preset difference threshold, it can be determined that the rotation angle of the target motor is within an acceptable deviation range, the target motor is operating normally, and no correction control is required.

[0053] For example, the positional deviation ΔP can be obtained by calculating |P1-P2|. If ΔP > threshold... If the value is determined to be a target motor offset (corresponding to a preset difference threshold) (e.g., 0.2°), a correction command can be triggered to perform correction control on the target motor.

[0054] By automatically correcting the target motor, precise control of the motor is ensured, thereby improving the stability and accuracy of the monitoring equipment.

[0055] Optionally, in the control method of the monitoring device provided in Embodiment 1 of this application, the preset difference threshold is determined by the following method: obtaining target parameters, wherein the target parameters include at least one of the following: environmental parameters of the environment where the target motor is located, and operating parameters of the target motor, wherein the operating parameters include at least one of the following: running time and load weight; inputting the target parameters and angle difference into the target model, and outputting the preset difference threshold, wherein the target model includes: a neural network model trained based on the correction records of the target motor over a historical time period.

[0056] For example, the target parameters mentioned above may include environmental parameters and operating parameters. Environmental parameters may include, but are not limited to, the temperature, humidity, air pressure, and electromagnetic interference of the environment in which the target motor is located. Operating parameters may include, but are not limited to, the operating time and load weight of the target motor. The operating time can reflect the wear and tear of the motor, while the load weight can affect the torque demand and response speed of the motor. Target parameters can be obtained through sensors or system monitoring.

[0057] The aforementioned preset difference threshold is a standard used to determine whether the motor is deviating. It can be determined and adaptively adjusted through a target model. For example, based on the recorded deviation ΔP and environmental parameters (temperature, load weight) for each correction, a neural network model (corresponding to the target model) can predict the deviation trend and adaptively adjust the threshold. The target model can be a neural network model trained based on the correction records of the target motor over a historical period. The target model can learn and predict the range of angle differences that the motor may produce under different environmental and operating parameters.

[0058] The aforementioned historical correction records can include angle difference data from past motor operations, along with the corresponding environmental and operational parameters. By collecting this historical data, a training dataset can be constructed. Using these historical correction records as training samples, a neural network model can be trained. The model's input can be environmental and operational parameters, and its output can be a preset difference threshold. During training, the model can learn the complex relationship between parameters and angle differences, enabling it to make accurate predictions even on unknown data.

[0059] By using machine learning models (neural network models) to predict the optimal preset difference threshold, more intelligent and efficient motor correction control can be achieved. Specifically, the application of deep learning technology in correction algorithms can significantly improve the accuracy and performance of monitoring equipment. Machine learning models can learn and predict errors, enabling real-time adjustments and optimizations, and can also improve the accuracy and stability of correction even in complex environmental conditions.

[0060] Optionally, in the control method of the monitoring device provided in Embodiment 1 of this application, when the target motor is deviated, the target motor is subjected to correction control, including: when the target motor is deviated, generating a reverse pulse sequence based on the angle difference, wherein the reverse pulse sequence is used to drive the target motor to rotate; and performing correction control on the target motor based on the reverse pulse sequence.

[0061] In this embodiment, if a difference is determined between the first rotation angle (the recorded theoretical rotation angle) and the second rotation angle (the actual measured rotation angle), and it is confirmed that the target motor has an offset, i.e., the angle difference exceeds a preset difference threshold, a reverse pulse sequence can be generated based on the magnitude and direction of the angle difference. For example, the main control chip (i.e., the target chip) generates a reverse pulse sequence to drive the stepper motor to rotate ΔP / 0.01° steps (e.g., when ΔP=0.6°, it drives 60 steps in the reverse direction). Simultaneously, the actual rotation angle is verified by a magnetic encoder. For example, the actual rotation angle of the target motor can be determined using the magnetic field data before rotation, the magnetic field data after rotation, and the magnetic field angle mapping relationship. It should be noted that the "reverse" in this pulse sequence refers to the opposite direction relative to the current direction of motor movement; the purpose is to correct the offset by driving the motor to rotate in the opposite direction.

[0062] The aforementioned reverse pulse sequence can be generated based on the control characteristics of a stepper motor. A stepper motor achieves precise rotation by receiving a certain number and sequence of pulse signals, each pulse representing a specific step angle. Therefore, to correct the angle difference, the required number of pulses and their transmission order can be calculated to drive the motor to rotate to the correct angle and eliminate the offset. Based on the reverse pulse sequence, a control signal is sent to the target motor, driving it to rotate the corresponding number of steps in the opposite direction. The rotation angle is equal to the previously calculated angle difference, achieving complete correction. During the motor's correction action, the change in the second rotation angle can be continuously monitored to verify whether the motor has correctly returned to the theoretical position. Feedback devices such as magnetic encoders can be used to measure the actual rotation angle of the motor in real time. Once the motor returns to the correct position, i.e., the angle difference is eliminated, the correction control process is complete. At this point, the motor's operating state should return to normal, meeting the expected accuracy requirements.

[0063] By automatically identifying the offset of the target motor and adopting precise control strategies to adjust it, the ideal rotation angle can be achieved, which can effectively improve the reliability and operating efficiency of monitoring equipment.

[0064] Optionally, in the control method of the monitoring device provided in Embodiment 1 of this application, after performing correction control on the target motor based on the reverse pulse sequence, the method includes: obtaining the number of consecutive corrections, wherein the number of consecutive corrections includes the number of times the target motor is continuously controlled for correction; comparing the number of consecutive corrections with a preset number threshold; if the number of consecutive corrections is greater than the preset number threshold, performing correction control on the target motor using a target correction mode and generating fault prompt information, wherein the target correction mode includes: directly controlling the target motor to rotate when the difference between the recorded rotation angle of the target motor and the actual rotation angle of the target motor is greater than a preset difference threshold.

[0065] The aforementioned number of consecutive correction cycles indicates the number of times a target motor is detected to have deviated and correction control is executed consecutively. If frequent deviance is detected during target motor operation, necessitating multiple consecutive correction operations, it can be determined that the motor or related components have a serious fault or instability.

[0066] The aforementioned preset threshold number can be a pre-defined value used to determine whether the number of consecutive corrections has reached a point where further measures are needed. If the number of consecutive corrections exceeds this threshold, it can be determined that the target motor's deviation problem may not be accidental, but rather caused by some persistent factor, requiring more forceful measures.

[0067] After each corrective control based on a reverse pulse sequence, it can be checked whether the number of consecutive corrective actions exceeds a preset threshold. If the threshold is not exceeded, it is determined that the previous corrective control was sufficient, and the target motor can continue to operate in normal mode, waiting for the next angle detection and corrective control. If the threshold is exceeded, the abnormal handling process is initiated, and the target corrective mode is used for more urgent and direct corrective control, and a fault prompt message is generated to notify maintenance personnel.

[0068] In target correction mode, if the difference between the recorded target motor rotation angle and the actual rotation angle is still greater than the preset difference threshold, it is not necessary to check whether the target motor has offset again. Instead, after obtaining the angle difference ΔP of the target motor, if ΔP > the threshold... In such cases, direct correction can be performed to eliminate the angle difference as quickly as possible. Simultaneously, fault alerts can be generated and sent to the monitoring center or user's terminal equipment via communication protocols, reminding relevant personnel to inspect the motor and its related components, identify the root cause of the continuous deviation, and perform necessary repairs or replacements.

[0069] For example, if ΔP still exceeds the threshold after three consecutive corrections (corresponding to the preset number of times threshold), the system can switch to the target correction mode, directly using the magnetic encoder feedback signal to control the motor and sending a fault code to the monitoring platform.

[0070] The target correction mode can take timely measures to ensure equipment safety and operational continuity when abnormal motor operation occurs, and can also effectively report potential faults to the maintenance team, facilitating rapid diagnosis and repair, and preventing the equipment from being in an unstable state for a long time, which would affect overall performance and service life.

[0071] In this embodiment, the design of the target motor and transmission system can reduce friction by optimizing the structure and materials. In this embodiment, the dimensions of the various high-precision components involved in the control method of the monitoring equipment can be precisely matched, improving the rigidity of the control device and reducing inertia and friction.

[0072] The control method for the monitoring equipment provided in this embodiment can achieve high-precision correction performance at a low cost.

[0073] Example 2

[0074] This application also provides a control device for a monitoring device. It should be noted that the control device for the monitoring device in this application can be used to execute the control method for the monitoring device provided in Embodiment 1 of this application. The control device for the monitoring device provided in Embodiment 2 of this application will be described below.

[0075] According to an embodiment of this application, an apparatus for implementing the control method of the monitoring equipment of this application is also provided. Figure 3 This is a schematic diagram of a control device for a monitoring equipment according to an embodiment of this application. Figure 1 ,like Figure 3 As shown, the device includes: a target motor 31, a magnetic encoder 32, and a target chip 33.

[0076] The target motor 31 is used to drive the monitoring equipment to rotate; the magnetic encoder 32 is deployed at the tail of the target motor to collect the magnetic field data of the monitoring equipment and obtain the target magnetic field data; the target chip 33 is connected to the magnetic encoder to record the first rotation angle of the target motor, determine the second rotation angle based on the target magnetic field data, and perform correction control on the target motor based on the first rotation angle and the second rotation angle, wherein the second rotation angle includes the actual rotation angle of the target motor at the current moment.

[0077] The target motor mentioned above can be a stepper motor, for example, Figure 4This is a schematic diagram of a control device for a monitoring equipment according to an embodiment of this application. Figure 2 ,like Figure 4 As shown, the target motor in the monitoring equipment can include a horizontally positioned stepper motor (horizontal motor) and a vertically positioned stepper motor (vertical motor) to control the horizontal and vertical rotation of the monitoring equipment. The target motor can also be a servo motor, serving as the primary power source for the monitoring equipment and driving the pan-tilt unit or other components to rotate. For example, the target motor can precisely control the rotation angle based on received control signals to adjust the monitoring viewing angle.

[0078] The aforementioned magnetic encoder can be deployed at the tail of the target motor and may include a magnetic field encoder disk and a magnetic chip. The magnetic chip can collect the magnetic field data of the magnetic field encoder disk to obtain the target magnetic field data. That is, the magnetic encoder can indirectly measure the actual rotation angle of the target motor shaft by monitoring the magnetic field change of the magnetic field of the magnetic encoder disk fixed on the target motor shaft.

[0079] The target chip is closely connected to the magnetic encoder and is responsible for processing rotation angle information and generating information for corrective control of the target motor. The target chip can be a microcontroller. It receives magnetic field strength signals (magnetic field data) from the magnetic chip and position feedback signals from the magnetic encoder, and drives the stepper motor via PWM (Pulse Width Modulation) chopping. The target chip can be powered by a -48V DC power supply.

[0080] In this embodiment, the first rotation angle recorded by the target chip can be acquired, which is the theoretical rotation angle that the target motor should reach. This angle is typically determined and stored based on control commands sent from the target chip. The target chip can receive magnetic field data from the magnetic encoder and calculate the actual rotation angle of the motor, i.e., the second rotation angle, using a built-in algorithm or a pre-established magnetic field angle mapping relationship.

[0081] The target chip can compare the first rotation angle (theoretical angle) with the second rotation angle (actual angle). If a significant difference (angle difference) is found between the two and this difference exceeds a preset difference threshold, it is determined that the motor is deviating. At this time, the target chip will generate a specific control signal, such as a reverse pulse sequence, to drive the target motor to rotate in order to correct this deviation, thereby achieving precise steering control.

[0082] In this embodiment, a built-in magnetic encoder is incorporated into the monitoring equipment. This enables the correction control of the target motor within the monitoring equipment based on magnetic field data, avoiding the low accuracy issues of pneumatic active correction methods and electro-hydraulic combined correction methods in related technologies. This improves the correction accuracy of the spherical camera and solves the problem of poor correction performance for spherical cameras in related technologies.

[0083] Optionally, in the control device of the monitoring equipment provided in Embodiment 2 of this application, the magnetic encoder further includes: a magnetic encoder disk, deployed at the end of the shaft of the target motor, which generates different magnetic fields with the rotation angle of the target motor; and a magnetic chip, used to collect target magnetic field data, wherein the target magnetic field data includes: magnetic field data of the magnetic field generated by the magnetic encoder disk at the current moment.

[0084] The aforementioned magnetic encoder disk can be part of a magnetic encoder, deployed at the end of the target motor's shaft, and rotates along with the shaft to generate different magnetic field strengths. Optionally, the magnetic encoder disk can have a pre-designed magnetic pattern that changes with the rotation of the motor shaft, resulting in different magnetic field distributions. The magnetic field changes are directly related to the motor's rotation angle; therefore, the motor's rotation angle can be indirectly measured by monitoring changes in the magnetic field. The magnetic encoder disk can be very precise, providing high-resolution angle measurement. For example, a magnetic encoder disk mounted at the end of the shaft (4000 lines / revolution resolution) generates a magnetic field that changes with the motor's rotation angle. A magnetic encoder disk with a resolution of up to 4000 lines / revolution can distinguish very subtle angular changes during the rotation of the motor shaft.

[0085] The aforementioned magnetic sensing chip can be fixed to the tail housing of the target motor, perpendicular to the motor axis, to collect magnetic field data (i.e., target magnetic field data) generated by the magnetic encoder disk. The magnetic sensing chip can sense and monitor the rotation angle of the magnetic encoder disk in a non-contact manner. The signal output terminal of the magnetic sensing chip can be connected to the main control chip (target chip) via an SPI (Serial Peripheral Interface) interface, ensuring the encoder's long-term reliability and low wear characteristics. The magnetic sensing chip can be a magnetic sensor with a resolution of 18 bits, possessing high-resolution magnetic field detection capabilities, capable of capturing minute magnetic field changes, thus accurately converting the magnetic field data into the target motor's rotation angle information.

[0086] The combination of a magnetic sensor chip and a magnetic encoder disk can be used to obtain the actual position of the motor. The two combined can be called a magnetic encoder.

[0087] Magnetic encoders utilize the characteristic of measuring angles by changing magnetic fields, giving them an advantage over optical encoders in certain environments. For example, in dusty or humid environments, magnetic encoders can provide stable measurement results and are less susceptible to changes in the external environment.

[0088] Optionally, in the control device of the monitoring equipment provided in Embodiment 2 of this application, the monitoring equipment further includes: a driven shaft for controlling the rotation of the monitoring equipment; a gear set including a first synchronous pulley and a second synchronous pulley, the first synchronous pulley being connected to the output shaft of the target motor, the second synchronous pulley being connected to the driven shaft, and the gear set being made of copper; a belt connecting the first synchronous pulley and the second synchronous pulley, for controlling the rotation of the monitoring equipment by using the target motor to drive the driven shaft to rotate based on the gear set; and a tensioning pulley for controlling the tension of the belt.

[0089] The driven shaft mentioned above can be a shaft used in monitoring equipment to directly control the rotation of the pan-tilt unit or other rotating components of the monitoring equipment. It is usually connected to the output shaft of the target motor through a transmission system (such as a gear set or belt), thereby converting the rotational power of the target motor into rotational control of the monitoring equipment.

[0090] The aforementioned gear set consists of a first synchronous pulley and a second synchronous pulley, which are connected by a belt. The first synchronous pulley is connected to the output shaft of the target motor. For example, the output shaft of the target motor can be connected to the first synchronous pulley (also called the motor's main synchronous pulley) via a metal shaft to transmit the motor's rotational power to the belt. The second synchronous pulley (also called the driven synchronous pulley) can be connected to the driven shaft to convert the belt's motion into the driven shaft's rotation. The gear set can be made of copper, as copper has good wear resistance and low noise characteristics. The main synchronous pulley (i.e., the first synchronous pulley) and the driven synchronous pulley (i.e., the second synchronous pulley) can form a 7:1 reduction ratio, increasing torque output and reducing the step angle resolution to 0.005° / step. Therefore, in monitoring equipment, copper gears can provide smooth, low-friction rotation, reducing energy loss and mechanical noise during transmission, thereby improving the positioning accuracy and operational stability of the monitoring equipment.

[0091] The aforementioned belt is a transmission medium connecting the first synchronous pulley (i.e., the main synchronous pulley of the motor) and the second synchronous pulley (i.e., the driven synchronous pulley), used to transmit the rotational force of the target motor to the driven shaft. In this embodiment, the belt and the synchronous pulleys together constitute a transmission system. The tension of the belt ensures the power transmission between the motor and the driven shaft. The use of a belt can reduce the noise and wear problems commonly found in direct gear meshing. At the same time, proper tension can prevent belt slippage during transmission, ensuring transmission efficiency and accuracy.

[0092] The aforementioned tensioner pulley is used to adjust belt tension. In a belt drive system, belt tension directly affects transmission efficiency. If the belt is too loose, transmission efficiency will decrease, and slippage may even occur; if the belt is too tight, friction and wear in the transmission system will increase, reducing the lifespan of the monitoring equipment. Therefore, the belt tension can be dynamically adjusted using the tensioner pulley to prevent slippage and ensure the belt operates in optimal condition. For example, the position of the tensioner pulley can be automatically adjusted according to changes in motor speed and load, thereby maintaining the belt at an appropriate tension—neither too loose nor too tight—ensuring the high efficiency and stability of the transmission system.

[0093] In this embodiment, a built-in magnetic encoder is incorporated into the monitoring equipment. This enables the correction control of the target motor within the monitoring equipment based on magnetic field data, avoiding the low accuracy issues of pneumatic active correction methods and electro-hydraulic combined correction methods in related technologies. This improves the correction accuracy of the spherical camera and solves the problem of poor correction performance for spherical cameras in related technologies.

[0094] Example 3

[0095] This application also provides a control device for a monitoring device. It should be noted that the control device for the monitoring device in this application can be used to execute the control method for a monitoring device provided in Embodiment 1 of this application. The control device for the monitoring device provided in this application will be described below.

[0096] According to an embodiment of this application, an apparatus for implementing the control method of the above-described monitoring equipment is also provided, such as... Figure 5 As shown, the device includes: an acquisition unit 51, a collection unit 52, a determination unit 53, and a correction unit 54.

[0097] The acquisition unit 51 is used to acquire the recorded rotation angle of the target motor at the current moment to obtain the first rotation angle. The target motor is deployed in the monitoring equipment to drive the monitoring equipment to rotate.

[0098] The acquisition unit 52 is used to acquire the magnetic field data of the monitoring equipment to obtain the target magnetic field data;

[0099] The determining unit 53 is used to determine a second rotation angle based on the target magnetic field data, wherein the second rotation angle includes the actual rotation angle of the target motor at the current moment;

[0100] The correction unit 54 is used to perform correction control on the target motor based on the first rotation angle and the second rotation angle.

[0101] In the control device of the monitoring equipment provided in Embodiment 3 of this application, the target motor's rotation angle at the current moment can be obtained by the acquisition unit 51 to obtain a first rotation angle. The target motor is deployed in the monitoring equipment to drive its rotation. The magnetic field data of the monitoring equipment is collected by the acquisition unit 52 to obtain target magnetic field data. Based on the target magnetic field data, the determination unit 53 determines a second rotation angle, which includes the actual rotation angle of the target motor at the current moment. Based on the first and second rotation angles, the correction unit 54 performs correction control on the target motor. In this embodiment, the correction control of the target motor in the monitoring equipment based on magnetic field data avoids the low accuracy of pneumatic active correction methods and electro-hydraulic combined correction methods in related technologies, thereby improving the correction accuracy of the spherical camera. This solves the technical problem of poor correction effect for spherical cameras in related technologies.

[0102] Optionally, in the control device of the monitoring equipment provided in Embodiment 3 of this application, the target magnetic field data includes: magnetic field data of the magnetic field generated by the magnetic encoder disk, wherein the magnetic encoder disk is deployed at the end of the shaft of the target motor, and the determining unit includes: an acquisition subunit for acquiring the magnetic field angle mapping relationship, wherein the magnetic field angle mapping relationship includes: the mapping relationship between the magnetic field data of the magnetic encoder disk and the actual rotation angle of the target motor, and the magnetic field angle mapping relationship is calibrated once every preset time interval; and a determining subunit for determining a second rotation angle based on the target magnetic field data and the magnetic field angle mapping relationship.

[0103] Optionally, in the control device of the monitoring equipment provided in Embodiment 3 of this application, the correction unit includes: a calculation subunit, used to calculate the difference between the first rotation angle and the second rotation angle to obtain the angle difference; a comparison subunit, used to compare the angle difference with a preset difference threshold to obtain a comparison result, and determine whether the target motor has an offset based on the comparison result; and a correction subunit, used to perform correction control on the target motor when the target motor has an offset.

[0104] Optionally, in the control device of the monitoring equipment provided in Embodiment 3 of this application, the preset difference threshold is determined by the following modules: a first acquisition module, used to acquire target parameters, wherein the target parameters include at least one of the following: environmental parameters of the environment where the target motor is located, and operating parameters of the target motor, wherein the operating parameters include at least one of the following: running time and load weight; a first processing module, used to input the target parameters and angle difference into the target model and output the preset difference threshold, wherein the target model includes: a neural network model trained based on the correction records of the target motor over a historical time period.

[0105] Optionally, in the control device of the monitoring equipment provided in Embodiment 3 of this application, the correction subunit includes: a generation module, used to generate a reverse pulse sequence based on the angle difference when the target motor has an offset, wherein the reverse pulse sequence is used to drive the target motor to rotate; and a correction module, used to perform correction control on the target motor based on the reverse pulse sequence.

[0106] Optionally, in the control device of the monitoring equipment provided in Embodiment 3 of this application, the correction subunit further includes: a second acquisition module, used to acquire the number of consecutive corrections after performing correction control on the target motor based on the reverse pulse sequence, wherein the number of consecutive corrections includes the number of times the target motor is continuously controlled for correction; a comparison module, used to compare the number of consecutive corrections with a preset number threshold; and a second processing module, used to perform correction control on the target motor using a target correction mode and generate fault prompt information when the number of consecutive corrections is greater than the preset number threshold, wherein the target correction mode includes: directly controlling the target motor to rotate when the difference between the recorded rotation angle of the target motor and the actual rotation angle of the target motor is greater than a preset difference threshold.

[0107] It should be noted that the acquisition unit 51, collection unit 52, determination unit 53, and correction unit 54 mentioned above correspond to steps S201 to S204 in Embodiment 1. Each unit and its corresponding step implements the same instance and application scenario, but is not limited to the content disclosed in Embodiment 1. It should be noted that the above modules or units can be hardware or software components stored in memory (e.g., memory 104) and processed by one or more processors (e.g., processors 102a, 102b, ..., 102n). The above modules can also be part of a device and run in the computer terminal 10 provided in Embodiment 1.

[0108] Example 4

[0109] Embodiments of this application may provide an electronic device. Figure 6 This is a structural block diagram of an electronic device according to an embodiment of this application. Figure 6 As shown, the electronic device may include: one or more ( Figure 6 (Only one is shown) Processor 602, memory 604, memory controller, and peripheral interface, wherein the peripheral interface is connected to the radio frequency module, audio module and display.

[0110] The memory can be used to store software programs and modules, such as the program instructions / modules corresponding to the methods and apparatus in the embodiments of this application. The processor executes various functional applications and data processing by running the software programs and modules stored in the memory, thereby implementing the above-described methods. The memory may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory may further include memory remotely located relative to the processor, and these remote memories can be connected to the terminal via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.

[0111] The processor can also call the information and application stored in the memory through the transmission device to perform the following steps: obtain the recorded rotation angle of the target motor at the current moment to obtain a first rotation angle, wherein the target motor is deployed in the monitoring equipment to drive the rotation of the monitoring equipment; collect the magnetic field data of the monitoring equipment to obtain target magnetic field data; determine a second rotation angle based on the target magnetic field data, wherein the second rotation angle includes the actual rotation angle of the target motor at the current moment; and perform correction control on the target motor based on the first rotation angle and the second rotation angle.

[0112] The processor can also call the information and application stored in the memory through the transmission device to execute the following steps: The target magnetic field data includes: magnetic field data of the magnetic field generated by the magnetic encoder disk, wherein the magnetic encoder disk is deployed at the end of the shaft of the target motor; based on the target magnetic field data, determining the second rotation angle includes: obtaining the magnetic field angle mapping relationship, wherein the magnetic field angle mapping relationship includes: the mapping relationship between the magnetic field data of the magnetic encoder disk and the actual rotation angle of the target motor, and the magnetic field angle mapping relationship is calibrated once every preset time interval; based on the target magnetic field data and the magnetic field angle mapping relationship, determining the second rotation angle.

[0113] The processor can also call the information and application stored in the memory through the transmission device to perform the following steps: based on the first rotation angle and the second rotation angle, perform correction control on the target motor, including: calculating the difference between the first rotation angle and the second rotation angle to obtain the angle difference; comparing the angle difference with a preset difference threshold to obtain a comparison result, and determining whether the target motor has a deviation based on the comparison result; and performing correction control on the target motor if the target motor has a deviation.

[0114] The processor can also call the information and application stored in the memory through the transmission device to perform the following steps: The preset difference threshold is determined by the following method: obtaining target parameters, wherein the target parameters include at least one of the following: environmental parameters of the environment in which the target motor is located, and operating parameters of the target motor, wherein the operating parameters include at least one of the following: running time, load weight; inputting the target parameters and angle difference into the target model, and outputting the preset difference threshold, wherein the target model includes: a neural network model trained based on the correction records of the target motor over a historical time period.

[0115] The processor can also call the information and application program stored in the memory through the transmission device to perform the following steps: when the target motor is offset, perform correction control on the target motor, including: when the target motor is offset, generate a reverse pulse sequence based on the angle difference, wherein the reverse pulse sequence is used to drive the target motor to rotate; and perform correction control on the target motor based on the reverse pulse sequence.

[0116] The processor can also call the information and application program stored in the memory through the transmission device to execute the following steps: After performing corrective control on the target motor based on the reverse pulse sequence, the steps include: obtaining the number of consecutive corrective cycles, wherein the number of consecutive corrective cycles includes the number of times the target motor has been continuously controlled for corrective rotation; comparing the number of consecutive corrective cycles with a preset number threshold; if the number of consecutive corrective cycles is greater than the preset number threshold, performing corrective control on the target motor using the target correction mode and generating a fault prompt message, wherein the target correction mode includes: if the difference between the recorded rotation angle of the target motor and the actual rotation angle of the target motor is greater than a preset difference threshold, directly controlling the target motor to rotate.

[0117] By employing the embodiments of this application, the target motor in the monitoring equipment is controlled for correction based on magnetic field data. This avoids the low accuracy issues of pneumatic active correction methods and electro-hydraulic combined correction methods in related technologies, thereby improving the correction accuracy of spherical cameras. Furthermore, it solves the technical problem of poor correction effect when correcting spherical cameras in related technologies.

[0118] Those skilled in the art will understand that Figure 6 The structure shown is for illustrative purposes only. Electronic devices can also be smartphones, tablets, handheld computers, mobile internet devices (MIDs), PADs, and other terminal devices. Figure 6 This does not limit the structure of the aforementioned electronic device. For example, electronic devices may also include components that are more... Figure 6 The more or fewer components shown (such as network interfaces, display devices, etc.), or having the same Figure 6The different configurations shown.

[0119] Those skilled in the art will understand that all or part of the steps in the various methods of the above embodiments can be implemented by a program instructing the hardware related to the terminal device. The program can be stored in a computer-readable storage medium, which may include: flash drive, read-only memory (ROM), random access memory (RAM), disk or optical disk, etc.

[0120] Example 5

[0121] Embodiments of this application also provide a storage medium. Optionally, in this embodiment, the storage medium can be used to store the program code executed by the control method of the monitoring device provided in Embodiment 1.

[0122] Optionally, in this embodiment, the storage medium may be located in any computer terminal in a group of computer terminals in a computer network, or in any mobile terminal in a group of mobile terminals.

[0123] This application also provides a computer program product that, when executed on a data processing device, is suitable for performing control method steps of a monitoring device.

[0124] The sequence numbers of the embodiments in this application are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.

[0125] In the above embodiments of this application, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments.

[0126] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. The device embodiments described above are merely illustrative; for example, the division of units is only a logical functional division, and in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the displayed or discussed mutual coupling, direct coupling, or communication connection may be through some interfaces; the indirect coupling or communication connection between units or modules may be electrical or other forms.

[0127] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.

[0128] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.

[0129] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as a USB flash drive, read-only memory (ROM), random access memory (RAM), portable hard drive, magnetic disk, or optical disk.

[0130] The above description is only a preferred embodiment of this application. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of this application, and these improvements and modifications should also be considered within the scope of protection of this application.

Claims

1. A control method for a monitoring device, characterized in that, include: The rotation angle of the target motor at the current moment is obtained to obtain the first rotation angle. The target motor is deployed in the monitoring equipment to drive the monitoring equipment to rotate. The first rotation angle is determined according to the theoretical number of steps of the target motor recorded by the main control chip in the monitoring equipment. The monitoring equipment is a spherical camera. The magnetic field data of the monitoring equipment is collected to obtain the target magnetic field data; Based on the target magnetic field data, a second rotation angle is determined, wherein the second rotation angle includes: the actual rotation angle of the target motor at the current moment; Based on the first rotation angle and the second rotation angle, the target motor is subjected to correction control; The target magnetic field data includes: magnetic field data of the magnetic field generated by the magnetic encoder disk, wherein the magnetic encoder disk is deployed at the end of the shaft of the target motor. Determining the second rotation angle based on the target magnetic field data includes: acquiring a magnetic field angle mapping relationship, wherein the magnetic field angle mapping relationship includes: a mapping relationship between the magnetic field data of the magnetic encoder disk and the actual rotation angle of the target motor. The magnetic field angle mapping relationship is calibrated every preset time interval. Calibrating the magnetic field angle mapping relationship includes: driving the target motor to rotate 360° and recording the magnetic field data for the entire circumference to update the magnetic field angle mapping relationship; determining the second rotation angle based on the target magnetic field data and the magnetic field angle mapping relationship. Based on the first rotation angle and the second rotation angle, the target motor is subjected to correction control, including: calculating the difference between the first rotation angle and the second rotation angle to obtain the angle difference; comparing the angle difference with a preset difference threshold to obtain a comparison result, and determining whether the target motor has an offset based on the comparison result; and performing correction control on the target motor if the target motor has an offset. The preset difference threshold is determined by: obtaining target parameters, wherein the target parameters include at least one of the following: environmental parameters of the environment in which the target motor is located, and operating parameters of the target motor, wherein the operating parameters include at least one of the following: running time, load weight; inputting the target parameters and the angle difference into a target model, and outputting the preset difference threshold, wherein the target model includes: a neural network model trained based on the correction records of the target motor over a historical time period; When the target motor is offset, the target motor is subjected to correction control, which includes: generating a reverse pulse sequence based on the angle difference when the target motor is offset, wherein the reverse pulse sequence is used to drive the target motor to rotate; and performing correction control on the target motor based on the reverse pulse sequence, wherein the correction control on the target motor based on the reverse pulse sequence further includes: verifying the actual rotation angle of the target motor through a magnetic encoder.

2. The control method according to claim 1, characterized in that, After performing correction control on the target motor based on the reverse pulse sequence, the process includes: The number of consecutive corrections is obtained, wherein the number of consecutive corrections includes the number of times the target motor is continuously controlled for correction. The number of consecutive corrections is compared with a preset threshold number. If the number of consecutive corrections exceeds the preset number threshold, a target correction mode is used to control the target motor and generate a fault prompt message. The target correction mode includes: if the difference between the recorded rotation angle of the target motor and the actual rotation angle of the target motor is greater than the preset difference threshold, the target motor is directly controlled to rotate.

3. A control device for monitoring equipment, characterized in that, The control device is used to execute the control method of the monitoring equipment according to any one of claims 1 to 2, including: A target motor is used to drive the monitoring equipment to rotate, wherein the monitoring equipment is a spherical camera; A magnetic encoder is deployed at the tail of the target motor to collect magnetic field data from the monitoring device and obtain target magnetic field data. A target chip, connected to the magnetic encoder, is used to record the first rotation angle of the target motor, determine the second rotation angle based on the target magnetic field data, and perform correction control on the target motor based on the first rotation angle and the second rotation angle. The first rotation angle is determined according to the theoretical number of steps of the target motor recorded by the main control chip in the monitoring device, and the second rotation angle includes the actual rotation angle of the target motor at the current moment. The magnetic encoder includes a magnetic encoder disk deployed at the end of the shaft of the target motor, which generates different magnetic fields depending on the rotation angle of the target motor. Determining a second rotation angle based on the target magnetic field data includes: acquiring a magnetic field angle mapping relationship, wherein the magnetic field angle mapping relationship includes a mapping relationship between the magnetic field data of the magnetic encoder disk and the actual rotation angle of the target motor. The magnetic field angle mapping relationship is calibrated at preset time intervals. Calibrating the magnetic field angle mapping relationship includes: driving the target motor to rotate 360° and recording the magnetic field data for the entire circumference to update the magnetic field angle mapping relationship; and determining the second rotation angle based on the target magnetic field data and the magnetic field angle mapping relationship. Based on the first rotation angle and the second rotation angle, the target motor is subjected to correction control, including: calculating the difference between the first rotation angle and the second rotation angle to obtain the angle difference; comparing the angle difference with a preset difference threshold to obtain a comparison result, and determining whether the target motor has an offset based on the comparison result; and performing correction control on the target motor if the target motor has an offset. The preset difference threshold is determined by: obtaining target parameters, wherein the target parameters include at least one of the following: environmental parameters of the environment in which the target motor is located, and operating parameters of the target motor, wherein the operating parameters include at least one of the following: running time, load weight; inputting the target parameters and the angle difference into a target model, and outputting the preset difference threshold, wherein the target model includes: a neural network model trained based on the correction records of the target motor over a historical time period; When the target motor is offset, the target motor is subjected to correction control, which includes: generating a reverse pulse sequence based on the angle difference when the target motor is offset, wherein the reverse pulse sequence is used to drive the target motor to rotate; and performing correction control on the target motor based on the reverse pulse sequence, wherein the correction control on the target motor based on the reverse pulse sequence further includes: verifying the actual rotation angle of the target motor through a magnetic encoder.

4. The control device according to claim 3, characterized in that, The magnetic encoder also includes: A magnetic sensing chip is used to collect the target magnetic field data, wherein the target magnetic field data includes the magnetic field data of the magnetic field generated by the magnetic sensing encoder disk at the current moment.

5. The control device according to claim 3, characterized in that, The monitoring equipment also includes: Driven shaft, used to control the rotation of the monitoring equipment; The gear set includes a first synchronous pulley and a second synchronous pulley. The first synchronous pulley is connected to the output shaft of the target motor, and the second synchronous pulley is connected to the driven shaft. The gear set is made of copper. A belt, connecting the first synchronous pulley and the second synchronous pulley, is used to drive the driven shaft to rotate based on the gear set using the target motor, so as to control the rotation of the monitoring equipment; The tension pulley is used to control the tension of the belt.

6. A computer program product comprising computer instructions, characterized in that, When the computer instructions are executed by the processor, they implement the steps of the control method for the monitoring device according to any one of claims 1 to 2.