Mechanical correction method, device, electronic equipment, system and storage medium
By establishing a working coordinate system and calculating the reference coordinate points of the machine, mechanical calibration is automatically completed, solving the problem of complex and time-consuming mechanical calibration in the prior art and achieving efficient and accurate mechanical calibration.
Patent Information
- Application Number
- CN202210570765.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-05-24
- Publication Date
- 2025-09-30
- Estimated Expiration
- 2042-05-24
AI Technical Summary
The mechanical correction method in the prior art is complex, time-consuming, labor-intensive and inefficient.
By establishing a working coordinate system, obtaining the distance and offset angle between the reference coordinate point and the extreme position of the machine to be corrected, calculating its actual coordinates in the coordinate system, and automatically completing the mechanical correction process.
It reduces the time engineers spend on mechanical calibration, reduces the complexity of calibration, and achieves efficient and accurate mechanical calibration.
Smart Images

Figure CN114963928B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of medical technology, and in particular to a mechanical correction method, device, electronic equipment, system and storage medium. Background Art
[0002] In conventional DR equipment (medical digital imaging equipment), the mechanical parts capable of moving in the equipment need to be calibrated to their extreme positions before use. Various manufacturers provide corresponding mechanical calibration methods for different types of products to assist staff in mechanical calibration.
[0003] Currently, the calibration of various machines generally requires manual participation. The specific process is: the machine is manually dragged to a position, and then the machine is moved to the extreme position. The distance in the corresponding direction is measured with a tape measure, and then the measured value is manually input into the calibration interface of the management system to complete the calibration.
[0004] The current manual mechanical correction method is not only complicated, but also time-consuming, labor-intensive and inefficient. Summary of the Invention
[0005] The purpose of the present invention is to overcome the above technical deficiencies and provide a mechanical correction method, device, electronic device, system and storage medium to solve the technical problems in the prior art that the mechanical correction method is complex, time-consuming, labor-intensive and inefficient.
[0006] In order to achieve the above technical objectives, the present invention adopts the following technical solutions:
[0007] In a first aspect, the present invention provides a mechanical calibration method, comprising the following steps:
[0008] Establishing a working coordinate system with a preset position as the origin, and obtaining a reference coordinate point of the machine to be calibrated in the working coordinate system;
[0009] Acquire the distance between the extreme position of the machine to be corrected in the first direction and the reference coordinate point and the offset angle of the machine to be corrected when the machine to be corrected moves to the extreme position in the first direction;
[0010] Calculate the actual coordinates of the limit position in the first direction of the machine to be corrected in the working coordinate system based on the reference coordinate point, the distance between the limit position in the first direction of the machine to be corrected and the reference coordinate point, and the offset angle of the machine to be corrected;
[0011] According to the reference coordinate point and the actual coordinates, a distance between a limit position of the machine to be corrected in the first direction and the reference coordinate point in the first direction is determined.
[0012] In some embodiments, the reference coordinate point is the initial coordinate of the initial position of the machine to be calibrated in the working coordinate system.
[0013] In some embodiments, the preset position is an initial position of the machine to be calibrated.
[0014] In some embodiments, the offset angle includes the angle between a line connecting the extreme position in the first direction of the machine to be corrected and a reference coordinate point and each coordinate axis of the working coordinate system.
[0015] In some embodiments, obtaining the distance between the extreme position of the machine to be corrected in the first direction and the reference coordinate point when the machine to be corrected moves to the extreme position in the first direction includes:
[0016] Acquiring a first distance value detected by a distance sensor configured for the machine to be calibrated when the machine to be calibrated is located at a reference coordinate point;
[0017] obtaining a second distance value detected by a distance sensor configured for the machine to be calibrated when the machine to be calibrated is located at an extreme position in the first direction;
[0018] The distance between the limit position in the first direction of the machine to be corrected and the reference coordinate point is obtained through the first distance value and the second distance value.
[0019] In some embodiments, calculating the actual coordinates of the limit position in the first direction of the machine to be calibrated in the working coordinate system based on the reference coordinate point, the distance between the limit position in the first direction of the machine to be calibrated and the reference coordinate point, and the offset angle of the machine to be calibrated includes:
[0020] Based on the reference coordinate point, the distance between the extreme position in the first direction of the machine to be corrected and the reference coordinate point, and the offset angle of the machine to be corrected, the coordinate values of the position in the first direction of the machine to be corrected in each direction in the working coordinate system are calculated respectively to obtain the actual coordinates of the extreme position in the first direction of the machine to be corrected in the working coordinate system.
[0021] In a second aspect, the present invention further provides a mechanical correction device, comprising:
[0022] A coordinate system establishment module is used to establish a working coordinate system with a preset position as the origin, and obtain the reference coordinate points of the machine to be calibrated in the working coordinate system;
[0023] a data acquisition module, configured to acquire, when the machine to be corrected moves to the extreme position in the first direction, the distance between the extreme position in the first direction of the machine to be corrected and the reference coordinate point, and an offset angle of the machine to be corrected;
[0024] a coordinate calculation module, configured to calculate the actual coordinates of the extreme position in the first direction of the machine to be corrected in the working coordinate system based on the reference coordinate point, the distance between the extreme position in the first direction of the machine to be corrected and the reference coordinate point, and the offset angle of the machine to be corrected;
[0025] The limit position determination module is used to determine the distance between the limit position of the machine to be corrected in the first direction and the reference coordinate point in the first direction according to the reference coordinate point and the actual coordinate.
[0026] In a third aspect, the present invention further provides an electronic device comprising: a processor, a memory, and a display;
[0027] The memory stores a computer-readable program executable by the processor;
[0028] When the processor executes the computer readable program, the steps in the mechanical correction method described above are implemented;
[0029] The display is used to display a visual interface.
[0030] In a fourth aspect, the present invention further provides a computer-readable storage medium storing one or more programs, which can be executed by one or more processors to implement the steps in the mechanical correction method as described above.
[0031] In a fifth aspect, the present invention also provides a mechanical correction system, comprising a distance sensor, an angle sensor and the electronic device as described above, wherein the distance sensor and the angle sensor are both installed on the machine to be corrected, and the distance sensor and the angle sensor are electrically connected to the electronic device.
[0032] Compared with the prior art, the mechanical correction method, device, electronic device, system and storage medium provided by the present invention first establish a working coordinate system, and the movement changes of the machine to be corrected can be converted into changes in the coordinate points in the working coordinate system. Then, by presetting a reference coordinate point of the machine to be corrected, the position of the machine to be corrected corresponding to this reference coordinate point is known. Then, when the machine to be corrected moves to the extreme position in the first direction, the distance between the extreme position of the machine to be corrected and the reference coordinate point and the offset angle of the machine to be corrected are obtained. Since the coordinate value of the reference coordinate point is known, the actual coordinates of the extreme position of the machine to be corrected in the working coordinate system can be calculated through the reference coordinate point, the distance between the extreme position of the machine to be corrected and the reference coordinate point, and the offset angle of the machine to be corrected. Since the position of the machine to be corrected corresponding to the reference coordinate point is known, the distance between the extreme position of the machine to be corrected and the reference coordinate point in the first direction can be determined based on the reference coordinate point and the actual coordinates. The present invention eliminates the need for manual calibration of the extreme positions of the machine to be calibrated, eliminates the need for manual measurement of distance values and filling in data, and all processes are completed automatically, reducing the time for engineers to calibrate the machine and reducing the complexity of calibration, thereby achieving efficient work and replacing manual calibration of the machine while ensuring calibration precision and accuracy. BRIEF DESCRIPTION OF THE DRAWINGS
[0033] Figure 1 is a flow chart of an embodiment of the mechanical correction method provided by the present invention;
[0034] Figure 2 is a schematic diagram of an embodiment of a mechanical correction device provided by the present invention;
[0035] Figure 3 is a schematic diagram of an operating environment of an embodiment of a mechanical calibration program of the present invention;
[0036] Figure 4 FIG. 1 is a schematic diagram of an embodiment of a mechanical correction system provided by the present invention. DETAILED DESCRIPTION
[0037] In order to make the purpose, technical solutions and advantages of the present invention more clearly understood, 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.
[0038] The mechanical calibration method, apparatus, electronic device, system, or computer-readable storage medium described herein can be used in DR devices (medical digital imaging devices) in the medical field, as well as in other fields requiring mechanical calibration. The method, apparatus, device, or computer-readable storage medium described herein can be integrated with the aforementioned systems or independently.
[0039] This embodiment provides a mechanical correction method that can be executed by a DR device (medical digital imaging device), specifically by one or more processors of the device. Of course, in other embodiments, it can also be executed by processors of other non-medical devices that require mechanical correction. Figure 1 This is a flow chart of the mechanical correction method provided by an embodiment of the present invention. Figure 1 , the mechanical correction method includes the following steps:
[0040] S100, establishing a working coordinate system with a preset position as the origin, and obtaining a reference coordinate point of the machine to be calibrated in the working coordinate system;
[0041] S200, obtaining the distance between the extreme position of the machine to be corrected and the reference coordinate point and the offset angle of the machine to be corrected when the machine to be corrected moves to the extreme position in the first direction;
[0042] S300, calculating the actual coordinates of the limit position in the first direction of the machine to be calibrated in the working coordinate system based on the reference coordinate point, the distance between the limit position in the first direction of the machine to be calibrated and the reference coordinate point, and the offset angle of the machine to be calibrated;
[0043] S400: Determine, based on the reference coordinate point and the actual coordinates, the distance between the limit position in the first direction of the machine to be calibrated and the reference coordinate point in the first direction.
[0044] In this embodiment, a working coordinate system is first established. Changes in the movement of the machine to be calibrated can be converted into changes in coordinate points in the working coordinate system. A reference coordinate point is then preset for the machine to be calibrated, and the position of the machine to be calibrated corresponding to this reference coordinate point is known. The distance between the machine to be calibrated's extreme position in a first direction and the reference coordinate point, as well as the offset angle of the machine to be calibrated, are then obtained. Since the coordinate values of the reference coordinate point are known, the actual coordinates of the machine to be calibrated's extreme position in the working coordinate system can be calculated based on the reference coordinate point, the distance between the machine to be calibrated's extreme position and the reference coordinate point, and the offset angle of the machine to be calibrated. Since the position of the machine to be calibrated corresponding to the reference coordinate point is known, the distance between the machine to be calibrated's extreme position and the reference coordinate point in the first direction can be determined based on the reference coordinate point and the actual coordinates. This embodiment of the present invention eliminates the need for manual calibration of the machine to be calibrated's extreme position, eliminates the need for manual distance measurement and data entry, and automatically completes the entire process. This reduces the time engineers spend calibrating the machine, reduces the complexity of calibration, and achieves efficient work. It can replace manual machine calibration while ensuring calibration accuracy and precision.
[0045] Among them, the first direction can be one of the three movement dimensions of the machine to be corrected, such as the left and right direction, the up and down direction, or the front and back direction. By repeating steps S100 to S400, the extreme position correction of multiple directions of the machine to be corrected can be completed.
[0046] In some embodiments, in step S100, the way of establishing the working coordinate system is related to the movement of the machine to be corrected. The working coordinate system can be a two-dimensional coordinate system or a three-dimensional coordinate system. When the machine to be corrected has only movements in two directions, for example, the machine to be corrected has only up and down movements and left and right movements, the working coordinate system can be set to a two-dimensional coordinate system or a three-dimensional coordinate system. When the machine to be corrected has movements in three directions, for example, the machine to be corrected has up and down movements, left and right movements, and front and back movements, the working coordinate system is set to a three-dimensional coordinate system. The establishment of the working coordinate system can be determined according to the actual movement of the machine to be corrected, and the embodiments of the present invention are not limited to this.
[0047] The origin of the working coordinate system can be determined according to the actual needs of the user, that is, the preset position can be selected at will. Optionally, the preset position is the initial position of the machine to be calibrated, which is convenient for the subsequent calculation of the extreme position of the machine. It should be noted that the initial position of the machine to be calibrated described in the present invention is the position of the machine to be calibrated in the most initial state without any movement, and the origin is any reference point selected on the machine to be calibrated, and the coordinates of all subsequent machines to be calibrated are the coordinates of this point. Among them, the selected reference point can be freely selected, and it is only necessary to ensure that the selected reference point is the same point when the coordinate calculation is performed subsequently.
[0048] Of course, it should be noted that in other embodiments, the origin of the working coordinate system can also be selected at other positions. For example, the position where the machine to be corrected moves upward by 50 cm can be used as the origin. Although this selection method will increase the complexity of subsequent calculations, it will not affect the accuracy of subsequent coordinate calculations.
[0049] In step S100, the reference coordinate point is a point freely selected by the user, and the coordinate point can be set arbitrarily. Preferably, in order to facilitate subsequent calculations, the reference coordinate point is the initial coordinate of the initial position of the machine to be calibrated in the working coordinate system. In this embodiment, selecting the reference coordinate point as the coordinate of the initial position of the machine to be calibrated can reduce many calculation processes, reduce the complexity of the calculation, and speed up the correction process. Since the preset position is preferably the initial position of the machine to be calibrated, the reference coordinate point is preferably the origin of the machine to be calibrated. All subsequent coordinate calculations are based on the origin. Since the coordinates of the origin are all 0, the complexity of the calculation will be greatly reduced during the calculation.
[0050] Of course, it should be understood that the embodiments of the present invention are not limited to selecting the initial coordinates of the initial position of the machine to be calibrated in the working coordinate system as the reference coordinate points. In other embodiments, other coordinate points can also be selected as reference coordinate points. For example, the position point after the machine to be calibrated moves 20 cm upward is used as the reference coordinate point. Although this will increase the difficulty of the calculation, it will not affect the accuracy of the calculation.
[0051] Step S200 is to obtain the distance from the reference coordinate point when the machine to be corrected moves to the extreme position and the offset angle of the machine to be corrected, so as to further realize the coordinate calculation of the extreme position of the machine to be corrected. Optionally, the extreme position can be one of the positions of the machine to be corrected in the three dimensions of movement, such as the extreme position in the left and right direction, the up and down direction, or the front and back direction. By calculating the extreme position in each direction, the mechanical correction of the machine to be corrected can be realized. In some embodiments, the distance value is obtained by a distance sensor, and the offset angle value is obtained by an angle sensor. Optionally, when the machine to be corrected moves to the extreme position in the first direction, the distance between the extreme position in the first direction of the machine to be corrected and the reference coordinate point is obtained, including:
[0052] Acquire a first distance value detected by a distance sensor configured for the machine to be calibrated when the machine to be calibrated is located at a reference coordinate point;
[0053] obtaining a second distance value detected by a distance sensor configured on the machine to be calibrated when the machine to be calibrated is located at an extreme position in the first direction;
[0054] The distance between the limit position in the first direction of the machine to be corrected and the reference coordinate point is obtained through the first distance value and the second distance value.
[0055] In this embodiment, the distance sensor is configured to detect the distance between the installation position of the distance sensor and the current position of the machine to be corrected. The distance sensor can be installed at a position where it will not move. In specific implementation, the distance sensor is installed at a position such as a suspension bracket. Since its value may not be zero when the machine to be corrected is located at the reference coordinate point, it is necessary to first confirm the position of the distance sensor, that is, obtain the first distance value S1 detected on the distance sensor when the machine to be corrected is located at the reference coordinate point, and then obtain the second distance value S2 detected on the distance sensor when the machine to be corrected moves to the extreme position. The difference between the first distance value S1 and the second distance value S2 is the distance S between the extreme position of the machine to be corrected and the reference coordinate point.
[0056] The angle sensor is used to obtain the offset angle of the machine to be calibrated. In some embodiments, for ease of calculation, the offset angle includes the angles between the line connecting the current position of the machine to be calibrated and the reference coordinate point and the various coordinate axes of the working coordinate system. Specifically, when the working coordinate system is a three-dimensional working coordinate system, the offset angle includes the angles between the line connecting the current position of the machine to be calibrated and the reference coordinate point and the X-axis, Y-axis, and Z-axis of the working coordinate system. These angles can be positive or negative. When the working coordinate system is a two-dimensional working coordinate system, the offset angle includes the angles between the line connecting the current position of the machine to be calibrated and the reference coordinate point and the X-axis and Y-axis of the working coordinate system. These angles can be positive or negative. In this embodiment, the offset angles include the angles θ1, θ2, and θ3 between the line connecting the current position of the machine to be calibrated and the reference coordinate point and the X-axis, Y-axis, and Z-axis of the working coordinate system. This allows correction of the extreme positions of the machine to be calibrated in three directions.
[0057] Step S300 is to calculate the actual coordinates of the machine to be calibrated in the working coordinate system when it moves to the extreme position. The three-dimensional coordinates of the machine to be calibrated can be calculated by using the reference coordinate point, the distance between the extreme position and the initial position of the machine to be calibrated, and the offset angle of the machine to be calibrated. In some embodiments, step S300 specifically includes:
[0058] Based on the reference coordinate point, the distance between the extreme position in the first direction of the machine to be corrected and the reference coordinate point, and the offset angle of the machine to be corrected, the coordinate values of the extreme position in the first direction of the machine to be corrected in each direction in the working coordinate system are calculated respectively to obtain the actual coordinates of the extreme position in the first direction of the machine to be corrected in the working coordinate system.
[0059] In this embodiment, after obtaining the reference coordinate point, the distance between the extreme position of the machine to be calibrated in the first direction and the reference coordinate point, and the offset angle of the machine to be calibrated, the three-dimensional coordinates of the machine to be calibrated can be calculated using trigonometric functions. For example, the coordinates of the reference coordinate point are (0,0,0), the distance between the extreme position of the machine to be calibrated in the first direction and the reference coordinate point is S, and the offset angle of the machine to be calibrated includes the angles θ1, θ2, and θ3 between the line connecting the current position of the machine to be calibrated and the reference coordinate point and the X-axis, Y-axis, and Z-axis of the working coordinate system. The actual coordinates (x, y, z) can be calculated using the following formula:
[0060]
[0061] Therefore, the actual coordinates are (S*cosθ1, S*cosθ2, S*cosθ3), through which the distance between the extreme position in the first direction of the machine to be corrected and the reference coordinate point in the first direction can be quickly calculated.
[0062] Step S400 is to determine the distance in the first direction between the extreme position of the machine to be calibrated and the reference coordinate point based on the reference coordinate point and the actual coordinates. When the extreme position of the machine to be calibrated is when it moves upward or downward, the distance in the Y-axis direction between the extreme position of the machine to be calibrated and the reference coordinate point can be obtained based on the Y-axis coordinate value of the actual coordinate and the Y-axis coordinate value of the reference coordinate point. When the extreme position of the machine to be calibrated is when it moves leftward or rightward, the distance in the X-axis direction between the extreme position of the machine to be calibrated and the reference coordinate point can be obtained based on the X-axis coordinate value of the actual coordinate and the X-axis coordinate value of the reference coordinate point. When the extreme position of the machine to be calibrated is when it moves forward or backward, the distance in the Z-axis direction between the extreme position of the machine to be calibrated and the reference coordinate point can be obtained based on the Z-axis coordinate value of the actual coordinate and the Z-axis coordinate value of the reference coordinate point. For example, the reference coordinate point is the initial position of the machine to be calibrated, and its coordinates are (0,0,0), and the actual coordinates are (S*cosθ1, S*cosθ2, S*cosθ3). If the current limit position is the limit position when the machine to be calibrated moves upward or downward, then the distance between the limit position and the initial position is S*cosθ2, where the value range of θ2 is -90° to 90°. When θ2 is a negative number, it indicates the limit position of downward movement, and when θ2 is a positive number, it indicates the limit position of upward movement. If the current limit position is the limit position when the machine to be calibrated moves left or right, If the current limit position is the limit position of the machine to be corrected when it moves forward or backward, the distance between the limit position and the initial position is S*cosθ1, where the value range of θ1 is -90° to 90°. When θ1 is a negative number, it indicates the limit position of leftward movement, and when θ1 is a positive number, it indicates the limit position of rightward movement. If the current limit position is the limit position of the machine to be corrected when it moves forward or backward, the distance between the limit position and the initial position is S*cosθ3, where the value range of θ3 is -90° to 90°. When θ3 is a negative number, it indicates the limit position of backward movement, and when θ3 is a positive number, it indicates the limit position of forward movement. By calculating the distance between the limit position and the initial position of the machine to be corrected in each direction, the limit position correction of the machine to be corrected is achieved.
[0063] The present invention eliminates the need for manual calibration of the extreme positions of the machine to be calibrated, eliminates the need for manual measurement of distance values and filling in data, and all processes are completed automatically, reducing the time for engineers to calibrate the machine and reducing the complexity of calibration, thereby achieving efficient work and replacing manual calibration of the machine while ensuring calibration precision and accuracy.
[0064] Based on the above mechanical correction method, the present invention also provides a mechanical correction device 500. Figure 2The mechanical calibration device 500 includes a coordinate system establishing module 510 , a data acquiring module 520 , a coordinate calculating module 530 and a limit position determining module 540 .
[0065] The coordinate system establishing module 510 is used to establish a working coordinate system with a preset position as the origin, and obtain reference coordinate points of the machine to be calibrated in the working coordinate system.
[0066] The data acquisition module 520 is used to acquire the distance between the extreme position of the machine to be corrected in the first direction and the reference coordinate point and the offset angle of the machine to be corrected when the machine to be corrected moves to the extreme position in the first direction.
[0067] The coordinate calculation module 530 is used to calculate the actual coordinates of the extreme position in the first direction of the machine to be corrected in the working coordinate system based on the reference coordinate point, the distance between the extreme position in the first direction of the machine to be corrected and the reference coordinate point, and the offset angle of the machine to be corrected.
[0068] The limit position determination module 540 is used to determine the distance between the limit position of the machine to be calibrated in the first direction and the reference coordinate point in the first direction according to the reference coordinate point and the actual coordinates.
[0069] In this embodiment, a working coordinate system is first established. Changes in the movement of the machine to be calibrated can be converted into changes in coordinate points in the working coordinate system. A reference coordinate point is then preset for the machine to be calibrated, and the position of the machine to be calibrated corresponding to this reference coordinate point is known. The distance between the machine to be calibrated's extreme position in a first direction and the reference coordinate point, as well as the offset angle of the machine to be calibrated, are then obtained. Since the coordinate values of the reference coordinate point are known, the actual coordinates of the machine to be calibrated's extreme position in the working coordinate system can be calculated based on the reference coordinate point, the distance between the machine to be calibrated's extreme position and the reference coordinate point, and the offset angle of the machine to be calibrated. Since the position of the machine to be calibrated corresponding to the reference coordinate point is known, the distance between the machine to be calibrated's extreme position and the reference coordinate point in the first direction can be determined based on the reference coordinate point and the actual coordinates. This embodiment of the present invention eliminates the need for manual calibration of the machine to be calibrated's extreme position, eliminates the need for manual distance measurement and data entry, and automatically completes all processes. This reduces the time engineers spend calibrating the machine, reduces the complexity of calibration, and achieves efficient work. It can replace manual machine calibration while ensuring calibration accuracy and precision.
[0070] In some embodiments, the reference coordinate point is the initial coordinate of the initial position of the machine to be calibrated in the working coordinate system.
[0071] In some embodiments, the preset position is an initial position of the machine to be calibrated.
[0072] In some embodiments, the offset angle includes the angle between a line connecting the extreme position in the first direction of the machine to be corrected and the reference coordinate point and each coordinate axis of the working coordinate system.
[0073] In some embodiments, obtaining the distance between the extreme position of the machine to be corrected in the first direction and the reference coordinate point when the machine to be corrected moves to the extreme position in the first direction includes:
[0074] Acquire a first distance value detected by a distance sensor configured for the machine to be calibrated when the machine to be calibrated is located at a reference coordinate point;
[0075] obtaining a second distance value detected by a distance sensor configured for the machine to be calibrated when the machine to be calibrated is located at an extreme position in the first direction;
[0076] The distance between the limit position in the first direction of the machine to be corrected and the reference coordinate point is obtained through the first distance value and the second distance value.
[0077] In some embodiments, the coordinate calculation module 530 is specifically used to calculate the coordinate values of the extreme position in the first direction of the machine to be corrected in each direction in the working coordinate system according to the reference coordinate point, the distance between the extreme position in the first direction of the machine to be corrected and the reference coordinate point, and the offset angle of the machine to be corrected, so as to obtain the actual coordinates of the extreme position in the first direction of the machine to be corrected in the working coordinate system.
[0078] like Figure 3 As shown, based on the above mechanical correction method, the present invention also provides an electronic device, which can be a computing device such as a mobile terminal, a desktop computer, a notebook, a palmtop computer, and a server. The electronic device includes a processor 10, a memory 20, and a display 30. Figure 3 Only some of the components of the electronic device are shown, but it should be understood that it is not required to implement all of the shown components, and more or fewer components may be implemented instead.
[0079] In some embodiments, the memory 20 may be an internal storage unit of the electronic device, such as a hard disk or memory of the electronic device. In other embodiments, the memory 20 may also be an external storage device of the electronic device, such as a plug-in hard disk equipped on the electronic device, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (Flash Card), etc. Furthermore, the memory 20 may also include both an internal storage unit of the electronic device and an external storage device. The memory 20 is used to store application software and various types of data installed in the electronic device, such as program codes installed in the electronic device. The memory 20 can also be used to temporarily store data that has been output or is to be output. In one embodiment, a mechanical correction program 40 is stored on the memory 20, and the mechanical correction program 40 can be executed by the processor 10, thereby realizing the mechanical correction method of each embodiment of the present application.
[0080] In some embodiments, the processor 10 may be a central processing unit (CPU), a microprocessor, or other data processing chip, configured to execute program codes stored in the memory 20 or process data, such as executing a mechanical calibration method.
[0081] In some embodiments, display 30 can be an LED display, a liquid crystal display, a touch-sensitive liquid crystal display, or an OLED (Organic Light-Emitting Diode) touchscreen. Display 30 is used to display information on the mechanical calibration device and to display a visual user interface. Components 10-30 of the electronic device communicate with each other via a system bus.
[0082] In one embodiment, when the processor 10 executes the mechanical calibration program 40 in the memory 20, the following steps are implemented:
[0083] Establish a working coordinate system with the preset position as the origin, and obtain the reference coordinate points of the machine to be calibrated in the working coordinate system;
[0084] Obtaining the distance between the extreme position of the machine to be corrected in the first direction and the reference coordinate point and the offset angle of the machine to be corrected when the machine to be corrected moves to the extreme position in the first direction;
[0085] Calculate the actual coordinates of the limit position in the first direction of the machine to be corrected in the working coordinate system based on the reference coordinate point, the distance between the limit position in the first direction of the machine to be corrected and the reference coordinate point, and the offset angle of the machine to be corrected;
[0086] According to the reference coordinate point and the actual coordinates, the distance between the limit position of the machine to be corrected in the first direction and the reference coordinate point in the first direction is determined.
[0087] In some embodiments, the reference coordinate point is the initial coordinate of the initial position of the machine to be calibrated in the working coordinate system.
[0088] In some embodiments, the preset position is an initial position of the machine to be calibrated.
[0089] In some embodiments, the offset angle includes the angle between a line connecting the extreme position in the first direction of the machine to be corrected and the reference coordinate point and each coordinate axis of the working coordinate system.
[0090] In some embodiments, when the processor 10 executes the mechanical calibration program 40 in the memory 20, the following steps are further implemented:
[0091] Acquire a first distance value detected by a distance sensor configured for the machine to be calibrated when the machine to be calibrated is located at a reference coordinate point;
[0092] obtaining a second distance value detected by a distance sensor configured for the machine to be calibrated when the machine to be calibrated is located at an extreme position in the first direction;
[0093] The distance between the limit position in the first direction of the machine to be corrected and the reference coordinate point is obtained through the first distance value and the second distance value.
[0094] In some embodiments, when the processor 10 executes the mechanical calibration program 40 in the memory 20, the following steps are further implemented:
[0095] Based on the reference coordinate point, the distance between the extreme position in the first direction of the machine to be corrected and the reference coordinate point, and the offset angle of the machine to be corrected, the coordinate values of the extreme position in the first direction of the machine to be corrected in each direction in the working coordinate system are calculated respectively to obtain the actual coordinates of the extreme position in the first direction of the machine to be corrected in the working coordinate system.
[0096] Based on the above electronic equipment, the present invention also provides a mechanical correction system. Figure 4 The mechanical correction system includes a distance sensor 1, an angle sensor 2 and an electronic device 3 as described in the above embodiments. The distance sensor 1 and the angle sensor 2 are both installed on the machine to be corrected, and the distance sensor 1 and the angle sensor 2 are electrically connected to the electronic device 3.
[0097] In this embodiment, distance sensor 1 is used to obtain the distance between the extreme position of the machine to be corrected and the reference coordinate point when the machine to be corrected moves to the extreme position. Angle sensor 2 is used to obtain the offset angle of the machine to be corrected when the machine to be corrected moves to the extreme position. The distance sensor can be an infrared rangefinder, ultrasonic rangefinder, or other device, and the angle sensor can be a gyroscope or other device. The data detected by distance sensor 1 and angle sensor 2 are directly transmitted to the electronic device, which then performs mechanical correction based on the data. The specific correction method follows the mechanical correction method described in the above embodiments and will not be further described here.
[0098] In summary, the mechanical correction method, device, electronic device, system and storage medium provided by the present invention first establish a working coordinate system, and the movement changes of the machine to be corrected can be converted into changes in the coordinate points in the working coordinate system. Then, by presetting a reference coordinate point of the machine to be corrected, the position of the machine to be corrected corresponding to this reference coordinate point is known. Then, when the machine to be corrected moves to the extreme position in the first direction, the distance between the extreme position of the machine to be corrected and the reference coordinate point and the offset angle of the machine to be corrected are obtained. Since the coordinate value of the reference coordinate point is known, the actual coordinates of the extreme position of the machine to be corrected in the first direction in the working coordinate system can be calculated through the reference coordinate point, the distance between the extreme position of the machine to be corrected and the reference coordinate point, and the offset angle of the machine to be corrected. Since the position of the machine to be corrected corresponding to the reference coordinate point is known, the distance between the extreme position of the machine to be corrected and the reference coordinate point in the first direction can be determined based on the reference coordinate point and the actual coordinates. The present invention eliminates the need for manual calibration of the extreme positions of the machine to be calibrated, eliminates the need for manual measurement of distance values and filling in data, and all processes are completed automatically, reducing the time for engineers to calibrate the machine and reducing the complexity of calibration, thereby achieving efficient work and replacing manual calibration of the machine while ensuring calibration precision and accuracy.
[0099] Of course, those skilled in the art will appreciate that all or part of the processes in the above-described method embodiments can be implemented by instructing related hardware (such as a processor, controller, etc.) through a computer program. The program can be stored in a computer-readable storage medium, and when executed, the program can include the processes in the above-described method embodiments. The storage medium can be a memory, a magnetic disk, an optical disk, etc.
[0100] The specific embodiments of the present invention described above do not limit the scope of protection of the present invention. Any other corresponding changes and modifications made based on the technical concept of the present invention should be included in the scope of protection of the claims of the present invention.
Claims
1. A mechanical calibration method, characterized in that: The steps include: Establishing a working coordinate system with a preset position as the origin, and obtaining a reference coordinate point of the machine to be calibrated in the working coordinate system; Acquire the distance between the extreme position of the machine to be corrected in the first direction and the reference coordinate point and the offset angle of the machine to be corrected when the machine to be corrected moves to the extreme position in the first direction; Calculate the actual coordinates of the limit position in the first direction of the machine to be corrected in the working coordinate system based on the reference coordinate point, the distance between the limit position in the first direction of the machine to be corrected and the reference coordinate point, and the offset angle of the machine to be corrected; According to the reference coordinate point and the actual coordinates, a distance between a limit position of the machine to be corrected in the first direction and the reference coordinate point in the first direction is determined.
2. The mechanical calibration method according to claim 1, wherein: The reference coordinate point is the initial coordinate of the initial position of the machine to be calibrated in the working coordinate system.
3. The mechanical calibration method according to claim 1 or 2, characterized in that: The preset position is the initial position of the machine to be calibrated.
4. The mechanical calibration method according to claim 1, wherein: The offset angle includes the angles between the line connecting the extreme position in the first direction of the machine to be corrected and the reference coordinate point and each coordinate axis of the working coordinate system.
5. The mechanical calibration method according to claim 1, wherein: The obtaining of the distance between the limit position of the machine to be corrected in the first direction and the reference coordinate point when the machine to be corrected moves to the limit position in the first direction includes: Acquiring a first distance value detected by a distance sensor configured for the machine to be calibrated when the machine to be calibrated is located at a reference coordinate point; obtaining a second distance value detected by a distance sensor configured for the machine to be calibrated when the machine to be calibrated is located at an extreme position in the first direction; The distance between the limit position in the first direction of the machine to be corrected and the reference coordinate point is obtained through the first distance value and the second distance value.
6. The mechanical calibration method according to claim 4, characterized in that: The step of calculating the actual coordinates of the limit position in the first direction of the machine to be corrected in the working coordinate system based on the reference coordinate point, the distance between the limit position in the first direction of the machine to be corrected and the reference coordinate point, and the offset angle of the machine to be corrected includes: Based on the reference coordinate point, the distance between the extreme position in the first direction of the machine to be corrected and the reference coordinate point, and the offset angle of the machine to be corrected, the coordinate values of the extreme position in the first direction of the machine to be corrected in each direction in the working coordinate system are calculated respectively to obtain the actual coordinates of the extreme position in the first direction of the machine to be corrected in the working coordinate system.
7. A mechanical correction device, characterized in that: include: A coordinate system establishment module is used to establish a working coordinate system with a preset position as the origin, and obtain the reference coordinate points of the machine to be calibrated in the working coordinate system; a data acquisition module, configured to acquire, when the machine to be corrected moves to the extreme position in the first direction, the distance between the extreme position in the first direction of the machine to be corrected and the reference coordinate point, and an offset angle of the machine to be corrected; a coordinate calculation module, configured to calculate the actual coordinates of the extreme position in the first direction of the machine to be corrected in the working coordinate system based on the reference coordinate point, the distance between the extreme position in the first direction of the machine to be corrected and the reference coordinate point, and the offset angle of the machine to be corrected; The limit position determination module is used to determine the distance between the limit position of the machine to be corrected in the first direction and the reference coordinate point in the first direction according to the reference coordinate point and the actual coordinate.
8. An electronic device, characterized in that: include: processor, memory, and display; The memory stores a computer-readable program executable by the processor; When the processor executes the computer-readable program, the steps of the mechanical correction method according to any one of claims 1 to 6 are implemented; The display is used to display a visual interface.
9. A computer-readable storage medium, characterized in that The computer-readable storage medium stores one or more programs, and the one or more programs can be executed by one or more processors to implement the steps in the mechanical correction method according to any one of claims 1 to 6.
10. A mechanical correction system, characterized in that: The device comprises a distance sensor, an angle sensor and the electronic device as claimed in claim 8, wherein the distance sensor and the angle sensor are both installed on the machine to be calibrated, and the distance sensor and the angle sensor are electrically connected to the electronic device.
Citation Information
Patent Citations
Displacement measurement method and device and expansion displacement detection method and device
CN113188498A