A shuttle vehicle operation curve correction method based on double-hole positioning
By employing dual-hole positioning and dynamic curve correction methods, the positioning accuracy problem caused by wheel slippage and wear of the four-way warehouse vehicle was solved, achieving high-precision motion control and meeting the needs of intelligent warehousing and logistics.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- NANJING INFORM STORAGE EQUIP (GRP) CO LTD
- Filing Date
- 2026-04-09
- Publication Date
- 2026-06-02
AI Technical Summary
The positioning accuracy of existing four-way warehouse vehicles is affected by wheel slippage and wear, resulting in accumulated distance measurement deviations, which cannot meet the high-precision requirements of smart warehousing. Existing solutions cannot effectively solve this problem.
A running curve correction method based on dual-hole positioning is adopted. By acquiring wheel rotation data and track marker hole signals in real time, the deviation coefficient and correction amount are calculated, a dual-reference distance measurement system is established, track vibration and electromagnetic interference are filtered out, and dynamic curve correction is achieved.
It improves the motion precision and operational accuracy of the four-way vehicle, meets the high-precision requirements of intelligent warehousing and logistics, and ensures the accuracy and continuity of positioning and ranging.
Smart Images

Figure CN122126576A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to shuttle operation control, specifically to a method for correcting shuttle operation curves based on dual-hole positioning. Background Technology
[0002] In the field of intelligent warehousing and logistics, four-way trolleys are the core handling equipment in automated warehouses, enabling goods to move in both lateral and longitudinal directions on tracks. The positioning and ranging accuracy during their movement directly determines the efficiency and accuracy of warehousing operations. Currently, the ranging and positioning of four-way trolleys mainly rely on encoders. Encoders convert the angular displacement of the wheel rotation into linear displacement to obtain the theoretical travel distance and real-time position of the four-way trolley.
[0003] However, in actual warehousing operations, four-way vehicles move at high speeds on tracks for extended periods, making slippage between the wheels and the tracks common. Furthermore, the wheels experience natural wear and tear over time, causing a discrepancy between the actual distance the wheels rotate and the actual distance traveled on the tracks. This results in a deviation between the theoretical distance measured by the encoder and the actual distance traveled. This deviation accumulates with the distance traveled, leading to a continuous loss of positioning accuracy for the four-way vehicle. This can cause problems such as discrepancies in cargo storage and retrieval positions and track docking errors, severely impacting the automated workflow of smart warehousing.
[0004] To address the positioning accuracy issue, existing technologies have begun to incorporate physical calibration holes on the four-way vehicle's movement track. These holes are identified as external positioning references, compensating for the limitations of encoders that rely solely on distance measurement. For example, some solutions use two holes with a fixed spacing on the track as positioning reference markers. The core of this approach is to capture the edge signals of the holes via GPIO external interrupts, combine this with encoder positioning, and then calibrate the distance measurement data based on the actual hole positions. Therefore, accurate hole identification, reliable acquisition of positioning data, quantified deviation coefficient and correction calculation, and integrated correction of positioning and distance measurement are crucial for solving the accuracy loss problem of warehouse four-way vehicles, placing extremely high demands on the algorithm's anti-interference capabilities, accuracy, and real-time performance.
[0005] Existing track hole positioning and ranging solutions for four-way warehouse vehicles mainly combine encoder-based single ranging with simple hole recognition assistance. Their core process and shortcomings are as follows:
[0006] 1. During the four-way vehicle's movement, the encoder continuously collects wheel rotation data to calculate the theoretical travel distance and position. Without an external reference to calibrate this data in real time, deviations caused by wheel slippage / wear will continue to accumulate.
[0007] 2. The identification of calibration holes on the track is achieved through GPIO pins. After the level change triggers an external interrupt, the encoder position is directly acquired. However, track vibration and electromagnetic interference can easily cause signal jitter and repeated triggering, resulting in distorted hole positioning data, which cannot be used as an effective calibration benchmark.
[0008] 3. The validity of the hole is judged solely by a fixed hole width threshold, which easily leads to interference signals being identified as valid holes, making it unreliable as a reference for actual position.
[0009] 4. Low coupling between positioning and ranging correction processes;
[0010] 5. Low data storage and processing efficiency: Using ordinary arrays to store identification data is prone to data overflow or interference from old data, making it impossible to achieve continuous positioning, distance measurement comparison, and motion curve correction;
[0011] In summary, the existing solutions can only achieve simple fixed-point positioning calibration at the hole location, which cannot solve the real-time distance measurement deviation caused by wheel slippage and wear during the movement of the four-way vehicle. Furthermore, the hole recognition has poor anti-interference ability and accuracy, and the calibration benchmark is unreliable. Ultimately, it is still impossible to avoid the loss of positioning accuracy and cannot meet the high-precision movement requirements of four-way vehicles in smart warehousing. Summary of the Invention
[0012] Purpose of the invention: To address the above-mentioned shortcomings, this invention provides a method for correcting the running curve of a shuttle based on dual-hole positioning to achieve high-precision shuttle movement.
[0013] Technical Solution: To solve the above problems, the present invention provides a method for correcting the running curve of a shuttle based on dual-hole positioning, comprising the following steps:
[0014] The system acquires wheel rotation data in real time during shuttle operation and simultaneously captures signals from marker holes on the track.
[0015] After detecting two marker holes on the track, the actual distance traveled by the shuttle between the two marker holes is obtained. Then, by collecting wheel rotation data, the theoretical distance traveled by the shuttle between the two marker holes is calculated. The ratio of the theoretical distance to the actual distance is used as the relative deviation coefficient. ;
[0016] Determine if the relative deviation coefficient exceeds the threshold. If the relative deviation coefficient exceeds the threshold, trigger the shuttle sampling point position correction.
[0017] The formula for correcting the sampling point position is:
[0018] ;
[0019] ;in, To correct the location of the sampling points, The original theoretical position of the sampling point is obtained based on the wheel rotation data. This is a correction factor per unit distance. This is the correction amount for the distance between the two marked holes. This represents the theoretical distance the shuttle car travels between the two marked holes.
[0020] Furthermore, the edge signals of the marking holes on the track are captured in real time through GPIO external interrupts to detect the marking holes on the track. The specific steps are as follows:
[0021] During the shuttle's operation, the GPIO pin detects a level change in the marker hole, triggering an external interrupt; it refreshes the GPIO input state and synchronously acquires valid data such as the current edge signal level, encoder real-time position, and system timestamp; it reads the edge signal level of the latest valid data stored in the edge buffer and compares it with the current edge signal level. If the latest stored edge signal level is consistent with the current edge signal level, it is determined that the current edge signal level is a repetitive triggering or jittering signal caused by track vibration, and the current edge signal level is discarded; if the latest stored edge signal level is inconsistent with the current edge signal level, the current edge signal level, encoder real-time position, and system timestamp are stored in the edge buffer; and the marker hole is identified based on the edge signal in the edge buffer.
[0022] Furthermore, the edge signals of the marking holes on the track are captured in real time through GPIO external interrupts to detect the marking holes on the track. The specific steps are as follows:
[0023] During shuttle operation, the GPIO pin detects a level change in the marker hole, triggering an external interrupt; refreshes the GPIO input state, and synchronously acquires valid data such as the current edge signal level, encoder real-time position, and system timestamp; reads the system timestamp of the latest valid data stored in the edge buffer, calculates the timestamp difference with the system timestamp of the current valid data, and compares the timestamp difference with the preset minimum edge trigger interval. If the timestamp difference is less than the preset minimum edge trigger interval, the current edge signal level is determined to be a repetitive trigger or jitter signal caused by track vibration, and the current edge signal level is discarded; if the timestamp difference is not less than the preset minimum edge trigger interval, the current edge signal level, encoder real-time position, and system timestamp are stored in the edge buffer; and the marker hole is identified based on the edge signal in the edge buffer.
[0024] Furthermore, the specific steps for identifying the marking hole based on the edge signal in the edge buffer include:
[0025] When a change in valid data occurs in the edge buffer, determine the amount of valid data in the edge buffer;
[0026] When the amount of valid data in the edge buffer is greater than or equal to 2, the edge signal levels in the edge buffer are traversed, and valid edge pairs including falling edges and rising edges are filtered. Based on the real-time encoder position corresponding to the falling edge and rising edge in the valid edge pair, the actual physical aperture width corresponding to the valid edge pair is calculated.
[0027] If the actual physical aperture width is not within the preset aperture width threshold range, the valid edge pair is discarded and the traversal continues; if the actual physical aperture width is within the preset aperture width threshold range, the reliability of single aperture recognition is quantitatively evaluated, and the single aperture confidence level is calculated.
[0028] If the confidence level of a single hole does not reach the preset threshold, the valid edge pair is discarded and the traversal continues; if the confidence level of a single hole reaches the preset threshold, the valid single hole and its start position, end position, center position, actual hole width, and single hole confidence level are recorded in the single hole buffer.
[0029] Furthermore, the specific steps for inspecting the two marking holes on the track are as follows:
[0030] When a change in valid single-hole data occurs in the single-hole buffer, the amount of valid data in the single-hole buffer is determined.
[0031] When the amount of valid data in the single-hole buffer is greater than or equal to 2, traverse the valid single holes in the single-hole buffer and calculate the actual physical hole spacing between two adjacent valid single holes in the valid hole pair based on the center position of the valid single hole.
[0032] If the actual physical hole spacing is not within the preset hole spacing threshold range, the valid hole pair is discarded and the traversal continues; if the actual physical hole spacing is within the preset hole spacing threshold range, the reliability of the pair pair is quantitatively evaluated, and the hole spacing confidence level is calculated; the pairing confidence level is calculated by weighting the single hole confidence level and the hole spacing confidence level.
[0033] If the pairing confidence does not reach the preset threshold, the valid hole pair is discarded and the traversal continues; if the pairing confidence reaches the preset threshold, two marked holes on the track are detected, and the complete information of the valid hole pair and the two single holes in the valid hole pair, the center position of the two holes, the actual hole spacing, and the pairing confidence are recorded in the hole pair buffer.
[0034] Furthermore, the single-hole confidence level The calculation formula is:
[0035] ;
[0036] in, This represents the maximum tolerance for the hole width. This represents the actual width of a single hole. This represents the ideal hole width for a single hole.
[0037] The confidence level of the hole spacing The calculation formula is:
[0038]
[0039] in, This represents the maximum tolerance for hole spacing. This refers to the actual hole spacing between adjacent single holes. This represents the ideal hole spacing between adjacent holes.
[0040] Furthermore, the single-hole confidence level The calculation formula is:
[0041] ;
[0042] in, This represents the maximum tolerance for the hole width. This represents the actual width of a single hole. The ideal hole width for a single hole. The attenuation coefficient;
[0043] The confidence level of the hole spacing The calculation formula is:
[0044] ;
[0045] in, This represents the maximum tolerance for hole spacing. This refers to the actual hole spacing between adjacent single holes. This represents the ideal hole spacing between adjacent holes.
[0046] Furthermore, the pairing confidence level The calculation formula is:
[0047] ;
[0048] in, This is the mean of the single-hole confidence scores of two adjacent valid single holes in the valid hole pair. For the confidence weight of a single hole, The confidence weight for the hole spacing.
[0049] Furthermore, the rotation data of the wheels is acquired by encoders installed on the wheels, and the number of pulses collected by the encoders is converted into the theoretical travel distance of the shuttle on the track. The calculation formula is as follows:
[0050] ;
[0051] in, This represents the theoretical distance the shuttle car will travel on the track. Here, represents the encoder pulse count, and represents the encoder pulses per millimeter.
[0052] The theoretical distance the shuttle car travels between the two marked holes is:
[0053] ;
[0054] in, The number of pulses acquired by the encoder at the position of the rear marker hole. The number of pulses acquired by the encoder at the position of the front marking hole.
[0055] Furthermore, when the shuttle is started, changes tracks, or switches work scenarios, a clear command is issued to reset the effective data volume, write pointers, and sequence values of all buffers, restoring all buffers to their initial state.
[0056] After the shuttle's running curve is corrected, it is determined whether the effective data volume of the circular buffer is greater than 2. If so, only the two most recently stored edge effective data are retained, and the rest of the old data is cleared.
[0057] Beneficial Effects: Compared with existing technologies, the significant advantage of this invention is the establishment of a dual-benchmark comparison system that combines actual distance measurement of dual-hole positioning with theoretical distance measurement of encoder. Based on the two benchmarks of actual travel distance of dual-hole positioning and theoretical travel distance of encoder, the deviation coefficient (k) and correction amount (ΔS) are calculated through quantitative formulas. The correction amount directly compensates for the distance measurement deviation caused by wheel slippage / wear, solving the problem of positioning accuracy loss. Through the quantitative formula system of the synergistic effect of deviation coefficient (k) and correction amount (ΔS), a complete, end-to-end positioning and distance correction solution is provided for warehouse four-way vehicles. This solves the core problem of positioning accuracy loss caused by wheel slippage / wear in existing technologies, improves the motion accuracy and operational accuracy of four-way vehicles, and fully meets the high precision requirements of intelligent warehousing and logistics for automated equipment.
[0058] The design incorporates an edge signal filtering mechanism to filter signal jitter and repeated triggering caused by track vibration and electromagnetic interference, ensuring the authenticity and accuracy of dual-hole positioning data and providing a reliable benchmark for the precise calculation of deviation coefficients and correction amounts.
[0059] A quantitative evaluation system for confidence measurement is introduced, and a quantitative calculation formula for the confidence of single-hole and dual-hole pairing is designed. The dual-hole recognition and pairing results are quantitatively scored from 0 to 100 to screen high-reliability positioning results and ensure the accuracy of deviation coefficient and correction calculation.
[0060] An integrated correction logic for positioning and ranging is constructed. The deviation coefficient (k) is first calculated using a quantitative formula, and then the correction amount (ΔS) is derived based on the deviation coefficient. The correction amount is used as the direct basis to perform real-time and dynamic correction of the four-way vehicle motion curve, thereby achieving accurate compensation for the deviation.
[0061] A circular buffer is used to store data for each stage, enabling data to be stored in a first-in-first-out manner and automatically overwritten. It supports continuous dual-hole positioning, distance measurement comparison, deviation coefficient and correction calculation, and motion curve correction during the four-way vehicle movement.
[0062] Achieve dynamic correction of the motion curve throughout the entire process: Using dual-hole positioning as nodes, the correction amount (ΔS) is distributed to the entire motion process between the two positioning nodes through an interpolation algorithm to ensure positioning accuracy throughout the entire process. Attached Figure Description
[0063] Figure 1 This is a schematic diagram of the overall process of the motion curve correction method in this invention.
[0064] Figure 2 This is a schematic diagram of the signal acquisition and filtering process in this invention.
[0065] Figure 3 This is a schematic diagram of the single-hole identification and confidence assessment process in this invention.
[0066] Figure 4 This is a flowchart illustrating the dual-hole pairing and comprehensive evaluation process in this invention.
[0067] Figure 5 This is a flowchart illustrating the comparison of dual-benchmark distance measurement and the calculation of k and ΔS in this invention.
[0068] Figure 6 This is a flowchart illustrating the data management process in this invention. Detailed Implementation
[0069] like Figure 1 As shown in this embodiment, a shuttle car operation curve correction method based on dual-hole positioning is specifically used for the motion positioning and distance correction of a four-way warehouse vehicle. The core of this method is to capture the edge signal of the dual holes using an external hardware interrupt, implement dual-hole positioning through layered and modular software processing, and calculate the deviation coefficient using a quantization formula. ) and correction amount ( ),based on and The overall technical solution, which dynamically adjusts the motion curves, revolves around the core logic of "precise dual-hole positioning, dual-benchmark distance comparison, quantitative calculation of deviation coefficients and correction amounts, and motion curve correction." It collaboratively completes the entire process from dual-hole positioning to dynamic motion curve correction, resolving the accuracy loss caused by slippage and wear of the four-way wheels in warehouses. This includes the following steps:
[0070] Initialize the four-way shuttle's dual-hole positioning and distance correction detector, complete the configuration of core parameters such as the hole width threshold, hole spacing threshold, confidence threshold, and encoder pulses per millimeter for the track's dual holes, restore the four-way shuttle's motion curve to the standard initial curve, and complete the parameter initialization of the quantization formula;
[0071] The four-way vehicle starts moving. During the operation of the four-way vehicle, the encoder acquires the rotation data of the wheels in real time. The theoretical travel distance and real-time position are calculated and output in real time through the basic conversion formula. At the same time, the GPIO external interrupt captures the signal of the marking hole on the track in real time.
[0072] After detecting two marker holes on the track, the actual distance traveled by the shuttle between the two marker holes is obtained (several marker holes are set on the track, and the distance between the marker holes is fixed; the actual travel distance is...). The theoretical distance the shuttle travels between the two marked holes is calculated using the collected wheel rotation data; the ratio of the theoretical distance to the actual distance is used as the relative deviation coefficient. ;
[0073] Determine if the relative deviation coefficient exceeds the threshold. If the relative deviation coefficient exceeds the threshold, trigger the shuttle operation curve correction, including the correction of the sampling point position.
[0074] The formula for correcting the sampling point position is:
[0075] ;
[0076] ;
[0077] in, To correct the location of the sampling points, The original theoretical position of the sampling point is obtained based on the wheel rotation data. This is a correction factor per unit distance. This is the correction amount for the distance between the two marked holes. This represents the theoretical distance the shuttle car travels between the two marked holes.
[0078] Dual-reference ranging concept: Establish two ranging references: the theoretical walking distance collected by the encoder and the actual walking distance calculated by dual-hole positioning, to provide basic data for the calculation of deviation coefficient and correction amount.
[0079] The number of pulses (position values) collected by the encoder is converted into the theoretical travel distance of the shuttle on the track, providing the basis for all subsequent calculations of physical quantities. This is the fundamental quantification formula of the algorithm, which is:
[0080]
[0081] in, This represents the theoretical travel distance (mm) of the shuttle on the track. This is the encoder position difference (number of pulses). This represents the number of pulses per millimeter (pulses / mm) for the encoder.
[0082] Based on the actual positioning of the two holes, the actual travel distance of the four-way vehicle between the two holes is obtained. Simultaneously, the theoretical travel distance of the same segment collected by the encoder is extracted using the theoretical travel distance formula. The theoretical travel distance of the four-way vehicle through the two-hole segment collected by the encoder (after encoder-to-physical dimension conversion) serves as comparative data for deviation calculation. The theoretical travel distance calculation formula is as follows:
[0083] ;
[0084] in, The position value (pulse) of the rear hole acquired by the encoder; The front hole position value (pulse) acquired by the encoder; This represents the number of pulses per millimeter of the encoder.
[0085] Furthermore, when capturing the identification hole signal on the track in real time via GPIO external interrupt, the dual-hole positioning is broken down into three levels: edge signal acquisition and filtering, single-hole identification, and dual-hole pairing. The accuracy of the dual-hole positioning results is ensured through signal filtering and confidence quantification evaluation, providing a reliable physical benchmark for the accurate calculation of deviation coefficient and correction amount.
[0086] First, the acquired edge signals are filtered to determine if they are repetitive trigger / jitter signals. If so, the signal is discarded; otherwise, the edge signal is stored in the edge buffer, and a change in the edge data is marked. This step relies on external hardware interrupts to achieve real-time acquisition of the edge signals from the dual-aperture track. The core function is to filter jitter and repetitive trigger signals caused by track vibration and electromagnetic interference, ensuring the validity of the original acquired data. Figure 2 As shown, the specific steps are as follows:
[0087] During the movement of the four-way trolley in the warehouse, photoelectric sensors detect changes in the GPIO pin level caused by the marking holes on the track. These changes trigger an external interrupt. The GPIO input state is refreshed, and the current signal level, encoder real-time position, and system timestamp are simultaneously acquired. The latest stored edge signal level in the circular buffer is read and compared with the current level to determine if it is a repeated trigger signal. If the two levels are the same, it is determined to be a repeated trigger or jitter signal caused by track vibration, and the signal is discarded, ending the current acquisition. If the two levels are different, complete edge information including the current level, encoder position, and timestamp is written to the circular buffer. The buffer write pointer and valid data volume are updated. If the buffer is full, new data automatically overwrites the oldest data to avoid data overflow. Changes in the marked edge data trigger the subsequent single-hole recognition process. In this embodiment, level comparison is used to achieve repeated trigger filtering. A time debouncing mechanism can also be replaced or added, setting a minimum edge trigger interval. If the difference in timestamps between two triggers is less than this interval, it is determined to be a jitter signal and filtered, further improving the anti-interference capability under strong track vibration scenarios.
[0088] Upon detecting changes in edge data, the single-aperture identification process is initiated. Valid edge pairs are selected, the actual aperture width is calculated using a basic transformation formula, and the confidence level is calculated using a single-aperture confidence formula. High-confidence valid single apertures are selected and stored. The validity of single apertures is evaluated through confidence quantification, and highly reliable single-aperture data is selected for pairing with two apertures and subsequent... , Computation provides a precise foundation. For example... Figure 3 As shown, the specific steps are as follows:
[0089] After detecting a change in edge data, the single-hole recognition process is initiated. First, it checks if the effective data volume in the edge buffer is ≥2; otherwise, recognition ends and returns. If the data volume meets the requirement, it iterates through the edge signals, selecting the effective edge pairs representing "hole start - hole end" (falling edge - rising edge). The encoder position difference between the effective edge pairs is calculated using the basic conversion formula (…). The edge pair is converted into the actual physical aperture width; it is then determined whether the actual aperture width is within the preset minimum and maximum aperture width threshold range. If not, the edge pair is discarded and the iteration continues; if the aperture width meets the requirements, the single aperture confidence formula ( The confidence score for a single hole is calculated. A smaller deviation results in a higher confidence score. If the deviation is greater than or equal to the maximum tolerance, the confidence score is 0, and the hole is considered invalid. The system checks if the single hole confidence score is greater than or equal to a preset threshold. If not, the edge pair is discarded, and the process continues. If the threshold is reached, the start position, end position, center position, actual hole width, and confidence score of the valid single hole are stored in the single hole buffer, and the single hole data is marked as changed. The single hole confidence score is calculated based on the linear decay of the deviation between the actual hole width and the ideal hole width, quantifying the reliability of single hole recognition. The formula for calculating the single hole confidence score is:
[0090]
[0091] in, This represents the maximum tolerance for the hole width (mm). , This is the maximum threshold for hole width (mm), the upper limit for the width of the hole processed by the track. For example, if the designed hole width is 10mm, the upper limit is 10.5mm. This is the minimum threshold (mm) for hole width, the lower limit for the width of the hole processed by the track. For example, if the designed hole width is 10mm, the lower limit is 9.5mm. This is the actual width of a single hole (mm). The ideal hole width (mm) for a single hole.
[0092] Based on the effective single-hole start-up dual-hole pairing process, precise pairing of two holes on the track is achieved. The actual hole spacing is calculated using a basic conversion formula, and then the pairing confidence score is calculated using the hole spacing confidence score and the comprehensive confidence score formula for dual-hole pairing. High-confidence effective dual-hole pairs are selected, completing the precise positioning of the dual holes and obtaining their actual physical positions on the track. For example... Figure 4 As shown, the specific steps are as follows:
[0093] Upon detecting a change in single-hole data, the dual-hole pairing process is initiated. First, it checks if the effective data volume in the single-hole buffer is ≥2; otherwise, pairing ends and returns. If the data volume meets the requirement, it iterates through the effective single-hole data, calculates the center position difference between two adjacent single holes, and applies the basic conversion formula (…). Convert the actual hole spacing to the actual physical hole spacing; determine whether the actual hole spacing is within the preset minimum and maximum hole spacing threshold range; if not, discard the hole pair and continue iterating; if the hole spacing meets the requirements, sequentially apply the hole spacing confidence formula ( The pairing confidence score is calculated using the formula for the overall confidence score of the two holes, resulting in a pairing confidence score value of 0-100. It is then determined whether the pairing confidence score has reached a preset threshold. If not, the hole pair is discarded and the process continues. If it has reached the threshold, the pairing is completed. The complete information of the two single holes of the effective pairing, the center position of the two holes, the actual hole spacing, the pairing confidence score, and other information are stored in a circular buffer. The pairing is then marked as complete, triggering the subsequent distance measurement and comparison process.
[0094] The confidence level for hole spacing is calculated using the same logic as that for single-hole spacing, quantifying the reliability of the matching between two hole spacings. The formula for calculating the confidence level for hole spacing is as follows:
[0095]
[0096] in, This represents the maximum tolerance for hole spacing (mm). , This is the maximum threshold for hole spacing (mm), the upper limit for hole spacing in track machining. For example, if the designed hole spacing is 100mm, the upper limit is 101mm. This is the minimum threshold for hole spacing (mm), the lower limit for hole spacing in track machining. For example, if the designed hole spacing is 100mm, the lower limit is 99mm. This represents the actual hole spacing (mm) between adjacent single holes. This represents the ideal hole spacing (mm) between adjacent single holes.
[0097] The confidence score for a single borehole / borehole spacing can also be calculated using a non-linear exponential decay formula (taking the single borehole confidence score calculation formula as an example): (where k is the attenuation coefficient) assigns a higher confidence weight to hole widths / hole spacings with smaller deviations, further improving the distinguishability of high-matching positioning results, which is suitable for warehousing scenarios with extremely high positioning accuracy requirements.
[0098] The pairing confidence score is used to weight and synthesize the average confidence score of a single aperture and the confidence score of the aperture spacing, quantifying the overall reliability of pairing. Priority is given to the matching degree of aperture spacing (with higher weight), while also considering the reliability of single-aperture identification to ensure accurate pairing results and provide a reliable basis for calculating the deviation coefficient and correction amount. The formula for calculating the pairing confidence score is:
[0099] ;
[0100] in, The average confidence level for two single holes: ; The single-hole confidence weight (40% by default in this embodiment, i.e., 0.4); The confidence weight for the hole spacing is 60% (60% by default in this embodiment, i.e., 0.6). .
[0101] like Figure 5As shown, after the dual-hole positioning is detected, the distance measurement and comparison process is initiated. Based on the actual center position of the dual holes, the actual travel distance of the warehouse four-way vehicle between the dual holes is calculated. The actual travel distance is then compared with the theoretical travel distance to obtain the relative deviation coefficient. Alternatively, a global traversal method can be used to traverse all single-hole combinations in the single-hole buffer zone and select the optimal dual-hole pair that meets the spacing and confidence requirements. This method is suitable for warehouse scenarios where holes are densely distributed on the track.
[0102] The idea of co-quantification of deviation coefficient and correction amount: First, calculate the deviation coefficient using the quantization formula. This characterizes the ratio between the theoretical distance and the actual distance, and then derives the correction amount based on the deviation coefficient. ), quantify the specific deviation compensation value, and the two work together to achieve "trend control + precise compensation".
[0103] The relative deviation coefficient characterizes the ratio between the theoretical distance and the actual distance, reflects the deviation trend, and is the basis for calculating the correction amount and the trend basis for motion curve correction. The formula for calculating the relative deviation coefficient is: .
[0104] >1 indicates that the encoder's distance measurement is too low (due to wheel slippage or wear, the actual distance traveled is farther). <1 indicates that the encoder's ranging accuracy is too high; =1 indicates no deviation.
[0105] Threshold determination: When the deviation exceeds the preset normal threshold (e.g., 0.95~1.05), it is determined to be a valid deviation caused by wheel slippage / wear, and will be... , and Store the data in the data buffer, triggering the calculation of the correction amount and the correction of the motion curve. If the data does not exceed the limit, continue monitoring.
[0106] Correction amount Quantifying specific deviation compensation values is the direct basis for motion curve correction and is used to compensate for distance deviations caused by wheel slippage / wear.
[0107] ;
[0108] in; Correction amount (mm); This represents the actual distance traveled. This represents the theoretical walking distance. >0 indicates that the actual distance is greater than the theoretical distance, and encoder ranging compensation needs to be added in subsequent movements; <0 indicates that the actual distance is less than the theoretical distance, and encoder ranging compensation needs to be reduced in subsequent movements; =0 indicates no deviation, no compensation is needed.
[0109] Correction amount The relative correction formula can be used ( The correction amount is represented by a relative proportion, which better matches the parameter requirements of some four-way vehicle motion control algorithms. Multiple sets of dual-hole averaging corrections can also be used, combining the k and... Using the mean formula respectively , After averaging, curve correction is performed to further reduce the impact of random errors and improve the stability of the correction.
[0110] unit distance correction factor The correction amount is evenly distributed throughout the entire movement segment between the two holes, providing a basis for accurate correction at each sampling point and achieving uniform compensation throughout the entire process.
[0111] ;
[0112] in, The unit distance correction factor (mm / mm); This is the correction amount for the distance between the two marked holes; This represents the theoretical travel distance between the two holes. The total correction is distributed proportionally to the theoretical distance to ensure that each motion sampling point receives corresponding compensation and to avoid the accumulation of local biases. Unit distance correction coefficient. Cubic spline interpolation algorithms can also be used, based on k and Nonlinear fitting of the sampling points makes the corrected motion curve smoother and avoids sudden speed changes caused by linear correction, making it suitable for warehouse scenarios with high-speed four-way vehicle movement.
[0113] Dynamic curve correction concept: Using dual-hole positioning as the correction node, the deviation coefficient ( As the trend basis for motion curve correction, the correction amount ( As a specific basis for deviation compensation, the correction amount is distributed to the entire motion process between the two positioning nodes through an interpolation algorithm, realizing real-time and dynamic correction of the motion curve, avoiding deviation accumulation, and compensating for deviations caused by wheel slippage / wear. The specific steps are as follows:
[0114] Once a valid deviation is detected, the motion curve correction process is initiated, and the relative deviation coefficient is extracted from the data buffer. Total correction amount Unit distance correction factor The node positions of the dual-hole positioning are determined; using this dual-hole positioning as the correction node, the effective range of the correction is determined as the motion segment between the current dual-hole node and the previous dual-hole node; a linear interpolation algorithm is used to divide the correction range into several motion sampling points, based on the unit distance correction coefficient. Total correction Correction formula based on user-specified sampling point locations Calculate the position correction for each sampling point; integrate the correction for each sampling point into the motion control algorithm of the four-way vehicle, dynamically adjust the encoder's theoretical ranging calculation logic, and ensure that the corrected position and velocity match the actual motion trajectory; after completing the curve correction for the current node, , , The corrected motion curve parameters are synchronized with the subsequent motion control process to provide calibration basis for the next stage of motion. At the same time, the deviation data is cleared and awaits the deviation detection and correction of the next round of dual-hole positioning.
[0115] The formula for correcting the sampling point location is:
[0116] ;
[0117] ;
[0118] in: The corrected sampling point position (mm); The original theoretical location of the sampling point (mm); This is a correction factor per unit distance; This is the total correction amount. The correction amount consists of two parts: the correction amount allocated proportionally to the theoretical position (…). This allows for precise compensation at each sampling point, directly mitigating deviations caused by wheel slippage or wear.
[0119] After the correction is completed, the subsequent edge signals and encoder data are continuously monitored, and the next round of dual-hole positioning, formulaic distance measurement comparison, k and ΔS calculation and curve correction process is entered to achieve continuous correction of the four-way vehicle movement.
[0120] Layered processing + quantitative evaluation + intelligent storage: Continuing the layered and modular processing logic, the entire process of identification, pairing, deviation, and correction is quantified through a quantitative formula system that coordinates the deviation coefficient and the correction amount. A circular buffer is used to store data to ensure the accuracy of dual-hole positioning, the stability of algorithm operation, and continuous processing capability.
[0121] The data management module is the backend support component of the algorithm, realizing full lifecycle management of data in each level of buffer. Its core functions lie in intelligent cleanup and overall clearing, ensuring efficient and continuous data storage. It adapts to the continuous movement of the warehouse's four-way trolley, providing a basis for continuous quantitative calculations of the formula system. , The collaborative correction provides data support, and the specific process is as follows: Figure 6Data Management Module Flowchart: This module includes overall clearing logic and intelligent cleanup logic, while also supporting the retention of critical data.
[0122] Overall clearing logic: When the four-way vehicle is powered on for initialization, when changing tracks, or when switching work scenarios, after receiving a clearing command, it sequentially clears the edge, single hole, double hole, and deviation data. , , The effective data volume, write pointer, and sequence value of the buffer are all reset, all buffers are restored to their initial state, and they are waiting for new data acquisition and processing. At the same time, the parameter initialization of the formula system is reset.
[0123] Intelligent cleaning logic: Each time, a round of dual-hole positioning and formulaic distance measurement comparison is completed. , After calculation and curve correction, determine whether the effective data volume of the edge buffer is >2. If not, retain all data in the buffer; if so, retain only the last two edge data and clear the rest of the old data to avoid the accumulation of old data interfering with subsequent identification, while ensuring that edge pairs across cycles can be formed normally.
[0124] Key data retention logic: For the dual-hole positioning results , , The key quantitative data calculated by the modified motion curve parameters and other formulas are retained for a long period of time until a new clearing instruction is received, providing data support for subsequent deviation analysis and algorithm parameter optimization.
[0125] The algorithm and quantization formula system of this invention are implemented based on the embedded MCU (such as STM32, DSP series) of the warehouse four-way vehicle. It relies on basic hardware resources such as GPIO external interrupt, encoder acquisition, and system clock. There are no special hardware dependencies. It can be deployed directly on the existing four-way vehicle hardware platform. The calculation of k and ΔS is implemented through embedded software programming. The amount of computation is low (only includes addition, subtraction, multiplication and division operations) and does not affect the real-time performance of the device.
[0126] The core parameters of the algorithm formula (hole width / hole spacing threshold, confidence threshold, number of encoder pulses per millimeter, deviation threshold, etc.) can be flexibly adjusted according to the actual warehouse four-way vehicle model and track calibration hole specifications to adapt to different smart warehouse scenarios, while the calculation logic of k and ΔS remains unchanged.
[0127] The actual position of the dual-hole positioning is determined based on the size of the physical calibration hole of the track. The calibration hole is a standard accessory of the warehouse four-way vehicle track. This invention only identifies its position and completes the calculation of k and ΔS and subsequent correction through algorithms and quantitative formulas, without the need for additional modifications to the track.
[0128] Each module of the algorithm is an independent functional unit with a simple interface design. The quantitative calculation of k and ΔS can be directly integrated with the existing motion control algorithm of the warehouse four-way vehicle. It only needs to be called through the process of "initialization-acquisition-positioning-formula comparison-k / ΔS calculation-formula correction" without reconstructing the original control system.
[0129] The technical solution and quantitative formula system of this invention are not only applicable to warehouse four-way vehicles, but can also be extended to various track-walking equipment such as track-mounted AGVs and intelligent handling robots. Only the adaptation parameters of the formula need to be adjusted, and the calculation logic of the core k and ΔS collaborative correction remains unchanged, which has good technical expansion space.
[0130] During actual operation, debugging functions such as log printing and data retention can be reduced or removed according to the needs of warehouse operations without affecting the implementation of core functions such as positioning, formulaic distance measurement comparison, k / ΔS calculation and correction. Moreover, the algorithm has low operating overhead and will not affect the real-time motion control of the four-way vehicle.
[0131] The quantitative formula system of this invention is the core quantitative basis of the algorithm. All formulas have been verified in actual scenarios. The threshold parameters of the formulas (such as the deviation coefficient threshold of 0.95~1.05) are adapted to the conventional operation scenarios of warehouse four-way vehicles and can be flexibly adjusted according to the actual equipment accuracy requirements.
Claims
1. A method for correcting the running curve of a shuttle based on dual-hole positioning, characterized in that, Includes the following steps: The system acquires wheel rotation data in real time during shuttle operation and simultaneously captures signals from marker holes on the track. After detecting two marker holes on the track, the actual distance traveled by the shuttle between the two marker holes is obtained. Then, by collecting wheel rotation data, the theoretical distance traveled by the shuttle between the two marker holes is calculated. The ratio of the theoretical distance to the actual distance is used as the relative deviation coefficient. ; Determine if the relative deviation coefficient exceeds the threshold. If the relative deviation coefficient exceeds the threshold, trigger the shuttle sampling point position correction. The formula for correcting the sampling point position is: ; ; in, To correct the location of the sampling points, The original theoretical position of the sampling point is obtained based on the wheel rotation data. This is a correction factor per unit distance. This is the correction amount for the distance between the two marked holes. This represents the theoretical distance the shuttle travels between the two marked holes.
2. The shuttle operation curve correction method based on dual-hole positioning according to claim 1, characterized in that, The edge signal of the marking hole on the track is captured in real time by external GPIO interrupt, thereby detecting the marking hole on the track. The specific steps are as follows: During the operation of the shuttle, the GPIO pin detects a change in the level of the marker hole and triggers an external interrupt; refreshes the GPIO input state and synchronously acquires valid data such as the current edge signal level, the real-time position of the encoder, and the system timestamp; compares the edge signal level of the latest valid data stored in the edge buffer with the current edge signal level. If the latest stored edge signal level is consistent with the current edge signal level, it is determined that the current edge signal level is a repetitive triggering or jittering signal caused by track vibration, and the current edge signal level is discarded. If the latest stored edge signal level is inconsistent with the current edge signal level, the current edge signal level, encoder real-time position, and system timestamp are stored in the edge buffer; the identification hole is identified based on the edge signal in the edge buffer.
3. The shuttle operation curve correction method based on dual-hole positioning according to claim 1, characterized in that, The edge signal of the marking hole on the track is captured in real time by external GPIO interrupt, thereby detecting the marking hole on the track. The specific steps are as follows: During the operation of the shuttle, the GPIO pin detects a change in the level of the marker hole, triggering an external interrupt; refreshes the GPIO input state, and synchronously acquires valid data such as the current edge signal level, the encoder's real-time position, and the system timestamp; Read the system timestamp of the latest valid data stored in the edge buffer, calculate the timestamp difference with the system timestamp of the current valid data, compare the timestamp difference with the preset minimum edge trigger interval, if the timestamp difference is less than the preset minimum edge trigger interval, determine that the current edge signal level is a repeated trigger or jitter signal caused by track vibration, and discard the current edge signal level. If the timestamp difference is not less than the preset minimum edge trigger interval, the current edge signal level, encoder real-time position, and system timestamp are stored in the edge buffer; the identification hole is identified based on the edge signal in the edge buffer.
4. The shuttle operation curve correction method based on dual-hole positioning according to claim 2 or 3, characterized in that, The specific steps for identifying the marker hole based on the edge signal in the edge buffer include: When a change in valid data occurs in the edge buffer, determine the amount of valid data in the edge buffer; When the amount of valid data in the edge buffer is greater than or equal to 2, the edge signal levels in the edge buffer are traversed, and valid edge pairs including falling edges and rising edges are filtered. Based on the real-time encoder position corresponding to the falling edge and rising edge in the valid edge pair, the actual physical aperture width corresponding to the valid edge pair is calculated. If the actual physical aperture width is not within the preset aperture width threshold range, the valid edge pair is discarded and the traversal continues; if the actual physical aperture width is within the preset aperture width threshold range, the reliability of single aperture recognition is quantitatively evaluated, and the single aperture confidence level is calculated. If the confidence level of a single hole does not reach the preset threshold, the valid edge pair is discarded and the traversal continues; if the confidence level of a single hole reaches the preset threshold, the valid single hole and its start position, end position, center position, actual hole width, and single hole confidence level are recorded in the single hole buffer.
5. The shuttle operation curve correction method based on dual-hole positioning according to claim 4, characterized in that, The specific steps for inspecting the two marking holes on the track are as follows: When a change in valid single-hole data occurs in the single-hole buffer, the amount of valid data in the single-hole buffer is determined. When the amount of valid data in the single-hole buffer is greater than or equal to 2, traverse the valid single holes in the single-hole buffer and calculate the actual physical hole spacing between two adjacent valid single holes in the valid hole pair based on the center position of the valid single hole. If the actual physical hole spacing is not within the preset hole spacing threshold range, the valid hole pair is discarded and the traversal continues; if the actual physical hole spacing is within the preset hole spacing threshold range, the reliability of the pair pair is quantitatively evaluated, and the hole spacing confidence level is calculated; the pairing confidence level is calculated by weighting the single hole confidence level and the hole spacing confidence level. If the pairing confidence does not reach the preset threshold, the valid hole pair is discarded and the traversal continues; If the pairing confidence reaches a preset threshold, two marked holes on the track are detected, and the complete information of the valid hole pair and the two single holes in the valid hole pair, the center position of the two holes, the actual hole spacing, and the pairing confidence are recorded in the hole pair buffer.
6. The shuttle operation curve correction method based on dual-hole positioning according to claim 5, characterized in that, The single-hole confidence level The calculation formula is: ; in, This represents the maximum tolerance for the hole width. This represents the actual width of a single hole. This represents the ideal hole width for a single hole. The confidence level of the hole spacing The calculation formula is: in, This represents the maximum tolerance for hole spacing. This refers to the actual hole spacing between adjacent single holes. This represents the ideal hole spacing between adjacent holes.
7. The shuttle operation curve correction method based on dual-hole positioning according to claim 5, characterized in that, The single-hole confidence level The calculation formula is: ; in, This represents the maximum tolerance for the hole width. This represents the actual width of a single hole. The ideal hole width for a single hole. The attenuation coefficient; The confidence level of the hole spacing The calculation formula is: ; in, This represents the maximum tolerance for hole spacing. This refers to the actual hole spacing between adjacent single holes. This represents the ideal hole spacing between adjacent holes.
8. The method for correcting the operation curve of a shuttle based on dual-hole positioning according to claim 6 or 7, characterized in that, The pairing confidence The calculation formula is: ; in, This is the mean of the single-hole confidence scores of two adjacent valid single holes in the valid hole pair. For the confidence weight of a single hole, The confidence weight for the hole spacing.
9. The method for correcting the operation curve of a shuttle based on dual-hole positioning according to claim 1, characterized in that, The rotation data of the wheels is acquired by encoders installed on the wheels. The number of pulses collected by the encoders is converted into the theoretical travel distance of the shuttle on the track. The calculation formula is as follows: ; in, This represents the theoretical distance the shuttle car will travel on the track. Here, represents the encoder pulse count, and represents the encoder pulses per millimeter. The theoretical distance the shuttle car travels between the two marked holes is: ; in, The number of pulses acquired by the encoder at the position of the rear marker hole. The number of pulses acquired by the encoder at the position of the front marking hole.
10. The method for correcting the operation curve of a shuttle based on dual-hole positioning according to claim 5, characterized in that, When the shuttle is started, changes track, or switches work scenarios, a clear command is issued to reset the effective data volume, write pointer, and sequence value of all buffers, and all buffers are restored to their initial state. After the shuttle's running curve is corrected, it is determined whether the effective data volume of the circular buffer is greater than 2. If so, only the two most recently stored edge effective data are retained, and the rest of the old data is cleared.