Motor control method, nucleic acid detection equipment and storage medium
Compensation signal is calculated through the photoelectric encoder feedback signal, which solves the problem of motor failure in the nucleic acid detection equipment, ensures that the motor accurately drives the mechanism to the designated position, prevents equipment from being damaged, and improves the reliability and stability of the equipment.
Patent Information
- Application Number
- CN202311871777.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-12-29
- Publication Date
- 2025-07-01
AI Technical Summary
As the motor of the nucleic acid detection equipment increases, the motion resistance increases, causing the motor to lose steps and cannot accurately drive the mechanism to the designated position, which may cause internal motion interference and equipment damage.
Through the feedback signal of the photoelectric encoder, the detection signal after the motor movement is obtained, and the compensation signal is calculated to control the motor to perform position compensation action to ensure that the motor is accurately driven to the specified position.
It realizes the accuracy of motor movement, prevents internal motion interference of equipment, reduces equipment damage, and improves the reliability and stability of nucleic acid detection equipment.
Smart Images

Figure CN120238012A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the technical field of medical device control, and particularly relates to a control method for a motor, a nucleic acid detection device, and a storage medium. Background Art
[0002] In the prior art, as the service life of the transmission device of the nucleic acid detection device increases, the movement resistance may become larger, which may cause the motor to lose steps. The motor losing steps will cause the motor to be unable to accurately drive the mechanism to move to the specified position.
[0003] The nucleic acid detection device is usually small in size. When the motor is unable to accurately drive the mechanism to reach the specified position, it may cause internal movement interference and continuous transmission obstruction. If it cannot be adjusted or repaired in time, it may damage the whole nucleic acid detection device. Summary of the Invention
[0004] The purpose of the present invention is to provide a control method for a motor, a nucleic acid detection device, and a storage medium, so as to perform compensation adjustment on the motor after the motor movement is completed, making the motor movement more accurate.
[0005] To achieve the above purpose, the first aspect of the present invention provides a control method for a motor, which is applied to a nucleic acid detection device. The nucleic acid detection device includes a motor and an optical encoder installed on the motor. The control method includes the following steps:
[0006] Obtain a control instruction for the motor;
[0007] Determine a target drive signal for the motor according to the control instruction;
[0008] Send the target drive signal to the motor to control the motor to start;
[0009] When the motor movement ends, obtain a first detection signal fed back by the optical encoder;
[0010] Determine a compensation signal for the motor according to the first detection signal and the target drive signal;
[0011] Control the motor to perform a position compensation action according to the compensation signal.
[0012] In some embodiments, the step of determining the compensation signal for the motor according to the first detection signal and the target drive signal includes: determining a third rotation amount corresponding to the first detection signal and a fourth rotation amount corresponding to the target drive signal; determining a second rotation difference between the third rotation amount and the fourth rotation amount; determining a compensation signal amount according to the second rotation difference, and further determining the compensation signal.
[0013] In some embodiments, the steps of controlling the motor to perform a position compensation action according to the compensation signal include: when the third rotation amount is less than the fourth rotation amount, controlling the motor to rotate in the rotation direction at startup; when the third rotation amount is greater than the fourth rotation amount, controlling the motor to rotate in the direction opposite to the rotation direction at startup.
[0014] In some embodiments, the control method further includes the following steps: after the motor completes the position compensation action, obtaining a second detection signal detected by the optical encoder; when the fifth rotation amount corresponding to the second detection signal is not equal to the first rotation amount corresponding to the target drive signal, controlling the motor to perform the position compensation again until the rotation amount corresponding to the detection signal detected by the optical encoder is equal to the first rotation amount.
[0015] In some embodiments, the control method further includes the following steps: after the motor starts, at each preset time period, obtaining the current drive signal of the motor and the current detection signal fed back by the optical encoder; determining the first rotation amount corresponding to the current drive signal and the second rotation amount corresponding to the current detection signal; determining the first rotation difference between the first rotation amount and the second rotation amount; when the absolute value of the first rotation difference is greater than the preset threshold for a continuous preset number of times, controlling the nucleic acid detection device to give a position deviation alarm.
[0016] In some embodiments, the steps of controlling the nucleic acid detection device to give a position deviation alarm when the absolute value of the first rotation difference is greater than the preset threshold for a continuous preset number of times include: when the absolute value of the first rotation difference is greater than the preset threshold, increasing the count of the deviation warning number; when the absolute value of the first rotation difference is less than the preset threshold, clearing the count of the deviation warning number; when the cumulative count of the deviation warning number is greater than or equal to the preset value, controlling the nucleic acid detection device to give an alarm.
[0017] In some embodiments, the control method further includes the following steps: when the absolute value of the first rotation difference is greater than the preset threshold for a continuous preset number of times, controlling the motor to reset and restart.
[0018] In some embodiments, the nucleic acid detection device further includes a reagent cartridge and a position detection component. The reagent cartridge is drivingly connected to the motor, and the position detection component is used to detect the position of the reagent cartridge. The control method further includes the following steps: after the motor completes the position compensation action, obtaining a first position signal sent by the position detection component; determining whether the reagent cartridge moves abnormally according to the control instruction and the first position signal; when the reagent cartridge moves abnormally, controlling the nucleic acid detection device to give an alarm.
[0019] In some embodiments, the nucleic acid detection device further includes a pipetting mechanism. The pipetting mechanism includes a pipetting pump. The pipetting mechanism is drivingly connected to the motor. The control method further includes the following steps: after the motor completes the position compensation action, control the pipetting pump to perform a pipetting operation; when the pipetting of the pipetting pump is abnormal, control the nucleic acid detection device to give an alarm.
[0020] A second aspect of the present invention provides a nucleic acid detection device, including: a motor, equipped with an optical encoder and a drive controller; and a processor configured to execute the above control method of the motor.
[0021] In some embodiments, the processor includes: an optical signal receiving module electrically connected to the optical encoder, and the optical signal receiving module is used to receive the detection signal fed back by the optical encoder.
[0022] A third aspect of the present invention provides a machine-readable storage medium, on which instructions are stored. It is characterized in that when the instructions are executed by the processor, the processor is configured to execute the above control method of the motor.
[0023] In the above technical solution, when controlling the motor, first obtain the control instruction of the motor, and determine the target drive signal of the motor according to the control instruction; secondly, send the target drive signal to the motor to control the motor to start; finally, after the motor stops moving to the theoretical target position, the first detection signal fed back by the optical encoder can be obtained, and it can be determined whether the motor needs to perform position compensation by comparing the first detection signal and the target drive signal; when compensation is required, control the motor to perform position compensation to prevent the mechanism driven by the motor from moving inaccurately due to reasons such as motor out-of-step.
[0024] Other features and advantages of the embodiments of the present invention will be described in detail in the subsequent specific embodiments section. BRIEF DESCRIPTION OF THE DRAWINGS
[0025] The drawings are used to provide a further understanding of the embodiments of the present invention, and constitute a part of the specification. Together with the following specific embodiments, they are used to explain the embodiments of the present invention, but do not constitute a limitation to the embodiments of the present invention. For those of ordinary skill in the art, other drawings can also be obtained based on the structures shown in these drawings without creative efforts. In the drawings:
[0026] Figure 1 is a flowchart of the control method of the motor according to an embodiment of the present invention;
[0027] Figure 2 is a schematic structural diagram of the nucleic acid detection device according to an embodiment of the present invention;
[0028] Figure 3Schematic diagram of steps for executing a sub - process of the control method of the motor.
[0029] Description of reference numerals
[0030] 1 Motor 2 Reagent cartridge
[0031] 3 Pipetting mechanism Detailed implementation manners
[0032] The following will describe in detail the specific implementation manners of the present invention with reference to the accompanying drawings. It should be understood that the specific implementation manners described herein are only for the purpose of illustrating and explaining the present invention, and are not used to limit the present invention.
[0033] As Figure 1 shown, it is a flowchart of the control method of the motor provided according to an embodiment of the present invention. As Figure 2 shown, it is a schematic diagram of an application scenario of the control method of the motor according to an embodiment of the present invention. The nucleic acid detection device includes a motor 1 and an encoder (not shown in the figure) installed on the motor 1. The encoder can detect the rotation angle of the motor 1 and send a first detection signal to the processor. The control method includes the following steps:
[0034] S101, Obtain the control instruction of the motor 1;
[0035] S102, Determine the target drive signal of the motor 1 according to the control instruction;
[0036] S103, Send the target drive signal to the motor 1 to control the motor 1 to start;
[0037] S104, When the movement of the motor 1 ends, obtain the first detection signal fed back by the optical encoder;
[0038] S105, Determine the compensation signal of the motor 1 according to the first detection signal and the target drive signal;
[0039] S106, Control the motor 1 to perform a position compensation action according to the compensation signal.
[0040] In an embodiment of the present invention, the processor is configured to execute the above-described control method of the motor, and the processor can receive external instructions and control the motor 1 to perform corresponding operations. When the processor receives a control instruction sent from the outside, it can determine the target drive signal of the motor 1 according to the control instruction. The target drive signal contains the target position information of the movement of the motor 1. When the motor 1 receives the target drive signal, it can rotate until the movement ends. During the operation of the motor 1, situations such as loss of step may occur due to excessive resistance, resulting in a position difference between the position after the movement ends and the position that is actually desired to move to. After the motor 1 stops at the theoretical target position, the processor can obtain the first detection signal detected by the optical encoder and determine whether there is a position difference between the position after the movement ends and the position that is actually desired to move to according to the first detection signal and the target drive signal. When there is a position difference, determine the compensation signal of the motor 1 according to the first detection signal and the target drive signal. Send the compensation signal to the motor 1 to control the motor 1 to perform a position compensation action, so that the motor 1 drives the mechanism of the nucleic acid detection device to the specified position.
[0041] By using the above-described control method of the motor, the movement position of the motor 1 is detected after the movement of the motor 1 is completed. When the motor 1 has an inaccurate movement situation, control the motor 1 to perform position compensation, so that the mechanism driven by the motor 1 can accurately move to the specified position.
[0042] In one embodiment, the control method further includes the following steps: after the motor 1 starts, at every preset time period, obtain the current drive signal of the motor 1 and the current detection signal feedback by the optical encoder; determine the first rotation amount corresponding to the current drive signal and the second rotation amount corresponding to the current detection signal; determine the first rotation difference between the first rotation amount and the second rotation amount; when the absolute value of the first rotation difference is greater than the preset threshold for a preset number of consecutive times, control the nucleic acid detection device to perform a position deviation alarm.
[0043] During the movement of the motor 1, it is possible that the deviation between the movement position of the motor 1 and the position it is expected to drive to is too large. In this case, the motor 1 may have a fault or the mechanism driven by the motor 1 may be stuck, and it is necessary to adjust or repair the motor 1 in time. After the motor 1 starts, the processor can obtain the current drive signal of the motor 1 and the current detection signal fed back by the photoelectric encoder at preset time intervals. During the movement of the motor 1, it is necessary to send the drive signal to the motor 1 in real time to make the motor 1 continue to move. The current detection signal is the running position of the motor 1 detected by the photoelectric encoder in real time, which can reflect the running position of the motor 1. After receiving the current drive signal and the current detection signal, the processor can determine the rotation amounts of the motor 1 corresponding to these two signals, which are the first rotation amount and the second rotation amount respectively. Compare the first rotation amount and the second rotation amount and determine the difference. When the absolute value of the difference is continuously greater than the preset threshold for multiple times, the motor 1 may have a fault, and the processor can control the motor 1 to alarm. Because signal transmission has a delay characteristic, there will be a difference in the time corresponding to the two signals. Therefore, the method of determining by multiple detections can reduce the misjudgment of the motor 1 caused by the time difference caused by signal transmission and affect the operation of the motor 1.
[0044] In a specific embodiment, as Figure 2 shown, the motor 1 drives a first lead screw (not shown in the figure) to move, and the first lead screw drives the reagent cartridge 2 of the nucleic acid detection device to move left and right. After the motor 1 starts, the current drive signal of the motor 1 and the current detection signal fed back by the photoelectric encoder are obtained every 10 ms, and the rotation amounts corresponding to the current drive signal and the current detection signal are compared. When the absolute value of the difference in the rotation amounts is continuously greater than the preset threshold for three times, it is determined that the motor 1 or the reagent cartridge 2 may have a fault during the movement, and the nucleic acid detection device is controlled to alarm to remind the user to adjust or repair in time.
[0045] In an embodiment, the control method further includes the following steps: when the absolute value of the first rotation difference is continuously greater than the preset threshold for a preset number of times, control the motor 1 to reset and restart. Because some mechanisms may affect the overall operation of the nucleic acid detection device after being stuck, when the absolute value of the first rotation difference is continuously greater than the preset threshold for a preset number of times, the motor 1 can be immediately controlled to reset to prevent accidents caused by continuous driving of the motor 1.
[0046] In a specific embodiment, as Figure 2As shown, the motor 1 drives the second lead screw (not shown in the figure) to move, and the second lead screw drives the pipetting mechanism 3 of the nucleic acid detection device to move up and down. After the motor 1 is started, the current drive signal of the motor 1 and the current detection signal fed back by the photoelectric encoder are acquired every 10 ms, and the rotation amounts corresponding to the current drive signal and the current detection signal are compared. When the absolute value of the difference in rotation amounts is continuously greater than the preset threshold three times, it is determined that a failure may occur to the motor 1 or the pipetting mechanism 3 during the movement. If continuous pressure is applied, it may cause continuous pressure between the pipetting interface and other mechanisms, resulting in damage to the pipetting interface. Therefore, when the absolute value of the difference in rotation amounts is continuously greater than the preset threshold three times, the motor 1 is immediately reset, and an alarm can be activated to notify the user to make timely adjustments and repairs.
[0047] In one embodiment, as Figure 3 shown, it is a schematic diagram of the steps of the sub-process for executing the control method of the motor. The control method further includes the following steps: After the motor 1 is started, at every preset time interval, the current drive signal of the motor 1 and the current detection signal fed back by the photoelectric encoder are acquired. Determine the first rotation amount corresponding to the current drive signal and the second rotation amount corresponding to the current detection signal. Determine the first rotation difference between the first rotation amount and the second rotation amount. When the absolute value of the first rotation difference is greater than the preset threshold, increase the count of the deviation warning number. When the absolute value of the first rotation difference is less than the preset threshold, clear the count of the deviation warning number. When the cumulative count of the deviation warning number is greater than or equal to the preset value, control the nucleic acid detection device to give an alarm. When the absolute value of the first rotation difference is continuously greater than the preset threshold a preset number of times, control the motor 1 to reset and restart.
[0048] In one embodiment, the step of determining the compensation signal of the motor 1 according to the first detection signal and the target drive signal includes: determining the third rotation amount corresponding to the first detection signal and the fourth rotation amount corresponding to the target drive signal; determining the second rotation difference between the third rotation amount and the fourth rotation amount; determining the compensation signal amount according to the second rotation difference, and further determining the compensation signal. After receiving the first detection signal, the processor can determine the third rotation amount corresponding to the first detection signal, or can also determine the corresponding fourth rotation amount according to the target drive signal, compare the third rotation amount and the fourth rotation amount. If the third rotation amount and the fourth rotation amount are equal, there is no need to supplement the motor 1. If the third rotation amount and the fourth rotation amount are not equal, determine the second rotation difference between the third rotation amount and the fourth rotation amount, determine the compensation signal amount according to the second rotation difference, and further determine the compensation signal. Subsequently, the compensation signal is sent to the motor 1 to make the motor 1 perform the position compensation action.
[0049] In one embodiment, the steps of controlling the motor 1 to perform a position compensation action according to the compensation signal include: when the third rotation amount is less than the fourth rotation amount, controlling the motor 1 to rotate in the rotation direction at startup; when the third rotation amount is greater than the fourth rotation amount, controlling the motor 1 to rotate in the direction opposite to the rotation direction at startup. When the third rotation amount is less than the fourth rotation amount, it means that the motor 1 does not rotate to the correct position, and the motor 1 can be controlled to rotate in the rotation direction at startup. It should be noted that when the third rotation amount is greater than the fourth rotation amount, it means that the motor 1 rotates excessively, and it needs to rotate in the direction opposite to the original rotation direction.
[0050] In one embodiment, the motor 1 further includes a drive controller, and the control method further includes the following steps: transmitting a target drive signal to the drive controller; when the transmission of the target drive signal fails, resending the target drive signal to the drive controller. The target drive signal needs to be transmitted to the drive controller. In the case of an abnormality in the drive controller or the transmission line, etc., the signal transmission may fail, and the processor can automatically resend the target drive signal to the drive controller to improve the operating efficiency of the motor 1.
[0051] In one embodiment, the control method further includes the following steps: after the motor 1 completes the position compensation action, obtaining a second detection signal detected by the optical encoder; when the fifth rotation amount corresponding to the second detection signal is not equal to the first rotation amount corresponding to the target drive signal, controlling the motor 1 to perform the position compensation again until the rotation amount corresponding to the detection signal detected by the optical encoder is equal to the first rotation amount. After the motor 1 completes one position compensation action, it is possible that the motor 1 still does not rotate to the position corresponding to the first rotation amount. Therefore, the second detection signal detected by the optical encoder can be obtained again, and the fifth rotation amount corresponding to the second detection signal can be determined. Comparing the fifth rotation amount and the first rotation amount, when the fifth rotation amount and the first rotation amount are not equal, controlling the motor 1 to perform the position compensation action again until the rotation amount corresponding to the detection signal detected by the optical encoder is equal to the first rotation amount. At this time, it can be determined that the motor 1 rotates to the correct position, and the motor 1 is no longer controlled to perform the position compensation action. In this embodiment, controlling the motor 1 to perform multiple compensation actions can further improve the accuracy of the motor 1 operation.
[0052] In a specific embodiment, the processor motor 1 drives the pipette pump of the nucleic acid detection device to move up and down. First, the processor obtains the control instruction for the motor 1 from the outside world, and determines the target drive signal of the motor 1 according to the control instruction. The target drive signal is sent to the motor 1 controller, so that the motor 1 rotates according to the target drive signal. If the transmission of the target drive signal fails, the target drive signal can be resent to the motor 1 controller. After the motor 1 starts, the current drive signal of the motor 1 and the current detection signal fed back by the photoelectric encoder are obtained every 10 ms, and the corresponding first rotation amount of the current drive signal and the corresponding second rotation amount of the current detection signal are determined. When the difference between the first rotation amount and the second rotation amount is greater than the preset threshold for three consecutive times, the nucleic acid detection device is controlled to alarm and the motor 1 is controlled to restart. Because the distance between the pipette joint controlled by the pipette pump and other mechanisms of the nucleic acid detection device is very small, if the motor 1 fails, the motor 1 should be immediately controlled to reset to prevent damage to the nucleic acid detection device. After the motor 1 moves to the theoretical target position, the first detection signal fed back by the photoelectric encoder can be obtained, the third rotation amount is determined according to the first detection signal, the fourth rotation amount is determined according to the target drive signal, the third rotation amount and the fourth rotation amount are compared, and when the two are not equal, the motor 1 is controlled to perform a position compensation action. After the motor 1 completes the position compensation action, the second detection signal detected by the photoelectric encoder is obtained, and it is determined whether the rotation of the motor 1 is in place according to the second detection signal.
[0053] In one embodiment, as Figure 2 shown, the nucleic acid detection device further includes a reagent cartridge 2 and a position detection component (not shown in the figure). The reagent cartridge 2 is drivingly connected to the motor 1. The position detection component is used to detect the position of the reagent cartridge 2. The control method further includes the following steps: after the motor 1 completes the position compensation action, the first position signal sent by the position detection component is obtained; whether the reagent cartridge 2 moves abnormally is determined according to the control instruction and the first position signal; when the reagent cartridge 2 moves abnormally, the nucleic acid detection device is controlled to alarm. In the embodiment of the present invention, the motor 1 drives the reagent cartridge 2 to move horizontally. After the motor 1 completes the position compensation action, the position detection component can detect the position of the reagent cartridge 2 to determine whether the reagent cartridge 2 moves to the specified position. Because when the motor 1 operates normally, the reagent cartridge 2 driven by the motor 1 may not move in place due to mechanical transmission errors, etc. Therefore, when the position detection component provided by the present invention detects the first position signal, it can be sent to the processor. The processor compares the first position signal with the control instruction, and the control instruction contains the target position information of the movement of the reagent cartridge 2. When it is determined that the reagent cartridge 2 moves abnormally, the nucleic acid detection device is controlled to alarm to remind the user to repair the mechanical failure of the reagent cartridge 2 in time. Among them, the position detection component can be an optical distance sensor, etc.
[0054] In one embodiment, asFigure 2 As shown, the nucleic acid detection device further includes a liquid transfer mechanism 3. The liquid transfer mechanism 3 includes a liquid transfer pump (not shown in the figure). The liquid transfer mechanism 3 is drivingly connected to the motor 1. The control method further includes the following steps: after the motor 1 completes the position compensation action, control the liquid transfer pump to perform a liquid transfer operation; when the liquid transfer of the liquid transfer pump is abnormal, control the nucleic acid detection device to alarm. When the motor 1 is operating normally, the liquid transfer mechanism 3 driven by the motor 1 may have abnormal movement. Therefore, it is necessary to detect the liquid transfer mechanism 3. The liquid transfer mechanism 3 can be used to transfer the liquid stored in the nucleic acid detection device. The liquid transfer mechanism 3 includes a liquid transfer pump, and the liquid transfer pump is a driving member that drives the liquid transfer mechanism 3 to pick up or discharge liquid. After the motor 1 completes the position compensation action, the processor can control the liquid transfer pump to perform a liquid transfer operation, where the liquid transfer operation is picking up or discharging liquid. When the liquid transfer operation of the liquid transfer pump is abnormal, the processor can determine that the liquid transfer mechanism 3 has abnormal movement and control the nucleic acid detection device to alarm.
[0055] By using the above control method of the motor, when the motor 1 has inaccurate rotational position due to reasons such as out-of-step, the motor 1 can be controlled to perform a position compensation operation, so that the motor 1 can drive the mechanism of the nucleic acid detection device more accurately and efficiently. And, by detecting the operating condition of the motor 1 in real time through the photoelectric encoder, when the motor 1 has an abnormal operation, an alarm can be given in time and the motor 1 can be controlled to reset to prevent the nucleic acid detection device from malfunctioning due to the continuous operation of the motor 1.
[0056] In one embodiment, a nucleic acid detection device is provided, including: a motor 1, equipped with a photoelectric encoder and a drive controller; and a processor configured to execute the above control method of the motor. Since this nucleic acid detection device adopts all the embodiments of the above control method of the motor, it has all the beneficial effects brought by the above control method of the motor, and will not be elaborated in detail here.
[0057] In one embodiment, the processor includes: a photoelectric signal receiving module electrically connected to the photoelectric encoder, and the photoelectric signal receiving module is used to receive the detection signal fed back by the photoelectric encoder.
[0058] In one embodiment, as Figure 2As shown in the figure, the control method of the motor in the present application is applied to a POCT nucleic acid detection automation device. The motor 1 drives the pipetting mechanism 3 to move up and down. The pipetting mechanism 3 includes a pipetting pump and a pipetting joint. The pipetting mechanism 3 moves downward into the reaction well of the reaction cartridge to pick up the pipette tip or perform a pipetting operation. If the reaction cartridge rotates inaccurately or the size error of the reaction cartridge is large, the pipetting joint cannot be aligned with the reaction well, and the pipetting joint will collide with the reaction cartridge when it moves downward, and the Z-direction pipetting motor 1 cannot work properly. Therefore, it is necessary to detect the movement of the motor 1 in real time and perform compensation after the movement of the motor 1 is completed. In the present invention, it can be determined whether the motor 1 fails or the pipetting joint collides with the reaction cartridge according to the current detection signal fed back by the photoelectric encoder and the current drive signal of the motor 1 in real time comparison. The processor can control the POCT nucleic acid detection automation device to alarm and reset the motor 1. When there is no abnormality or fault during the movement, after the motor 1 moves to the theoretical target position and stops, position compensation can be performed according to the control of the motor 1, so that the pipetting joint can accurately move to the specified height.
[0059] It should be noted that the motor 1 is a device that provides rotational driving force. It can be drivingly connected to the A mechanism to drive the A mechanism to move, or it can be disconnected from the A mechanism and drivingly connected to the B mechanism to drive the B mechanism to move. The number of motors 1 in the nucleic acid detection device of the present application can also be multiple to drive different mechanisms to move.
[0060] In one embodiment, a machine-readable storage medium is provided. The machine-readable storage medium stores instructions, and is characterized in that when the instructions are executed by a processor, the processor is configured to execute the above-mentioned control method of the motor.
[0061] Those skilled in the art should understand that the embodiments of the present application can be provided as a method, a system, or a computer program product. Therefore, the present application can take the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware aspects. Moreover, the present application can take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0062] This application is described with reference to the flowcharts and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the present application. It should be understood that each flow and / or block in the flowchart and / or block diagram can be implemented by computer program instructions, and the combination of flows and / or blocks in the flowchart and / or block diagram can also be implemented by computer program instructions. These computer program instructions can be provided to the processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing devices to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing devices generate a device for implementing the functions specified in one or more flows Figure 1 or more flows and / or blocks Figure 1 or more blocks.
[0063] These computer program instructions can also be stored in a computer-readable memory that can direct a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer-readable memory generate a manufactured article including an instruction device, and the instruction device implements the functions specified in one or more flows Figure 1 or more flows and / or blocks Figure 1 or more blocks.
[0064] These computer program instructions can also be loaded onto a computer or other programmable data processing device, so that a series of operation steps are executed on the computer or other programmable device to generate a computer-implemented process, and thus the instructions executed on the computer or other programmable device provide steps for implementing the functions specified in one or more flows Figure 1 or more flows and / or blocks Figure 1 or more blocks.
[0065] In a typical configuration, a computing device includes one or more processors (CPUs), an input / output interface, a network interface, and a memory.
[0066] The memory may include non-permanent memory in a computer-readable medium, in the form of random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash memory (flash RAM). The memory is an example of a computer-readable medium.
[0067] A computer-readable medium includes permanent and non-permanent, removable and non-removable media and can implement information storage by any method or technology. The information can be computer-readable instructions, data structures, program modules, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, compact disc read-only memory (CD-ROM), digital versatile disc (DVD) or other optical storage, magnetic cassette tapes, magnetic disk storage or other magnetic storage devices, or any other non-transitory medium that can be used to store information that can be accessed by a computing device. As defined herein, a computer-readable medium does not include transitory computer-readable media such as modulated data signals and carrier waves.
[0068] In the description of the present invention, it should be understood that the terms "first" and "second" are used only for descriptive purposes and cannot be construed as indicating or implying relative importance or implicitly specifying the quantity of the indicated technical features. Thus, features defined with "first" and "second" may explicitly or implicitly include at least one of such features. In the description of the present invention, "a plurality of" means at least two, such as two, three, etc., unless otherwise specifically defined.
[0069] In the present invention, unless otherwise clearly specified and defined, the terms "mounted", "connected", "coupled", "fixed", etc. shall be construed in a broad sense. For example, it may be a fixed connection, a detachable connection, or integrated; it may be a mechanical connection, an electrical connection, or communicable with each other; it may be directly connected, or indirectly connected through an intermediate medium, and may be the internal communication of two elements or the interaction relationship between two elements, unless otherwise clearly defined. For those of ordinary skill in the art, the specific meanings of the above terms in the present invention can be understood according to specific circumstances.
[0070] In the description of this specification, the description with reference to terms such as "one embodiment", "some embodiments", "examples", "specific examples", or "some examples" means that the specific features, structures, materials, or characteristics described in connection with the embodiment or example are included in at least one embodiment or example of the present invention. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials, or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, without contradiction, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of different embodiments or examples.
[0071] Although the embodiments of the present invention have been shown and described above, it can be understood that the above embodiments are exemplary and should not be construed as limiting the present invention. Those of ordinary skill in the art can make changes, modifications, substitutions, and variations to the above embodiments within the scope of the present invention.
Claims
1. A control method for a motor, applied to a nucleic acid detection device, characterized in that, The nucleic acid detection device includes a motor (1) and an optical encoder mounted on the motor (1), and the control method includes the following steps: Obtain the control instruction of the motor (1); Determine the target drive signal of the motor (1) according to the control instruction; Send the target drive signal to the motor (1) to control the start of the motor (1); After the movement of the motor (1) ends, obtain the first detection signal fed back by the optical encoder; Determine the compensation signal of the motor (1) according to the first detection signal and the target drive signal; Control the motor (1) to perform a position compensation action according to the compensation signal.
2. The control method of the motor according to claim 1, characterized in that, The step of determining the compensation signal of the motor (1) according to the first detection signal and the target drive signal includes: Determine the third rotation amount corresponding to the first detection signal and the fourth rotation amount corresponding to the target drive signal; Determine the second rotation difference between the third rotation amount and the fourth rotation amount; Determine the compensation signal amount according to the second rotation difference, and then determine the compensation signal.
3. The control method of the motor according to claim 2, characterized in that The step of controlling the motor (1) to perform a position compensation action according to the compensation signal includes: When the third rotation amount is less than the fourth rotation amount, control the motor (1) to rotate in the rotation direction at startup; When the third rotation amount is greater than the fourth rotation amount, control the motor (1) to rotate in the direction opposite to the rotation direction at startup.
4. The control method of the motor according to claim 1, characterized in that The control method further includes the following steps: After the motor (1) completes the position compensation action, obtain the second detection signal detected by the optical encoder; When the fifth rotation amount corresponding to the second detection signal is not equal to the first rotation amount corresponding to the target drive signal, control the motor (1) to perform position compensation again until the rotation amount corresponding to the detection signal detected by the optical encoder is equal to the first rotation amount.
5. The control method of the motor according to claim 1, characterized in that The control method further includes the following steps: After the motor (1) starts, every preset time period, obtain the current drive signal of the motor (1) and the current detection signal fed back by the optical encoder; Determine the first rotation amount corresponding to the current drive signal and the second rotation amount corresponding to the current detection signal; Determine the first rotation difference between the first rotation amount and the second rotation amount; When the absolute value of the first rotation difference is greater than the preset threshold for a continuous preset number of times, control the nucleic acid detection device to give a position deviation alarm.
6. The control method of the motor according to claim 5, characterized in that, The step of controlling the nucleic acid detection device to give a position deviation alarm when the absolute value of the first rotation difference is greater than the preset threshold for a continuous preset number of times includes: When the absolute value of the first rotation difference is greater than the preset threshold, increase the count of the deviation warning number; When the absolute value of the first rotation difference is less than the preset threshold, clear the count of the deviation warning number; When the cumulative count of the deviation warning number is greater than or equal to the preset value, control the nucleic acid detection device to give an alarm.
7. The control method of the motor according to claim 5, characterized in that, The control method further includes the following steps: When the absolute value of the first rotation difference is greater than the preset threshold for a continuous preset number of times, control the motor (1) to reset and restart.
8. The control method of the motor according to any one of claims 1 to 7, characterized in that, The nucleic acid detection device further includes a reagent cartridge (2) and a position detection component. The reagent cartridge (2) is drivingly connected to the motor (1). The position detection component is used to detect the position of the reagent cartridge (2). The control method further includes the following steps: After the motor (1) executes the position compensation action, obtain the first position signal sent by the position detection component; Determine whether the reagent cartridge (2) moves abnormally according to the control instruction and the first position signal; When the reagent cartridge (2) moves abnormally, control the nucleic acid detection device to alarm.
9. The control method of the motor according to any one of claims 1 to 7, characterized in that The nucleic acid detection device further includes a liquid transfer mechanism (3). The liquid transfer mechanism (3) includes a liquid transfer pump. The liquid transfer mechanism (3) is drivingly connected to the motor (1). The control method further includes the following steps: After the motor (1) executes the position compensation action, control the liquid transfer pump to perform a liquid transfer operation; When the liquid transfer pump has abnormal liquid transfer, control the nucleic acid detection device to alarm.
10. A nucleic acid detection device, characterized in that, Including: A motor (1) equipped with an optical encoder and a drive controller; And A processor configured to execute the control method of the motor according to any one of claims 1 to 9.
11. The nucleic acid detection device according to claim 10, wherein The processor includes: An optical signal receiving module electrically connected to the optical encoder. The optical signal receiving module is used to receive the detection signal fed back by the optical encoder.
12. A machine-readable storage medium, characterized in that, Instructions are stored on the machine-readable storage medium, characterized in that when the instructions are executed by the processor, the processor is configured to execute the control method of the motor according to any one of claims 1 to 9.