Method for realizing automatic synchronization operation of double beds and control device thereof
By using infrared ranging sensors and SPI communication technology, the automatic synchronous operation and remote control of the two beds are realized, which solves the problems of inconvenience in operation and instability of existing physiotherapy and rehabilitation beds, and improves the convenience and safety of rehabilitation training.
Patent Information
- Application Number
- CN202411882675.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-19
- Publication Date
- 2025-11-18
- Estimated Expiration
- 2044-12-19
AI Technical Summary
Existing physiotherapy and rehabilitation beds are inconvenient to operate, cannot be remotely controlled, are unstable in operation and are noisy, and traditional control methods cannot achieve automatic synchronous operation of two beds.
Employing infrared ranging sensors and SPI communication technology, the motors of both beds are synchronously controlled via remote control. PID regulation is used to synchronize the distance difference between the beds. After stopping, the machine automatically finds a horizontal position. Combined with a DC brushless motor and a fault detection module, safety and stability are ensured.
It enables real-time synchronous operation of two beds, remote gear switching, and automatic leveling upon shutdown. It is easy to operate, reduces noise, and improves operational stability and safety.
Smart Images

Figure CN119781338B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of control and drive technology of low-voltage DC motors, and relates to a method for realizing automatic synchronous operation of dual beds, and more particularly to a method for realizing automatic synchronous operation of dual beds and its control device. Background Technology
[0002] In contemporary society, with the development and progress of science and technology, people have higher pursuits for quality of life and health, especially during illness, there is an urgent need for joint mobility or rehabilitation training, and there is an urgent need to solve the practical needs of specific audiences in this field.
[0003] Currently, most physiotherapy and rehabilitation applications still rely on manual, mechanical control, requiring traction devices or external force for assistance. This is especially problematic in situations where patients need to train independently, where existing control methods are insufficient. In such cases, new intelligent automatic control methods have emerged to meet market demands for functional applications.
[0004] The existing control method has drawbacks such as inconvenience in operation, inability to be remotely controlled, and inability to automatically return to the horizontal position after use.
[0005] Traditional physiotherapy and rehabilitation beds can only be controlled on a single bed, have poor operational stability, and produce significant noise during operation. Summary of the Invention
[0006] To address the aforementioned technical problems, the present invention aims to provide a method and control device for the automatic synchronous operation of two beds.
[0007] To achieve the above objectives, the present invention adopts the following technical solution:
[0008] A method for implementing automatic synchronous operation of two beds includes the following steps:
[0009] Step 1: After both beds are powered on, the motors are driven to run simultaneously via remote control. First, it is necessary to determine the direction of the periodic up-and-down swing of the bed. During the motor operation, the infrared ranging sensor records the distance between the bed and the infrared sensor at time t1. After an interval of 200ms, the distance between the bed and the infrared sensor at time t2 is recorded again.
[0010] Step 2: Synchronous control. When the two beds are running in the same direction, the speed of one bed (master bed) remains constant. The other bed (slave bed) obtains the distance between the bed and the infrared sensor measured by the previous bed (master bed) through SPI communication, and compares the difference δ between its own bed (slave bed) and the infrared sensor.
[0011] Step 3: When the two beds are running in different directions, the machine tool decelerates by 20% and waits for the main machine tool to run in the same direction before judging the distance difference between the bed and the infrared sensor, and then executes the synchronization control in step 2.
[0012] Step 4: When δ<0, the slave machine tool has not caught up with the master machine tool. The slave machine tool automatically accelerates to catch up with the master machine tool based on the change in distance difference using PID. When δ>0, the slave machine tool runs ahead of the master machine tool. The slave machine tool automatically decelerates to wait for the distance difference to approach the master machine tool.
[0013] Step 5: After the dual-bed remote control stops the machine, if the bed is not in a horizontal position after the stop command is issued, the driver control motor must wait for the photoelectric distance measurement to obtain the horizontal position before executing the stop action, and then execute the brake to prevent the position from moving. This ensures that the next time the machine starts running at the same time, it can quickly enter the synchronous running state and reduce the synchronization time.
[0014] Preferably, in the method for implementing automatic synchronous operation of two beds, in step 1, the upward or downward movement direction of the bed is determined by measuring the distance difference.
[0015] Preferably, in the method for achieving automatic synchronous operation of two beds, in step 4, when the distance difference δ between the two beds is within 10mm, the speed of the motors is controlled to the same value after the two beds meet the requirements for synchronous operation, so as to achieve long-term synchronous operation.
[0016] Preferably, in the method for implementing automatic synchronous operation of dual beds, in step 4, when there is a speed difference due to different loads during operation, and asynchronous operation occurs again, the action of step 3 is repeated, and the speed of the main machine tool is kept constant, and the slave machine tool synchronizes the operation of the main machine tool body according to the distance difference.
[0017] Preferably, the control device for automatic synchronous operation of two beds includes a power supply, a first control unit and a second control unit with the same module. The output terminal of the power supply is connected to the input terminal of the first control unit, and the output terminal of the power supply is connected to the input terminal of the second control unit. The first control unit is interconnected with an SPI communication circuit, and the second control unit is interconnected with an SPI communication circuit. The device also includes a remote controller. The output terminal of the remote controller is connected to the input terminal of the first remote control control unit. The control terminal of the first remote control control unit is connected to the controlled terminal of the first control unit. The output terminal of the remote controller is connected to the input terminal of the second remote control control unit, and the control terminal of the second remote control control unit is connected to the controlled terminal of the second control unit.
[0018] Preferably, in the control device for automatic synchronous operation of two beds, the first control unit includes a power adapter module. The output terminal of the power adapter module is connected to the input terminal of the motor drive module. The output terminal of the motor drive module is connected to the input terminal of the brushless DC motor. The output terminal of the brushless DC motor is connected to the input terminal of the rehabilitation training bed. The output terminal of the rehabilitation training bed is connected to the input terminal of the ranging module. The output terminal of the ranging module is connected to the input terminal of the synchronization control module. The synchronization control module is interconnected with an SPI communication circuit. The output terminal of the synchronization control module is connected to the input terminal of a 485 communication module. The output terminal of the 485 communication module is connected to the input terminal of the motor drive module. The output terminal of the motor drive module is connected to the input terminal of a fault detection module. The output terminal of the fault detection module is connected to a fault indicator light.
[0019] Preferably, in the control device for automatic synchronous operation of two beds, the first remote control unit and the second remote control unit are the same remote control module;
[0020] The first remote control unit includes a remote control module and a TTL communication module. The input terminal of the remote control module is connected to the output terminal of the remote controller, the output terminal of the remote control module is connected to the input terminal of the TTL communication module, and the output terminal of the TTL communication module is connected to the input terminal of the synchronization control module.
[0021] Preferably, in the control device for automatic synchronous operation of dual beds, the ranging module is an infrared ranging sensor.
[0022] Preferably, in the control device for automatic synchronous operation of dual beds, the synchronous control module uses a chip model of APM32F030c8T6, and the fault detection module uses a chip model of IRMCF171.
[0023] By means of the above-described solution, the present invention has at least the following advantages:
[0024] This invention can realize the functions of real-time motor-driven synchronous operation of two beds, remote-controlled gear switching, and automatic leveling when the machine stops. It is simple and convenient to operate.
[0025] The above description is merely an overview of the technical solution of the present invention. In order to better understand the technical means of the present invention and to implement it in accordance with the contents of the specification, the preferred embodiments of the present invention are described in detail below with reference to the accompanying drawings. Attached Figure Description
[0026] To more clearly illustrate the technical solutions of the embodiments of the present invention, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of the present invention and should not be regarded as a limitation on the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0027] Figure 1 This is a flowchart of the present invention;
[0028] Figure 2 This is a block diagram of the control principle of the present invention;
[0029] Figure 3 This is a circuit diagram of the motor drive module of the present invention;
[0030] Figure 4 This is a circuit diagram of the synchronization control module of the present invention;
[0031] Figure 5 This is the circuit diagram of the 485 communication module of the present invention;
[0032] Figure 6 This is a circuit diagram of the SPI communication module of the present invention;
[0033] Figure 7 This is the circuit diagram of the fault detection module of the present invention. Detailed Implementation
[0034] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, and not all embodiments. The components of the embodiments of this application described and shown in the accompanying drawings can generally be arranged and designed in various different configurations.
[0035] Therefore, the following detailed description of the embodiments of this application provided in the accompanying drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of the application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.
[0036] Example
[0037] like Figures 2 to 6As shown, a control circuit for driving motors to achieve synchronous motion of two machines includes a power supply 1, a first control unit 2 and a second control unit 3 of the same module. The output terminal of the power supply 1 is connected to the input terminal of the first control unit 2, and the output terminal of the power supply 1 is connected to the input terminal of the second control unit 3. The first control unit 2 is interconnected with an SPI communication circuit 7, and the second control unit 3 is interconnected with an SPI communication circuit 7. The circuit also includes a remote controller 4. The output terminal of the remote controller 4 is connected to the input terminal of a first remote control control unit 5. The control terminal of the first remote control control unit 5 is connected to the controlled terminal of the first control unit 2. The output terminal of the remote controller 4 is connected to the input terminal of a second remote control control unit 6, and the control terminal of the second remote control control unit 6 is connected to the controlled terminal of the second control unit 3.
[0038] In this invention, the first control unit 2 includes a power adapter module 21. The output of the power adapter module 21 is connected to the input of the motor drive module 22. The output of the motor drive module 22 is connected to the input of the brushless DC motor 23. The output of the brushless DC motor 23 is connected to the input of the rehabilitation training bed 24. The output of the rehabilitation training bed 24 is connected to the input of the ranging module 25. The output of the ranging module 25 is connected to the input of the synchronization control module 26. The synchronization control module 26 is interconnected with the SPI communication circuit 7. The output of the synchronization control module 26 is connected to the input of the 485 communication module 27. The output of the 485 communication module 27 is connected to the input of the motor drive module 22. The output of the motor drive module 22 is connected to the input of the fault detection module 28. The output of the fault detection module 28 is connected to the fault indicator light 29.
[0039] In this invention, the first remote control unit 5 and the second remote control unit 6 are the same remote control module;
[0040] The first remote control unit 5 includes a remote control module 51 and a TTL communication module 52. The input terminal of the remote control module 51 is connected to the output terminal of the remote controller 4. The output terminal of the remote control module 51 is connected to the input terminal of the TTL communication module 52. The output terminal of the TTL communication module 52 is connected to the input terminal of the synchronization control module 26.
[0041] The ranging module described in this invention is a 25 infrared ranging sensor.
[0042] The synchronization control module 26 described in this invention uses a chip model of APM32F030c8T6.
[0043] The fault detection module 28 described in this invention uses an IRMCF171 chip.
[0044] The working principle of this invention is as follows:
[0045] During operation, an external 220V power supply is converted into a 29VDC output with a 3A regulated power supply via a power adapter module to power the motor drive module. The motor drive module controls the brushless DC motor, which in turn drives the back-and-forth rocking motor, the automatic headrest lifting motor, and the joint flexion and extension push rod motor of the rehabilitation training bed. The distance measuring module monitors these actions and transmits the corresponding information to the synchronization control module for synchronous control. Feedback is also sent to the motor drive module via a 485 communication module to further improve synchronization.
[0046] in:
[0047] Power adapter module:
[0048] It converts 220VAC AC mains power into a regulated 29VDC output power supply with a capacity of 3A, providing a stable and reliable voltage input for the motor driver.
[0049] Motor drive module:
[0050] As shown in Figure 2, the variable frequency sine wave control method reduces reactive power compared to the traditional electrolytic capacitor scheme at rated power, greatly reducing the impact of harmonic noise. It can detect the actual speed of the motor in real time. The design adopts a closed-loop control mode for motor adjustment. When there is a deviation between the set target speed and the actual speed, the PID dynamically adjusts the actual speed to the target speed, which has better stability.
[0051] Synchronization control module:
[0052] To achieve synchronization between the two beds through distance measurement, each bed uses a synchronization control module. The current position status of the bed is obtained through SPI master-slave communication. When the distance sensor detects a missynchronization, it sends a 485 communication command to the motor driver. The slave device then dynamically adjusts the motor speed using PID control. When the two beds are nearly synchronized, the slave bed switches to the master bed to run at the same speed, thus achieving the requirement of synchronous operation of the two beds.
[0053] Distance measuring module:
[0054] The ranging module uses a high-precision infrared ranging sensor with a measurement accuracy error of 1mm, a power supply voltage of 5V, and a ranging range of 10-70CM to achieve real-time monitoring of the bed's position.
[0055] Remote control refers to a remote control module (both known remote controls and remote control modules):
[0056] The remote control circuit and remote controller use 2.4G wireless communication. Electromagnetic wave propagation has penetrability, reflection and diffraction. This method can achieve long distance, wide range, and simultaneous control of multiple devices by a single remote controller, thereby enabling synchronous start and stop operations.
[0057] TTL communication module:
[0058] After receiving a gear switching request from the remote controller, the remote control circuit sends a gear switching command to the synchronous control box via TTL communication to realize the gear switching.
[0059] SPI communication module:
[0060] The current position information between the two beds is exchanged via SPI communication. When the synchronization box obtains the position deviation between the beds, it performs synchronous PID adjustment.
[0061] 485 communication module:
[0062] This interface adopts the standard RS485 communication protocol, and the communication command is sent once every 1 second. If the communication is interrupted abnormally for more than 30 seconds, the motor driver will automatically stop, which improves reliability and safety.
[0063] DC brushless motor:
[0064] The motor is a brushless DC motor with a reduction ratio of 1:50, which achieves the purpose of high torque start-up when running at low speed.
[0065] Rehabilitation training bed (existing technology in this field):
[0066] The bed is equipped with a front and rear rocking motor, an automatic headboard lifting motor, a joint extension and flexion push rod motor, and a position locking device.
[0067] Fault detection module:
[0068] The motor driver fault detection circuit includes alarms for motor overcurrent, loss of synchronism, stalled rotor, phase loss, overvoltage, and undervoltage. Overcurrent alarms include both hardware and software methods, displaying fault codes via indicator lights. Software overcurrent protection works by sampling the voltage between current-sampling resistors and amplifying it; when the sampled current exceeds a limit, the power device's output is shut off. This dual hardware and software overcurrent protection improves the reliability of the frequency converter drive and further protects the motor and user safety.
[0069] The working principle of this invention is as follows:
[0070] like Figure 1As shown, a method for implementing automatic synchronous operation of two beds includes the following steps:
[0071] Step 1: After both beds are powered on, the motors are driven to run simultaneously via remote control. First, it is necessary to determine the direction of the periodic up-and-down swing of the bed. During the motor operation, the infrared ranging sensor records the distance between the bed and the infrared sensor at time t1. After an interval of 200ms, the distance between the bed and the infrared sensor at time t2 is recorded again.
[0072] Step 2: Synchronous control. When the two beds are running in the same direction, the speed of one bed (master bed) remains constant. The other bed (slave bed) obtains the distance between the bed and the infrared sensor measured by the previous bed (master bed) through SPI communication, and compares the difference δ between its own bed (slave bed) and the infrared sensor.
[0073] Step 3: When the two beds are running in different directions, the machine tool decelerates by 20% and waits for the main machine tool to run in the same direction before judging the distance difference between the bed and the infrared sensor, and then executes the synchronization control in step 2.
[0074] Step 4: When δ<0, the slave machine tool has not caught up with the master machine tool. The slave machine tool automatically accelerates to catch up with the master machine tool based on the change in distance difference using PID. When δ>0, the slave machine tool runs ahead of the master machine tool. The slave machine tool automatically decelerates to wait for the distance difference to approach the master machine tool.
[0075] Step 5: After the dual-bed remote control stops the machine, if the bed is not in a horizontal position after the stop command is issued, the driver control motor must wait for the photoelectric distance measurement to obtain the horizontal position before executing the stop action, and then execute the brake to prevent the position from moving. This ensures that the next time the machine starts running at the same time, it can quickly enter the synchronous running state and reduce the synchronization time.
[0076] In step 1, the direction of the bed's upward or downward movement is determined by measuring the distance difference.
[0077] In step 4, when the distance difference δ between the two beds is within 10mm, the two beds meet the requirement of synchronous operation, and the motor speed is controlled to the same value to achieve long-term synchronous operation.
[0078] In step 4, when a speed difference occurs due to different loads during operation, and the operation becomes asynchronous again, the action of step 3 is repeated. The speed of the main machine tool remains unchanged, and the slave machine tool synchronizes the operation of the main machine tool body according to the distance difference.
[0079] It should be noted that similar labels and letters in the following figures indicate similar items. Therefore, once an item is defined in one figure, it does not need to be further defined and explained in subsequent figures.
[0080] In the description of this application, it should be noted that the terms "vertical," "horizontal," "inner," and "outer," etc., indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings, or the orientation or positional relationship commonly used when the product is in use. They are used only for the convenience of describing this application and for simplifying the description, and do not indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on this application. Furthermore, the terms "first," "second," etc., are used only to distinguish descriptions and should not be construed as indicating or implying relative importance.
[0081] Furthermore, terms such as "horizontal" and "vertical" do not imply that components must be absolutely horizontal or vertical, but rather that they can be slightly tilted. For example, "horizontal" simply means that its direction is more horizontal than "vertical," and does not mean that the structure must be completely horizontal, but can be slightly tilted.
[0082] In the description of this application, it should also be noted that, unless otherwise expressly specified and limited, the terms "set up," "install," "connect," and "link" should be interpreted broadly. For example, they can refer to a fixed connection, a detachable connection, or an integral connection; they can refer to a mechanical connection or an electrical connection; they can refer to a direct connection or an indirect connection through an intermediate medium; and they can refer to the internal connection of two components. Those skilled in the art can understand the specific meaning of the above terms in this application based on the specific circumstances.
[0083] The above description is merely a preferred embodiment of the present invention and is not intended to limit the present invention. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the technical principles of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.
Claims
1. A method for implementing automatic synchronous operation of two beds, characterized in that, Includes the following steps: Step 1: After both beds are powered on, the motors are driven to run simultaneously via remote control. First, it is necessary to determine the direction of the periodic up-and-down swing of the bed. During the motor operation, the infrared ranging sensor records the distance between the bed and the infrared sensor at time t1. After an interval of 200ms, the distance between the bed and the infrared sensor at time t2 is recorded again. Step 2: Synchronization control. When the two beds are running in the same direction, the speed of one bed remains constant. The other bed obtains the distance between the bed and the infrared sensor measured by the previous bed through SPI communication and compares the difference δ between its own bed and the infrared sensor. Step 3: When the two beds are running in different directions, the machine tool decelerates by 20% and waits for the main machine tool to run in the same direction before judging the distance difference between the bed and the infrared sensor, and then executes the synchronization control in step 2. Step 4: When δ<0, the slave machine tool has not caught up with the master machine tool. The slave machine tool automatically accelerates to catch up with the master machine tool based on the change in distance difference using PID. When δ>0, the slave machine tool runs ahead of the master machine tool. The slave machine tool automatically decelerates to wait for the distance difference to approach the master machine tool. Step 5: After the dual-bed remote control stops the machine, if the bed is not in a horizontal position after the stop command is issued, the driver control motor must wait for the photoelectric distance measurement to obtain the horizontal position before executing the stop action, and then execute the brake to prevent the position from moving. This ensures that the next time the machine starts running at the same time, it can quickly enter the synchronous running state and reduce the synchronization time.
2. The method for achieving automatic synchronization operation of a dual-bed according to claim 1, characterized in that: In step 1, the direction of the bed's upward or downward movement is determined by measuring the distance difference.
3. The method of claim 1, wherein the method comprises: In step 4, when the distance difference δ between the two beds is within 10mm, the two beds meet the requirement of synchronous operation, and the motor speed is controlled to the same value to achieve long-term synchronous operation.
4. The method of claim 1, wherein: In step 4, when a speed difference occurs due to different loads during operation, and the operation becomes asynchronous again, the action of step 3 is repeated. The speed of the main machine tool remains unchanged, and the slave machine tool synchronizes the operation of the main machine tool body according to the distance difference.
5. A control device for automatic synchronization of dual-bed operation, characterized by: The implementation method according to any one of claims 1-4.
6. The control device for automatic synchronization operation of a dual bed according to claim 5, wherein: The system includes a power supply (1), a first control unit (2) and a second control unit (3) of the same module. The output terminal of the power supply (1) is connected to the input terminal of the first control unit (2), and the output terminal of the power supply (1) is connected to the input terminal of the second control unit (3). The first control unit (2) is interconnected with the SPI communication circuit (7), and the second control unit (3) is interconnected with the SPI communication circuit (7). The system also includes a remote controller (4). The output terminal of the remote controller (4) is connected to the input terminal of the first remote control unit (5). The control terminal of the first remote control unit (5) is connected to the controlled terminal of the first control unit (2). The output terminal of the remote controller (4) is connected to the input terminal of the second remote control unit (6), and the control terminal of the second remote control unit (6) is connected to the controlled terminal of the second control unit (3).
7. The control device for automatic synchronization operation of a dual bed according to claim 6, wherein: The first control unit (2) includes a power adapter module (21). The output of the power adapter module (21) is connected to the input of the motor drive module (22). The output of the motor drive module (22) is connected to the input of the brushless DC motor (23). The output of the brushless DC motor (23) is connected to the input of the rehabilitation training bed (24). The output of the rehabilitation training bed (24) is connected to the input of the ranging module (25). The output of the ranging module (25) is connected to the input of the synchronization control module (26). The synchronization control module (26) is interconnected with the SPI communication circuit (7). The output of the synchronization control module (26) is connected to the input of the 485 communication module (27). The output of the 485 communication module (27) is connected to the input of the motor drive module (22). The output of the motor drive module (22) is connected to the input of the fault detection module (28). The output of the fault detection module (28) is connected to the fault indicator light (29).
8. The control device for automatic synchronization operation of a dual bed according to claim 6, wherein: The first remote control unit (5) and the second remote control unit (6) are the same remote control module; The first remote control unit (5) includes a remote control module (51) and a TTL communication module (52). The input terminal of the remote control module (51) is connected to the output terminal of the remote controller (4). The output terminal of the remote control module (51) is connected to the input terminal of the TTL communication module (52). The output terminal of the TTL communication module (52) is connected to the input terminal of the synchronization control module (26).
9. The control device for automatic synchronization operation of a dual bed according to claim 6, wherein: The ranging module is an infrared ranging sensor (25).
10. A control device for automatic synchronous operation of two beds according to claim 6, characterized in that: The synchronous control module (26) uses an APM32F030c8T6 chip, and the fault detection module (28) uses an IRMCF171 chip.
Citation Information
Patent Citations
Electric bed networking pairing method and device based on Internet of Things
CN113645596A
Bed control motor push rod driving system
CN118432478A