Method, device and equipment for detecting roughness of metal surface based on coded sticker
By using a detection method based on coded stickers, the actual measurement pose is generated and the detection station is determined. Combined with normal pre-contact and elastic pre-tightening, the problems of visual marking being difficult to convert into measurement pose and robot station in the prior art are solved, and high-reliability roughness detection in complex environments is achieved.
Patent Information
- Application Number
- CN202610934728.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2026-06-26
- Publication Date
- 2026-11-24
- Estimated Expiration
- 2046-06-26
AI Technical Summary
In existing technologies for metal surface roughness inspection, visual identification results are difficult to directly convert into actual roughness measurement poses. Fixed workstations or ordinary robot solutions cannot meet the contact detection station requirements in complex environments. Mobile robots cannot reliably complete stylus pre-tightening contact and short-range line scanning, resulting in insufficient detection consistency and reliability.
A detection method based on coded stickers is adopted. By obtaining the unique identifier of the target coded sticker and the number of the measurement point to be detected, the pose transformation matrix of the sticker coordinate system relative to the camera is identified, the target measurement pose is generated, the target detection station of the detection robot is determined, and the roughness result is generated through normal pre-contact, elastic pre-tightening and short-range line scanning.
It improves the consistency of measurement point positioning and retesting, avoids problems such as the inability to observe stickers, the inability to cover line scan trajectories, or unstable posture after the robot is in place, reduces the risk of accidental collisions, overpressure, contact loss, and invalid scans, and improves the reliability of contact roughness detection.
Smart Images

Figure CN122650859B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the fields of metal surface quality inspection, autonomous operation of mobile robots, machine vision positioning, and contact roughness measurement technology, and in particular to a method, apparatus, and equipment for metal surface roughness inspection based on coded stickers. Background Technology
[0002] Metal surface roughness is one of the important indicators for evaluating machining quality, assembly performance, friction and wear performance, and surface treatment quality. In existing industrial settings, roughness testing can be performed using stylus-type roughness testers or profile measuring devices. The basic method involves bringing the measuring stylus into contact with the metal surface being tested, scanning a short distance along a predetermined direction, collecting the profile undulation information of the surface, and then calculating roughness parameters such as Ra and Rz. This type of testing method can obtain relatively direct contact profile data, thus having a basis for application in the testing of metal components, machined surfaces, blades, molds, and sheet metal.
[0003] In existing technologies, the main detection methods are as follows: Background Technology 1: Contact Roughness Detection System Based on Robot Arm.
[0004] Chinese invention patent CN105783851B, publication number CN105783851A, discloses a detection system combining a robotic arm and a surface roughness measuring instrument. The system mainly includes a motion module, a detection module, an industrial control computer, and a pressure sensor module. The motion module includes a robotic arm controller and a robotic arm. The robotic arm controller receives instructions from the industrial control computer via Ethernet and controls the robotic arm to move the detection module to the detection point. The detection module includes an electromagnetic drive module, a surface roughness measuring instrument, and a CCD camera. The pressure sensor module is used to determine whether the surface roughness measuring instrument is in contact with the surface of the workpiece being measured and transmits the pressure signal to the industrial control computer in real time.
[0005] The detection process of this solution is roughly as follows: First, the calibration coordinates are obtained manually by the robotic arm, and the industrial control computer automatically generates the robotic arm control program; then, the industrial control computer transmits the control program to the robotic arm controller via Ethernet and starts the robotic arm; after the robotic arm moves to the designated detection point according to the instructions, the pressure sensor module detects the contact pressure in real time; when the pressure value reaches the preset condition, it is considered that the roughness measuring instrument has been in contact with the detection point, and the electromagnetic drive module drives the roughness measuring instrument to start detection; after the detection is completed, the data displayed on the screen of the roughness measuring instrument is acquired by the CCD camera, and the industrial control computer processes it to generate a detection report.
[0006] In this solution, a robotic arm or robotic hand can be used to drive the roughness measuring instrument to the detection point, and a pressure sensor can be used to determine the contact state between the measuring instrument and the workpiece surface, thereby achieving a certain degree of automated contact roughness detection.
[0007] Background Technology 2: Robot Visual Positioning Scheme Based on Two-Dimensional Recognition Board.
[0008] Chinese invention patent application CN115345936A discloses a method and robot system for testing the angular positioning accuracy of a robot using a two-dimensional recognition plate.
[0009] This scheme involves setting up a 2D recognition board on the robot under test, which can include multiple ArUco codes. During detection, image data and point cloud data of the scene where the robot is located are acquired through a camera. The 2D recognition board is then identified, and its coordinate data is determined based on the image data and point cloud data. Subsequently, the positioning angle data of the robot under test is determined based on the coordinate data of the 2D recognition board, and the positioning angle dataset is obtained by changing the scene multiple times, thereby estimating the robot's angle positioning accuracy.
[0010] The main technical measures of this solution include: acquiring image data and point cloud data through a camera; determining whether the image data contains all the ArUco codes on the 2D recognition board; determining the 2D and 3D numbers of the vertices of each ArUco code; and then obtaining the spatial coordinate data of the 2D recognition board based on the point cloud data. This background technology explains that board-type coding markers can serve as pose reference objects in machine vision systems, used to assist in robot localization or localization accuracy testing.
[0011] Based on the aforementioned existing technologies, it is evident that contact roughness measurement, automated positioning of the detection module by a robotic arm, and visual pose recognition based on 2D recognition boards or ArUco coding all have corresponding technical solutions. Specifically, CN105783851B focuses on utilizing a robotic arm, pressure sensor, and roughness measuring instrument in conjunction to complete contact roughness detection; CN115345936A focuses on using a 2D recognition board, camera images, and point cloud data to calculate robot positioning angle data. These two technologies respectively embody the two related technical directions of "robot contact roughness detection" and "board-based coding visual positioning."
[0012] However, existing technologies typically treat roughness contact measurement, mobile robot on-site positioning, plate coding mark pose recognition, and stylus stabilization line scanning as independent technical steps, and have not yet formed a unified detection process that uses plate coding stickers as the measurement pose reference, a quadruped robot to select the contact detection position, and then a robotic arm stylus to complete the stabilization and pre-tensioning line scanning. Summary of the Invention
[0013] In view of the above, this application provides a method, apparatus and equipment for detecting the roughness of metal surfaces based on coded stickers, the purpose of which is to form a closed-loop detection process from plate coded sticker recognition, real measurement pose generation, detection robot contact detection station determination to stylus stabilization and pre-tightening line scanning.
[0014] In a first aspect, this application provides a method for detecting the surface roughness of metals based on coded stickers, applied to an inspection robot. The inspection robot includes a mobile platform, a camera, a robotic arm, a stylus-type roughness detection probe, and an elastic loading or equivalent pre-tightening detection module. The method includes: Obtain the unique identifier of the target coded sticker and the number of the test point to be detected; The preset detection formula is obtained based on the unique identifier and the number; Identify the target coded sticker and determine the pose transformation matrix of the sticker coordinate system relative to the camera coordinate system; Based on the preset detection formula, the pose transformation matrix, and the pre-calibrated coordinate transformation relationship, a target measurement pose for station selection is generated; Based on the target measurement pose, the target detection station of the detection robot is determined; The detection robot is controlled to move to the target detection station, and after generating the actual measurement pose in the current robot arm base coordinate system at the target detection station, surface roughness detection is performed.
[0015] Secondly, this application provides a metal surface roughness detection device based on coded stickers, comprising: The first acquisition module is used to acquire the unique identifier of the target coded sticker and the number of the test point to be detected. The second acquisition module is used to acquire a preset detection formula based on the unique identifier and the number; The first determining module is used to identify the target coded sticker and determine the pose transformation matrix of the sticker coordinate system relative to the camera coordinate system of the camera. The generation module is used to generate a target measurement pose for station selection based on the preset detection formula, the pose transformation matrix, and the pre-calibrated coordinate transformation relationship. The second determining module is used to determine the target detection station of the detection robot based on the target measurement pose; The detection module is used to control the detection robot to move to the target detection station, and after generating the actual measurement pose in the current robot arm base coordinate system at the target detection station, perform surface roughness detection.
[0016] Thirdly, this application provides an electronic device, including a processor, a communication interface, a memory, and a communication bus; when the processor executes a program stored in the memory, it implements the method described in any embodiment of the first aspect.
[0017] Fourthly, this application provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the method described in any embodiment of the first aspect.
[0018] The technical solutions provided in this application have the following advantages compared with the prior art: (1) The plate-type coded sticker serves as a measurement pose reference, rather than just an identification mark or a general visual positioning mark. It can generate the real measurement point position, local surface normal and stylus scanning direction through the detection formula under the sticker coordinate system, thereby improving the consistency of measurement point positioning and retesting. (2) The target detection station position is determined by the visibility of the sticker, the reachability of the robotic arm, and the stability of the robot's posture. This can avoid the problem that the robot cannot observe the sticker, cannot cover the line scan trajectory, or has an unstable posture when it reaches the vicinity of the target for measurement. (3) By using normal pre-contact, closed-loop pre-tightening of stylus compression, judgment of stable pre-tightening ratio and judgment of short-range line scan effectiveness, the risks of accidental contact, overpressure, contact loss and invalid scanning can be reduced, thereby improving the reliability of contact roughness detection. Attached Figure Description
[0019] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.
[0020] To more clearly illustrate the technical solutions in the embodiments of this application or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0021] Figure 1 This is a flowchart illustrating a preferred embodiment of the metal surface roughness detection method based on coded stickers in this application; Figure 2 This is a schematic diagram of a preferred embodiment of the metal surface roughness detection device based on coded stickers in this application; Figure 3 This is a schematic diagram of a preferred embodiment of the metal surface roughness detection system based on coded stickers of this application; Figure 4 This is a schematic diagram of a preferred embodiment of the electronic device of this application; The realization of the purpose, functional features and advantages of this application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation
[0022] To make the objectives, technical solutions, and advantages of this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and not intended to limit the scope of this application. All other embodiments obtained by those skilled in the art based on the embodiments in this application without inventive effort are within the scope of protection of this application.
[0023] It should be noted that the descriptions involving "first," "second," etc., in this application are for descriptive purposes only and should not be construed as indicating or implying their relative importance or implicitly specifying the number of technical features indicated. Therefore, a feature defined as "first" or "second" may explicitly or implicitly include at least one of that feature. Furthermore, the technical solutions of the various embodiments can be combined with each other, but this is based on the premise that those skilled in the art can implement them. When the combination of technical solutions is contradictory or impossible to implement, it should be considered that such a combination of technical solutions does not exist and is not within the scope of protection claimed in this application.
[0024] When faced with complex, variable, and unstructured metal surface inspection scenarios in real industrial settings, especially in high-altitude, hazardous, narrow, cross-regional inspection areas, or when component postures are not fixed, existing roughness inspection technologies, while possessing capabilities such as manual stylus measurement, robotic arm automatic inspection, or visual marker positioning, still have the following key shortcomings.
[0025] 1. Visual identifier recognition results are difficult to directly convert into actual roughness measurement pose.
[0026] Existing visual positioning solutions based on QR codes, ArUco encoding, or 2D recognition boards can identify the identity, position, and posture of the identifier itself, and can be used for robot localization, pose calibration, or positioning accuracy testing. For example, the solution disclosed in CN115345936A obtains the coordinate data of the recognition board through a 2D recognition board and an ArUco encoding unit to achieve robot angle positioning accuracy testing. This type of solution demonstrates that board-type coded identifiers can serve as pose reference objects in machine vision.
[0027] However, roughness detection requires not the pose of the marker itself, but the position of the actual measurement point, the local surface normal, and the scanning direction of the stylus. For contact roughness measurement, the stylus reaches the specific measurement point and performs a short-range line scan along the specified direction of the surface being measured. If existing vision recognition solutions only output the marker pose without establishing a fixed mapping relationship between the marker coordinate system and the actual measurement point, local normal, and scanning direction, then even if the robot "sees the marker," it cannot reliably translate this into "the stylus reaching the correct measurement point and scanning in the correct direction."
[0028] Therefore, existing visual marker localization technologies have a critical bottleneck when used for roughness detection: there is a lack of executable measurement pose mapping between the recognition results and the actual contact measurement actions. This leads to difficulties in reproducing the measurement point positions and unifying the scanning directions, thus affecting the consistency and comparability of multiple tests.
[0029] 2. Fixed workstations or ordinary robot solutions are difficult to meet the requirements of contact detection stations in complex environments.
[0030] Existing robotic arm-based roughness inspection solutions can improve automation levels to some extent. For example, the roughness inspection system disclosed in CN105783851B uses a robotic arm to move the roughness measuring instrument to the inspection point, and combines a pressure sensor to determine whether the roughness measuring instrument is in contact with the workpiece surface. This type of solution demonstrates that robotic arms can be used in conjunction with roughness inspection modules to automate contact-type roughness inspection.
[0031] However, fixed-station or traditional industrial robotic arm solutions typically rely on pre-taught, known workstations, regular workpiece placement, or relatively stable tooling and fixture environments. When the metal component being measured is located at a height, in a narrow area, a hazardous area, in a complex ground environment, or in a site that requires movement across areas, fixed robotic arms or fixed testing stations cannot directly access the target measurement point, and their mobility is insufficient.
[0032] On the other hand, even if a regular mobile robot can navigate to the vicinity of the target, it doesn't necessarily mean it can complete contact roughness detection. Contact roughness detection places higher demands on the robot's positioning: the camera needs to be able to stably observe the coded sticker, the robotic arm needs to be able to reach the actual measurement point, and the robot itself needs to maintain a sufficiently stable posture to avoid posture disturbances during stylus contact and line scanning. If the robot simply moves to the target area according to ordinary navigation logic without considering sticker visibility, robotic arm accessibility, and robot posture stability, problems may arise such as not being able to see the sticker after reaching the target, the robotic arm not being able to reach the measurement point, and the robot's posture being unstable during contact.
[0033] Therefore, the shortcomings of existing fixed-station or ordinary mobile robot solutions are that their ability to "reach the vicinity of the target" is not equivalent to "having the conditions for contact roughness detection", and it is difficult to meet the operational requirements of simultaneous visual recognition, robotic arm contact and stylus line scanning in complex environments.
[0034] 3. Mobile robots have difficulty reliably completing stylus pre-tightening contact and short-range line scanning.
[0035] Roughness inspection differs from ordinary visual inspection or surface defect photography. Visual inspection typically only requires acquiring images or point clouds, while stylus-based roughness inspection involves the probe's measuring end forming controlled contact with the metal surface and performing a short-distance scan along a specified direction under appropriate preload. If the contact force or preload is insufficient, the stylus may not properly adhere to the surface; if the contact force is excessive, it may damage the probe or scratch the measured surface; if the contact state is unstable during the scan, the acquired contour data may be invalid.
[0036] While existing robotic arm-based inspection solutions can determine whether the measuring instrument is in contact with the workpiece using pressure sensors, their focus is typically on contact detection and measurement triggering in fixed positions, lacking a continuous contact control process for mobile robot on-site operations. Especially when a quadruped robot is equipped with a robotic arm, there are coupling relationships between the robot's posture, the robotic arm's end effector movement, the normal of the measured surface, the stylus compression, and the short-range scanning direction. If the robotic arm moves directly from space to the measuring point and touches the workpiece, problems such as accidental collisions, overpressure, insufficient contact, or loss of contact during scanning can easily occur.
[0037] Therefore, existing technologies still have significant shortcomings in mobile robot roughness inspection scenarios: they lack a complete control process from setting up pre-contact points, gradually approaching along the local normal, establishing elastic pre-tightening, maintaining stable contact, to performing short-range line scanning. This deficiency directly affects the safety, effectiveness, and measurement reliability of contact roughness inspection.
[0038] This application addresses the three key steps required for contact roughness testing and provides a metal surface roughness testing method based on coded stickers. The method mainly comprises three parts: First, a measurement pose is generated from the coded sticker and its testing formula; second, a testing robot selects a testing station that satisfies the requirements of sticker visibility, robotic arm reachability, and robot stability, wherein the testing robot is preferably a quadruped robot; third, an effective roughness result is generated by the robotic arm stylus through normal pre-contact, elastic pre-tensioning, and short-range linear scanning.
[0039] In some embodiments, the technical solution of this application can be described using the method of basic variables → intermediate variables → advanced variables → final result. The overall algorithm chain is shown in equation (1): (1) In equation (1), Indicates the first Each board-type coded sticker has a unique code. This indicates the number corresponding to the sticker. One measuring point, This indicates the test formula that is retrieved by the sticker code and test point number. This represents the actual measured pose of the robotic arm in the base coordinate system. This indicates the final inspection station of the quadruped robot. It represents a set of test results consisting of contour sequence, scan validity, roughness parameters, roughness grade, and pass / fail status.
[0040] The system of this application may include a plate-type coded sticker and a test recipe module, a test robot mobile platform, a vision recognition module, a robotic arm and stylus contact measurement module, an elastic loading or equivalent pre-tightening test module, and a control and recording module. The test robot mobile platform is preferably a quadruped robot mobile platform. The plate-type coded sticker is placed near the surface of the metal to be tested to provide sticker identification and pose reference; the camera is used to identify the sticker code and obtain the sticker's real-time pose; the test robot is used to enter the target area and select a suitable test station for contact measurement; the robotic arm is used to drive the stylus-type contact probe to the measurement pose; the elastic loading or equivalent pre-tightening test module is used to obtain the compression, contact force, or equivalent contact state during stylus contact; the control and recording module is used to perform recipe invocation, pose calculation, station selection, pre-tightening control, contour processing, and result output.
[0041] This application adopts a unified coordinate transformation convention. Let... For world or map coordinate systems, The coordinate system of the quadruped robot is the body coordinate system. For the robot arm base coordinate system, For the camera coordinate system, For the first A coordinate system for a board-style coded sticker. For the first The first sticker Measurement pose coordinate system of each measuring point Install a coordinate system for the end effector flange or tool of the robotic arm. This article uses... Indicates from coordinate system To coordinate system The homogeneous transformation of , i.e., any point satisfies equation (2).
[0042] (2) The homogeneous transformation matrix in equation (2) is expressed in the form of equation (3).
[0043] (3) In equation (3), Let be a rotation matrix. Let be the translation vector. All subsequent formulas follow the coordinate conventions of equations (2) and (3).
[0044] Reference Figure 1 The diagram shown is a flowchart illustrating an embodiment of the metal surface roughness detection method based on coded stickers according to this application. The method is executed by an electronic device, which can be implemented by a software system and / or a hardware system. The method includes: Step 101: Obtain the unique identifier of the target coded sticker and the number of the test point to be tested.
[0045] Target coding stickers are flat markers affixed near the surface of the metal component being measured, serving to carry identification information and measurement references. Target coding stickers contain a specific coding pattern, such as an ArUco code or a QR code, which has a unique binary sequence or combination of numbers.
[0046] The unique identifier is a non-repeating identification code inherent to the target coded sticker.
[0047] The number of the test point is a serial number used to distinguish different measurement locations within the detection area corresponding to the same target coded sticker. Since a large metal surface may require multiple point detections, the number of the test point is used to distinguish multiple points under the same sticker.
[0048] In some embodiments, the unique identifier of the target coded sticker to be detected and the number of the test point to be detected within the area covered by the sticker can be extracted from the task list.
[0049] Step 102: Obtain the preset detection formula based on the unique identifier and the number.
[0050] A preset inspection formula is a set of structured parameters pre-stored in the inspection robot control system. The preset inspection formula establishes a mapping relationship from the coded sticker to the physical measurement action. The preset inspection formula includes at least the measurement point position, local normal, and stylus scanning direction defined in the sticker coordinate system, and preferably also includes scanning length, scanning speed, sampling frequency, pre-contact safety distance, contact establishment threshold, target pre-tightening compression amount, stable pre-tightening interval, and roughness judgment threshold.
[0051] The sticker coordinate system is a three-dimensional Cartesian coordinate system established with the physical feature points of the target coded sticker as the origin. The center point or a corner point of the sticker can be selected as the origin, and the two orthogonal edges of the sticker can be used as the coordinate axes. For example, the origin of the sticker coordinate system can be set at the geometric center of the sticker, with the X-axis pointing to the right along the long side of the sticker, the Y-axis pointing upwards along the short side of the sticker, and the Z-axis pointing outwards perpendicular to the sticker surface.
[0052] The measurement point location is the three-dimensional coordinate of the metal surface point that the stylus roughness probe needs to contact, defined in the sticker coordinate system.
[0053] The local normal is a unit vector perpendicular to the surface of the metal being measured at the measurement point. This vector defines the direction the stylus probe should approach. For example, for a horizontally placed steel plate, its local normal is a vertically upward vector.
[0054] The stylus scanning direction is the unit vector along which the stylus needs to reciprocate in a straight line at the measurement point, and this vector is perpendicular to the local normal.
[0055] The pre-contact safety distance is the safe distance offset outward from the measuring point along the local normal, for example, 2 mm. The contact establishment threshold is the minimum value at which the stylus compression first reaches a point of contact determination, for example, 0.05 mm. The target preload compression is the desired compression value to be maintained after the stylus has made stable contact, for example, 0.15 mm. The stable preload range is the permissible range of compression, for example, 0.12 mm to 0.18 mm.
[0056] In some embodiments, the acquired unique identifier and the number of the test point to be tested can be used as a combined index key to access a local or cloud database. The database retrieves and returns the corresponding preset test formula based on this index key.
[0057] To address the issue that a camera seeing a sticker cannot directly translate it into a stylus reaching the actual measurement point and scanning in the correct direction, this application uniformly incorporates the sticker code, measurement point position, local normal, and scanning direction into the detection formula, and generates the actual measurement pose in the robotic arm base coordinate system layer by layer from the basic variables.
[0058] For the The first board-type coded sticker and its first The test point is defined as shown in equation (4).
[0059] (4) In equation (4), This represents the preferred set of parameters excluding the measurement point location, local normal, and scanning direction; the core essential variable is... , and , respectively representing the measuring points in the sticker coordinate system The position below, the local surface normal of the measuring point, and the scanning direction of the stylus. , and These represent the scan length, scan speed, and sampling frequency, respectively. Indicates the pre-contact safety distance; Indicates the contact establishment threshold; Indicates the target preload compression amount; Indicates the allowable range for stable pre-tightening; and This indicates the acceptable roughness threshold. This indicates the contour processing parameters. In formal implementation, the detection formula should at least include the measurement point location, local normal, and scanning direction; the remaining parameters can be configured as preferred parameters.
[0060] Step 103: Identify the target coded sticker and determine the pose transformation matrix of the sticker coordinate system relative to the camera coordinate system.
[0061] An inspection robot is an automated device that integrates a mobile platform, a camera, a robotic arm, a stylus-type roughness detection probe, and an elastic loading or equivalent preload detection module. In some embodiments, the inspection robot may be a quadruped robot equipped with a camera.
[0062] The camera coordinate system is a three-dimensional coordinate system established with the optical center of the camera mounted on the inspection robot as its origin. The X and Y axes of the camera coordinate system correspond to the pixel coordinate system of the image, and the Z axis points along the camera's optical axis towards the scene.
[0063] A pose transformation matrix is a mathematical representation describing the spatial position and rotation relationship between two different coordinate systems. It consists of two parts: a translation vector and a rotation matrix. A pose transformation matrix can transform the coordinates of a point in one coordinate system to another.
[0064] In some embodiments, the detection robot moves into the observation range of the target coded sticker, acquires image data of the current environment through a camera, decodes the image using an image processing algorithm, identifies the pattern feature points of the target coded sticker, and calculates the three-dimensional pose of the target coded sticker in the current field of view of the camera.
[0065] Step 104: Based on the preset detection formula, the pose transformation matrix, and the pre-calibrated coordinate transformation relationship, generate the target measurement pose for station selection.
[0066] The pre-defined coordinate transformation relationships include the fixed transformation matrix from the camera coordinate system to the robot arm base coordinate system, and the transformation relationship from the robot arm base coordinate system to the world coordinate system.
[0067] The coordinate system of the robotic arm base is a coordinate system established with the bottom mounting center of the robotic arm mounted on the inspection robot as the origin.
[0068] The target measurement pose is the spatial pose of the measurement point used for detection station selection and line scan trajectory planning. It can be represented in the world coordinate system or the map coordinate system. The actual measurement pose is the precise position and orientation that the end effector of the robotic arm needs to reach in the current coordinate system of the robotic arm base after the detection robot arrives at the target detection station in order to achieve contact measurement. The actual measurement pose includes position coordinates and orientation, and its orientation ensures that the stylus axis matches the normal of the metal surface and that the scanning direction is consistent with the preset direction.
[0069] In some embodiments, generating a target measurement pose for station selection based on the preset detection formula, the pose transformation matrix, and the pre-calibrated coordinate transformation relationship, and generating the actual measurement pose in the current robotic arm base coordinate system at the target detection station, includes: S11, normalize the local normal to obtain the normalized normal.
[0070] The normalized normal vector is the local normal vector obtained after normalization.
[0071] S12, the stylus scanning direction is projected onto a tangent plane perpendicular to the normalized normal, and the projection result is normalized to obtain the normalized scanning direction.
[0072] A tangent plane is a plane that passes through the measuring point and is perpendicular to the local normal. For an ideal planar metal surface, the entire surface is a tangent plane; for a curved surface, the tangent plane is tangent to the surface only at the measuring point.
[0073] Projection is a geometric operation that maps a vector in space onto a plane or line.
[0074] The normalized scan direction is a vector located in the tangent plane after projection and normalization.
[0075] S13, construct a measurement coordinate system rotation matrix in the sticker coordinate system with the normalized scanning direction as the first axis of the measurement coordinate system, the normalized normal direction as the third axis of the measurement coordinate system, and the cross product direction of the two as the second axis.
[0076] The measurement coordinate system is a temporary coordinate system established to describe the ideal pose of the stylus at the moment of measurement. The axes of this coordinate system are aligned with the measurement action, and the X-axis can be defined as the scanning direction, the Z-axis as the normal direction, and the Y-axis determined by the right-hand rule.
[0077] A rotation matrix is a 3x3 matrix used to describe the rotational relationship between two coordinate systems. Each column of the rotation matrix represents a unit vector along one of the coordinate axes.
[0078] S14. Based on the position of the measuring point and the rotation matrix of the measuring coordinate system, construct the measuring pose in the sticker coordinate system.
[0079] Measurement pose is a pose description that includes both position and orientation information. Measurement pose specifies not only where the stylus should contact, but also at what angle.
[0080] In some embodiments, the position of the measurement point can be used as the translation vector of the origin of the measurement coordinate system in the sticker coordinate system, and the rotation matrix can be combined with the translation vector to form the measurement pose in the sticker coordinate system.
[0081] S15, obtain the pre-calibrated coordinate transformation relationship, which includes at least the fixed transformation matrix from the camera coordinate system to the robot arm base coordinate system.
[0082] A fixed transformation matrix is a matrix that describes the relative pose between two physically rigidly connected coordinate systems. Since the camera is fixed to the robot, and the robotic arm is also fixed to the robot, the relative position of the camera coordinate system to the robotic arm base coordinate system remains constant.
[0083] Before leaving the factory or during on-site deployment, the relative positional relationship between the camera and the robotic arm base has been determined through a hand-eye calibration process. The results of the calibration process are stored as a fixed transformation matrix.
[0084] S16, calculate the target measurement pose for station selection based on the pose transformation matrix, the fixed transformation matrix and the measurement pose; after re-identifying the target coded sticker at the target detection station, calculate the actual measurement pose in the current robotic arm base coordinate system.
[0085] In some embodiments, during the station selection stage, based on the pose transformation matrix, the pose information of the detection robot, and the pre-calibrated coordinate transformation relationship, the measured pose in the sticker coordinate system is converted into the target measured pose in the world coordinate system or the map coordinate system.
[0086] During the station selection stage, the measured pose in the sticker coordinate system can be transformed to the world coordinate system or map coordinate system for candidate station generation and evaluation. At the target detection station, the measured pose in the sticker coordinate system can be transformed to the camera coordinate system using the pose transformation matrix obtained from the re-identification. Then, the fixed transformation matrix from the camera coordinate system to the robot arm base coordinate system can be used to further transform it to the current robot arm base coordinate system to obtain the true measured pose.
[0087] The process of determining the true pose described above can be illustrated in the following embodiment: First, the local normals in the formula are normalized, as shown in equation (5).
[0088] (5) Then, the scanning direction in the formula is projected into a tangent plane perpendicular to the local normal, as shown in equation (6).
[0089] (6) Normalize the scanning direction after projection to obtain equation (7).
[0090] (7) Based on equations (5) and (7), a second axis is generated from the local normal and the scanning direction, as shown in equation (8).
[0091] (8) The rotation matrix of the measurement coordinate system under the sticker coordinate system is constructed by equations (5), (7) and (8), as shown in equation (9).
[0092] (9) In equation (9), the measurement coordinate system of The axis is defined as the scanning direction of the stylus. An axis is defined as a local surface normal. The axis is obtained by the cross product of the normal and the scanning direction. Therefore, the measurement pose in the sticker coordinate system can be constructed by the measurement point position and the rotation matrix, as shown in equation (10).
[0093] (10) Equation (10) shows that this application does not treat the measured pose as an isolated black box result in the database, but generates it layer by layer from the position of the measurement point, the local normal and the scanning direction.
[0094] After the camera recognizes the coded sticker, it obtains the sticker's pose relative to the camera. The system pre-calibrates a fixed transformation from the camera coordinate system to the robot arm base coordinate system. Combining equation (10), the actual measured pose in the coordinate system of the robotic arm base is generated according to equation (11).
[0095] (11) If the inverse kinematics solution for the robotic arm is the pose of the end flange, and the installation extrinsic parameters from the flange coordinate system to the measurement coordinate system are... Then the target pose of the flange is obtained by equation (12).
[0096] (12) Equations (11) and (12) complete the mapping from sticker recognition results to the target pose that the robotic arm can execute. Thus, the final output of the actual measured pose is... This demonstrates that after the robot recognizes the sticker, it not only obtains the sticker's identity and posture, but also the actual measurement point location, local surface normal, and stylus scanning direction.
[0097] Step 105: Based on the target measurement pose, determine the target detection station of the detection robot.
[0098] The target detection station is used to detect the optimal parking position and posture of the robot body on the ground.
[0099] In some embodiments, determining the target detection station position of the detection robot based on the target measurement pose includes: S21, generate a set of candidate stations near the measurement point position corresponding to the target measurement pose.
[0100] Candidate stations are potential docking points inferred from the surrounding environment of the measurement point location. Each candidate station includes the coordinates of the robot chassis on the plane and the orientation angle of the robot body. The candidate station set is a collection of multiple candidate stations.
[0101] In some embodiments, the target's measurement pose can be analyzed to extract the coordinates of the measurement point location in a global or local map. Using this measurement point location as the center, a reasonable search area is delineated based on the robot's mobility and environmental perception data. Within this area, a series of candidate stations are generated using a sampling algorithm.
[0102] S22, for each candidate station in the candidate station set, evaluate its sticker visibility index, robotic arm reachability index, and posture stability index respectively.
[0103] Sticker visibility index is a Boolean value or score used to quantitatively determine whether the camera on the robot can clearly and completely identify the target coded sticker at a certain candidate station.
[0104] The robotic arm reachability index is a Boolean value or score used to quantitatively determine whether a robotic arm can successfully execute the motion from the pre-contact point to the complete scanning trajectory without collision or joint over-limit at a certain candidate station.
[0105] The standing stability index is used to quantify the robot chassis's ability to remain static and not tip over or slip when subjected to the contact reaction force of the stylus in a candidate standing position.
[0106] In some embodiments, evaluating the visibility metrics of the sticker includes: Calculate the camera image projection area of the target coded sticker at the candidate station, the recognition distance from the camera to the sticker, the viewing angle of the camera to the sticker, and the occlusion status.
[0107] The camera image projection area refers to the pixel area of the four corner points or outline of the target coded sticker on the camera imaging plane, which can be a quadrilateral area.
[0108] The camera-to-sticker recognition distance refers to the three-dimensional straight-line distance from the optical center of the camera to the geometric center of the sticker, for example, 0.8 meters.
[0109] The viewing angle of the camera when viewing the sticker refers to the angle between the direction of the camera's optical axis and the direction of the normal to the sticker's plane, for example, 15 degrees.
[0110] Obstruction status refers to whether there are other objects blocking the line from the camera position to the sticker.
[0111] If the camera image projection area is within the effective recognition area, the recognition distance is within the allowable recognition distance range, the observation angle is less than or equal to the maximum allowable observation angle, and the occlusion state is unobstructed, then the sticker visibility index is determined to be valid; otherwise, it is determined to be invalid.
[0112] The effective recognition area refers to the range of pixels in the camera image that can reliably decode the sticker's encoded information. The effective recognition area can be slightly smaller than the entire image; for example, it can be 50 pixels wide to 50 pixels low and 50 pixels high.
[0113] The permissible recognition distance range refers to the interval between the minimum and maximum distances from which the camera can clearly image and decode the sticker. For example, the minimum distance is 0.3 meters and the maximum distance is 1.5 meters.
[0114] The maximum permissible observation angle refers to the maximum angle between the camera's optical axis and the sticker's normal that ensures effective identification. For example, 45 degrees or 60 degrees.
[0115] In some embodiments, evaluating the robotic arm reachability index for each candidate station in the candidate station set includes: S221, based on the target measurement pose and the preset scan length and number of sampling points, generate a set of target poses for the pre-contact point of the robotic arm end flange and a set of target poses for the line scan trajectory at the candidate station.
[0116] The scanning length is the linear distance that the stylus needs to move along the scanning direction after contacting the metal surface, as defined in the preset detection formula.
[0117] The number of sampling points is the number of discrete points within the scan length range that are planned to be collected, as defined in the preset detection formula.
[0118] The end flange of a robotic arm is a connecting plate at the very end of the robotic arm, used to mount tools or sensors. In some embodiments, a stylus-type roughness probe is mounted on the end flange of the robotic arm.
[0119] The target pose set for the line scan trajectory is a list of discrete spatial pose points that the end effector flange of the robotic arm needs to sequentially traverse to complete a full short-range line scan on a metal surface. Each element in the set includes position coordinates and attitude angles.
[0120] In some embodiments, the candidate station currently being evaluated can be obtained, and the transformation of the robot arm base coordinate system relative to the world coordinate system or map coordinate system can be calculated based on the robot pose of the station. The target measurement pose can be transformed to the robot arm base coordinate system corresponding to the current candidate station using coordinate transformation, and the linear spacing between adjacent sampling points can be calculated based on the preset scan length and number of sampling points.
[0121] Furthermore, starting from the pre-contact point, a series of discrete target points are generated sequentially along the stylus scanning direction defined in the target measurement pose, using the calculated spacing as the step size. For each generated target point, the same pose is assigned, and the discrete points with position and pose information are aggregated to generate a set of target poses for the line scan trajectory.
[0122] S222, traverse each target pose in the set of target poses of the line scan trajectory.
[0123] The target pose is a single element in the set of target poses of the line scan trajectory, representing the spatial state that the end flange of the robotic arm needs to reach at a specific sampling moment.
[0124] S223, for each target pose in the set of target poses of the pre-contact point and the line scan trajectory, determine whether there are joint angle solutions of the robot arm that satisfy the joint limit, obstacle avoidance constraint and end-effector posture constraint.
[0125] The joint angle solution of a robotic arm is a set of joint angle values calculated by a certain algorithm to enable the end effector of the robotic arm to reach a specified target pose.
[0126] The pre-contact point is a spatial point defined in the target or actual measurement pose, located at a safe distance from the surface along the normal direction of the measuring point. The robotic arm needs to move to the pre-contact point before performing contact to avoid high-speed impact on the workpiece.
[0127] In some embodiments, for each target pose traversed, the inverse kinematics solver of the robotic arm is invoked. The solver attempts to calculate a set of robotic arm joint angles such that when the joints of the robotic arm rotate to these angles, the pose of the end effector flange of the robotic arm perfectly matches the target pose.
[0128] S224, if each target pose in the pre-contact point target pose and the line scan trajectory target pose set has a robotic arm joint angle solution that satisfies the constraint conditions, then the robotic arm reachability index is determined to be valid; otherwise, it is determined to be invalid.
[0129] In some embodiments, the inspection results can be summarized. If, during the traversal of the target pose set of the line scan trajectory, it is found that no valid robotic arm joint angle solution can be found for any target pose, or that the pre-contact point is unreachable, then the robotic arm reachability index of that candidate station can be determined to be invalid. Conversely, when every target pose in the target pose set of the line scan trajectory, including the pre-contact point and all scan points, successfully finds a robotic arm joint angle solution that satisfies the constraints, the robotic arm reachability index of that candidate station is determined to be valid.
[0130] In some embodiments, evaluating the posture stability index for each candidate station in the candidate station set includes: S225, obtain the target pre-tightening compression amount set in the preset detection formula and the equivalent stiffness of the elastic loading or equivalent pre-tightening detection module.
[0131] Equivalent stiffness is a physical parameter that describes the ability of a stylus or its connected elastic element to resist compressive deformation. Its value is equal to the force required to produce a unit amount of compression.
[0132] In some embodiments, a preset test recipe database associated with the current test point can be accessed to extract a pre-configured target pre-tightening compression value from the recipe, and the equivalent stiffness calibration value of the elastic loading mechanism or force sensor equipped with the stylus probe can be read from a hardware configuration parameter library.
[0133] S226. The estimated normal contact force generated when the stylus is pre-tightened is estimated according to FN=k·Δd, where k is the equivalent stiffness of the elastic loading mechanism and Δd is the target pre-tightening compression.
[0134] The estimated normal contact force generated when the stylus is pre-tightened is the vertical force applied by the stylus to the metal surface during the stable measurement phase, which is predicted by theoretical calculation based on the target pre-tightening compression and equivalent stiffness.
[0135] This calculation relationship establishes a definite linear correspondence between the target preload compression, equivalent stiffness, and estimated normal contact force.
[0136] S227, Obtain robot attitude angles and ground support information at candidate stations.
[0137] The robot attitude angle at the candidate station refers to the tilt angle of its body coordinate system relative to the horizontal plane or the direction of gravity when the robot chassis is located at the candidate station. It can include roll angle and pitch angle.
[0138] Ground support information refers to data related to the physical characteristics of the ground in contact with the robot's feet. This ground support information includes the foot support polygon, the ground friction coefficient, or the ground supportability assessment result.
[0139] The foot support polygon is a convex polygon formed by connecting the four foot contact points of a robot in sequence. This polygon is used to calculate the stability margin of the robot.
[0140] The coefficient of friction refers to the static friction coefficient between the robot and the ground it contacts. For example, the coefficient of friction for a rough concrete surface is 0.8, while the coefficient of friction for a smooth steel plate surface is 0.3.
[0141] The ground supportability assessment result is a Boolean value, indicating whether the location where the robot's foot is placed is sufficient to provide stable support. For example, terrain analysis can be used to determine whether the location is a flat, hard surface rather than soft mud or suspended in mid-air.
[0142] In some embodiments, a three-dimensional model of the robot can be set in the pose of a candidate station, and the roll and pitch angles of the robot relative to the horizontal plane can be simulated or calculated based on forward kinematics using an inertial measurement unit on the robot body.
[0143] In some embodiments, the robot can use foot force sensors or contact sensors to determine whether each foot is in contact with the ground, project the contact points onto a horizontal plane, and connect them in a counterclockwise order to form a foot support polygon.
[0144] The ground friction coefficient is read from a pre-built site surface property map, which can be generated through visual or lidar semantic segmentation.
[0145] The ground supportability assessment result can be obtained by combining terrain geometry information and friction coefficient. For example, when the ground slope at the foot position is less than 10 degrees and the friction coefficient is greater than 0.5, the supportability is true; otherwise, it is false.
[0146] S228, determine whether the stance stability margin of the candidate station is greater than or equal to the minimum stability margin threshold under the condition of bearing the estimated normal contact force, and whether the robot attitude angle is within the allowable range.
[0147] The stability margin under a predicted normal contact force is an indicator of a robot's resistance to tipping over. It calculates the shortest distance from the robot's center of gravity projection point to the boundary of the supporting polygon when the predicted normal contact force is applied to the end effector of the robotic arm. A larger distance indicates greater robot stability.
[0148] The minimum stability margin threshold is a preset minimum stability margin threshold value to ensure safety.
[0149] The permissible range of robot attitude angles refers to the maximum absolute values of the robot's roll and pitch angles that ensure normal operation. For example, the roll angle is within ±5 degrees, and the pitch angle is within ±5 degrees.
[0150] S229. If all the above conditions are met, the standing posture stability index is determined to be valid; otherwise, it is determined to be invalid.
[0151] In this embodiment, key mechanical constraints in contact measurement are incorporated into the positioning decision in advance. By theoretically estimating the contact force and calculating the robot's static stability margin, a forward-looking and quantitative assessment of the robot's posture stability is achieved.
[0152] S23, select a set of feasible detection stations that simultaneously meet the sticker visibility index, robotic arm accessibility index, and standing posture stability index.
[0153] Feasible test stations are candidate stations that have passed all hard constraint checks. The set of feasible test stations is a set consisting of all feasible test stations.
[0154] In some embodiments, the evaluation results of each candidate station can be checked one by one to determine whether the sticker visibility index, the robotic arm reachability index, and the posture stability index of each candidate station are valid. When all three indicators meet the conditions, the candidate station can be classified as a feasible detection station.
[0155] S24. If there are multiple feasible detection stations, the station with the lowest cost is selected from the set of feasible detection stations based on a preset comprehensive cost function as the target detection station.
[0156] The comprehensive cost function is a mathematical model used to weight and combine multiple evaluation indicators from different dimensions into a single scalar value to measure the quality of a feasible detection station.
[0157] The comprehensive cost function includes visual recognition cost, robotic arm operability cost, posture stability cost, and path cost.
[0158] In some embodiments, the size of the set of feasible detection stations can be checked. If there is only one feasible detection station in the set, it is directly determined as the target detection station. If there are multiple feasible detection stations, a preset comprehensive cost function is called to calculate the cost. All calculated cost values are compared, and the feasible detection station with the smallest cost value is selected and established as the target detection station.
[0159] Step 105 corresponds to the second main part of this application, namely, the quadruped robot does not simply move to the vicinity of the sticker, but selects a detection station that can support subsequent contact measurements. This detection station should at least meet three conditions: the sticker is visible, the robotic arm is reachable, and the robot's posture is stable.
[0160] The quadruped robot generates a set of candidate stations near the target area, as shown in Equation (13).
[0161] (13) In equation (13), Indicates the first There are 10 candidate locations. For each candidate location, this application calculates the sticker visibility separately. Robotic arm accessibility and robot standing stability .
[0162] The sticker visibility calculation is shown in Equation (14).
[0163] (14) In equation (14), This indicates that the value is 1 if the condition is met, and 0 otherwise. Indicates position The position of the sticker's projection in the camera image; Indicates the effective recognition area of the camera image; Indicates the distance from the camera to the sticker; and Indicates the allowed recognition distance range; This indicates the angle at which the camera observes the sticker; Indicates the maximum allowable angle of observation; The value represents the occlusion state; it is 0 when there is no occlusion. Equation (14) ensures that the candidate station position can stably identify the board-type coded sticker.
[0164] Robotic arm accessibility determines not only whether the robotic arm can reach a single measurement point, but also whether it can cover the pre-contact point and the entire short-range linear scanning trajectory. Candidate station locations. The set of flange target trajectories is defined as shown in equation (15).
[0165] (15) In equation (15), Indicates candidate station The coordinate system of the robot arm base is below. Indicates the first The flange target pose corresponding to each line scan sampling point. Based on equation (15), the reachability calculation of the robotic arm is shown in equation (16).
[0166] (16) In equation (16), For the first The reachability indicator of each line scan trajectory point. When joint solutions exist. ,make ,and , season Otherwise, set it to 0. Equation (16) shows that the detection station in this application is not an ordinary navigation point, but a working station that must be able to support the robotic arm to complete pre-contact and full-segment line scanning.
[0167] The robot's standing stability should also consider the normal force resulting from the subsequent pre-tightening contact of the stylus. If the equivalent stiffness of the elastic loading mechanism is... The target pre-tight compression amount is Then the estimated normal contact force can be given by equation (17).
[0168] (17) Combining equation (17), the robot's standing posture stability is calculated as shown in equation (18).
[0169] (18) In equation (18), This indicates the stance stability margin after considering the estimated normal contact force. This represents the minimum stability margin threshold. and These represent the robot's roll angle and pitch angle, respectively. and These represent the allowable attitude angle thresholds, This indicates the ground supportability assessment. Equation (18) makes the stability of the detection station directly related to the subsequent stylus pre-tightening contact action.
[0170] The feasible set of detection stations is selected by combining equations (14), (16) and (18), as shown in equation (19).
[0171] (19) When multiple feasible detection stations are obtained from equation (19), a comprehensive cost function can be further set, as shown in equation (20).
[0172] (20) In equation (20), Indicates the cost of visual recognition. This indicates the cost of maneuverability of the robotic arm. This indicates the cost of maintaining stability in a standing posture. Indicates the path or movement cost. to is the weighting coefficient. The final detection station location is determined by equation (21).
[0173] (twenty one) Equation (21) is the final output of the target detection station, which shows that the quadruped robot does not move to the vicinity of the target based solely on distance or path, but rather filters and selects contact roughness detection stations from the candidate stations that meet the requirements of sticker visibility, robotic arm reachability, and robot stability.
[0174] Step 106: Control the detection robot to move to the target detection station, and after generating the actual measurement pose in the current robot arm base coordinate system at the target detection station, perform surface roughness detection.
[0175] Surface roughness testing is a process that uses a stylus profilometer to make a stylus contact the metal surface and drag it at a constant speed along a straight line. The displacement of the stylus caused by the surface undulation is measured by an inductive sensor, thereby evaluating the surface roughness.
[0176] In some embodiments, after the detection robot reaches the target detection station, the camera re-identifies the target coded sticker, and generates the real measurement pose in the current robot base coordinate system based on the pose transformation matrix obtained from the re-identification, the preset detection formula, and the fixed transformation matrix from the camera coordinate system to the robot base coordinate system.
[0177] In some embodiments, performing surface roughness detection may include the following process: Based on the position of the measuring point and the local normal in the actual measurement pose, the pre-contact point is determined, and the end of the robotic arm equipped with the stylus-type roughness detection probe is controlled to move to the pre-contact point and gradually advance along the local normal until the stylus compression reaches the contact establishment threshold.
[0178] After contact is established, the normal compensation amount of the end of the robotic arm along the local normal is adjusted according to the error between the stylus compression amount and the target pre-tightening compression amount, so that the stylus compression amount meets the stable pre-tightening range.
[0179] Under the condition of stable pre-tightening, the end of the robotic arm is controlled to perform a short-range linear scan along the scanning direction of the stylus, collect stylus compression data and normal compensation data, generate a surface profile sequence, and calculate the roughness parameters based on the surface profile sequence to obtain the detection result.
[0180] In some embodiments, determining the pre-contact point based on the measurement point position and local normal in the actual measurement pose, controlling the end effector of the robotic arm equipped with a stylus-type roughness detection probe to move to the pre-contact point, and gradually advancing along the local normal until the stylus compression reaches the contact establishment threshold, includes: S31, extract the position of the measuring point, the local normal, and the stylus scanning direction in the current robotic arm base coordinate system from the actual measurement pose generated under the target detection station.
[0181] The position of the measuring point in the robot arm base coordinate system refers to the three-dimensional coordinates extracted from the translation components of the actual measured pose.
[0182] The local normal in the robot arm base coordinate system is a unit direction vector perpendicular to the metal surface being measured in the robot arm's own coordinate system, which is derived from the attitude components of the actual measured pose.
[0183] The stylus scanning direction in the robot arm base coordinate system is a unit direction vector that the stylus should move along the metal surface in the robot arm's own coordinate system, which is derived from the attitude components of the actual measured pose.
[0184] S32, calculate the position of the pre-contact point based on the position of the measuring point, the local normal, and the pre-contact safety distance.
[0185] The pre-contact point position is the calculated spatial coordinates of a point located at the measuring point position offset by a safe distance in the opposite direction of the local normal.
[0186] In some embodiments, the three-dimensional coordinates of the measuring point position can be read from the actual measurement pose, and the pre-contact safety distance parameter can be obtained from the preset detection formula or system configuration. The local normal vector is multiplied by the negative pre-contact safety distance to obtain the offset vector pointing from the measuring point into the air. The coordinates of the measuring point position are added to this offset vector to obtain the three-dimensional coordinates of the pre-contact point position.
[0187] S33, control the end effector of the robotic arm to move to the pre-contact point position, and gradually advance along the local normal.
[0188] Stylus compression is the physical length of the stylus compressed relative to the probe housing, as measured by the internal elastic mechanism or displacement sensor of the stylus probe. The compression is zero when the stylus is not in contact, and increases with increasing pressure after contact.
[0189] The contact establishment threshold is a preset stylus compression value.
[0190] S34, during the advancement process, the original signal output by the elastic loading or equivalent pre-tightening detection module is collected, and the original signal is converted into the stylus compression amount.
[0191] The raw signal refers to the original data output by the elastic loading or equivalent preload detection module. For example, a voltage value of 0.5 volts or a current value of 4 milliamps.
[0192] Stylus compression refers to the elastic deformation displacement of the stylus relative to its free state after it is compressed by a metal surface, for example, 0.05 mm.
[0193] S35, when the compression of the stylus reaches the contact establishment threshold, it is determined that the stylus-type roughness detection probe has established contact with the metal surface to be tested.
[0194] After each step of the process, the calculated stylus compression is compared with the contact establishment threshold. For example, if the contact establishment threshold is 0.05 mm, and the current compression is 0.05 mm or slightly higher, then contact is considered to have been established.
[0195] In some embodiments, the step of ensuring that the stylus compression meets a stable preload range includes: S41, continuously collects pre-tightened sampling data within a preset time window or a preset number of times.
[0196] The preset time window refers to the pre-set continuous data acquisition duration. For example, 0.5 seconds.
[0197] The preset quantity is the total number of pre-sampled data frames that need to be continuously collected, which is set in advance for the purpose of validity statistics.
[0198] Continuous preload sampling data refers to a sequence of stylus compression values collected sequentially over time during the process of maintaining or fine-tuning the normal position of the robotic arm end effector after contact is established. Each value represents the compression amount at a sampling moment. For example, 0.12 mm, 0.13 mm, 0.14 mm, etc.
[0199] S42, calculate the error between the actual compression of the stylus and the target pre-tightening compression in each frame of sampled data.
[0200] The actual compression of the stylus is the true length of the stylus probe that is physically compressed at the corresponding moment, as recorded in each frame of pre-tightening sampling data.
[0201] The target preload compression is the ideal value of stylus compression that is expected to be maintained during the stable measurement phase, as predefined in the test formulation.
[0202] The error is the difference between the target preload compression value and the actual compression value of the stylus.
[0203] S43, based on the error and the preset proportional coefficient, dynamically update the normal compensation amount of the robotic arm end along the local normal.
[0204] The preset proportional coefficient is an adjustable control parameter used to convert error values into control action quantities proportionally.
[0205] The normal compensation amount of the robotic arm end effector along the normal direction is the additional displacement that needs to be moved along the normal direction of the local surface.
[0206] Dynamic updates refer to recalculating and correcting the value of the normal compensation amount in real time during each control cycle based on the latest calculated error.
[0207] In some embodiments, after obtaining the error of the current control cycle, the error value can be multiplied by a preset proportional coefficient to obtain a preliminary displacement adjustment amount. Then, the displacement adjustment amount is added to the normal compensation amount used in the previous control cycle to generate a new normal compensation amount for the current cycle.
[0208] S44, Calculate the proportion of the actual compression amount falling into the stable pre-tightening range in the continuous pre-tightening sampling data.
[0209] The stable preload range is the allowable fluctuation range centered on the target preload compression amount, including the lower limit and the upper limit.
[0210] S45, if the ratio is greater than or equal to the preset minimum effective pre-tightening ratio, then it is determined that the stable pre-tightening state has been entered.
[0211] The preset minimum effective preload ratio is a threshold percentage set for determining stability.
[0212] In this embodiment, a stability determination mechanism based on statistical process control is introduced, transforming the stable pre-tension state from subjective experience-based judgment into an objective, quantifiable standard. It not only approximates the target pressure through closed-loop feedback control but also verifies the sustainability of stability by statistically analyzing the proportion of pressure maintained within the acceptable range over a period of time. This effectively avoids the risk of data distortion caused by hasty scanning due to instantaneous pressure reaching the target but large fluctuations in the state. It ensures that the robotic arm can only perform subsequent precision contour scanning after the contact force has truly reached and remained stable, thereby fundamentally improving the reliability and accuracy of roughness measurement results.
[0213] In some embodiments, generating a surface profile sequence based on the stylus compression data sequence and the normal compensation data, determining the scanning validity, and calculating roughness parameters to obtain the detection result includes: S51, during the short-range linear scanning process, the sampling interval is determined based on the scanning speed and sampling frequency.
[0214] The scanning speed is the linear velocity of the stylus carried by the end of the robotic arm moving along the scanning direction on the metal surface, as defined in the preset detection formula.
[0215] The sampling frequency is the number of times the system collects stylus compression data per unit time, as defined in the preset test formula.
[0216] The sampling interval is the actual spatial distance between two adjacent sampling points on the scanning trajectory, calculated based on the scanning speed and sampling frequency.
[0217] In some embodiments, the sampling interval is calculated by dividing the value of the scanning speed by the value of the sampling frequency.
[0218] S52, for the k-th sampling point, calculate the discrete value of the contour based on the actual compression amount and normal compensation amount of the stylus, and generate the surface contour sequence.
[0219] The k-th sampling point refers to the k-th data point collected sequentially in time during the short-range line scan, where k is an integer index starting from zero. For example, the fiftieth sampling point corresponds to the fiftieth data point collected after the scan begins.
[0220] The actual compression of the stylus is the physical length of the stylus compressed, measured and recorded in real time by the sensor at the k-th sampling moment during the short-range linear scan.
[0221] The normal compensation amount is the compensation displacement value of the robotic arm end effector moving along the local normal direction at the k-th sampling time during short-range scanning to maintain a stable preload state.
[0222] The profile discrete value is a numerical value obtained by processing the actual compression and normal compensation of the stylus using a specific formula. It represents the height variation caused purely by the micro-geometry of the metal surface.
[0223] The surface profile sequence is a one-dimensional array composed of the discrete profile values corresponding to all sampling points along the entire short-range line scan, arranged in ascending order of the sampling point number k.
[0224] S53, statistically analyze the proportion of line scan sampling data in which the stylus compression falls within the stable pre-tightening range, and determine whether the line scan sampling proportion is greater than or equal to the minimum effective scan proportion, and whether the stylus compression is greater than the contact loss threshold and less than the overpressure threshold.
[0225] The line scan sampling ratio refers to the number of sampling points whose compression falls within the stable pre-tightening range during the entire line scan process, divided by the total number of sampling points.
[0226] The minimum effective scan ratio is a preset threshold.
[0227] The contact loss threshold is the minimum allowable compression level below which the stylus has detached from the surface. For example, 0.04 mm.
[0228] The overpressure threshold is the maximum allowable compression; exceeding this value indicates excessive pressure that may damage the probe or workpiece. For example, 0.25 mm.
[0229] S54. If the above conditions are met, the short-range line scan is determined to be valid, and the surface contour sequence is de-tilted and filtered to obtain the roughness contour; otherwise, the short-range line scan is determined to be invalid and the reason for failure is recorded.
[0230] De-tilting refers to eliminating the overall trend term in a contour sequence. This includes linear or polynomial offsets caused by imperfect robotic arm movements or macroscopic surface tilt.
[0231] Filtering refers to using low-pass or Gaussian filters to remove high-frequency noise while preserving the true roughness information.
[0232] Roughness profile refers to the effective height sequence that characterizes the micro-undulations of a surface, obtained after preprocessing.
[0233] The reason for failure refers to the specific problem description that leads to ineffectiveness, such as insufficient stable preload ratio or excessive compression at a certain point.
[0234] S55, based on the roughness profile, calculate roughness parameters including at least the roughness arithmetic mean deviation and the maximum height parameter, and generate a test result including the roughness level and the test pass status.
[0235] The roughness arithmetic mean deviation refers to the arithmetic mean of the absolute values of the ordinate of the roughness profile.
[0236] The maximum height parameter refers to the vertical distance between the peak and valley of the roughness profile.
[0237] Roughness grade is a classification based on the roughness arithmetic mean deviation and the maximum height parameter value.
[0238] The pass / fail status refers to whether the roughness parameter meets the pass / fail threshold given in the preset test formula. For example, pass or fail.
[0239] In some embodiments, a structured data object or database record can be created to write the unique identifier of the target coded sticker, the measurement point number, the test formula, the target test station, the actual measurement pose, the scanning validity, the roughness parameter, the roughness grade, and the test pass status into the test record.
[0240] In this embodiment, the spatial resolution of the contour data is ensured by accurately calculating the sampling interval. The discrete value of the contour is calculated by combining the change in stylus compression with the change in normal compensation, thus eliminating the impact of robot active compensation on the realism of the contour. At the same time, the validity of the scan is determined by a dual condition of line scan sampling ratio and compression boundary. Only scans that meet the stable pre-tightening ratio and have no contact loss or overpressure throughout the entire process are adopted, effectively filtering out invalid data caused by posture disturbances or environmental interference.
[0241] Step 106 involves surface roughness detection, which includes three parts: roughness detection based on normal pre-contact, elastic pre-tightening, and short-path line scanning.
[0242] Contact roughness inspection differs from ordinary visual inspection. The stylus must be in stable contact with the metal surface under appropriate pre-tension and perform short-range scanning along a specified direction. This application generates a pre-contact point from the actual measurement pose at the target inspection station, establishes contact and pre-tension along the local normal, and then generates the contour sequence, scanning validity, and roughness results.
[0243] The actual measured pose obtained from equation (11) can be written as equation (22).
[0244] (twenty two) The scanning direction and local normal in the coordinate system of the robot arm base are extracted from equation (22), as shown in equation (23).
[0245] (twenty three) In equation (23), and These represent the scanning direction unit axis and the normal unit axis of the measurement coordinate system, respectively. This indicates the direction of the stylus scanning in the robot arm's base coordinate system. This represents the local surface normal in the coordinate system of the robot arm base.
[0246] The pre-contact point is set according to the local normal, as shown in equation (24): (twenty four) Equation (24) indicates that the pre-contact point is located in the direction away from the metal surface to be measured along the local normal of the measuring point. The corresponding pre-contact measurement pose is given by Equation (25), and the flange target pose can be further obtained from the installation extrinsic relationship of Equation (12).
[0247] (25) As can be seen from equations (24) and (25), the robotic arm does not directly collide with the measuring point, but first reaches the pre-contact point set along the local normal, thereby reducing the risk of probe mis-collision and overpressure.
[0248] After reaching the pre-contact point, the robotic arm advances step by step along the local normal. Let the... The depth of the next propulsion is Then the target position during the advancement process is given by equation (26): (26) During the propulsion process, the stylus or elastic loading mechanism outputs the original signal. The compression amount was obtained after calibration, as shown in equation (27): (27) In equation (27), and This is the calibration coefficient for the stylus or elastic loading mechanism. When the compression reaches the contact establishment threshold, it is determined that the stylus has established contact with the metal surface. The contact establishment sampling point is defined as shown in equation (28): (28) If the set in equation (28) is empty, it means that contact could not be established within the maximum allowable advance distance, and the measurement will enter the failure or retry process; if equation (28) has a solution, it will enter the pre-tightening adjustment stage.
[0249] After contact is established, the system adjusts the compression amount to the target preload compression amount. In some embodiments, the preload error can be used as a reference. Update normal compensation amount ,Right now To determine whether a stable preload state has been reached, this application statistically analyzes the proportion of compression within the stable preload range during the preload adjustment phase, as shown in equation (29): (29) in In the The value is 1 if the pre-tightening sample meets the stable pre-tightening interval, and 0 otherwise. The effective condition for stable pre-tightening is expressed by equation (30): (30) Equations (29) and (30) show that this application does not start scanning immediately after the stylus "touches" the metal surface, but requires the stylus to enter a stable pre-tightened state before performing short-range line scanning.
[0250] During the online scanning phase, the sampling interval is determined based on the scanning speed and sampling frequency, as shown in equation (31): (31) The number of sampling points is determined by equation (32): (32) No. The scanning distance of each sampling point is Combining equation (23), the first step in the line scan process... The target location of each sampling point is given by equation (33): (33) In equation (33), Indicates a short-range movement along the scanning direction. This indicates pre-tightening compensation along the local normal. The target position can be further constructed according to equation (3) to form the corresponding measurement pose, and converted into the flange target pose through equation (12).
[0251] During the scanning process The probe compression at each sampling point is given by equation (34): (34) The discrete value of the contour is generated by the change in stylus compression and the change in the normal of the robotic arm, as shown in equation (35): (35) In equation (35), The calibration coefficient represents the change in compression along the profile direction. The calibration coefficients represent the normal compensation changes to the profile direction. and These represent the reference compression amount and the reference normal compensation amount when entering the line scan, respectively. Equation (35) shows that this application does not directly equate the original output of the stylus to the roughness profile, but rather unifies the stylus compression change and the active normal compensation of the robotic arm into the surface profile expression.
[0252] In certain implementations with relatively flat surfaces, stable standing posture, and no need for active normal compensation, it is possible to make Then equation (35) degenerates into equation (36): (36) To ensure the reliability of the scanning results, this application statistically analyzes the sampling ratio within the stable pre-tightening range during the scanning process, as shown in equation (37): (37) in In the The value is 1 if the line scan sampling meets the stable pre-tightening interval, and 0 otherwise. The scan validity judgment is expressed by equation (38): (38) In equation (38), Indicates the minimum effective scan ratio. Indicates the contact loss threshold. This represents the overpressure threshold. The system will only use the corresponding profile sequence for roughness result calculation when equation (38) is satisfied.
[0253] The contour sequence is de-tilted, filtered, or roughness contour extracted to obtain the roughness contour, as shown in equation (39): (39) In equation (39), Indicates the formula parameters The defined contour processing procedure. The roughness arithmetic mean deviation is calculated by equation (40): (40) In equation (40), Indicates the first The absolute value of the roughness profile sampling amplitude. The maximum height parameter can be calculated by equation (41): (41) The roughness grade and the pass / fail status are determined by equation (42): (42) Equations (39) to (42) are the final output results of the surface roughness test. Roughness grade It can be determined by the level mapping function. This indicates that the roughness parameters, roughness grade, and passability are calculated based on the effective profile sequence only after the pre-tightening contact and scanning effectiveness requirements are met.
[0254] To ensure that the test results are verifiable and traceable, this application uniformly writes the key outputs of the aforementioned steps into the final test record, as shown in equation (43): (43) In equation (43), The generation of the corresponding board-type coded sticker into the actual measured pose; Selection of detection station for quadruped robots; The output of the corresponding surface roughness test includes at least the following: , , , , and Through equation (43), the final detection record is not just a normal result storage, but also records the source of the measurement pose, the detection station, and the effectiveness of the contact line scan.
[0255] In some embodiments, the complete detection process of this application may be as follows: S1. Establish the plate-type coded sticker and the test formula. Place the plate-type coded sticker near the surface of the metal to be tested, and establish the correspondence between the sticker's unique identifier, the test point number, and the test formula. The test formula should at least include the test point location, local normal, and scanning direction, and preferably include the scanning length, scanning speed, sampling frequency, pre-contact safety distance, contact establishment threshold, target pre-tightening compression amount, stable pre-tightening range, and roughness judgment threshold.
[0256] S2. The detection robot enters the target area and performs initial sticker recognition. The detection robot acquires images near the target area and recognizes the board-type coded stickers to obtain the initial sticker pose for generating the target measurement pose; if the sticker is not yet visible, it can first enter the initial observation position based on the task list, map information, or historical sticker poses.
[0257] S3. Generate the target measurement pose for station selection. The system calls the detection recipe, constructs the measurement pose in the sticker coordinate system, and combines the initial sticker pose with the pre-calibrated coordinate transformation relationship to convert it into the target measurement pose in the world coordinate system or map coordinate system.
[0258] S4. Determine the target detection station. The detection robot generates a set of candidate stations near the target measurement pose and judges the visibility of the sticker, the reachability of the robotic arm to the pre-contact point and the line scan trajectory, and the stability of the posture, thereby obtaining the final detection station.
[0259] S5. Upon arrival at the station, the sticker is re-identified and the actual measurement pose is generated. After the detection robot moves to the target detection station, the camera re-identifies the board-type coded sticker. Based on the sticker pose obtained from the re-identification, the detection formula, and the fixed transformation matrix from the camera coordinate system to the robot arm base coordinate system, the system generates the actual measurement pose in the current robot arm base coordinate system.
[0260] S6. The robotic arm reaches the pre-contact point and establishes pre-tight contact. The robotic arm first reaches the pre-contact pose set along the local normal, and then gradually advances along the local normal, and determines whether contact is established based on the compression of the stylus; after contact is established, it determines whether to enter the stable pre-tight state based on the stable pre-tight range and the minimum effective pre-tight ratio.
[0261] S7. Perform a short-range linear scan and determine its validity. Under stable pre-tension conditions, the system generates a short-range linear scan trajectory, collects stylus compression data and normal compensation data, generates a surface profile sequence, and determines the validity of the scan based on the linear scan sampling ratio, contact loss threshold, and overpressure threshold.
[0262] S8. Calculate and output roughness results. For valid scans, the system calculates roughness parameters, roughness grade, and pass / fail status, and generates a final inspection record containing the sticker's unique identifier, measurement point number, measurement pose source, inspection station, scan validity, and roughness results.
[0263] This application also provides the following specific embodiments: 1. Example 1: Roughness detection of a single sticker at a single measuring point A coded sticker is fixed near the target measurement point on the metal plate or component to be measured. The position of this measurement point in the sticker's coordinate system is obtained through teaching, offline measurement, or CAD modeling. Local normal and scanning direction And establish the test formula according to formula (4).
[0264] During testing, the quadruped robot receives the target sticker. and measurement point number The system enters the target area and generates a set of candidate stations. The system determines whether the sticker is visible according to equation (14), whether the robotic arm can cover the pre-contact point and short-range line scanning trajectory according to equation (16), whether the robot's posture is suitable for subsequent contact measurement according to equation (18), and determines the final detection station according to equation (21).
[0265] Upon reaching the detection station, the camera identifies the sticker and calculates... The system constructs the measurement pose in the sticker coordinate system using equations (5) to (10), and then obtains the actual measurement pose in the robot arm base coordinate system using equation (11). Subsequently, the robot arm reaches the pre-contact point according to equations (24) and (25), establishes a stable pre-tight contact according to equations (26) to (30), and performs short-range line scanning and scanning validity judgment according to equations (31) to (38). Finally, the system outputs the roughness parameters, roughness grade, pass status, and inspection record of the measurement point according to equations (39) to (43).
[0266] 2. Example 2: Batch testing of multiple measurement points on a single sticker For multiple measuring points on the same metal component, the same plate-type coded sticker can be used to correspond to the numbers of multiple measuring points. Each measuring point has an independent measuring point location, local normal, scanning direction, scanning parameters, contact threshold, and roughness acceptance threshold in the testing formula.
[0267] During inspection, the robot can obtain information through a single sticker recognition. Then, for each different measuring point number, call the corresponding [method / method]. And generate multiple real measurement poses in sequence. For each measuring point, the system repeatedly performs station accessibility confirmation, normal pre-contact, elastic pre-tightening, short-range line scanning, scan validity judgment, and roughness result calculation. If a measuring point experiences contact establishment failure, unstable pre-tightening, or invalid scanning, the system can record the reason for the failure for that measuring point and select retesting, without affecting the detection and result traceability of other measuring points under the same sticker.
[0268] 3. Example 3: Simplified detection without active normal compensation In scenarios where the surface to be tested is relatively flat, the quadruped robot's posture is stable, and the short-range line scan error of the robotic arm is small, active normal compensation can be omitted. In this case, the line scan stage... The simplified implementation retains the pre-contact and stable pre-tightening judgments of equations (24) to (30), and also retains the scanning validity judgments of equations (37) and (38). Therefore, it still falls within the scope of the technical solution of this application.
[0269] The main objectives of the technical solutions disclosed in the above embodiments of this application may include the following aspects: 1. Generate the actual roughness measurement pose from the plate-type coded sticker.
[0270] Firstly, it enables the board-type coded stickers to no longer serve merely as ordinary identification marks or visual positioning marks, but rather as a measurement pose reference for detecting the roughness of metal surfaces.
[0271] By establishing a correspondence between the plate-type coded sticker and the actual measurement point position, local surface normal, and stylus scanning direction, after the robot recognizes the sticker, it can calculate the actual measurement point position, normal orientation, and line scanning direction that need to be performed for contact measurement based on the sticker's pose. This solves the problem in existing technologies where "seeing the mark" cannot be reliably converted into "the stylus reaching the actual measurement point and scanning in the correct direction."
[0272] This aspect aims to improve the consistency of measurement point positioning, scanning direction determination, and repeated measurements in roughness inspection.
[0273] 2. Determination of the inspection station position for a quadruped robot for contact roughness inspection.
[0274] Secondly, it enables the quadruped robot to not simply move to the vicinity of the target area, but to determine a suitable work station for performing contact roughness inspection.
[0275] The testing station should meet at least three conditions simultaneously: first, the camera should be able to stably observe and identify the board-type coded sticker; second, the robotic arm should be able to reach the actual measurement pose calculated from the sticker; and third, the quadruped robot body should be able to maintain a stable posture suitable for contact measurement.
[0276] This aspect aims to address the issues of insufficient mobility of fixed-station testing equipment and the fact that ordinary mobile robots may not necessarily have the necessary testing capabilities once in place, enabling the testing system to adapt to the needs of metal surface roughness testing in high-altitude, hazardous, narrow, cross-regional inspection areas, or unstructured environments.
[0277] 3. Short-range linear scanning of stylus based on local normal pre-contact and elastic pre-tension Thirdly, it enables the stylus-type contact probe mounted on the robotic arm to reliably establish controlled contact with the metal surface and complete short-range roughness line scanning under the on-site working conditions of the mobile robot.
[0278] This application proposes to determine the pre-contact direction by measuring the local normal of the point, so that the robotic arm first reaches the pre-contact position and then gradually approaches the surface to be measured along the local normal; after the stylus contacts the surface, the contact state is judged by elastic loading or equivalent pre-tightening detection method, and short-range line scanning is performed along the predetermined scanning direction after the stable pre-tightening condition is met.
[0279] This aspect aims to address issues such as accidental collisions, overpressure, insufficient contact, loss of contact, or invalid scanning data that may occur when a robotic arm directly contacts a workpiece, thereby improving the safety and measurement reliability of mobile robots performing contact roughness inspection.
[0280] The beneficial effects that the embodiments of this application can bring include the following aspects: 1. Improve the consistency of roughness measurement point positioning and retesting.
[0281] Current manual handheld roughness inspection methods typically rely on the operator manually locating the measurement points, manually determining the scanning direction, and manually maintaining the probe's contact with the surface. Therefore, deviations in measurement point positions and scanning directions can easily occur between different operators and different inspection batches. While existing purely visual recognition solutions can identify markings or identification boards, they usually only obtain the position and orientation of the marking itself, making it difficult to directly obtain the actual measurement point positions, local surface normals, and stylus scanning directions required for roughness inspection.
[0282] This application uses a plate-type coded sticker as a measurement pose reference. The corresponding detection formula is called through the sticker ID, and a fixed correspondence is established between the detection formula and the measurement point position, local surface normal, and scanning direction. After the robot recognizes the sticker, it not only obtains the sticker's identity but also generates the actual measurement pose in the robotic arm's base coordinate system based on the sticker's real-time pose and the fixed mapping relationship from sticker to measurement pose. Therefore, each detection can determine the measurement point and scanning direction according to the same sticker ID, the same measurement point number, and the same pose generation rule, thereby reducing inconsistencies caused by manual point finding, manual alignment, and manual selection of the scanning direction.
[0283] Therefore, this application can improve the consistency of measurement point positioning and retesting in roughness inspection, and is especially suitable for scenarios that require periodic retesting of the same metal component, the same measurement point or the same area.
[0284] 2. Improve the feasibility of contact roughness testing in complex environments.
[0285] Existing fixed-station or traditional industrial robotic arm-based roughness inspection typically relies on fixed fixtures, regularly arranged workpieces, or pre-taught inspection paths. While suitable for structured workstations, they are difficult to apply directly to high-altitude, hazardous, narrow, cross-area, or unstructured ground environments. Although ordinary mobile robots can navigate to the vicinity of the target, "reaching the vicinity of the target" does not equate to completing contact roughness inspection. If the sticker is invisible, the robotic arm is unreachable, or the robot's posture is unstable, even if the robot is in position, subsequent stylus contact and short-range line scanning cannot be reliably performed.
[0286] This application filters candidate stations after the quadruped robot enters the target area. The filtering criteria include at least the visibility of the coded sticker, the reachability of the robotic arm to the measurement pose and short-range line scan trajectory, and the stability of the quadruped robot's posture during the contact detection process. Therefore, the robot ultimately selects a detection station that can simultaneously meet the requirements of visual recognition, robotic arm reach, and contact stability, rather than a regular navigation target point.
[0287] Therefore, this application reduces the reliance on fixed workstations, rigorous tooling, and manual access to measurement points, enabling contact roughness testing to be extended to non-fixed workstations and complex field environments. For inspection areas where manual access is inconvenient or poses safety risks, this application can use a quadruped robot to replace manual labor in completing the approach, positioning, identification, and contact measurement processes, thereby improving the engineering feasibility and safety of the inspection operation.
[0288] 3. Improve the reliability of stylus contact line scanning and reduce the risks of accidental contact, overvoltage, contact loss and invalid scanning.
[0289] Roughness inspection differs from ordinary visual inspection or non-contact surface inspection. Stylus-based roughness inspection requires the probe to contact the metal surface with appropriate preload and perform short-range linear scanning along a specified scanning direction. If the robotic arm moves directly towards the measurement point, problems such as accidental collisions, overpressure, insufficient contact, lost contact, or invalid scan data can easily occur due to pose errors, changes in surface posture, or disturbances in the robot's standing posture.
[0290] This application sets a pre-contact point based on the local surface normal in the actual measurement pose, allowing the robotic arm to first reach a position at a certain safe distance from the measurement point, and then gradually advance along the local normal. The system determines whether contact has been established and whether the contact state is stable by measuring the stylus compression, contact establishment threshold, and stable pre-tightening interval. Only after the stable pre-tightening condition is met does the system perform a short-range linear scan along the preset scanning direction. During the scanning process, the system can also determine the scan validity based on changes in stylus compression, normal compensation, and stable pre-tightening interval, and invalidate the scan if contact is lost, overpressure occurs, or the pre-tightening state is abnormal.
[0291] Therefore, this application can transform the movement of a conventional robotic arm into a controlled stylus contact measurement process, reducing the risk of the probe directly impacting the workpiece, reducing erroneous contour data output due to unstable contact, and improving the reliability of roughness parameters, roughness grades, and acceptance status judgment.
[0292] Reference Figure 2 The diagram shown is a functional module schematic of the metal surface roughness detection device 100 based on coded stickers according to this application.
[0293] The detection device 100 described in this application is installed in an electronic device. Depending on its function, the detection device 100 includes a first recipe acquisition module 110, a second acquisition module 120, a first determination optical module 130, a generation module 140, a second determination module 150, and a detection module 160. These modules can also be referred to as units, which are a series of computer program segments that can be executed by the processor of an electronic device and perform a fixed function, and are stored in the memory of the electronic device.
[0294] In this embodiment, the functions of each module / unit are as follows: The first acquisition module 110 is used to acquire the unique identifier of the target coded sticker and the number of the test point to be detected. The second acquisition module 120 is used to acquire a preset detection formula based on the unique identifier and the number; The first determining module 130 is used to identify the target coded sticker and determine the pose transformation matrix of the sticker coordinate system relative to the camera coordinate system of the camera. The generation module 140 is used to generate a target measurement pose for station selection based on the preset detection formula, the pose transformation matrix and the pre-calibrated coordinate transformation relationship. The second determining module 150 is used to determine the target detection station of the detection robot based on the target measurement pose; The detection module 160 is used to control the detection robot to move to the target detection station, and after generating the actual measurement pose in the current robot arm base coordinate system at the target detection station, perform surface roughness detection.
[0295] The specific implementation of the detection device in this application is largely the same as the specific implementation of the metal surface roughness detection method based on coded stickers described above, and will not be repeated here. For detailed descriptions of each module, please refer to the preceding text. Figure 1 The relevant descriptions will not be repeated here.
[0296] Reference Figure 3 The diagram shown is a schematic representation of the modules of the metal surface roughness detection system 200 based on coded stickers according to this application, which includes: The plate-type coded sticker 210 is placed near the metal surface to be tested to provide a unique identifier for the sticker and a sticker coordinate system; The inspection robot 220 includes a mobile platform, a camera, a robotic arm, and a stylus-type roughness inspection probe. The mobile platform is preferably a quadrupedal mobile platform. The elastic loading or equivalent preload detection module 230 is used to obtain the stylus compression amount, contact force or equivalent contact state; The control and recording module 240 is used to call the preset detection formula based on the unique identifier of the sticker and the measurement point number, generate the target measurement pose and the actual measurement pose, determine the target detection station, control the robotic arm to perform normal pre-contact, stabilization pre-tightening and short-range line scanning, and generate the detection results. The target detection station is determined based on the visibility of the sticker, the accessibility of the robotic arm to the pre-contact point and the line scan trajectory, and the stability of the detection robot's posture under the estimated normal contact force.
[0297] In some embodiments, the above-described metal surface roughness detection system 200 based on coded stickers can be used to perform the functions described in this application. Figure 1 The specific process of the metal surface roughness detection method based on coded stickers shown can be found in the previous description and will not be repeated here.
[0298] Reference Figure 4 The diagram shown is a schematic representation of a preferred embodiment of the electronic device of this application.
[0299] The electronic device includes a processor 111, a communication interface 112, a memory 113, and a communication bus 114, wherein the processor 111, the communication interface 112, and the memory 113 communicate with each other through the communication bus 114. The memory 113 is used to store computer programs, such as a metal surface roughness detection program based on coded stickers; In some embodiments, the processor 111 may be a central processing unit (CPU), a controller, a microcontroller, a microprocessor, or other data processing chip. The processor 111 can be used to control the overall operation of the electronic device, such as performing data interaction or communication-related control and processing. In this embodiment, the processor 111 is used to run program code stored in the memory 113 or process data.
[0300] The communication interface 112 may optionally include a standard wired interface or a wireless interface (such as a Wi-Fi interface). The communication interface 112 may also be used to establish a communication connection between the electronic device and other electronic devices.
[0301] The memory 113 includes at least one type of readable storage medium, including flash memory, hard disk, multimedia card, card-type memory (e.g., SD or DX memory), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic memory, magnetic disk, optical disk, etc. In some embodiments, the memory 113 may be an internal storage unit of the electronic device, such as the hard disk or memory of the electronic device. In other embodiments, the memory 113 may also be an external storage device of the electronic device, such as a plug-in hard disk, smart media card (SMC), secure digital (SD) card, flash card, etc. of the electronic device. Of course, the memory 113 may include both internal storage units and external storage devices of the electronic device. In this embodiment, the memory 113 may be used to store the operating system and various computer programs installed on the electronic device, such as the program code of a metal surface roughness detection program based on coded stickers. In addition, the memory 113 can also be used to temporarily store various types of data that have been output or will be output.
[0302] Figure 4 Only an electronic device with component processor 111, communication interface 112, memory 113 and communication bus 114 is shown. However, it should be understood that it is not required to implement all the components shown, and more or fewer components may be implemented instead.
[0303] In one embodiment of this application, when the processor 111 executes the program stored in the memory 113, it implements the metal surface roughness detection method based on coded stickers provided in any of the aforementioned method embodiments, including: obtaining the unique identifier of the target coded sticker and the number of the test point to be detected; obtaining a preset detection formula based on the unique identifier and the number; identifying the target coded sticker; determining the pose transformation matrix of the sticker coordinate system relative to the camera coordinate system; generating a target measurement pose for station selection based on the preset detection formula, the pose transformation matrix, and the pre-calibrated coordinate transformation relationship; determining the target detection station of the detection robot based on the target measurement pose; controlling the detection robot to move to the target detection station; and generating the actual measurement pose in the current robotic arm base coordinate system under the target detection station before performing surface roughness detection.
[0304] For a detailed explanation of the above steps, please refer to the above. Figure 1 A flowchart illustrating an embodiment of a method for detecting the roughness of metal surfaces based on coded stickers.
[0305] Furthermore, this application also proposes a computer-readable storage medium, which can be a non-transitory computer-readable storage medium. This computer-readable storage medium can be any one or any combination of several of the following: hard disk, multimedia card, SD card, flash memory card, SMC, read-only memory (ROM), erasable programmable read-only memory (EPROM), portable compact disc read-only memory (CD-ROM), USB memory, etc. The computer-readable storage medium stores a metal surface roughness detection program based on coded stickers, and when the program is executed by a processor, it implements the steps provided in any of the foregoing method embodiments.
[0306] The specific implementation of the computer-readable storage medium in this application is largely the same as the specific implementation of the metal surface roughness detection method based on the above-described coded sticker, and will not be repeated here.
[0307] It should be noted that 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. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, apparatus, article, or method that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, apparatus, article, or method. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, apparatus, article, or method that includes that element.
[0308] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware simulation platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) as described above, and includes several instructions to cause a terminal device to execute the methods described in the various embodiments of this application.
[0309] The above are merely preferred embodiments of this application and do not limit the patent scope of this application. Any equivalent structural or procedural transformations made using the content of this application's specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of this application.
Claims
1. A method for detecting the surface roughness of metal based on coded stickers, the method comprising: Obtain the unique identifier of the target coded sticker and the number of the test point to be detected; The preset detection formula is obtained based on the unique identifier and the number; The preset test formula includes at least the measurement point location, local normal, and stylus scanning direction defined in the sticker coordinate system; Identify the target coded sticker and determine the pose transformation matrix of the sticker coordinate system relative to the camera coordinate system; Based on the preset detection formula, the pose transformation matrix, and the pre-calibrated coordinate transformation relationship, a target measurement pose for station selection is generated; Based on the target measurement pose, the target detection station of the detection robot is determined; After controlling the detection robot to move to the target detection station and generating the actual measurement pose in the current robot arm base coordinate system at the target detection station, surface roughness detection is performed. Determining the target detection station position of the detection robot based on the target measured pose includes: A set of candidate stations is generated near the measurement point location corresponding to the target measurement pose. For each candidate station in the candidate station set, the sticker visibility index, the robotic arm reachability index, and the station posture stability index are evaluated respectively. Select a set of feasible detection sites that simultaneously meet the sticker visibility index, the robotic arm accessibility index, and the standing posture stability index; If there are multiple feasible detection stations, the station with the lowest cost is selected from the set of feasible detection stations as the target detection station based on a comprehensive cost function that includes visual recognition cost, robotic arm operability cost, posture stability cost and path cost. The process of controlling the detection robot to move to the target detection station, generating the actual measurement pose in the current robot arm base coordinate system at the target detection station, and then performing surface roughness detection includes: Based on the position of the measuring point and the local normal in the actual measurement pose, the pre-contact point is determined, and the end of the robotic arm equipped with the stylus-type roughness detection probe is controlled to move to the pre-contact point and gradually advance along the local normal until the stylus compression reaches the contact establishment threshold. After contact is established, the normal compensation amount of the end of the robotic arm along the local normal is adjusted according to the error between the stylus compression amount and the target pre-tightening compression amount, so that the stylus compression amount meets the stable pre-tightening range. Under the condition of stable pre-tightening, the end of the robotic arm is controlled to perform a short-range linear scan along the scanning direction of the stylus, collect stylus compression data and normal compensation data, generate a surface profile sequence, and calculate the roughness parameters based on the surface profile sequence to obtain the detection result.
2. The method for detecting metal surface roughness based on coded stickers according to claim 1, characterized in that, The step of generating the target measurement pose for station selection based on the preset detection formula, the pose transformation matrix, and the pre-calibrated coordinate transformation relationship includes: The local normals are normalized to obtain the normalized normals; The stylus scanning direction is projected onto a tangent plane perpendicular to the normalized normal, and the projection result is normalized to obtain the normalized scanning direction. Using the normalized scanning direction as the first axis of the measurement coordinate system, the normalized normal direction as the third axis of the measurement coordinate system, and the cross product direction of the two as the second axis, a rotation matrix of the measurement coordinate system under the sticker coordinate system is constructed. Based on the measurement point position and the rotation matrix of the measurement coordinate system, the measurement pose in the sticker coordinate system is constructed; During the station selection stage, based on the pose transformation matrix, the pose information of the detection robot, and the pre-calibrated coordinate transformation relationship, the measured pose in the sticker coordinate system is converted into the target measured pose in the world coordinate system or map coordinate system.
3. The method for detecting metal surface roughness based on coded stickers according to claim 1, characterized in that, Evaluate sticker visibility metrics, including: Calculate the camera image projection area of the target coded sticker at the candidate station, the recognition distance from the camera to the sticker, the observation angle of the camera to the sticker, and the occlusion state; If the camera image projection area is within the effective recognition area, the recognition distance is within the allowable recognition distance range, the observation angle is less than or equal to the maximum allowable observation angle, and the occlusion state is unobstructed, then the sticker visibility index is determined to be valid; otherwise, it is determined to be invalid.
4. The method for detecting metal surface roughness based on coded stickers according to claim 1, characterized in that, Assess robotic arm reachability metrics, including: Based on the target measurement pose and the preset scan length and number of sampling points, a set of target poses for the pre-contact point of the robotic arm end flange and a set of target poses for the line scan trajectory are generated at the candidate station. For each target pose in the set of target poses of the pre-contact point and the line scan trajectory, determine whether there exists a robot arm joint angle solution that satisfies the joint limit, obstacle avoidance constraint and end-effector posture constraint. If both exist, the robotic arm reachability index is considered valid; otherwise, it is considered invalid.
5. The method for detecting metal surface roughness based on coded stickers according to claim 1, characterized in that, Indicators for assessing standing stability include: Obtain the target preload compression amount set in the preset test formula and the equivalent stiffness of the elastic loading or equivalent preload test module; The estimated normal contact force generated during the pre-tightening contact of the stylus is calculated according to FN=k·Δd, where k is the equivalent stiffness and Δd is the target pre-tightening compression. Obtain robot posture angles and ground support information at candidate stations. The ground support information includes foot support polygons, ground friction coefficients, or ground supportability assessment results. Determine whether, under the condition of bearing the estimated normal contact force, the posture stability margin of the candidate station is greater than or equal to the minimum stability margin threshold, and whether the robot posture angle is within the allowable range. If all the above conditions are met, the standing posture stability index is deemed valid; otherwise, it is deemed invalid.
6. The method for detecting metal surface roughness based on coded stickers according to claim 1, characterized in that, The control of the robotic arm equipped with a stylus-type roughness detection probe to move its end to the pre-contact point and gradually advance along the local normal includes: Extract the position of the measuring point, the local normal, and the stylus scanning direction in the current robotic arm base coordinate system from the actual measurement pose generated under the target detection station; The position of the pre-contact point is calculated based on the position of the measuring point, the local normal, and the pre-contact safety distance. Control the end effector of the robotic arm to move to the pre-contact point position, and gradually advance along the local normal; During the advancement process, the original signal output by the elastic loading or equivalent pre-tightening detection module is collected, and the original signal is converted into the stylus compression amount; When the compression of the stylus reaches the contact establishment threshold, it is determined that the stylus-type roughness detection probe has established contact with the metal surface to be tested.
7. The method for detecting metal surface roughness based on coded stickers according to claim 1 or 6, characterized in that, The process of ensuring that the stylus compression meets the stable preload range includes: Continuously collect pre-tightened sampling data within a preset time window or a preset number of times; Calculate the error between the actual compression of the stylus and the target pre-tight compression in each frame of sampled data; Based on the error and the preset scaling factor, the normal compensation amount of the robotic arm end effector along the local normal is dynamically updated; The proportion of actual compression falling within the stable preload range in the continuous preload sampling data is statistically analyzed. If the ratio is greater than or equal to the preset minimum effective pretension ratio, then it is determined that the system has entered a stable pretension state.
8. The method for detecting metal surface roughness based on coded stickers according to claim 1, characterized in that, The process of generating a surface profile sequence and calculating roughness parameters based on the surface profile sequence to obtain detection results includes: During short-range linear scanning, the sampling interval is determined based on the scanning speed and sampling frequency; For the kth sampling point, the discrete value of the contour is calculated based on the actual compression amount and normal compensation amount of the stylus, and a surface contour sequence is generated; The proportion of line scan sampling data in which the stylus compression falls within the stable pre-tightening range is statistically analyzed, and it is determined whether the line scan sampling proportion is greater than or equal to the minimum effective scan proportion, and whether the stylus compression is greater than the contact loss threshold and less than the overpressure threshold. If the above conditions are met, the short-range line scan is deemed valid, and the surface profile sequence is de-tilted and filtered to obtain the roughness profile; otherwise, the short-range line scan is deemed invalid and the reason for failure is recorded. Based on the roughness profile, roughness parameters are calculated, including at least the roughness arithmetic mean deviation and the maximum height parameter, and a test result containing the roughness grade and the test pass status is generated.
9. A metal surface roughness detection device based on coded stickers, characterized in that, The device includes: The first acquisition module is used to acquire the unique identifier of the target coded sticker and the number of the test point to be detected. The second acquisition module is used to acquire a preset detection formula based on the unique identifier and the number; the preset detection formula includes at least the measurement point position, local normal and stylus scanning direction defined in the sticker coordinate system; The first determining module is used to identify the target coded sticker and determine the pose transformation matrix of the sticker coordinate system relative to the camera coordinate system of the camera. The generation module is used to generate a target measurement pose for station selection based on the preset detection formula, the pose transformation matrix, and the pre-calibrated coordinate transformation relationship. The second determining module is used to determine the target detection station of the detection robot based on the target measurement pose; the determination of the target detection station of the detection robot based on the target measurement pose includes: A set of candidate stations is generated near the measurement point location corresponding to the target measurement pose. For each candidate station in the candidate station set, the sticker visibility index, the robotic arm reachability index, and the station posture stability index are evaluated respectively. Select a set of feasible detection sites that simultaneously meet the sticker visibility index, the robotic arm accessibility index, and the standing posture stability index; If there are multiple feasible detection stations, the station with the lowest cost is selected from the set of feasible detection stations as the target detection station based on a comprehensive cost function that includes visual recognition cost, robotic arm operability cost, posture stability cost and path cost. The detection module is used to control the detection robot to move to the target detection station, and after generating the actual measurement pose in the current robot arm base coordinate system at the target detection station, perform surface roughness detection. The process of controlling the detection robot to move to the target detection station, generating the actual measurement pose in the current robot arm base coordinate system at the target detection station, and then performing surface roughness detection includes: Based on the position of the measuring point and the local normal in the actual measurement pose, the pre-contact point is determined, and the end of the robotic arm equipped with the stylus-type roughness detection probe is controlled to move to the pre-contact point and gradually advance along the local normal until the stylus compression reaches the contact establishment threshold. After contact is established, the normal compensation amount of the end of the robotic arm along the local normal is adjusted according to the error between the stylus compression amount and the target pre-tightening compression amount, so that the stylus compression amount meets the stable pre-tightening range. Under the condition of stable pre-tightening, the end of the robotic arm is controlled to perform a short-range linear scan along the scanning direction of the stylus, collect stylus compression data and normal compensation data, generate a surface profile sequence, and calculate the roughness parameters based on the surface profile sequence to obtain the detection result.
10. An electronic device, characterized in that, It includes a processor, a communication interface, a memory, and a communication bus, wherein the processor, the communication interface, and the memory communicate with each other through the communication bus; Memory, used to store computer programs; The processor, when executing a program stored in memory, implements the metal surface roughness detection method based on coded stickers as described in any one of claims 1 to 8.
Citation Information
Patent Citations
A roughness detection system and method
CN105783851B
Robot angle positioning precision testing method and robot system
CN115345936A
Roughness detection system and detection method
CN105783851A
Online flatness detection platform and detection method based on multi-joint robot
CN116175283A
