A method, device, equipment and medium for detecting motor state based on coding

By connecting the motor to the light shield, using the light-transmitting hole to represent phase encoding, and receiving the electric pulse signal in real time generates detection encoding, solving the accuracy and anti-interference problems of motor status detection, and achieving higher precision motor status monitoring.

CN120254611BActive Publication Date: 2025-08-22GUANGZHOU ANGTE MASCH EQUIP CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202510749791.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-06-06
Publication Date
2025-08-22
Estimated Expiration
2045-06-06

AI Technical Summary

Technical Problem

The existing motor state detection methods cannot provide accurate initial phase reference, cannot determine the specific phase interval in which the motor subsequent rotation is located, and cannot truly reflect the actual operating status of the motor when it encounters elastic resistance or abnormal vibration.

Method used

By connecting the motor to the light shield, the phase encoding is represented by the light-transmitting holes on the light shield, the electric pulse signal is received in real time to generate the detection encoding, and the target phase is determined based on the relationship between the pre-constructed phase encoding and the motor phase, thereby determining the operating state of the motor.

Benefits of technology

It improves the accuracy and anti-interference ability of the motor phase detection, ensures the intelligent and precise operation of the robot, and can withstand signal distortion caused by factors such as mechanical vibration and oil pollution occlusion.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120254611B_ABST
    Figure CN120254611B_ABST
Patent Text Reader

Abstract

The present application discloses a method, device, equipment and medium for detecting the state of a motor based on coding, and the present application belongs to the field of manipulator technology. The method includes: receiving an electric pulse signal in real time; wherein the electric pulse signal is obtained by converting the optical signal passing through the shading plate; generating a detection code according to the electric pulse signal; determining the target phase according to the correlation between the detection code and the pre-constructed phase code and the motor phase; wherein the number of the phase codes is at least two; and determining the operating state of the motor according to the target phase. This technical solution converts the motor phase information into a phase code that can be accurately identified, which can effectively resist signal distortion caused by factors such as mechanical vibration and oil obstruction, has higher detection accuracy, stronger anti-interference ability and more flexible scalability, and provides reliable protection for the intelligent and precise operation of the manipulator.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application belongs to the field of manipulator technology, and specifically relates to a motor state detection method, device, equipment and medium based on coding. Background Art

[0002] Stepper motors, with their high control precision and fast response speed, are the core components of robotic arms. Whether handling materials on industrial production lines, assembling precision parts, or precisely manipulating medical surgical manipulators, the stepper motor's power output stability and phase accuracy directly determine the manipulator's machining accuracy and operational reliability. Therefore, real-time monitoring of the stepper motor's operating status is essential.

[0003] The most common detection method currently used is photoelectric signal detection: a gear-shaped light shield rotates via the motor's rotating shaft, and the protruding portion of the light shield's gear periodically blocks the light source, causing the photodetector to generate a periodic pulse signal to monitor the motor's power output. However, without a precise initial phase reference, this method cannot determine the specific phase interval in which the motor's subsequent rotation will occur. Furthermore, if the motor encounters elastic resistance or abnormal vibration, the light shield may continue to rotate slightly due to inertia or vibration, even if the power shaft becomes stuck or reverses direction. This can cause the photodetector to continue to output normal pulse signals, failing to accurately reflect the motor's actual operating status.

[0004] Therefore, how to achieve accurate detection of the motor phase and feedback the true motor operating status is an urgent problem that people in this field need to solve. Summary of the Invention

[0005] The present application provides a motor state detection method, device, equipment and medium based on encoding, the purpose of which is to improve the detection accuracy of the motor phase, improve the anti-interference ability and scalability of the detection method, and provide reliable protection for the intelligent and precise operation of the manipulator.

[0006] In a first aspect, the present application provides a method for detecting a motor state based on encoding, wherein a motor is connected to a light shielding plate, and the operation of the motor drives the light shielding plate to rotate; the light shielding plate is provided with a light-transmitting hole, and the light-transmitting hole is used to represent a phase encoding; the method comprises:

[0007] receiving an electrical pulse signal in real time; wherein the electrical pulse signal is converted from an optical signal passing through the light shield;

[0008] generating a detection code according to the electrical pulse signal;

[0009] Determining a target phase according to the detection code and a pre-established correlation between the phase code and the motor phase; wherein the number of the phase codes is at least two;

[0010] An operating state of the electric motor is determined based on the target phase.

[0011] In a second aspect, the present application provides a motor state detection device based on encoding, wherein the motor is connected to a light shielding plate, and the operation of the motor drives the light shielding plate to rotate; the light shielding plate is provided with a light-transmitting hole, and the light-transmitting hole is used to indicate phase encoding; the device comprises:

[0012] A signal receiving module, configured to receive an electrical pulse signal in real time; wherein the electrical pulse signal is converted from an optical signal passing through the light shield;

[0013] A code generation module, configured to generate a detection code according to the electrical pulse signal;

[0014] a phase determination module, configured to determine a target phase based on the detection code and a pre-established correlation between the phase code and the motor phase; wherein the number of the phase codes is at least two;

[0015] A state determination module is used to determine the operating state of the motor according to the target phase.

[0016] In a third aspect, the present application provides an electronic device comprising a processor, a memory, and a program or instruction stored in the memory and executable on the processor, wherein the program or instruction, when executed by the processor, implements the steps of the method described in the first aspect.

[0017] In a fourth aspect, the present application provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, the steps of the method described in the first aspect are implemented.

[0018] In the present application, an electric pulse signal is received in real time; wherein, the electric pulse signal is obtained by converting the optical signal passing through the shading plate; a detection code is generated according to the electric pulse signal; a target phase is determined according to the detection code and the correlation between the pre-constructed phase code and the motor phase; wherein, the number of the phase codes is at least two; and the operating state of the motor is determined according to the target phase. The above-mentioned encoding-based motor state detection method converts the motor phase information into a phase code that can be accurately identified, which can effectively resist signal distortion caused by factors such as mechanical vibration and oil obstruction, and has higher detection accuracy, stronger anti-interference ability and more flexible scalability, providing reliable protection for the intelligent and precise operation of the manipulator. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] Figure 1 1 is a flow chart of a motor state detection method based on encoding provided in Example 1 of the present application;

[0020] Figure 2 1 is a schematic structural diagram of a motor state detection system based on encoding provided in Example 1 of the present application;

[0021] Figure 3 This is a structural example diagram of the light shield provided in Example 1 of the present application;

[0022] Figure 4 This is an example diagram of the electrical pulse signal provided in Example 1 of the present application;

[0023] Figure 5 1 is a flow chart of a motor state detection method based on encoding provided in Example 2 of the present application;

[0024] Figure 6 1 is a flow chart of a motor state detection method based on encoding provided in Example 3 of the present application;

[0025] Figure 7 1 is a schematic structural diagram of a motor state detection device based on encoding provided in a fourth embodiment of the present application;

[0026] Figure 8 This is a structural diagram of the electronic device provided in Example 5 of the present application. DETAILED DESCRIPTION

[0027] To further clarify the objectives, technical solutions, and advantages of this application, specific embodiments of the present application are described in further detail below with reference to the accompanying drawings. It should be understood that the specific embodiments described herein are intended only to illustrate this application and are not intended to limit it. It should also be noted that, for ease of description, the drawings only illustrate portions relevant to this application, not all of them. Before discussing the exemplary embodiments in more detail, it should be noted that some exemplary embodiments are described as processes or methods depicted as flowcharts. Although the flowcharts depict the various operations (or steps) as sequential processes, many of the operations can be performed in parallel, concurrently, or simultaneously. Furthermore, the order of the operations can be rearranged. The process may terminate upon completion of its operations, but may also include additional steps not shown in the accompanying drawings. The process may correspond to a method, function, procedure, subroutine, subprogram, or the like.

[0028] The following will be combined with the accompanying drawings in the embodiments of the present application to clearly describe the technical solutions in the embodiments of the present application. Obviously, the embodiments described are part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in this field are within the scope of protection of this application.

[0029] The terms "first," "second," and the like in the specification and claims of this application are used to distinguish similar objects, and are not used to describe a specific order or precedence. It should be understood that the terms used in this manner are interchangeable where appropriate, so that the embodiments of this application can be implemented in an order other than that illustrated or described herein, and that the objects distinguished by "first," "second," and the like are generally of the same type, and do not limit the number of objects; for example, the first object can be one or more. In addition, the term "and / or" in the specification and claims refers to at least one of the connected objects, and the character " / " generally indicates that the objects connected are in an "or" relationship.

[0030] The following describes in detail the motor state detection method, device, equipment and medium based on encoding provided by the embodiments of the present application through specific embodiments and their application scenarios in conjunction with the accompanying drawings.

[0031] Example 1

[0032] Figure 1 This is a flow chart of the motor state detection method based on coding provided in the first embodiment of the present application. Figure 1 As shown, the specific steps include:

[0033] S101, receiving an electrical pulse signal in real time; wherein the electrical pulse signal is converted from an optical signal passing through the light shield;

[0034] First, this application is applicable to scenarios where the motor operating status needs to be detected to ensure the stable operation of the manipulator. Based on the above usage scenarios, it can be understood that the execution subject of this application can be a microprocessor. Specifically, the determination of the target phase and the operating status of the motor can be performed by the microprocessor. Detecting the operating status of the motor can help warn of potential faults, thereby improving the safety and stability of the motor's operation.

[0035] Figure 2 This is a schematic diagram of the structure of the motor state detection system based on encoding provided in the first embodiment of the present application. Figure 2 As shown, the motor state detection system based on encoding includes a microcontroller, a motor, a light shield, a light source, a photoelectric sensor and a transistor.

[0036] A microcontroller can be a monolithic integrated circuit chip that integrates functional modules such as a central processing unit (CPU), memory (ROM / RAM), input and output interfaces (I / O), timers / counters, and analog-to-digital converters (such as ADC).

[0037] An electric motor is a device that converts electrical energy into mechanical energy. It drives the rotor through electromagnetic induction or other physical effects, thereby driving a mechanical load. A microcontroller can be used to control the operation of the motor. In this scenario, the motor can specifically refer to a stepper motor. Specifically, a stepper motor is an electric motor that converts electrical pulse signals into precise mechanical motion.

[0038] When VCC (Volt Current Condenser, power supply voltage) is not 0, the transistor is turned on and the light source can emit a light signal. The light source can be an LED (Light Emitting Diode, light emitting diode). GND represents the ground terminal.

[0039] The light shield can be a key functional component for converting the mechanical motion (rotational state) of the motor into changes in the optical signal. The light shield can be circular. The light shield is provided with a light-transmitting hole that allows the light signal to pass through, while the solid part of the light shield does not allow the light signal to pass through.

[0040] Figure 3 This is an example diagram of the structure of the light shield provided in Example 1 of this application. Figure 3 As shown, the light shielding plate is circular, the gray circular area is the settable area of ​​the light transmission hole, the white square is the light transmission hole, and the black square is the solid part within the settable area of ​​the light transmission hole.

[0041] The motor and the sunshade can be connected via a transmission device, such that the motor's operation drives the sunshade to rotate. It is understood that the mechanical movement (rotational state) of the motor is synchronized with the rotational state of the sunshade. The transmission device can be a belt or gear, etc., and is not limited here.

[0042] A photoelectric sensor is a device that converts light signals into electrical signals. The light source is fixed in position, allowing the light signal emitted by the light source to reach a relatively fixed position within the aperture of the light shield. During the light shield's rotation, if the fixed position is the aperture, the light signal can pass through the aperture and be converted into an electrical signal by the photoelectric sensor. If the fixed position is the solid portion of the light shield, the light signal cannot pass through the aperture, and the photoelectric sensor outputs no electrical signal.

[0043] An electrical pulse signal may be an electrical signal that changes suddenly within a short period of time. Figure 4 This is an example diagram of the electrical pulse signal provided in Example 1 of this application. Figure 4 As shown, as time passes (i.e., as the light shield rotates), the light signal is transmitted to the photoelectric sensor or not, and the electrical signal is generated or not, forming an electrical pulse signal.

[0044] The photoelectric sensor can send the converted electrical pulse signal to the analog-to-digital converter, and the analog-to-digital converter receives the electrical pulse signal in real time.

[0045] S102, generating a detection code according to the electrical pulse signal;

[0046] An analog-to-digital converter (ADC) is an electronic device that converts a continuously changing analog signal (such as the electrical pulse signal in this solution) into a discrete digital signal. The discrete digital signal obtained by converting the electrical pulse signal in this solution through the ADC is the detection code.

[0047] S103, determining a target phase according to the detection code and a pre-established correlation between the phase code and the motor phase; wherein the number of the phase codes is at least two;

[0048] Phase encoding can be a set of discrete digital signals that can represent the motor phase. The motor phase can refer to the mechanical position angle of the motor rotor, which describes the spatial position of the motor rotor during rotation.

[0049] Phase coding can be in binary, quaternary, octal, hexadecimal, etc., and is not limited here.

[0050] The relationship between the phase encoding and the motor phase may refer to a one-to-one mapping relationship between the phase encoding and the motor phase. Figure 3 As shown, if the phase code is "010100110", the associated motor phase is 0~π / 2; if the phase code is "010110010", the associated motor phase is π / 2~π; if the phase code is "010110001", the associated motor phase is π~3π / 2; if the phase code is "010100101", the associated motor phase is 3π / 2~2π.

[0051] It can be understood that the motor phases associated with each phase encoding should be able to be combined into a complete 2π; the encoding length of the phase encoding is positively correlated with the motor phase resolution.

[0052] The target phase is the motor phase corresponding to the current detection code. Based on the detection code and the pre-established relationship between the phase code and the motor phase, the target phase can be determined by determining the motor phase associated with the phase code that successfully matches the detection code as the target phase.

[0053] S104: Determine the operating state of the motor according to the target phase.

[0054] The operating status of the motor may be a data set used to describe the current operating characteristics of the motor, and may include the rotational speed and the total number of revolutions.

[0055] The method of determining the running state of the motor according to the target phase may include determining the rotation speed according to the target phase determined in real time, and accumulating and adding the target phase to obtain the total number of revolutions.

[0056] In an embodiment of the present application, an electric pulse signal is received in real time; wherein the electric pulse signal is obtained by converting the optical signal passing through the shading plate; a detection code is generated according to the electric pulse signal; a target phase is determined according to the detection code and the correlation between the pre-constructed phase code and the motor phase; wherein the number of the phase codes is at least two; and the operating state of the motor is determined according to the target phase. The above-mentioned encoding-based motor state detection method converts the motor phase information into a phase code that can be accurately identified, which can effectively resist signal distortion caused by factors such as mechanical vibration and oil obstruction, has higher detection accuracy, stronger anti-interference ability and more flexible scalability, and provides reliable protection for the intelligent and precise operation of the manipulator.

[0057] Example 2

[0058] Figure 5 This is a flow chart of the motor state detection method based on coding provided in Example 2 of the present application. This solution makes a better improvement on the above embodiment, specifically: the phase coding includes a starting coding sequence, a phasing coding sequence and a detection and error correction coding sequence.

[0059] like Figure 5 As shown, the specific steps include:

[0060] S501, receiving an electrical pulse signal in real time; wherein the electrical pulse signal is converted from an optical signal passing through the light shield;

[0061] S502, generating a detection code according to the electrical pulse signal;

[0062] S503, determining a target phase based on the detection code and a pre-established correlation between the phase code and the motor phase; wherein the number of the phase codes is at least two, and the phase codes include a starting code sequence, a phasing code sequence, and a detection and error correction code sequence;

[0063] The start code sequence may be a code sequence used to identify the beginning of a complete phase code and help extract a valid detection code from a detection code.

[0064] The phasing code sequence may be a code sequence for identifying the phases of the motor.

[0065] The detection error correction code sequence may be a code sequence used to help identify whether the extracted effective detection code is correct and effective.

[0066] Generally, the code length of the phasing code sequence should be greater than the code length of the error detection and correction code sequence.

[0067] In this technical solution, optionally, the starting coding sequence of each phase coding is the same, and the phasing coding sequence and the detection and error correction coding sequence do not include a coding sequence that is the same as the starting coding sequence.

[0068] The starting code sequence of each phase code is the same, which enables the start position of the effective detection code for detection matching to be quickly and uniformly identified. For example, the starting code sequence of each phase code is "0101".

[0069] The phase-fixed coding sequence and the detection and error correction coding sequence do not include a coding sequence that is identical to the starting coding sequence. This may be because no coding sequence that is identical to the starting coding sequence can be extracted from the phase-fixed coding sequence and the detection and error correction coding sequence, that is, the starting coding sequence appears only once in the entire phase coding and is unique.

[0070] The advantage of this arrangement of the scheme is that it can not only realize the rapid extraction of valid detection codes through a unified starting code sequence, but also avoid the misjudgment of valid detection codes through uniqueness constraints, thereby improving the parsing accuracy of the detection codes.

[0071] In the present technical solution, optionally, the phase-fixed coding sequences of each phase code are different, and the phase-fixed coding sequences of each phase code correspond to a motor phase.

[0072] For example, if the phase-fixed coding sequence is "0011", the corresponding motor phase is 0~π / 2; if the phase-fixed coding sequence is "1001", the corresponding motor phase is π / 2~π; if the phase-fixed coding sequence is "1000", the corresponding motor phase is π~3π / 2; if the phase-fixed coding sequence is "0010", the corresponding motor phase is 3π / 2~2π.

[0073] The advantage of this arrangement of the present invention is that the phase coding sequence of each phase code is different, and each phase coding sequence corresponds to a motor phase, ensuring that each phase code corresponds to only a unique motor phase, thus avoiding decoding ambiguity.

[0074] S504: Determine the operating state of the motor according to the target phase.

[0075] The advantage of this arrangement of the present scheme is that the phase coding includes a starting coding sequence, a phasing coding sequence, and a detection and error correction coding sequence, which can efficiently identify effective detection codes and improve the speed and accuracy of determining the target phase.

[0076] Example 3

[0077] Figure 6 1 is a flow chart of a motor state detection method based on coding provided in the third embodiment of the present application. This solution makes a better improvement to the above embodiment, specifically: the phase coding adopts binary.

[0078] like Figure 6 As shown, the specific steps include:

[0079] S601, receiving an electrical pulse signal in real time; wherein the electrical pulse signal is converted from an optical signal passing through the light shield;

[0080] S602, generating a detection code according to the electrical pulse signal;

[0081] S603, determining a target phase based on the detection code and a pre-established relationship between the phase code and the motor phase; wherein the number of the phase codes is at least two, the phase codes include a starting code sequence, a phasing code sequence, and a detection and error correction code sequence, and the phase code is binary;

[0082] Binary is a base-2 counting system that underlies computer data storage and computation. Binary uses only two symbols, 0 and 1, to represent numerical values, with each bit weighted as a power of 2. In other words, in this scheme, each code sequence consists of only 0 and 1.

[0083] In this technical solution, optionally, the light-transmitting hole includes a small hole, and the small hole is used to represent code 1;

[0084] Correspondingly, the non-hole position on the light shield is used to represent code 0;

[0085] or,

[0086] The light-transmitting hole further includes a long hole, and the long hole is used to represent code 0.

[0087] like Figure 3 As shown, the white square is a small hole, which is coded as 1; the black square is a position without a hole, which is coded as 0.

[0088] It can be understood that the length of the long hole should be greater than the length of the small hole, and the length of the long hole can be a preset multiple of the length of the small hole.

[0089] The advantage of this arrangement is that a small hole is used to represent code 1, and a hole-free position or a long hole is used to represent code 0. Significant differences in light intensity or duration can be used to improve signal reliability, simplify decoding logic to improve processing efficiency, and enhance anti-interference capabilities with the help of physical structural characteristics.

[0090] In this technical solution, optionally, the detection error correction coding sequence is used to indicate the parity of the number of code 1s or code 0s in the phase-fixed coding sequence in the same group of phase coding.

[0091] The detection error correction coding sequence is used to indicate the parity of the number of code 1s (or code 0s) in the phase-fixed coding sequence in the same group of phase codes. A detection error correction coding sequence of 0 indicates that the phase-fixed coding sequence includes an even number of code 1s (or code 0s), and a detection error correction coding sequence of 1 indicates that the phase-fixed coding sequence includes an odd number of code 1s (or code 0s).

[0092] For example, the detection error correction coding sequence is used to indicate the parity of the number of code 1s in the phase-fixed coding sequence in the same group of phase codes; if the phase-fixed coding sequence is "0011", its corresponding detection error correction coding sequence is 0; if the phase-fixed coding sequence is "1001", its corresponding detection error correction coding sequence is 0; if the phase-fixed coding sequence is "1000", its corresponding detection error correction coding sequence is 1; if the phase-fixed coding sequence is "0010", its corresponding detection error correction coding sequence is 1.

[0093] The advantage of this arrangement of the present scheme is that the error correction coding sequence is used to detect the parity of the number of code 1s or code 0s in the phase-fixed coding sequence in the same group of phase coding. The parity check mechanism can be used to quickly identify whether there are errors in the phase-fixed coding sequence parsed from the detection coding, while maintaining the simplicity and real-time performance of the coding system. It is particularly suitable for motor control scenarios that have certain requirements on the bit error rate but are resource-constrained.

[0094] S604: Determine the operating state of the motor according to the target phase.

[0095] The advantage of this arrangement of the present invention is that the phase encoding adopts binary, and the combination characteristics of binary can be used to flexibly adjust the phase resolution of the motor. It is directly compatible with the computer system, simplifies the data transmission and processing flow, and reduces the complexity of hardware design and anti-interference ability.

[0096] Example 4

[0097] Figure 7 Schematic diagram of the structure of the motor state detection device based on coding provided in the fourth embodiment of the present application. Figure 7 As shown, the device includes:

[0098] The signal receiving module 710 is used to receive an electrical pulse signal in real time; wherein the electrical pulse signal is converted from an optical signal passing through the light shield;

[0099] A code generation module 720 is configured to generate a detection code according to the electrical pulse signal;

[0100] A phase determination module 730 is configured to determine a target phase based on the detection code and a pre-established correlation between the phase code and the motor phase; wherein the number of the phase codes is at least two;

[0101] The state determination module 740 is configured to determine the operating state of the motor according to the target phase.

[0102] In an embodiment of the present application, a signal receiving module is used to receive an electric pulse signal in real time; wherein, the electric pulse signal is obtained by converting the optical signal passing through the shading plate; a coding generation module is used to generate a detection code according to the electric pulse signal; a phase determination module is used to determine the target phase according to the detection code and the correlation between the pre-constructed phase code and the motor phase; wherein the number of the phase codes is at least two; a state determination module is used to determine the operating state of the motor according to the target phase. The above-mentioned coding-based motor state detection device converts the motor phase information into a phase code that can be accurately identified, can effectively resist signal distortion caused by factors such as mechanical vibration and oil obstruction, has higher detection accuracy, stronger anti-interference ability and more flexible scalability, and provides reliable protection for the intelligent and precise operation of the manipulator.

[0103] The encoding-based motor state detection device in the embodiments of the present application can be a device, or a component, integrated circuit, or chip in a terminal. The device can be a mobile electronic device or a non-mobile electronic device. For example, the mobile electronic device can be a mobile phone, a tablet computer, a laptop computer, a PDA, an in-vehicle electronic device, a wearable device, an ultra-mobile personal computer (UMPC), a netbook, or a personal digital assistant (PDA), etc. The non-mobile electronic device can be a server, a network attached storage (NAS), a personal computer (PC), a television (TV), a teller machine, or a self-service machine, etc., and the embodiments of the present application do not specifically limit this.

[0104] The motor state detection device based on encoding in the embodiment of the present application may be a device having an operating system. The operating system may be an Android operating system, an iOS operating system, or other possible operating systems, which are not specifically limited in the embodiment of the present application.

[0105] The encoding-based motor state detection device provided in the embodiment of the present application can implement the various processes implemented in the above-mentioned embodiments one to three. To avoid repetition, they will not be described here.

[0106] Example 5

[0107] like Figure 8 As shown, an embodiment of the present application also provides an electronic device 800, including a processor 801, a memory 802, and a program or instruction stored in the memory 802 and executable on the processor 801. When the program or instruction is executed by the processor 801, the various processes of the above-mentioned encoding-based motor state detection method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.

[0108] It should be noted that the electronic devices in the embodiments of the present application include the mobile electronic devices and non-mobile electronic devices mentioned above.

[0109] Example 6

[0110] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, the various processes of the above-mentioned encoding-based motor state detection method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.

[0111] The processor is the processor in the electronic device described in the above embodiment. The readable storage medium includes a computer-readable storage medium, such as a computer read-only memory (ROM), random access memory (RAM), a magnetic disk, or an optical disk.

[0112] It should be noted that, in this article, the terms "comprise", "include" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the statement "comprises a ..." does not exclude the presence of other identical elements in the process, method, article or device comprising the element. In addition, it should be noted that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in the opposite order according to the functions involved. For example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.

[0113] Through the description of the above embodiments, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus the necessary general hardware platform. Of course, they can also be implemented by hardware, but in many cases the former is a better embodiment. Based on this understanding, the technical solution of this application, or the part that contributes to the existing technology, can be embodied in the form of a computer software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes a number of instructions for enabling a terminal (which can be a mobile phone, computer, server, or network device, etc.) to execute the methods described in each embodiment of this application.

[0114] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of this application, ordinary technicians in this field can also make many forms without departing from the purpose of this application and the scope of protection of the claims, all of which are within the protection of this application.

[0115] The above are only preferred embodiments of the present application and the technical principles employed. The present application is not limited to the specific embodiments described herein, and various obvious changes, readjustments, and substitutions that are possible for those skilled in the art will not depart from the scope of protection of the present application. Therefore, although the present application has been described in more detail through the above embodiments, the present application is not limited to the above embodiments and may include more other equivalent embodiments without departing from the concept of the present application. The scope of the present application is determined by the scope of the claims.

Claims

1. A motor state detection method based on coding, characterized in that: A motor is connected to a light shielding plate, and the operation of the motor drives the light shielding plate to rotate; the light shielding plate is provided with light-transmitting holes, and the light-transmitting holes are provided in the same circular area of ​​the light shielding plate; according to the rotation order of the light shielding plate, the light-transmitting holes are used to represent phase coding; the phase coding includes a starting coding sequence, a phasing coding sequence, and a detection and error correction coding sequence; the starting coding sequence of each phase coding is the same, and the phasing coding sequence and the detection and error correction coding sequence do not include a coding sequence that is the same as the starting coding sequence; the phasing coding sequence of each phase coding is different, and the phasing coding sequence of each phase coding corresponds to a motor phase; the method includes: receiving an electrical pulse signal in real time; wherein the electrical pulse signal is converted from an optical signal passing through the light shield; generating a detection code according to the electrical pulse signal; Determining a target phase according to the detection code and a pre-established correlation between the phase code and the motor phase; wherein the number of the phase codes is at least two; An operating state of the electric motor is determined based on the target phase.

2. The motor state detection method based on encoding according to claim 1, characterized in that: The phase encoding adopts binary.

3. The motor state detection method based on encoding according to claim 2, characterized in that: The light-transmitting hole includes a small hole, and the small hole is used to represent code 1. The non-hole position on the light-shielding plate is used to represent code 0.

4. The motor state detection method based on encoding according to claim 2, characterized in that: The detection error correction code sequence is used to indicate the parity of the number of code 1s or code 0s in the phased code sequence in the same group of phase codes.

5. A motor state detection device based on coding, characterized in that: A motor is connected to a light shielding plate, and the operation of the motor drives the light shielding plate to rotate; the light shielding plate is provided with light-transmitting holes, and the light-transmitting holes are arranged in the same circular area of ​​the light shielding plate; according to the rotation order of the light shielding plate, the light-transmitting holes are used to represent phase coding; the phase coding includes a starting coding sequence, a phasing coding sequence, and a detection and error correction coding sequence; the starting coding sequence of each phase coding is the same, and the phasing coding sequence and the detection and error correction coding sequence do not include a coding sequence that is the same as the starting coding sequence; the phasing coding sequence of each phase coding is different, and the phasing coding sequence of each phase coding corresponds to a motor phase; the device includes: A signal receiving module, configured to receive an electrical pulse signal in real time; wherein the electrical pulse signal is converted from an optical signal passing through the light shield; A code generation module, configured to generate a detection code according to the electrical pulse signal; a phase determination module, configured to determine a target phase based on the detection code and a pre-established correlation between the phase code and the motor phase; wherein the number of the phase codes is at least two; A state determination module is used to determine the operating state of the motor according to the target phase.

6. An electronic device, characterized in that: The method comprises a processor, a memory and a program or instruction stored in the memory and executable on the processor, wherein the program or instruction, when executed by the processor, implements the steps of the motor state detection method based on encoding as described in any one of claims 1 to 4.

7. A readable storage medium, characterized in that: The readable storage medium stores a program or instruction, and when the program or instruction is executed by a processor, the steps of the motor state detection method based on encoding as described in any one of claims 1 to 4 are implemented.

Citation Information

Patent Citations

  • Method and device for collecting rotor position of permanent magnet synchronous motor of direct-drive type ball mill

    CN106026536A

  • Encoding and decoding methods and encoding and decoding devices of angle encoder, and encoder

    CN113670344A

  • Motor running state detection device and infusion pump

    CN119001430A