A fast adjustment method for ophthalmic OCT reference arm based on microcontroller technology

Through microcontrol technology and S-type acceleration and deceleration control technology, the adjustment process of the OCT reference arm is decomposed, and the problem of position error and slow adjustment speed caused by acceleration impact in the prior art is solved, and the rapid, precise adjustment and high OCT reference arm are achieved. Quality image acquisition.

CN115145226BActive Publication Date: 2024-11-08SHENYANG GUOKE BRIGHT MEDICAL TECH CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210883475.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-07-26
Publication Date
2024-11-08
Estimated Expiration
2042-07-26

AI Technical Summary

Technical Problem

During the adjustment of the existing OCT reference arm, there is an acceleration impact, resulting in large position errors and slow adjustment speed, which affects the quality of image acquisition.

Method used

Using interpolation technology based on microcontrol technology and S-type acceleration and deceleration control technology, the optical path difference is measured through the optical path measurement device, and decompose it into continuous micro-line segments. The forward-looking control technology and S-type acceleration and deceleration control technology are used for dynamic processing and speed. Planning to achieve rapid and accurate adjustment of the reference arm.

Benefits of technology

It effectively solves the position error problem caused by acceleration impact, improves the adjustment speed, and realizes the rapid and accurate arrival of the reference arm, and improves the image acquisition quality.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115145226B_ABST
    Figure CN115145226B_ABST
Patent Text Reader

Abstract

The present invention discloses a method for rapid adjustment of an ophthalmic OCT reference arm based on microcontrol technology, and belongs to the technical field of ophthalmic medical device control. The method first measures the optical path of a sample beam and a reference beam by an optical path measurement device. In order to make the reference beam and the sample beam produce equal optical paths, the reference arm needs to be adjusted axially, and the axial displacement is the optical path difference. Then, the axial displacement of the reference arm is analyzed, and the axial displacement is interpolated into continuous tiny line segments by using interpolation technology. Finally, the above-mentioned continuous tiny line segments are dynamically processed and speed planning is performed using the forward-looking control technology and the S-type acceleration and deceleration control technology. After each tiny line segment is planned, the reference arm is fed to the tiny line segment in real time until the axial displacement feeding is completed. The present invention can achieve high-speed and high-precision effects in the adjustment process of the reference arm device by processing continuous tiny line segments, combining the forward-looking control technology and the S-type acceleration and deceleration control technology.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of ophthalmic medical device control, and in particular relates to a method for quickly adjusting an ophthalmic OCT reference arm based on microcontroller technology. Background Art

[0002] Optical Coherence Tomography (OCT) is widely used in the detection of ophthalmic diseases. It uses the basic principle of weak coherent light interferometer to detect the back reflection or several scattered signals of the incident weak coherent light at different depths of biological tissues, and obtains a two-dimensional or three-dimensional structural image of the biological tissue by scanning. The OCT reference arm and the OCT sample arm are connected in parallel to two different ports of the fiber coupler. Interference imaging can only be achieved when the optical path difference between the sample arm and the reference arm is within the coherence length. Therefore, when the optical path difference of the sample arm at different positions during scanning exceeds the interference length, imaging will not be possible. In order to ensure the imaging quality, the adjustment process of the reference arm is particularly important. It is necessary to adjust the position of the reference arm so that a certain equal optical path is generated between the sample arm and the reference arm.

[0003] The fiber coupler divides the light source into the first original light and the second original light. The first original light is reflected back to the coupler through the reference arm to form a reference beam. The second original light is reflected and scattered back to the fiber coupler through the sample arm to form a sample beam, which interferes with the reference beam to form an image. However, the condition for obtaining a clear image is that the optical path difference between the reference beam and the sample beam is within a certain range. During the imaging process, the reference arm needs to be dynamically adjusted due to the uncertainty of the sample beam.

[0004] The existing reference arm device adjustment technology generally drives the lead screw through the motor shaft, and then drives the reference arm device to complete the position adjustment. The reference arm adjustment method reaches the vicinity of the specified position at one time and achieves high position accuracy through multiple automatic compensations through the judgment of the axial displacement. However, since the automatic compensation process is relatively cumbersome, the speed of reaching the determined position point is relatively slow. In the process of measuring the biological parameters of the human eye, the adjustment time of the reference arm greatly affects the image acquisition quality, and every extra second may increase the imaging error. Therefore, it is particularly important that the reference arm device can reach the optimal position point quickly and accurately. At the same time, the reference arm will inevitably experience acceleration and deceleration during the movement process. The existence of acceleration will produce impact and increase the position error, thereby affecting the accuracy of the reference arm movement adjustment. Summary of the invention

[0005] 1. Technical issues to be resolved

[0006] The present invention aims to solve the problems existing in the existing reference arm motion adjustment process, such as acceleration, acceleration impact during the acceleration process leading to large position error, slow adjustment speed, insufficient accuracy, thus affecting the image acquisition quality.

[0007] (II) Technical solution

[0008] In order to solve the above technical problems, the present invention provides a method for quickly adjusting an ophthalmic OCT reference arm based on microcontroller technology. The specific technical solutions adopted are as follows:

[0009] A method for quickly adjusting an ophthalmic OCT reference arm based on microcontroller technology, the steps of the method are as follows:

[0010] S1: Measure the optical path length of the sample beam and the reference beam through the optical path measurement device, and the optical path difference is the axial feed displacement;

[0011] S2: Use interpolation technology to interpolate the reference arm axial feed displacement into continuous tiny line segments;

[0012] S3: Utilize the forward-looking control technology and S-type acceleration and deceleration control technology to dynamically process the continuous tiny line segments and perform speed planning. After each tiny line segment is planned, real-time control is performed to allow the reference arm to feed the tiny line segment until the axial displacement feeding is completed.

[0013] Preferably, the tiny line segments are micrometer-scale line segments.

[0014] Preferably, the S-type acceleration and deceleration control technology in step S3 divides the axial displacement of the reference arm into 6 or 7 stages, namely, acceleration stage T1, uniform acceleration stage T2, deceleration stage T3, uniform speed stage T4, acceleration and deceleration stage T5, uniform deceleration stage T6, and deceleration and deceleration stage T7; when the axial feed distance is too short, there is no uniform speed stage T4; the time calculation formula for each stage is:

[0015] T1=T3=T5=T7=a max / j max

[0016]

[0017]

[0018] Where: a max is the maximum axial acceleration allowed by the system, j max is the maximum axial acceleration allowed by the system, v max is the maximum axial feed speed that can be achieved. When there is a uniform speed stage, v max is the maximum axial feed speed allowed by the system. When there is no uniform speed stage, v max is the maximum axial feed speed actually achieved; vs , v e They are the initial velocity and the final velocity, both of which are 0. The uniform speed stage time T4 can be obtained by the acceleration stage displacement S a , deceleration stage displacement S d The total displacement L and the maximum axial feed speed v that can be achieved max Specifically, T4 is obtained by subtracting the acceleration phase displacement and the deceleration phase displacement from the total displacement L to obtain the uniform phase displacement, and the uniform phase time T4 is obtained by dividing the uniform phase displacement by the maximum axial feed speed allowed by the system.

[0019] Preferably, the process of processing the continuous micro-line segments and speed planning using the forward-looking control technology in step S3 is as follows:

[0020] S31: According to the maximum axial feed speed v that can be achieved max Determine the number of forward-looking segments N;

[0021] S32: Reading the line segment information from the first segment to the Nth segment through the forward-looking buffer module, and completing the speed planning of the first line segment in the forward-looking buffer;

[0022] S33: After the first line segment planning is completed, the forward buffer is exited, and the N+1th line segment enters the buffer. The speed planning of the first line segment in the buffer continues, and so on, until all the line segments are read into the forward buffer. When there are no line segments that can be read into the buffer, the forward buffer spits out the line segments whose speed planning has been completed in sequence until all the line segments exit the forward buffer.

[0023] Preferably, the process of determining the number of forward-looking segments N is as follows:

[0024] S311: Calculate the maximum axial feed speed v that can be achieved max The minimum distance L min Among them, L min It is the sum of the minimum acceleration distance and the minimum deceleration distance. The minimum distance L min The calculation formula is:

[0025]

[0026] In the formula, the initial velocity v s and final velocity v e Both are 0, v max The value is the maximum axial feed speed allowed by the system;

[0027] S312: Compare the axial displacement L of the reference arm with the minimum distance L min Compare and determine whether there is a uniform speed stage. The judgment formula is as follows:

[0028] When L>Lmin When , there is a uniform speed stage;

[0029] When L≤L min There is no uniform speed stage.

[0030] When there is no uniform speed stage, the maximum axial feed speed v that can be achieved max The calculation formula is:

[0031]

[0032] S313: Based on the maximum achievable axial feed speed v max The forward-looking segment number N is calculated and the calculation formula of the forward-looking segment number N is as follows:

[0033]

[0034]

[0035] In the formula, S a is the total displacement in the acceleration phase, L x is the length of the pre-set small line segment after interpolation, N is rounded up; when there is a uniform speed stage, v max is the maximum axial feed speed allowed by the system. When there is no uniform speed stage, v max is the maximum axial feed speed actually achieved.

[0036] More preferably, during speed planning in step S32, the final speed of the previous line segment is the initial speed of the next line segment, and the initial speed of the first line segment and the final speed of the last line segment are both zero.

[0037] Preferably, before performing speed planning, the forward buffer module reads the line segment information and speed information; determines whether it is in the acceleration stage, the uniform speed stage or the deceleration stage; wherein the speed limit value calculation formula in the acceleration stage is:

[0038]

[0039] v2=v1+j max T1T2

[0040]

[0041] Wherein, v1 is the maximum feed speed in the acceleration stage, v2 is the maximum feed speed in the uniform acceleration stage, and v3 is the maximum feed speed in the deceleration stage;

[0042] The speed calculation formula in the uniform speed stage is:

[0043] v4=v3

[0044] The calculation formula for the speed limit value in the deceleration stage is:

[0045]

[0046] v6=v5-j max T5T6

[0047]

[0048] In the formula, v5 is the minimum feed speed in the acceleration and deceleration stage, v6 is the minimum feed speed in the uniform deceleration stage, and v7 is the minimum feed speed in the deceleration stage;

[0049] The actual speed value during speed planning should not be greater than the maximum axial feed speed v that can be achieved max ; When it is greater than the maximum axial feed speed, the actual speed is taken as the maximum axial feed speed v that can be achieved max .

[0050] More preferably, after the acceleration phase is determined, the specific speed planning process of each phase in the acceleration phase is as follows:

[0051] Acceleration phase:

[0052] First, the feed time t of the first line segment is calculated by the following formula: 11 :

[0053]

[0054] In the formula, S x is the length of the continuous tiny line segment;

[0055] Secondly, the reference arm feed speed v of the first line segment is calculated by the following formula: 11 :

[0056]

[0057] Again, the feed time of the second small line segment and the feed speed v of the reference arm are calculated and obtained by the following formula: 12 :

[0058]

[0059]

[0060] And so on, the feed speed v of the reference arm in the subsequent small line segment is calculated 13 、v 14 ,...,v 1a ;

[0061] Finally, the final velocity of the acceleration phase is corrected according to the following rules to ensure the accuracy of the displacement:

[0062] When v 1a When ≤v1, there is no need to correct the feed speed;

[0063] When v 1a When >v1, the proportional coefficients k1 and k2 are calculated according to the following formula:

[0064]

[0065] In the formula, v 1a-1 is the feed rate of the previous segment of line segment 1a; except for k1 and k2, all other variables are known. By solving the values ​​of variables k1 and k2, v1 is assigned to v 1a , the final velocity of the axial displacement of this section is corrected to ensure the accuracy of the displacement and the accuracy of the axial feed of the reference arm device. At this point, the velocity planning of the acceleration stage is completed;

[0066] Uniform acceleration stage:

[0067] The initial speed of uniform acceleration is v1, and the maximum feed speed is v2. First, the feed time t of the first line segment in the uniform acceleration stage is calculated according to the following formula 21 :

[0068]

[0069] Secondly, the feed speed v of the first line segment is calculated by the following formula: 21 :

[0070] v 21 =v1+j max T1t 21

[0071] Again, the feed time t of the second line segment is calculated by the following formula: 22 and feed speed v 22 :

[0072]

[0073] v 22 =v 21 +j max T1t 22

[0074] Calculate v in the same way 23 、v 24 ,...,v 2b ;

[0075] Finally, the final velocity of the uniform acceleration stage is corrected according to the following rules to ensure the accuracy of the displacement:

[0076] When v 2b When ≤v2, there is no need to correct the feed speed;

[0077] When v 2b When >v2, the proportional coefficients k3 and k4 are introduced and calculated according to the following formula:

[0078]

[0079] In the formula, v 2b-1 is the feed rate of the first segment of line segment 2b; except for k3 and k4, all other variables are known. By solving the values ​​of variables k3 and k4, v2 is assigned to v 2b , by correcting the jerk and feed time, the accuracy of displacement and the axial feed of the reference arm device are guaranteed, and the speed planning of the uniform acceleration stage is completed;

[0080] Deceleration phase:

[0081] The initial speed of the deceleration and acceleration phase is v2, and the maximum feed speed is v3. First, the feed time t of the first line segment of the deceleration and acceleration phase is calculated according to the following formula: 31 :

[0082]

[0083] Secondly, calculate the feed speed v of the first line segment in the deceleration phase according to the following formula: 31 :

[0084]

[0085] Next, calculate the feed time t of the second line segment in the deceleration phase 32 and feed speed v 32 :

[0086]

[0087]

[0088] Calculate v in the same way 33 、v 34 ,...,v 3c ;

[0089] Finally, the final velocity of the deceleration phase is corrected according to the following rules to ensure the accuracy of the displacement:

[0090] When v 3c When ≤v3, there is no need to correct the feed speed;

[0091] When v 3cWhen >v3, the proportional coefficients k5 and k6 are introduced and calculated according to the following formula:

[0092]

[0093] In the formula, v 3c-1 is the feed rate of the first segment of line segment 3c; except for k5 and k6, all other variables are known. By solving the values ​​of variables k5 and k6, v3 is assigned to v 3c , the final velocity of this section of axial displacement is corrected to ensure the accuracy of the displacement and the accuracy of the axial feed of the reference arm device. At this point, the speed planning of the deceleration and acceleration stage is completed.

[0094] Preferably, after being determined as the uniform speed stage, the reference arm is fed according to the maximum axial feed speed v3 (v4) of the uniform acceleration stage.

[0095] Preferably, after determining the deceleration stage, the specific speed planning process of each stage in the deceleration stage is as follows:

[0096] Acceleration and deceleration phases:

[0097] The initial speed of the acceleration and deceleration stage is v4, and the minimum feed speed is v5. First, the feed time t of the first line segment in the acceleration and deceleration stage is calculated according to the following formula 51 :

[0098]

[0099] Secondly, the feed speed v of the first line segment is calculated by the following formula: 51 :

[0100]

[0101] Again, the feed time t of the second line segment is calculated by the following formula: 52 and feed speed v 52 :

[0102]

[0103]

[0104] Calculate v in the same way 53 、v 54 ,...,v 5d ;

[0105] Finally, the final velocity of the acceleration and deceleration stage is corrected according to the following rules to ensure the accuracy of the displacement:

[0106] When v5≤v 5d There is no need to correct the feed speed;

[0107] When v5>v 5d When , the proportional coefficients k7 and k8 are introduced, and the proportional coefficients k7 and k8 are calculated according to the following formula:

[0108]

[0109] In the formula, v 5d-1 is the feed rate of the segment before line segment 5d; except for k7 and k8, all other variables are known. By solving the values ​​of variables k7 and k8, v5 is assigned to v 5d , the final speed of the axial displacement of this section is corrected to ensure the accuracy of the displacement and the accuracy of the axial feed of the reference arm device. At this point, the speed planning of the acceleration and deceleration stage is completed;

[0110] Uniform deceleration stage:

[0111] The initial speed of the uniform deceleration stage is v5, and the minimum feed speed is v6. First, the feed time t of the first line segment in the uniform deceleration stage is calculated according to the following formula 61 :

[0112]

[0113] Secondly, the feed speed v of the first line segment is calculated by the following formula: 61 :

[0114] v 61 =v5-j max T5t 61

[0115] Again, the feed time t of the second line segment is calculated by the following formula: 62 and feed speed v 62 :

[0116]

[0117] v 62 =v 61 -j max T5t 62

[0118] Calculate v in the same way 63 、v 64 ,...,v 6e ;

[0119] Finally, the final velocity of the uniform deceleration stage is corrected according to the following rules to ensure the accuracy of the displacement:

[0120] When v6≤v 6e There is no need to correct the feed speed;

[0121] When v6>v6e When the proportional coefficients k9 and k 10 , and calculate the proportional coefficients k9 and k according to the following formula 10 :

[0122]

[0123] In the formula, v 6e-1 is the feed rate of the first segment of line segment 6e; except for k3 and k4, all other variables are known. By solving variables k9 and k 10 Assign v6 to v 6e , the final speed of the axial displacement of this section is corrected to ensure the accuracy of the displacement and the accuracy of the axial feed of the reference arm device. At this point, the speed planning of the uniform deceleration stage is completed;

[0124] Deceleration phase:

[0125] The initial speed of the deceleration stage is v6, and the minimum feed speed is v7. First, the feed time t of the first line segment in the deceleration stage is calculated according to the following formula 71 :

[0126]

[0127] Secondly, the feed speed v of the first line segment is calculated by the following formula: 71 :

[0128]

[0129] Again, the feed time t of the second line segment is calculated by the following formula: 72 and feed speed v 72 :

[0130]

[0131]

[0132] Calculate v in the same way 73 、v 74 ,...,v 7f ;

[0133] Finally, the final velocity of the deceleration stage is corrected according to the following rules to ensure the accuracy of the displacement:

[0134] When v7≤v 7f There is no need to correct the feed speed;

[0135] When v7>v 7f When the proportionality coefficient k is introduced 11 , k 12 , and calculate the proportionality coefficient k according to the following formula11 , k 12 :

[0136]

[0137] In the formula, v 7f-1 is the feed rate of the first segment of line segment 7f; except k 11 , k 12 , are all known quantities, and by solving the variable k 11 , k 12 Assign v7 to v 7f , the final speed of this section of axial displacement is corrected to ensure the accuracy of the displacement and the accuracy of the axial feed of the reference arm device. At this point, the speed planning of the deceleration stage is completed.

[0138] The present invention adopts a linear motion mode in which a motor shaft drives a lead screw, and the lead screw drives a reference arm related device.

[0139] (III) Beneficial effects

[0140] Compared with the prior art, the present invention has the following beneficial effects:

[0141] The present invention applies S-type acceleration and deceleration control technology to eliminate the speed and acceleration impact problems in the acceleration and deceleration process. Secondly, the forward-looking control technology is used to complete the continuous small line segment processing process, which effectively solves the accuracy and efficiency problems, eliminates the tedious automatic compensation process, and realizes the fast and precise adjustment process of the reference arm device, providing a good foundation for the acquisition of high-quality images.

[0142] The present invention uses the forward control technology to achieve dynamic processing of the forward segment number, fast reading of small line segments, reasonable use of the forward buffer space and optimization of overall efficiency. In view of the problem that all the information of tiny line segments is read in at one time, which occupies a large amount of buffer space, and a large amount of calculation leads to a long program running time and cannot realize the fast feeding process, the forward buffer is used to buffer the data processing. The forward buffer module reads a fixed number of small line segments each time, and through the dynamic reading and processing of the small line segments, the calculation load is reduced, and the problem of occupying a large amount of buffer space and causing the program to run for a long time is avoided.

[0143] The speed curve and acceleration curve of the S-shaped acceleration and deceleration control adopted by the present invention have good continuity. This technology is applied in the acceleration and deceleration process, which can effectively reduce the accuracy error caused by the sudden impact of speed and acceleration, and can effectively improve the accuracy of the arrival position by correcting the key point speed. At the same time, the present invention uses the forward-looking control technology to complete the optimal planning of the speed of the small line segment control point, thereby ensuring that the reference arm device quickly reaches the equal optical path point and generates high-quality images.

[0144] The present invention is a continuous tiny line segment feeding process, and the speed that can be increased or decreased for each small line segment is very small. Therefore, each process of T1, T2, T3, T4, T5, T6, and T7 is completed by a large number of small line segments to complete the speed connection process, thereby achieving accurate control of the speed, thereby achieving precise control of the axial feed displacement.

[0145] Symbols

[0146] The meanings of the symbols involved in the formula of the present invention are as follows:

[0147] T1: time of acceleration stage; T2: time of uniform acceleration stage; T3: time of deceleration stage;

[0148] T4: time of acceleration and deceleration stage; T5: time of uniform deceleration stage; T6: time of deceleration and deceleration stage;

[0149] a max : The maximum axial acceleration allowed by the system;

[0150] j max : The maximum axial acceleration allowed by the system;

[0151] v max : The maximum axial feed speed that can be achieved, when there is a uniform speed stage, v max is the maximum axial feed speed allowed by the system. When there is no uniform speed stage, v max is the maximum axial feed speed actually achieved;

[0152] v s : initial velocity; v e : final speed;

[0153] S a : Displacement in acceleration phase; S d Displacement during deceleration phase; L: total displacement;

[0154] N: number of forward-looking segments;

[0155] L min : The minimum distance to reach the maximum axial feed speed allowed by the system;

[0156] L x : Preset length of small line segment after interpolation;

[0157] v1: maximum feed rate in the acceleration stage; v2: maximum feed rate in the uniform acceleration stage; v3: maximum feed rate in the deceleration stage; v4: feed rate in the uniform speed stage; v5: minimum feed rate in the acceleration and deceleration stage; v6: minimum feed rate in the uniform deceleration stage; v7: minimum feed rate in the deceleration and deceleration stage;

[0158] Sx : The length of continuous tiny line segments;

[0159] v 1i : The feed rate of the i-th small line segment during the acceleration phase; t 1i : Feeding time of the i-th small line segment in the acceleration phase;

[0160] v 2i : the feed speed of the ith small line segment in the uniform acceleration stage; t 2i : Feeding time of the ith small line segment in the uniform acceleration stage;

[0161] v 3i : The feed rate of the ith small line segment during the deceleration and acceleration phase; t 3i : Feeding time of the i-th small line segment in the deceleration and acceleration phase;

[0162] v 5i : The feed rate of the i-th small line segment during the acceleration and deceleration phase; t 5i : Feeding time of the i-th small line segment during the acceleration and deceleration phase;

[0163] v 6i : The feed speed of the ith small line segment during the uniform deceleration stage; t 6i : The feeding time of the i-th small line segment in the uniform deceleration stage;

[0164] v 7i : The feed rate of the i-th small line segment during the deceleration phase; t 7i : Feeding time of the i-th small line segment during the deceleration phase;

[0165] k: proportionality coefficient. BRIEF DESCRIPTION OF THE DRAWINGS

[0166] Figure 1 The figure is an overall flow chart of a method for rapid adjustment of an ophthalmic OCT reference arm in a preferred embodiment of the present invention.

[0167] Figure 2 This is a speed control curve diagram when the axial feed distance is large in a preferred embodiment of the present invention.

[0168] Figure 3 This is a speed control curve diagram when the axial feed distance is small in a preferred embodiment of the present invention.

[0169] Figure 4 The figure is a schematic diagram of the working mode of the look-ahead buffer in a preferred embodiment of the present invention.

[0170] Figure 5 The figure is a logical flow chart of speed planning in a preferred embodiment of the present invention. DETAILED DESCRIPTION

[0171] The following is a combination of specific implementation cases and attached Figure 1-5 The present invention is further described below, but the present invention is not limited to these embodiments.

[0172] The technical solutions in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all of the embodiments. The components of the embodiments of the present application described and shown in the drawings here can be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of the present application provided in the drawings is not intended to limit the scope of the application claimed for protection, but merely represents the selected embodiments of the present application. Based on the embodiments of the present application, all other embodiments obtained by those skilled in the art without making creative work belong to the scope of protection of the present application.

[0173] It should be noted that similar reference numerals and letters represent similar items in the following drawings, so once an item is defined in one drawing, it does not need to be further defined and explained in subsequent drawings. At the same time, in the description of this application, the terms "first", "second", etc. are only used to distinguish the description and cannot be understood as indicating or implying relative importance.

[0174] The present invention adopts a linear motion method in which the motor shaft drives the lead screw, and the lead screw drives the reference arm related devices. The optical path measurement device and interpolation technology actuator used are all built-in devices on the OCT device, and the program modules such as the forward control module and the speed planning module are loaded with the algorithm of the present invention and integrated into the OCT device.

[0175] The technical core of the present invention is to quickly and accurately adjust the reference arm device to the equal optical path position point, so as to obtain a high-quality human eye recognition image. The present invention interpolates the axial displacement of the reference arm by using interpolation technology to obtain continuous micro-line segments, and then completes the feeding process of the continuous micro-line segments through forward control technology and S-type acceleration and deceleration control technology, achieving high speed and high precision of the feeding process. The overall process is as follows: Figure 1 The specific implementation process is as follows:

[0176] First, the optical path length of the reference beam and the sample beam is measured by an optical path length measuring device to calculate the axial displacement of the reference arm. The main function of the optical path length measuring device is to determine the next position to which the reference arm is about to move and to measure the distance moved.

[0177] Second, the axial displacement of the reference arm device is analyzed, that is, the axial displacement is interpolated into continuous tiny line segments using interpolation technology. Since the axial feed motion of this reference arm is linear, the interpolation cycle of the interpolation technology is extremely short, about 1 millisecond. By controlling the interpolation speed during the interpolation process, the length of the interpolated line segment is a micron-level line segment. Since the reference arm device is axially fed and the feed route is a straight line segment, the length of the interpolated line segment is the same, and the speed planning process is simplified. At the same time, it is also through the subsequent feeding of micron-level line segments that a higher-precision control process can be completed, allowing the reference arm to accurately reach the specified position point.

[0178] Third, to ensure the completion of axial rapid feeding, the forward control technology and S-type acceleration and deceleration control technology are introduced to process continuous small segments to avoid the problem of excessive calculation in the speed planning process of continuous small segments. The segments obtained through interpolation are first processed by the forward buffer module. The function of the forward buffer is to read a fixed number of small segments each time to avoid directly reading all the small segments of path information at once, resulting in excessive buffer space, large amount of calculation, long program running time, and inability to achieve rapid feeding process.

[0179] Fourth, the look-ahead buffer module adaptively selects the appropriate number of look-ahead segments N. The look-ahead buffer selects the number of look-ahead segments based on the axial feed displacement to determine the maximum achievable axial feed speed. That is, the number of look-ahead segments N is adaptively selected according to the size of the feed speed. Generally speaking, the greater the maximum axial feed speed, the more look-ahead segments are required, and the space requirement of the look-ahead buffer increases accordingly, and the number of small line segments read in each time increases. The number of look-ahead segments is obtained by calculating the maximum axial feed speed, which can achieve the rational use of the look-ahead buffer space and the optimization of the overall efficiency, and ensure the rapid adjustment of the reference arm device. Taking the small line segments N of the look-ahead segment number N read by the look-ahead buffer module each time as an example, the process is:

[0180] (1) The look-ahead buffer module first reads in line segment 1 to line segment N;

[0181] (2) The speed of the first line segment in the look-ahead buffer is planned. After the planning is completed, the first line segment exits the look-ahead buffer and the N+1th line segment enters, and so on, until the last line segment is read into the look-ahead buffer. When the speeds of all the line segments in the look-ahead buffer are planned, the speed planning of all the line segments is completed.

[0182] Fifth, in the actual axial feeding process, starting from the first time the look-ahead buffer module reads the small line segment information, the speed processing module starts to plan the speed of the axial feeding according to the S-type acceleration and deceleration rule, and completes the real-time axial feeding through the continuous updating of the small line segments in the look-ahead buffer. The look-ahead buffer module reads the small line segments and feeds the small line segments with completed speed planning in real time, instead of feeding after reading all the line segments and calculating the speed information, which can save a lot of time and improve the overall efficiency.

[0183] Finally, the reference arm completes the axial feeding and reaches the equal optical path position for image acquisition.

[0184] When using S-type acceleration and deceleration control technology for speed planning, the complete S-type acceleration and deceleration control divides the entire process into 7 stages, such as Figure 2 As shown. That is, the acceleration stage T1, the uniform acceleration stage T2, the deceleration stage T3, the uniform speed stage T4, the acceleration and deceleration stage T5, the uniform deceleration stage T6, and the deceleration and deceleration stage T7. In the case of a short distance, the uniform speed stage may not exist, such as Figure 3 shown.

[0185] In the process of continuous micro-segment feeding, the speed that can be increased or decreased for each small segment is very small. Therefore, each process of T1, T2, T3, T4, T5, T6, and T7 is completed by a large number of small segments to complete the speed connection process, so as to achieve accurate control of the speed and thus achieve precise control of the axial feed displacement. The time spent in each stage is:

[0186] T1=T3=T5=T7=a max / j max

[0187]

[0188]

[0189] In the formula, a max is the maximum axial acceleration allowed by the system, j max is the maximum axial acceleration allowed by the system, v max is the maximum axial feed speed that can be achieved. When there is a uniform speed stage, v max is the maximum axial feed speed allowed by the system. When there is no uniform speed stage, v max is the maximum axial feed speed actually achieved; v s , v e are the initial velocity and the final velocity, both of which are 0. The uniform speed stage time T4 can be calculated by the acceleration stage displacement S a , deceleration stage displacement S d With the total displacement L, the maximum axial feed speed v maxThe uniform speed stage time T4 is calculated by using the total displacement L and the acceleration stage displacement S a , deceleration stage displacement S d The displacement of the uniform speed stage is calculated by the difference between the two. Since there is a uniform speed stage, the feed speed of the reference arm in this stage must be the maximum axial feed speed allowed by the system. Therefore, the time of the uniform speed stage can be obtained by dividing the two.

[0190] Since the speed curve and acceleration curve of S-type acceleration and deceleration control have good continuity, this technology can be used in the acceleration and deceleration process to effectively reduce the accuracy error problems caused by sudden changes in speed and acceleration, and can effectively improve the accuracy of the reached position. It is especially suitable for axial adjustment of ophthalmic medical equipment.

[0191] In the S-shaped acceleration and deceleration forward planning process of continuous micro-line segments, there are two situations in the linear axial feed adjustment of the reference arm device:

[0192] The first case is that the axial feed distance is large, and the axial moving speed of the reference arm device can reach the maximum axial feed speed allowed by the system after acceleration, such as Figure 2 shown.

[0193] The second situation is that the axial feed distance of the reference arm device is extremely short and the maximum axial feed speed cannot be reached. The maximum axial feed speed that can be achieved needs to be calculated using the formula, such as Figure 3 shown.

[0194] Before the look-ahead buffer performs look-ahead processing on a tiny line segment, it is necessary to judge the axial displacement to determine whether the axial segment can reach the maximum axial feed rate allowed by the system. The judgment process is as follows:

[0195] First, the minimum distance L that can achieve the maximum axial feed speed of the system is solved according to the following formula: min ,

[0196] L min = shortest acceleration distance + shortest deceleration distance

[0197]

[0198] Among them, the starting and ending speeds are both 0, that is, v s , v e Both are 0, v max The value is the maximum axial feed speed allowed by the system.

[0199] Then, by analyzing the optical path, the reference arm axial feed displacement L is determined and compared with L min Compare.

[0200] When L>L minThere is a uniform speed phase

[0201] When L≤L min There is no uniform speed stage. The maximum axial feed speed v that can be reached at this time max It can be calculated by the following formula:

[0202]

[0203] After obtaining the maximum axial feed speed that can be achieved in each stage of the feeding process, the forward-looking segment number N is calculated and obtained. The forward-looking segment number N is specifically calculated by the following two formulas:

[0204]

[0205]

[0206] In the formula, S a is the total displacement in the acceleration phase, L x The length of the interpolated small line segment is pre-set, and N is rounded up. For example, the calculated value is 5.6, which is rounded up to 6. When there is a uniform speed stage, v max is the maximum axial feed speed allowed by the system. When there is no uniform speed stage, v max is the maximum axial feed rate actually achieved. Therefore, the number of forward-looking segments N is 1 greater than the total number of small line segments interpolated in the acceleration phase, which can ensure that the maximum feed rate is achieved within the forward-looking segment N distance range. Since the acceleration phase and the deceleration phase are mirror images, it can also be ensured that the speed can be reduced to 0 within the forward-looking segment N distance range.

[0207] After determining the number of forward-looking segments N, the forward-looking buffer module starts to read continuous small line segments. The forward-looking buffer works as follows: Figure 4 . E is the number of the last line segment. The specific process is as follows:

[0208] First, read the information of the 1st to Nth line segments.

[0209] Secondly, the S-type acceleration and deceleration control principle is applied to plan the final velocity of the first line segment in the look-ahead buffer. In the process of processing continuous small line segments, the final velocity value of the previous line segment is the initial velocity value of the next line segment. After the final velocity planning of the first line segment in the look-ahead buffer is completed, the first line segment in the buffer exits, and the line segment exits the buffer. The system completes the real-time feeding process for this line segment. The N+1th line segment enters the look-ahead buffer, and the final velocity of the first line segment in the look-ahead buffer is continued to be planned. At this time, the initial velocity value of this line segment is the final velocity value of the previous line segment exiting the buffer. The amount of calculation of the system each time is very small, and the program running speed and real-time axial feed speed can be guaranteed through the design of the look-ahead module.

[0210] This process continues in this way until all line segment information is read into the look-ahead buffer, speed planning for all line segments is completed, and the speed of the last line segment is accurately reduced to 0.

[0211] Since continuous tiny line segments are processed, the speed increment of each line segment is very small. Each stage of the speed increase and decrease process is completed by a large number of small line segments to complete the speed connection work. The speed connection work is the focus of the speed processing module in the look-ahead control technology.

[0212] The speed processing of the look-ahead buffer module is to plan the final speed value of the next line segment based on the final speed value of the previous line segment. The look-ahead buffer must always ensure that the speed of the last line segment can be reduced to 0. There should be no sudden changes in speed during the speed planning process to maintain speed continuity.

[0213] The speed planning process is as follows: Figure 5 As shown, first, the buffer reads the line segment information, and reads the initial velocity value and line segment information of the first line segment in the buffer.

[0214] Secondly, based on the read speed value and the previous speed plan, determine whether it is in the acceleration stage, uniform speed stage or deceleration stage. If it is in the acceleration stage, compare it with the maximum feed speed v1 in the acceleration stage, the maximum feed speed v2 in the uniform acceleration stage, and the maximum feed speed v3 in the deceleration stage to determine which acceleration stage of the S-type acceleration and deceleration control it is in.

[0215]

[0216] v2=v1+j max T1T2

[0217]

[0218] If it is in the deceleration stage, compare it with the minimum feed speed v5 of the acceleration and deceleration stage, the minimum feed speed v6 of the uniform deceleration stage, and the minimum feed speed v7 of the deceleration stage to determine which deceleration stage it belongs to.

[0219]

[0220] v6=v5-j max T5T6

[0221]

[0222] Finally, speed planning is done through speed formulas at different stages. The specific planning procedures are described in detail below. In addition, the feed speed value during speed planning should not exceed the maximum axial feed speed allowed by the system. If the planned speed is greater than the maximum feed speed, the maximum axial feed speed value allowed by the system is used. v4 is the feed speed in the uniform speed stage. Generally, v3 and v4 are equal.

[0223] The process of judging which large line segment the reference arm is in at a certain moment, the acceleration stage, the uniform speed stage or the deceleration stage:

[0224] The first step is to assume that the line is in the acceleration phase after reading the initial velocity of the first line segment, and compare the initial velocity with v1, v2, and v3 to determine which stage of the acceleration phase it belongs to, and perform acceleration processing according to the velocity formula of the corresponding stage;

[0225] The second step is to determine whether the speed after acceleration can meet the requirement of reducing the speed to 0 through the small line segment in the look-ahead buffer; if the speed can be reduced to 0, it is in the acceleration stage; if the speed cannot be reduced to 0, it is in the uniform speed stage or the deceleration stage;

[0226] The third step is to further determine whether it is in the uniform speed stage or the deceleration stage if it is in the non-acceleration stage. If the initial speed of the first line segment in the look-ahead buffer is maintained and the line moves uniformly to the end of the first line segment, and the remaining small line segments in the look-ahead buffer can be decelerated to 0, then it is in the uniform speed stage; if it cannot be decelerated to 0, then it is in the deceleration stage.

[0227] As for how to judge whether the requirement of speed reduction to 0 can be met, it can be judged by calculating and comparing the feed speed formula in the deceleration stage.

[0228] After determining whether the vehicle is in the acceleration phase, the uniform speed phase, or the deceleration phase, the speed planning process steps for the specific phase are as follows:

[0229] First, calculate the feed time and feed speed of the first small line segment according to the initial speed;

[0230] Second, the feeding time of the second line segment is calculated according to the feeding speed of the first small line segment, and the feeding speed of the second line segment is calculated according to the feeding time of the second line segment;

[0231] Third, calculate the feed time and feed speed of subsequent line segments in sequence;

[0232] Fourth, the feed rate of the last line segment is compared and corrected with the maximum feed rate or the minimum feed rate of the current stage.

[0233] The feed speed planning at different stages is as follows:

[0234] The first is the acceleration phase, which is divided into the acceleration phase, the uniform acceleration phase and the deceleration phase. The speed planning of each specific phase is as follows:

[0235] 1. Acceleration phase:

[0236] Starting from the first line segment, we first determine that it is in the acceleration stage, and then start speed planning. The feed time t of the first line segment is calculated by the following formula: 11 :

[0237]

[0238] Where S x is the length of the continuous small line segment, and the feed speed v of the first line segment is calculated. 11 :

[0239]

[0240] Then, calculate the feed time t of the second small line segment 12 and feed speed v 12 :

[0241]

[0242]

[0243] And so on, the feed speed v of the subsequent small line segment is calculated 13 、v 14 ,...,v 1a

[0244] In the actual feeding process, it is inevitable that there will be an error between the actual feeding speed and the theoretical feeding speed, and the occurrence of this error will reduce the feeding accuracy. In order to improve the feeding accuracy, it is necessary to correct the feeding position of each stage. Specifically, the final speed of each small stage in each large stage (acceleration stage, uniform speed stage and deceleration stage) is assigned a value correction. The details are as follows:

[0245] When v 1a ≥v1, if v 1a =v1, no speed correction is required.

[0246] If v 1a >v1, in order to avoid the accumulation of errors and ensure the final position accuracy, it is necessary to adjust v 1a Speed ​​correction.

[0247] Simply assign v1 to v 1a This is obviously undesirable and will lead to displacement errors. Here, v1 is assigned the value v 1aAt the same time, in order to ensure the accuracy of displacement, the acceleration value and feed time of the current segment need to be corrected. The proportional coefficients k1 and k2 are introduced here. The specific solution is as follows:

[0248]

[0249] Except for k1 and k2, all other variables are known. By solving the values ​​of variables k1 and k2, v1 is assigned to v. 1a By correcting the jerk and feed time, and ensuring the accuracy of displacement, the accuracy of the axial feed of the reference arm device is ensured. At this point, the speed planning of the jerk stage is completed. When the speed reaches v1, the system determines that it has entered the uniform acceleration stage.

[0250] 2. Uniform acceleration stage:

[0251] v1 is the starting speed of the uniform acceleration stage. Continue to plan the speed of the buffer segment. The maximum feed speed v2 in the uniform acceleration stage. First, calculate the feed time t of the first segment in the uniform acceleration stage. 21 :

[0252]

[0253] Secondly, calculate the feed speed v of the first line segment in the uniform acceleration stage 21 :

[0254] v 21 =v1+j max T1t 21

[0255] Next, calculate the feed time t of the second line segment in the uniform acceleration phase 22 and feed speed v 22 :

[0256]

[0257] v 22 =v 21 +j max T1t 22

[0258] Calculate v in the same way 23 、v 24 ,...,v 2b .

[0259] Finally, the accuracy of the feed position is corrected by correcting the final velocity in the uniform acceleration stage:

[0260] When v 2b ≥v2, if v 2b = v2, no need to correct the speed, if v 2b>v2, in order to avoid the accumulation of errors and ensure the final position accuracy, it is necessary to adjust v 2b Speed ​​correction.

[0261] Proportional coefficients k3 and k4 are introduced here to correct the speed of the last line segment in the uniform acceleration stage.

[0262]

[0263] In the formula, except for k3 and k4, all other variables are known. By solving the values ​​of variables k3 and k4, v2 is assigned to v. 2b By correcting the jerk and feed time, the accuracy of the displacement is guaranteed, and the accuracy of the axial feed of the reference arm device is guaranteed. At this point, the speed planning of the jerk stage is completed.

[0264] 3. Deceleration and acceleration stage:

[0265] The deceleration and acceleration phase starts with v2 as the starting speed, plans the speed of the small line segment, and the maximum feed speed v3 in the deceleration and acceleration phase. First, calculate the feed time t of the first small line segment in the deceleration and acceleration phase. 31 :

[0266]

[0267] Secondly, calculate the feed speed v of the first small line segment in the deceleration phase 31 :

[0268]

[0269] Next, calculate the feed time t of the second line segment in the deceleration phase 32 and feed speed v 32 :

[0270]

[0271]

[0272] Calculate v in the same way 33 、v 34 ,...,v 3c

[0273] Finally, the accuracy of the feed position is corrected by correcting the final velocity in the deceleration phase:

[0274] When v 3c ≥v3, if v 3c = v3, no need to correct the speed, if v 3c >v3, in order to avoid the accumulation of errors and ensure the final position accuracy, it is necessary to adjust v 3c Speed ​​correction.

[0275] Proportional coefficients k5 and k6 are introduced here to correct the speed of the last line segment in the uniform acceleration stage.

[0276]

[0277] In the formula, except for k5 and k6, all other variables are known. By solving the values ​​of variables k5 and k6, v3 is assigned to v 3c By correcting the jerk and feed time and ensuring the accuracy of the displacement, the accuracy of the axial feed of the reference arm device is guaranteed. At this point, the speed planning of the deceleration stage is completed.

[0278] At this point, the speed planning of the three processes in the acceleration stage is completed, and the speed completes the precise connection process. If there is a uniform speed stage, continue to plan the uniform speed stage. If there is no uniform speed stage, deceleration is performed at the maximum axial feed speed v3.

[0279] Speed ​​planning in the uniform speed phase:

[0280] Since the speed is constant in the uniform speed stage, which is the maximum axial feed speed v3 obtained at the end of the acceleration stage, the entire uniform speed stage is fed at this speed.

[0281] Speed ​​planning for deceleration phase planning:

[0282] The deceleration phase includes the acceleration and deceleration phase, the uniform deceleration phase, and the deceleration and acceleration phase. The speed planning of the deceleration process is a mirror image of the speed planning of the acceleration phase. The details are as follows:

[0283] Acceleration and deceleration phases:

[0284] The initial speed of the acceleration and deceleration stage is v4, and the minimum feed speed is v5. First, the feed time t of the first line segment in the acceleration and deceleration stage is calculated according to the following formula 51 :

[0285]

[0286] Secondly, the feed speed v of the first line segment is calculated by the following formula: 51 :

[0287]

[0288] Again, the feed time t of the second line segment is calculated by the following formula: 52 and feed speed v 52 :

[0289]

[0290]

[0291] Calculate v in the same way 53 、v 54 ,...,v 5d ;

[0292] Finally, the accuracy of the feed position is corrected by correcting the final speed of the acceleration and deceleration stage:

[0293] When v5≤v 5d There is no need to correct the feed speed;

[0294] When v5>v 5d When , the proportional coefficients k7 and k8 are introduced, and the proportional coefficients k7 and k8 are calculated according to the following formula:

[0295]

[0296] In the formula, v 5d-1 is the feed rate of the segment before line segment 5d; except for k7 and k8, all other variables are known. By solving the values ​​of variables k7 and k8, v5 is assigned to v 5d , the final velocity of this section of axial displacement is corrected to ensure the accuracy of the displacement and the accuracy of the axial feed of the reference arm device. At this point, the speed planning of the acceleration and deceleration stage is completed.

[0297] Uniform deceleration stage:

[0298] The initial speed of the uniform deceleration stage is v5, and the minimum feed speed is v6. First, the feed time t of the first line segment in the uniform deceleration stage is calculated according to the following formula 61 :

[0299]

[0300] Secondly, the feed speed v of the first line segment is calculated by the following formula: 61 :

[0301] v 61 =v5-j max T5t 61

[0302] Again, the feed time t of the second line segment is calculated by the following formula: 62 and feed speed v 62 :

[0303]

[0304] v 62 =v 61 -j max T5t 62

[0305] Calculate v in the same way63 、v 64 ,...,v 6e ;

[0306] Finally, the final velocity of the uniform deceleration stage is corrected to achieve the correction of the feed position accuracy:

[0307] When v6≤v 6e There is no need to correct the feed speed;

[0308] When v6>v 6e When the proportional coefficients k9 and k 10 , and calculate the proportional coefficients k9 and k according to the following formula 10 :

[0309]

[0310] In the formula, v 6e-1 is the feed rate of the first segment of line segment 6e; except for k9, k 10 , are all known quantities. By solving the variables k9 and k 10 Assign v6 to v 6e , the final velocity of this section of axial displacement is corrected to ensure the accuracy of the displacement and the accuracy of the axial feed of the reference arm device. At this point, the speed planning of the uniform deceleration stage is completed.

[0311] Deceleration phase:

[0312] The initial speed of the deceleration stage is v6, and the minimum feed speed is v7. First, the feed time t of the first line segment in the deceleration stage is calculated according to the following formula 71 :

[0313]

[0314] Secondly, the feed speed v of the first line segment is calculated by the following formula: 71 :

[0315]

[0316] Again, the feed time t of the second line segment is calculated by the following formula: 72 and feed speed v 72 :

[0317]

[0318]

[0319] Calculate v in the same way 73 、v 74 ,...,v 7f ;

[0320] Finally, the final speed of the deceleration stage is corrected according to the following rules to calibrate the accuracy of the feed position:

[0321] When v7≤v 7f There is no need to correct the feed speed;

[0322] When v7>v 7f When the proportionality coefficient k is introduced 11 , k 12 , and calculate the proportionality coefficient k according to the following formula 11 , k 12 :

[0323]

[0324] In the formula, v 7f-1 is the feed rate of the first segment of line segment 7f; except k 11 , k 12 , are all known quantities, and by solving the variable k 11 , k 12 Assign v7 to v 7f , the final speed of this section of axial displacement is corrected to ensure the accuracy of the displacement and the accuracy of the axial feed of the reference arm device. At this point, the speed planning of the deceleration stage is completed.

[0325] Through the above process, the reading, speed processing and feeding process of continuous tiny line segments are completed, so that the reference arm device can reach the equal optical path position point at high speed and high precision, and generate high-quality human eye images.

[0326] For further explanation, an exemplary case is used to illustrate the adjustment process of the entire OCT reference arm:

[0327] (1) The optical path length of the reference beam and the sample beam is measured by the optical path length measurement device provided by the OCT, and the axial feed distance of this stage is calculated to be 100 mm by the device software provided by the OCT;

[0328] (2) The OCT device interpolates the axial feed distance of 100 mm into small line segments of 10 μm by using the interpolation technology loaded into the system, totaling 10,000 small line segments;

[0329] (3) Based on the maximum axial acceleration allowed by the system, the maximum axial jerk, the maximum axial feed speed allowed by the system, and other technical parameters preset by specific working conditions or the equipment itself, calculate the minimum distance L required to achieve the maximum axial feed speed allowed by the system. min , and use the minimum distance L min Determine whether there is a uniform speed stage; the result of the determination is that there is a uniform speed stage;

[0330] (4) Using the maximum axial feed speed v allowed by the system max The forward-looking segment N is determined by calculation using the formula, and the forward-looking segment number N is determined to be 100;

[0331] (5) The forward-looking buffer module starts to read the information of the first line segment and determines through calculation that it is in the acceleration phase (the first line segment is the initial line segment and the speed is 0); after the judgment is completed, the final speed of the first line segment is planned according to the formula;

[0332] (6) After the final velocity planning of the first line segment is completed, the first line segment exits the look-forward buffer, the 101st line segment enters the look-forward buffer, and the reference arm completes the feeding of the first line segment;

[0333] (7) The forward-looking buffer module continues to plan the speed of the first line segment in the buffer. At this time, the first line segment in the forward-looking buffer is the second of all line segments, and the final speed of the second line segment is planned with the final speed of the first line segment as its initial speed. After the final speed planning of the second line segment is completed, the second line segment exits the forward-looking buffer, and the 102nd line segment enters the forward-looking buffer. At the same time, the reference arm completes the feeding of the second line segment. Similarly, according to the planning information of each stage obtained by the S-type addition and subtraction control technology, the speed planning and feeding of each line segment are continuously and uninterruptedly completed from the acceleration stage to the deceleration stage, until the 10,000th line segment exits the forward-looking buffer to complete the speed planning and feeding process of the axial feeding, thereby completing the adjustment of the reference arm this time;

[0334] (8) When readjustment is required, the optical path measurement device of the OCT device measures the axial displacement again, and then readjusts according to the above steps.

[0335] The above method can ensure the accuracy of the reference arm position and fully reduce the impact of acceleration and speed changes during acceleration and deceleration by successively planning and real-time feeding of continuous tiny line segments after interpolation, eliminating the tedious automatic compensation process, and realizing fast and precise adjustment of the reference arm device, providing a good foundation for the acquisition of high-quality images.

[0336] Although the present invention has been disclosed as above in the preferred embodiment, it is not intended to limit the present invention. Anyone familiar with this technology can make various changes and modifications without departing from the spirit and scope of the present invention. Therefore, the scope of protection of the present invention should be based on the definition of the claims.

Claims

1. A method for rapid adjustment of an ophthalmic OCT reference arm based on microcontroller technology, characterized in that: Here are the steps: S1: Measure the optical path length of the sample beam and the reference beam through the optical path measurement device, and the optical path difference is the axial feed displacement; S2: Use interpolation technology to interpolate the axial feed displacement of the reference arm into continuous tiny line segments; S3: using the forward-looking control technology and S-type acceleration and deceleration control technology to dynamically process the continuous tiny line segments and perform speed planning, and after each tiny line segment is planned, the reference arm is controlled in real time to feed the tiny line segment until the axial displacement feeding is completed; The process of processing and speed planning of continuous small line segments using forward-looking control technology is as follows: S31: According to the maximum axial feed speed v that can be achieved max Determine the number of forward-looking segments N; S32: Reading the line segment information from the first segment to the Nth segment through the forward-looking buffer module, and completing the speed planning of the first line segment in the forward-looking buffer; S33: After the first line segment is planned, the forward buffer is exited, and the N+1th line segment enters the buffer. The speed planning of the first line segment in the buffer is continued, and so on, until all the line segments are read into the forward buffer. When there are no line segments that can be read into the buffer, the forward buffer spits out the line segments whose speed planning has been completed in sequence, until all the line segments have exited the forward buffer; The process of determining the number of forward-looking segments N is as follows: S311: Calculate the maximum axial feed speed v that can be achieved max The minimum distance L min Among them, L min It is the sum of the minimum acceleration distance and the minimum deceleration distance. The minimum distance L min The calculation formula is: In the formula, the initial velocity v s and final velocity v e Both are 0, v max The value is the maximum axial feed speed allowed by the system; S312: Compare the axial displacement L of the reference arm with the minimum distance L min Compare and determine whether there is a uniform speed stage. The judgment formula is as follows: When L>L min When , there is a uniform speed stage; When L≤L min There is no uniform speed stage. When there is no uniform speed stage, the maximum axial feed speed v that can be achieved max The calculation formula is: S313: Based on the maximum achievable axial feed speed v max The forward-looking segment number N is calculated and the calculation formula for the forward-looking segment number is as follows: In the formula, S a is the displacement in the acceleration stage, L x is the length of the pre-set small line segment after interpolation, N is rounded up; when there is a uniform speed stage, v max is the maximum axial feed speed allowed by the system. When there is no uniform speed stage, v max is the maximum axial feed speed actually achieved.

2. The method for rapid adjustment of an ophthalmic OCT reference arm based on microcontroller technology according to claim 1, characterized in that: The tiny line segments are micrometer-scale line segments.

3. The method for rapid adjustment of an ophthalmic OCT reference arm based on microcontroller technology according to claim 1, characterized in that: The S-type acceleration and deceleration control technology described in step S3 divides the axial displacement of the reference arm into 6 or 7 stages, namely, acceleration stage T1, uniform acceleration stage T2, deceleration stage T3, uniform speed stage T4, acceleration and deceleration stage T5, uniform deceleration stage T6, and deceleration and deceleration stage T7. When the axial feed distance is too short, there is no uniform speed stage T4. The time calculation formula for each stage is: <h2 style=";text-align:left;direction:ltr">T1 = f3 = T5 = T7 = a<h2 style=";text-align:left;direction:ltr"> max <h2 style=";text-align:left;direction:ltr"> / j<h2 style=";text-align:left;direction:ltr"> max Where: a max is the maximum axial acceleration allowed by the system, j max is the maximum axial acceleration allowed by the system, v max is the maximum axial feed speed that can be achieved. When there is a uniform speed stage, v max is the maximum axial feed speed allowed by the system. When there is no uniform speed stage, v max is the maximum axial feed speed actually achieved; v s , v e They are the initial velocity and the final velocity, both of which are 0. The uniform speed stage time T4 can be obtained by the acceleration stage displacement S a , deceleration stage displacement S d The total displacement L and the maximum axial feed speed v that can be achieved max Find out the relationship.

4. The method for rapid adjustment of an ophthalmic OCT reference arm based on microcontroller technology according to claim 1, characterized in that: During speed planning in step S33, the final speed of the previous line segment is the initial speed of the next line segment, and the initial speed of the first line segment and the final speed of the last line segment are both 0.

5. The method for rapid adjustment of an ophthalmic OCT reference arm based on microcontroller technology according to claim 1, characterized in that: Before speed planning, the look-ahead buffer module reads the line segment information and speed information; determines whether it is in the acceleration phase, the uniform speed phase, or the deceleration phase; the calculation formula for the speed limit value in the acceleration phase is: <h2 style=";text-align:left;direction:ltr">v2 = v1 + j<h2 style=";text-align:left;direction:ltr"> max <h2 style=";text-align:left;direction:ltr"> T1T2 Wherein, v1 is the maximum feed speed in the acceleration stage, v2 is the maximum feed speed in the uniform acceleration stage, and v3 is the maximum feed speed in the deceleration stage; The speed calculation formula in the uniform speed stage is: v4=v3 The calculation formula for the speed limit value in the deceleration stage is: v6=v5-j max T5T6 In the formula, v5 is the minimum feed speed in the acceleration and deceleration stage, v6 is the minimum feed speed in the uniform deceleration stage, and v7 is the minimum feed speed in the deceleration stage; The actual speed value during speed planning should not be greater than the maximum axial feed speed v that can be achieved max ; When it is greater than the maximum axial feed speed, the actual speed is taken as the maximum axial feed speed v that can be achieved max .

6. The method for rapid adjustment of an ophthalmic OCT reference arm based on microcontroller technology according to claim 5, characterized in that: After determining whether the vehicle is in the acceleration phase, the uniform speed phase, or the deceleration phase, the speed planning process steps for the specific phase are as follows: First, calculate the feed time and feed speed of the first small line segment according to the initial speed; Second, the feeding time of the second line segment is calculated according to the feeding speed of the first small line segment, and the feeding speed of the second line segment is calculated according to the feeding time of the second line segment; Third, calculate the feed time and feed speed of subsequent line segments in sequence; Fourth, the feed rate of the last line segment is compared and corrected with the maximum feed rate or the minimum feed rate of the current stage.

7. The method for rapid adjustment of an ophthalmic OCT reference arm based on microcontroller technology according to claim 6, characterized in that: After the acceleration phase is determined, the specific speed planning process of each phase in the acceleration phase is as follows: Acceleration phase: First, the feed time t of the first small line segment is calculated by the following formula: 11 : In the formula, S x is the length of the continuous tiny line segment; Secondly, the reference arm feed speed v of the first small line segment is calculated by the following formula: 11 : Again, the feed time t of the second small line segment is calculated and obtained by the following formula: 12 and the feed speed v of the reference arm 12 : And so on, the feed speed v of the reference arm in the subsequent small line segment is calculated 13 、v 14 ,...,v 1a ; Finally, the final velocity of the acceleration phase is corrected according to the following rules to ensure the accuracy of the displacement: When v 1a When ≤v1, there is no need to correct the feed speed; When v 1a When >v1, the proportional coefficients k1 and k2 are calculated according to the following formula: In the formula, v 1a-1 is the feed rate of the previous segment of line segment 1a; except for k1 and k2, all other variables are known. By solving the values ​​of variables k1 and k2, v1 is assigned to v 1a , the final velocity of the axial displacement of this section is corrected to ensure the accuracy of the displacement and the accuracy of the axial feed of the reference arm device. At this point, the velocity planning of the acceleration stage is completed; Uniform acceleration stage: The initial speed in the uniform acceleration stage is v1, and the maximum feed speed is v2. First, the feed time t of the first line segment in the uniform acceleration stage is calculated according to the following formula: 21 : Secondly, the feed speed v of the first line segment is calculated by the following formula: 21 : v 21 =v1+j max T1t 21 Again, the feed time t of the second line segment is calculated by the following formula: 22 and feed speed v 22 : v 22 =v 21 +j max T1t 22 Calculate v in the same way 23 、v 24 ,...,v 2b ; Finally, the final velocity of the uniform acceleration stage is corrected according to the following rules to ensure the accuracy of the displacement: When v 2b When ≤v2, there is no need to correct the feed speed; When v 2b When >v2, the proportional coefficients k3 and k4 are introduced and calculated according to the following formula: In the formula, v 2b-1 is the feed rate of the first segment of line segment 2b; except for k3 and k4, all other variables are known. By solving the values ​​of variables k3 and k4, v2 is assigned to v 2b , the final velocity of the axial displacement of this section is corrected to ensure the accuracy of the displacement and the accuracy of the axial feed of the reference arm device. At this point, the velocity planning of the uniform acceleration stage is completed; Deceleration phase: The initial speed of the deceleration and acceleration phase is v2, and the maximum feed speed is v3. First, the feed time t of the first line segment of the deceleration and acceleration phase is calculated according to the following formula: 31 : Secondly, calculate the feed speed v of the first line segment in the deceleration phase according to the following formula: 31 : Next, calculate the feed time t of the second line segment in the deceleration phase 32 and feed speed v 32 : Calculate v in the same way 33 、v 34 ,...,v 3c ; Finally, the final velocity of the deceleration phase is corrected according to the following rules to ensure the accuracy of the displacement: When v 3c When ≤v3, there is no need to correct the feed speed; When v 3c When >v3, the proportional coefficients k5 and k6 are introduced and calculated according to the following formula: In the formula, v 3c-1 is the feed rate of the first segment of line segment 3c; except for k5 and k6, all other variables are known. By solving the values ​​of variables k5 and k6, v3 is assigned to v 3c By correcting the deceleration and feed time, the accuracy of the displacement and the axial feed of the reference arm device are guaranteed. At this point, the speed planning of the deceleration stage is completed.

8. The method for rapid adjustment of an ophthalmic OCT reference arm based on microcontroller technology according to claim 6, characterized in that: After the deceleration stage is determined, the specific speed planning process of each stage in the deceleration stage is as follows: Acceleration and deceleration phases: The initial speed of the acceleration and deceleration stage is v4, and the minimum feed speed is v5. First, the feed time t of the first line segment in the acceleration and deceleration stage is calculated according to the following formula 51 : Secondly, the feed speed v of the first line segment is calculated by the following formula: 51 : Again, the feed time t of the second line segment is calculated by the following formula: 52 and feed speed v 52 : Calculate v in the same way 53 、v 54 ,...,v 5d ; Finally, the final velocity of the acceleration and deceleration stage is corrected according to the following rules to ensure the accuracy of the displacement: When v5≤v 5d There is no need to correct the feed speed; When v5>v 5d When , the proportional coefficients k7 and k8 are introduced, and the proportional coefficients k7 and k8 are calculated according to the following formula: In the formula, v 5d-1 is the feed rate of the segment before line segment 5d; except for k7 and k8, all other variables are known. By solving the values ​​of variables k7 and k8, v5 is assigned to v5 d , the final speed of the axial displacement of this section is corrected to ensure the accuracy of the displacement and the accuracy of the axial feed of the reference arm device. At this point, the speed planning of the acceleration and deceleration stage is completed; Uniform deceleration stage: The initial speed of the uniform deceleration stage is v5, and the minimum feed speed is v6. First, the feed time t of the first line segment in the uniform deceleration stage is calculated according to the following formula 61 : Secondly, the feed speed v of the first line segment is calculated by the following formula: 61 : in 61 =v5-j max T5t 61 Again, the feed time t of the second line segment is calculated by the following formula: 62 and feed speed v 62 : in 62 =in 61 -j max T5t 62 Calculate v in the same way 63 、v 64 ,...,v 6e ; Finally, the final velocity of the uniform deceleration stage is corrected according to the following rules to ensure the accuracy of the displacement: When v6≤v6e, there is no need to correct the feed speed; When v6>v 6e When the proportional coefficients k9 and k 10 , and calculate the proportional coefficients k9 and k according to the following formula 10 : In the formula, v 6e-1 is the feed rate of the first segment of line segment 6e; except for k9, k 10 , are all known quantities. By solving the variables k9 and k 10 Assign v6 to v 6e , the final speed of the axial displacement of this section is corrected to ensure the accuracy of the displacement and the accuracy of the axial feed of the reference arm device. At this point, the speed planning of the uniform deceleration stage is completed; Deceleration phase: The initial speed of the deceleration stage is v6, and the minimum feed speed is v7. First, the feed time t of the first line segment in the deceleration stage is calculated according to the following formula 71 : Secondly, the feed speed v of the first line segment is calculated by the following formula: 71 : Again, the feed time t of the second line segment is calculated by the following formula: 72 and feed speed v 72 : Calculate v in the same way 73 、v 74 ,...,v 7f ; Finally, the final velocity of the deceleration stage is corrected according to the following rules to ensure the accuracy of the displacement: When v7≤v 7f There is no need to correct the feed speed; When v7>v 7f When the proportionality coefficient k is introduced 11 , k 12 , and calculate the proportionality coefficient k according to the following formula 11 , k 12 : In the formula, v 7f-1 is the feed rate of the first segment of line segment 7f; except k 11 , k 12 , are all known quantities, and by solving the variable k 11 , k 12 Assign v7 to v 7f , the final speed of this section of axial displacement is corrected to ensure the accuracy of the displacement and the accuracy of the axial feed of the reference arm device. At this point, the speed planning of the deceleration stage is completed.