Stepping motor detection device based on optocoupler isolation
By using an optocoupler-based stepper motor testing device, which utilizes a microcontroller and optocouplers for electrical isolation, the problems of low testing accuracy and cumbersome operation in existing technologies are solved, achieving efficient and low-cost stepper motor testing.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Utility models(China)
- Current Assignee / Owner
- AUTOBIO LABTEC INSTR CO LTD
- Filing Date
- 2025-05-28
- Publication Date
- 2026-05-19
AI Technical Summary
Existing stepper motor testing devices lack electrical isolation protection, resulting in low testing accuracy and cumbersome operation. Furthermore, using optocouplers for electrical isolation presents problems such as large tooling size and high cost.
A stepper motor testing device based on optocoupler isolation is adopted. The first and second microcontrollers interact with each other through a CAN transceiver communication circuit, and the input and output sides are functionally measured and verified through optocouplers, which simplifies the design and improves the testing efficiency.
It achieves electrical isolation protection for stepper motor testing, improves testing accuracy and efficiency, simplifies the operation process, and reduces equipment size and cost.
Smart Images

Figure CN224263350U_ABST
Abstract
Description
Technical Field
[0001] This utility model relates to a stepper motor testing device, and more particularly to a stepper motor testing device based on optocoupler isolation. Background Technology
[0002] Existing stepper motor testing fixtures mostly use multimeters and control chips to test stepper motors, lacking electrical isolation protection. The load is susceptible to electrical interference and shocks, leading to malfunctions and reducing the testing accuracy. If optocouplers are used for electrical isolation, a multimeter is needed to perform functional measurements and verification on both the input and output sides of the optocoupler. For multi-channel optocouplers, this presents disadvantages such as cumbersome and inconvenient operation, large fixture size, difficulty in maintenance, and high cost. Summary of the Invention
[0003] The purpose of this invention is to provide a stepper motor testing device based on optocoupler isolation, thereby improving the efficiency of stepper motor testing.
[0004] To achieve the above objectives, the present invention can adopt the following technical solution:
[0005] The stepper motor detection device based on optocoupler isolation described in this utility model includes a first microcontroller and a second microcontroller. The first microcontroller and the second microcontroller communicate with each other through a CAN transceiver communication circuit, and the hierarchical processing has a fast response speed.
[0006] The first microcontroller is used to send the operating parameters required by the stepper motor to the motor driver, such as the configuration of parameters like power-on, speed, rotation direction, and enable / disable of the origin sensor, as well as the current value of the stepper motor. It controls the stepper motor through pulse control and receives the detection signals sent by the origin / position sensor in real time to complete the functions of reset and limit.
[0007] The second microcontroller is used for data interaction and instruction parsing with the host computer, and to send control instructions to the first microcontroller, as well as modify the stepper motor's operating parameters and control logic; such as rotating to the left at 100 rpm, stopping the motor, and powering off the motor; it compares the two sets of input data obtained before and after power-on, judges the results, and realizes the stepper motor inspection function.
[0008] Optionally, the control output terminal of the first microcontroller is connected to the control input terminal of the motor driver via a first optocoupler, and the signal output terminal of the origin / position sensor is connected to the signal input terminal of the first microcontroller via a second optocoupler. When the first optocoupler is turned on (conducted), the level signal output by the second optocoupler to the first microcontroller is low; conversely, when the first optocoupler is turned off (cut off), the level signal output by the second optocoupler to the first microcontroller is high. Therefore, by comparing and judging the two states of the first and second optocouplers, it can be determined whether the functions of the first and second optocouplers are normal, thereby realizing automatic functional measurement and verification of the input and output sides of the optocouplers.
[0009] Optionally, status indicator lights are connected to the output terminal of the first optocoupler and the input terminal of the second optocoupler respectively, for visual observation of the output and input signal status.
[0010] This invention uses optocoupler circuit design to perform functional verification on the input and output sides, reducing the size of inspection personnel and equipment, simplifying the design, and improving the inspection efficiency of stepper motors. Attached Figure Description
[0011] Figure 1 This is a circuit block diagram of this utility model.
[0012] Figure 2 This is the circuit schematic diagram of the first microcontroller of this utility model.
[0013] Figure 3 This is a circuit diagram of the CAN transceiver communication circuit described in this utility model.
[0014] Figure 4 This is the circuit schematic diagram of the second microcontroller of this utility model.
[0015] Figure 5 This is the circuit schematic diagram of the second optocoupler U1 of this utility model.
[0016] Figure 6 This is the circuit schematic diagram of the first optocoupler U2 of this utility model.
[0017] Figure 7 This is the wiring diagram of the first terminal H1 of this utility model.
[0018] Figure 8 This is the wiring diagram of the second terminal H2 of this utility model. Detailed Implementation
[0019] The technical solutions of the present utility model will be clearly and completely described below with reference to the accompanying drawings of the embodiments. Obviously, the described embodiments are only some embodiments of the present utility model, and not all embodiments. Based on the embodiments of the present utility model, all other embodiments obtained by those of ordinary skill in the art without creative effort are within the protection scope of the present utility model.
[0020] It should be noted that all directional indicators (such as up, down, left, right, front, back, etc.) in this utility model embodiment are only used to explain the relative positional relationship and movement of each component in a certain specific posture (as shown in the figure). If the specific posture changes, the directional indicator will also change accordingly.
[0021] In this utility model, unless otherwise explicitly specified and limited, the terms "connection," "fixing," etc., should be interpreted broadly. For example, "fixing" can mean a fixed connection, a detachable connection, or an integral part; it can mean a mechanical connection or an electrical connection; it can mean a direct connection or an indirect connection through an intermediate medium; it can mean the internal communication of two components or the interaction between two components, unless otherwise explicitly limited. Those skilled in the art can understand the specific meaning of the above terms in this utility model according to the specific circumstances.
[0022] Furthermore, in this utility model, descriptions involving "first," "second," etc., are for descriptive purposes only and should not be construed as indicating or implying their relative importance or implicitly specifying the number of technical features indicated. Therefore, a feature defined with "first" or "second" may explicitly or implicitly include at least one of those features.
[0023] Furthermore, the meaning of "and / or" throughout the text is to include three parallel solutions. Taking "A and / or B as an example" as an example, it includes solution A, solution B, or a solution that satisfies both A and B. Additionally, the technical solutions of the various embodiments can be combined with each other, but this must be based on the ability of a person skilled in the art to implement them. When the combination of technical solutions is contradictory or cannot be implemented, it should be considered that such a combination of technical solutions does not exist and is not within the scope of protection claimed by this utility model.
[0024] As shown in Figure 1, the stepper motor detection device based on optical isolation of this utility model includes a first microcontroller and a second microcontroller. The first microcontroller and the second microcontroller communicate with each other through a CAN transceiver to exchange data, and the hierarchical processing has a fast response speed.
[0025] The first microcontroller is used to send the operating parameters required by the stepper motor to the motor driver, such as the configuration of parameters like power-on, speed, rotation direction, enable / disable of the origin / position sensor, and the current value of the stepper motor. It controls the stepper motor through pulse control and receives the detection signals sent by the origin / position sensor in real time to complete the functions of reset and limit.
[0026] The second microcontroller is used for data interaction and instruction parsing with the host computer, and to send control instructions to the first microcontroller, as well as modify the stepper motor's operating parameters and control logic; such as rotating to the left at 100 rpm, stopping the motor, and powering off the motor; it compares the two sets of input data obtained before and after power-on, judges the results, and realizes the stepper motor inspection function.
[0027] Beneficially or exemplaryly, the control output terminal of the first microcontroller is connected to the control input terminal of the motor driver via a first optocoupler, and the signal output terminal of the origin / position sensor is connected to the signal input terminal of the first microcontroller via a second optocoupler. When the first optocoupler is turned on (conducted), the level signal output by the second optocoupler to the first microcontroller is low; conversely, when the first optocoupler is turned off (cut off), the level signal output by the second optocoupler to the first microcontroller is high. Therefore, by comparing and judging the two states of the first and second optocouplers, it can be determined whether the functions of the first and second optocouplers are normal, thereby realizing automatic functional measurement and verification of the input and output sides of the optocouplers.
[0028] Advantageously or exemplaryly, the output terminal of the first optocoupler and the input terminal of the second optocoupler are respectively connected to status indicator lights for intuitive observation of the output and input signal status.
[0029] Specifically, such as Figure 2 As shown, in the control circuit, U3 (the first microcontroller, model STM32F103VET6) is the main control chip, responsible for receiving data and controlling the stepper motor. It is powered by 3.3V. Pins 5 and 6 are connected to the two ends of crystal oscillator Y1 as an external clock for the system. Capacitors C1 and C2 are start-up capacitors used in conjunction with the crystal oscillator to keep the U3 system in a stable working state.
[0030] like Figure 3 As shown, CAN transceiver U5 (model: TJA1051) and CAN transceiver U6 (model: TJA1051) are control conversion chips for CAN communication. Pins 44 and 45 of U3 are connected to the data receiving and transmitting ends of the U5 chip. Pin 44 of U3 is connected to pin 1 of U5 for data transmission, and pin 45 of U3 is connected to pin 4 of U5 for data reception. Pins 7 and 8 of U5 and pins 7 and 8 of U6 are connected to complete the CAN communication between U3 and U4.
[0031] like Figure 4 As shown, pins 32 and 33 of U4 (the second microcontroller, model STM32F103C8T6) are connected to the data receiving and transmitting ends of U6. Pin 32 of U4 is connected to pin 1 of U6 for data transmission, and pin 33 of U4 is connected to pin 4 of U6 for data reception. U4 acts as an extended processor for the system, responsible for logic operations and issuing control instructions. Pins 5 and 6 of U4 are connected to the two ends of crystal oscillator Y2 as an external clock for the system. Capacitors C3 and C4 are start-up capacitors used in conjunction with the crystal oscillator, and their function is the same as that of capacitors C1 and C2.
[0032] like Figure 5 , 6 As shown in Figures 7 and 8, the second optocoupler U1 serves as a 4-channel signal input, connected to pins PB12-PB15 of the first microcontroller U3, with its input terminal connected to the first terminal H1; the first optocoupler U2 serves as a 4-channel signal output control terminal, connected to pins PC6-PC9 of U3, with its output terminal connected to the second terminal H2. This system design enables multi-channel optocoupler function detection through the signal connection of the input and output terminals of U1 and U2.
[0033] The four pins of the first terminal H1 are connected to the four pins of the second terminal H2, that is, H1 pins IN1-IN4 are connected to H2 pins OUT1-OUT4. By controlling the high / low level of the output signal of U2, the signal level status of U1 to U3 is read. By comparing the signal level status of U2 when it is open and closed, that is, when U2 controls it to be open, the signal level of U1 to U3 is low, and vice versa, when U2 controls it to be closed, the signal level of U1 to U3 is high. By comparing the two states of U1 and U2, it can be determined whether the optocoupler function is normal, and at the same time the condition of the motor can be determined, simplifying the inspection process and reducing the operation time.
[0034] U3 is responsible for setting the required operating parameters of the generator driver, including the rotation direction and current value. It controls the stepper motor using pulse control. U3 also sends the number of pulses required for the stepper motor to run, which the motor driver processes and controls. U3 also receives the origin / position sensor detection signal. When the motor reaches the origin position, the origin / position sensor is triggered, and U3 executes a stop procedure after detecting the signal on its input pin. U4 sends control commands to U3 to perform the stepper motor inspection function.
Claims
1. A stepper motor detection device based on optocoupler isolation, characterized in that: It includes a first microcontroller and a second microcontroller, which communicate with each other via a CAN transceiver. The first microcontroller is used to send the required operating parameters of the stepper motor to the motor driver, set the rotation direction and current value of the stepper motor, control the stepper motor through pulse control, and receive the detection signals sent by the motor driver and the origin / position sensor in real time to complete the reset and limit functions of the stepper motor. The second microcontroller is used for data interaction and instruction parsing with the host computer, as well as for sending control instructions to the first microcontroller and modifying the stepper motor's operating parameters and control logic.
2. The stepper motor detection device based on optical isolation according to claim 1, characterized in that: The first microcontroller control output terminal is connected to the motor driver control input terminal via a first optocoupler, and the origin / position sensor signal output terminal is connected to the first microcontroller signal input terminal via a second optocoupler. When the first optocoupler is turned on, the level signal output by the second optocoupler to the first microcontroller is low; conversely, when the first optocoupler is turned off, the level signal output by the second optocoupler to the first microcontroller is high.
3. The stepper motor detection device based on optical isolation according to claim 2, characterized in that: The output terminal of the first optocoupler and the input terminal of the second optocoupler are respectively connected to status indicator lights for intuitive observation of the output and input signal status.