CN114179080B - Motion control method, motion control device, mechanical arm, interaction system and storage medium - Google Patents
Motion control method, motion control device, mechanical arm, interaction system and storage medium Download PDFInfo
- Publication number
- CN114179080B CN114179080B CN202111454235.4A CN202111454235A CN114179080B CN 114179080 B CN114179080 B CN 114179080B CN 202111454235 A CN202111454235 A CN 202111454235A CN 114179080 B CN114179080 B CN 114179080B
- Authority
- CN
- China
- Prior art keywords
- load
- external force
- mechanical arm
- electronic device
- feedback
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 230000033001 locomotion Effects 0.000 title claims abstract description 122
- 238000000034 method Methods 0.000 title claims abstract description 77
- 230000003993 interaction Effects 0.000 title abstract description 21
- 230000009471 action Effects 0.000 claims abstract description 27
- 230000036544 posture Effects 0.000 claims description 41
- 238000006073 displacement reaction Methods 0.000 claims description 19
- 238000004422 calculation algorithm Methods 0.000 claims description 18
- 230000002452 interceptive effect Effects 0.000 claims description 8
- 230000008569 process Effects 0.000 abstract description 19
- 238000010586 diagram Methods 0.000 description 7
- 238000006243 chemical reaction Methods 0.000 description 6
- 230000006870 function Effects 0.000 description 6
- 230000000694 effects Effects 0.000 description 5
- 230000005484 gravity Effects 0.000 description 3
- 238000004364 calculation method Methods 0.000 description 2
- 230000001413 cellular effect Effects 0.000 description 1
- 230000008859 change Effects 0.000 description 1
- 238000004590 computer program Methods 0.000 description 1
- 230000006872 improvement Effects 0.000 description 1
- 238000009877 rendering Methods 0.000 description 1
- 238000004088 simulation Methods 0.000 description 1
- 238000005303 weighing Methods 0.000 description 1
Classifications
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B25—HAND TOOLS; PORTABLE POWER-DRIVEN TOOLS; MANIPULATORS
- B25J—MANIPULATORS; CHAMBERS PROVIDED WITH MANIPULATION DEVICES
- B25J9/00—Programme-controlled manipulators
- B25J9/16—Programme controls
- B25J9/1628—Programme controls characterised by the control loop
- B25J9/1633—Programme controls characterised by the control loop compliant, force, torque control, e.g. combined with position control
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B25—HAND TOOLS; PORTABLE POWER-DRIVEN TOOLS; MANIPULATORS
- B25J—MANIPULATORS; CHAMBERS PROVIDED WITH MANIPULATION DEVICES
- B25J9/00—Programme-controlled manipulators
- B25J9/16—Programme controls
- B25J9/1602—Programme controls characterised by the control system, structure, architecture
-
- B—PERFORMING OPERATIONS; TRANSPORTING
- B25—HAND TOOLS; PORTABLE POWER-DRIVEN TOOLS; MANIPULATORS
- B25J—MANIPULATORS; CHAMBERS PROVIDED WITH MANIPULATION DEVICES
- B25J9/00—Programme-controlled manipulators
- B25J9/16—Programme controls
- B25J9/1656—Programme controls characterised by programming, planning systems for manipulators
- B25J9/1664—Programme controls characterised by programming, planning systems for manipulators characterised by motion, path, trajectory planning
Landscapes
- Engineering & Computer Science (AREA)
- Robotics (AREA)
- Mechanical Engineering (AREA)
- Automation & Control Theory (AREA)
- Manipulator (AREA)
Abstract
The embodiment of the application discloses a motion control method, a motion control device, a mechanical arm, an interaction system and a storage medium. The method comprises the steps of obtaining an external force load obtained when the mechanical arm is in a current gesture, wherein the external force load is a load applied to the mechanical arm by electronic equipment connected with the mechanical arm under the action of external force, determining feedback parameters based on the external force load, and controlling the mechanical arm to apply force feedback to the electronic equipment based on the feedback parameters. Through the mode, after the electronic equipment is connected with the mechanical arm, the electronic equipment can apply load to the mechanical arm under the condition of external force action, so that the mechanical arm can give force feedback to the electronic equipment according to the received external force load, and further a user can provide more real experience for the user in the process of using the electronic equipment, and user experience is improved.
Description
Technical Field
The application belongs to the technical field of mechanical control, and particularly relates to a motion control method, a motion control device, a mechanical arm, an interaction system and a storage medium.
Background
With the richness of applications in electronic devices, users may use applications in electronic devices to achieve various functional requirements, but related electronic devices (e.g., mobile phones) cannot provide force feedback to users in the use process, so that user experience needs to be improved.
Disclosure of Invention
In view of the above, the present application proposes a motion control method, apparatus, robot arm, interactive system, and storage medium to achieve improvement of the above problems.
In a first aspect, an embodiment of the present application provides a motion control method, which is applied to a mechanical arm, and the method includes obtaining an external force load obtained when the mechanical arm is in a current posture, where the external force load is a load applied to the mechanical arm by an electronic device connected with the mechanical arm under an external force action, determining a feedback parameter based on the external force load, and controlling the mechanical arm to apply force feedback to the electronic device based on the feedback parameter.
In a second aspect, an embodiment of the present application provides a motion control device, which is operated on a mechanical arm, where the motion control device includes a load obtaining unit, configured to obtain an external force load obtained when the mechanical arm is in a current posture, where the external force load is a load applied to the mechanical arm by an electronic device connected to the mechanical arm under an external force effect, a parameter determining unit, configured to determine a feedback parameter based on the external force load, and a feedback unit, configured to control the mechanical arm to apply force to the electronic device to feedback based on the feedback parameter.
In a third aspect, an embodiment of the present application provides a mechanical arm, where the mechanical arm includes a revolute joint, a link between the revolute joints, and a motor for driving the revolute joint, and the mechanical arm is configured to perform the method described above.
In a fourth aspect, an embodiment of the present application provides an interaction system, where the interaction system includes an electronic device and a mechanical arm, and the electronic device is connected to the mechanical arm.
In a fifth aspect, embodiments of the present application provide a computer readable storage medium having program code stored therein, wherein the above-described method is performed when the program code is run.
The embodiment of the application provides a motion control method, a motion control device, an interaction system and a storage medium. The method comprises the steps of firstly obtaining an external force load obtained when the mechanical arm is in a current gesture, wherein the external force load is a load applied to the mechanical arm by electronic equipment connected with the mechanical arm under the action of external force, and then determining a feedback parameter based on the external force load, so that the mechanical arm is controlled to apply force to the electronic equipment for feedback according to the feedback parameter. Through the mode, after the electronic equipment is connected with the mechanical arm, the electronic equipment can apply load to the mechanical arm under the condition of external force action, so that the mechanical arm can give force feedback to the electronic equipment according to the received external force load, and further a user can provide more real experience for the user in the process of using the electronic equipment, and user experience is improved.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings that are needed in the description of the embodiments will be briefly described below, it being obvious that the drawings in the following description are only some embodiments of the present application, and that other drawings may be obtained according to these drawings without inventive effort for a person skilled in the art.
Fig. 1 is a schematic diagram of an application scenario of a motion control method according to an embodiment of the present application;
fig. 2 is a schematic diagram of an application scenario of a motion control method according to an embodiment of the present application;
FIG. 3 is a flow chart of a motion control method according to an embodiment of the present application;
FIG. 4 is a flow chart of a motion control method according to another embodiment of the present application;
FIG. 5 is a flow chart of a motion control method according to yet another embodiment of the present application;
FIG. 6 is a flow chart of a motion control method according to yet another embodiment of the present application;
FIG. 7 is a block diagram showing a motion control apparatus according to an embodiment of the present application;
Fig. 8 shows a structural diagram of a mechanical arm according to an embodiment of the present application;
fig. 9 shows a block diagram of an electronic device for performing a motion control method according to an embodiment of the present application in real time;
Fig. 10 shows a storage unit for storing or carrying program code for implementing a motion control method according to an embodiment of the present application in real time.
Detailed Description
The following description of the embodiments of the present application will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present application, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
With the richness of applications in electronic devices, users may use applications in electronic devices to achieve various functional requirements, but related electronic devices (e.g., mobile phones) cannot provide force feedback to users in the use process, so that user experience needs to be improved.
Accordingly, the inventors propose a motion control method, apparatus, robotic arm, interactive system, and storage medium in the present application. The method comprises the steps of firstly obtaining an external force load obtained when the mechanical arm is in a current gesture, wherein the external force load is a load applied to the mechanical arm by electronic equipment connected with the mechanical arm under the action of external force, and then determining a feedback parameter based on the external force load, so that the mechanical arm is controlled to apply force to the electronic equipment for feedback according to the feedback parameter. According to the method, the motion state of the mechanical arm is changed through the external force load applied to the mechanical arm by the electronic equipment connected with the mechanical arm under the action of external force, so that force feedback is provided for a user, more real feeling is provided for the user, and user experience is improved.
Referring to fig. 1, fig. 1 is a schematic diagram of an application scenario of a motion control method according to an embodiment of the application. The motion control method may be applied to the interactive system 100 shown in fig. 1, and the interactive system 100 may include the electronic device 110 and the mechanical arm 120. The electronic device 110 may be held by the arm 120 at the end of the arm 120 by a clamping tool. Further, when the user is operating the electronic device 110, the mechanical arm 120 can sense the force applied by the user on the electronic device 110, and feedback the reaction force or resistance opposite to the force applied by the user on the electronic device 110 to the user, so as to bring a more complete user experience to the user. The mechanical arm 120 may include a rotational joint, a link between the rotational joints, and a motor driving the rotational joint. When the robotic arm 120 feeds back to the user a reaction force or resistance in the same, opposite direction as the force applied by the user to the electronic device 110, the force applied by the user to the electronic device 110 may be sensed by a motor in the robotic arm 120 driving a revolute joint. The feedback parameter may then be determined by the force exerted on the electronic device 110 by the user as perceived by the motor in the robotic arm driving the revolute joint, such that the robotic arm 120 may be controlled to exert force feedback on the electronic device 110 by the feedback parameter.
In an embodiment of the present application, force feedback for different interaction scenarios may be simulated by an interaction system 100 as shown in fig. 1.
For example, in an application scenario in which a racing game simulates a steering wheel, the electronic device 110 in the interactive system 100 may be used as a steering wheel, when an operation of the user acting on the electronic device 110 (for example, an operation of the user rotating the electronic device 110) is detected, a force acting on the electronic device 110 when the user rotates the electronic device 110 may be obtained through the mechanical arm 120, and then the mechanical arm 120 may feedback a reaction force or resistance acting on the electronic device 110 in the same direction as that of the force acting on the electronic device 110 when the user rotates the electronic device 110 to the user. The reaction force may be the same force as the force applied to the electronic device when the user rotates the electronic device 110 and the opposite force, and the resistance force may be the force fed back to the electronic device 110 when the simulated racing car hits the wall.
For another example, in an application scenario simulating a gunshot game, the electronic device 110 in the interactive system 100 may be used as a carrier for simulating the gunshot game. When the operation of clicking the electronic device 110 by the user is detected, it is determined that the user starts shooting the target object, and at this time, the force acting on the electronic device 110 when the user clicks the electronic device 110 can be acquired through the mechanical arm 120, so that the reaction force having the same magnitude and opposite direction as the force acting on the electronic device 110 when the user clicks the electronic device 110 can be fed back to the user through the mechanical arm 120.
Alternatively, as shown in fig. 2, a communication unit may be disposed in the mechanical arm 120, so that the mechanical arm 120 may also be connected to the server 130. Further, when the force applied to the electronic device 110 by the user is obtained through the motor driving the rotation joint in the mechanical arm 120, the mechanical arm 120 may transmit the force applied to the electronic device 110 by the user to the server 130 through the communication unit, and the server 130 may determine a feedback parameter based on the force applied to the electronic device 110 by the user and transmit the feedback parameter to the mechanical arm 120, so that the mechanical arm 120 may control the motor to perform a corresponding operation to apply force feedback to the electronic device 110 based on the feedback parameter.
Optionally, the mechanical arm 120 may also establish a wireless communication connection with the electronic device 110 through the communication unit, so that the mechanical arm 120 may directly obtain the interaction data from the electronic device 110.
It should be noted that, the electronic device 110 may be a car device, a wearable device, a tablet computer, a notebook computer, a smart speaker, etc. in addition to the smart phone shown in fig. 1 and 2. The server 120 may be a stand-alone physical server, or may be a server cluster or a distributed system formed by a plurality of physical servers.
Alternatively, the motor driving the rotary joint in the mechanical arm 120 may also be referred to as a servo motor (servo motor), where the servo motor is an engine that controls the operation of mechanical elements in a servo system, and is an indirect speed change device of a supplementary motor.
The servo motor can accurately control the speed and the position accuracy, and can convert the voltage signal into the torque and the rotating speed to drive a control object. The rotation speed of the rotor of the servo motor is controlled by an input signal, can react quickly, is used as an executive component in an automatic control system, has the characteristics of small electromechanical time constant, high linearity and the like, and can convert the received electric signal into angular displacement or angular speed output on the motor shaft. The servo motor can be divided into two major types of direct current and alternating current servo motors, and is mainly characterized in that when the signal voltage is zero, no autorotation phenomenon exists, and the rotating speed is reduced at a constant speed along with the increase of the torque.
Embodiments of the present application will be described in detail below with reference to the accompanying drawings.
Referring to fig. 3, a motion control method provided by an embodiment of the present application is applied to a mechanical arm in an interaction system as shown in fig. 1, and the method includes:
Step S110, obtaining an external force load obtained when the mechanical arm is in the current gesture, wherein the external force load is applied to the mechanical arm by electronic equipment connected with the mechanical arm under the action of external force.
In the embodiment of the application, the current gesture of the mechanical arm can be the gesture of the mechanical arm when the external force load is obtained, and the external force load can be understood as the load of the mechanical arm applied by the external force acting on the electronic equipment when a user operates the electronic equipment, for example, the magnitude of the force acting on the electronic equipment when the user operates the electronic equipment is 10N, and then the load of the external force acting on the electronic equipment when the user operates the electronic equipment is 10N.
As one way, the mechanical arm can fix the electronic device through one clamping tool, and then when detecting that the user is operating the electronic device, the mechanical arm can acquire the load applied to the mechanical arm by the external force acting on the electronic device when the user is operating the electronic device.
Optionally, in the interaction process of the electronic device and the mechanical arm, the external force load can be obtained in real time through the mechanical arm.
And step S120, determining a feedback parameter based on the external force load.
In the embodiment of the application, the feedback parameter may include a motion parameter or a feedback force.
As one way, when determining the feedback parameter based on the external force load, it may be determined what the feedback parameter is specifically based on the magnitude of the external force load. As one mode, if the external force load is larger than a preset load threshold, the feedback parameter is determined to be a motion parameter, and if the external force load is smaller than or equal to the load threshold, the feedback parameter is determined to be a feedback force. In another mode, if the external force load is smaller than or equal to the preset external force load, the feedback parameter is determined to be the feedback force, and if the external force load is larger than the preset external force load, the feedback parameter is determined to be the motion parameter, and the method is not particularly limited.
And step S130, controlling the mechanical arm to apply force feedback to the electronic equipment based on the feedback parameters.
In the embodiment of the application, after the feedback parameters are determined based on the external force load, the motion state of the mechanical arm can be changed based on the feedback parameters so as to control the mechanical arm to apply force feedback to the electronic equipment.
According to the motion control method provided by the application, firstly, the external force load obtained when the mechanical arm is in the current gesture is obtained, the external force load is the load applied to the mechanical arm by the electronic equipment connected with the mechanical arm under the action of external force, and then the feedback parameter is determined based on the external force load, so that the mechanical arm is controlled to apply force to the electronic equipment according to the feedback parameter for feedback. Through the mode, after the electronic equipment is connected with the mechanical arm, the electronic equipment can apply load to the mechanical arm under the condition of external force action, so that the mechanical arm can give force feedback to the electronic equipment according to the received external force load, and further a user can provide more real experience for the user in the process of using the electronic equipment, and user experience is improved.
Referring to fig. 4, a motion control method provided by an embodiment of the present application is applied to a mechanical arm in an interaction system as shown in fig. 1, and the method includes:
Step S210, a first load when the mechanical arm is in the current gesture is obtained, wherein the first load is the load detected by each motor of the mechanical arm when the electronic equipment connected with the mechanical arm is acted by external force.
In the embodiment of the application, the current gesture of the mechanical arm can be understood as the gesture of the mechanical arm at the current moment. In the interaction process of the mechanical arm and the electronic equipment, the current gesture of the mechanical arm can be obtained in real time. The first load is all loads of the mechanical arm and the electronic equipment in the interaction process.
As one way, the current posture of the mechanical arm can be determined based on the joint angles of the mechanical arm acquired by the motors included in the mechanical arm, and the current posture of the mechanical arm can be calculated through a forward kinematics algorithm according to the joint angles of the mechanical arm acquired by the motors included in the mechanical arm.
Alternatively, the joint angle of the mechanical arm can also be directly obtained through a motor included in the mechanical arm.
And step S220, based on the first load and the second load, determining the external force load of each motor of the mechanical arm, wherein the second load is the load detected by each motor of the mechanical arm when the electronic equipment connected with the mechanical arm has no external force effect and the mechanical arm is in the current gesture.
In the embodiment of the application, the second load refers to a load detected by each motor of the mechanical arm when the mechanical arm is in the current posture and is only subjected to self gravity and connection supporting force with the electronic equipment and is not subjected to other external acting forces.
As one way, after the first load and the second load are obtained, a difference value between the first load and the second load may be calculated, and the difference value between the first load and the second load is determined as an external force load of each motor of the mechanical arm.
Step S230, determining whether the external force load exceeds a load threshold, if so, executing step S240 and step S250, and if not, executing step S260.
In the embodiment of the application, the load threshold is a limit of the external force load of the mechanical arm under each gesture, which is set before the interaction of the user. As one way, the load threshold may be a maximum external load that the mechanical arm can bear when the mechanical arm is in the current posture. When the mechanical arms are in different postures, the corresponding maximum bearable external force loads can be the same or different.
Alternatively, the load threshold may be a fixed value or may be a dynamically adjustable value, which is not specifically limited herein.
As a way, after the external force load of the mechanical arm in the current posture is obtained, the load threshold corresponding to the current posture can be obtained, and then the external force load of the mechanical arm in the current posture is compared with the load threshold.
And step 240, determining a motion parameter triggering the electronic equipment to move based on the external force load, wherein the load threshold is different when the mechanical arm is in different postures.
In the embodiment of the application, if the external force load of the mechanical arm in the current gesture is greater than the load threshold, determining the motion parameter for triggering the electronic equipment to move based on the external force load.
And step S250, based on the motion parameters, controlling each motor of the mechanical arm to execute corresponding motion so as to apply force feedback to the electronic equipment.
In the embodiment of the application, after the motion parameters triggering the electronic equipment to move are determined, each motor of the mechanical arm is controlled to execute the motion corresponding to the motion parameters so as to apply force feedback to the electronic equipment, so that a user can experience the force feedback.
And step S260, determining feedback force triggering the electronic equipment to move based on the external force load.
In the embodiment of the application, the feedback force is the force with the same magnitude but opposite directions of the external force load. When the external force load of the mechanical arm in the current gesture is smaller than or equal to a load threshold value, determining feedback force for triggering the electronic equipment to move based on the external force load, and applying force feedback to the electronic equipment based on the feedback force. At this point, force feedback may be provided by keeping the motors of the robotic arm non-rotating.
The motion control method comprises the steps of firstly obtaining a first load and a second load when the mechanical arm is in a current gesture, then determining external force loads of motors of the mechanical arm based on the first load and the second load, judging whether the external force loads exceed a load threshold, determining motion parameters for triggering the electronic equipment to perform motion based on the external force loads if the external force loads exceed the load threshold, controlling the motors of the mechanical arm to perform corresponding motion based on the motion parameters so as to apply force feedback to the electronic equipment, and determining feedback force for triggering the electronic equipment to perform motion based on the external force loads if the external force loads do not exceed the feedback force. Through the mode, after the electronic equipment is connected with the mechanical arm, the electronic equipment can apply load to the mechanical arm under the condition of external force action, so that the mechanical arm can give force feedback to the electronic equipment according to the received external force load, and further a user can provide more real experience for the user in the process of using the electronic equipment, and user experience is improved.
Referring to fig. 5, a motion control method provided by an embodiment of the present application is applied to a mechanical arm in an interaction system as shown in fig. 1, and the method includes:
and step S310, receiving an external force load transmitted by the electronic equipment through a wireless communication mode.
In the embodiment of the application, the mechanical arm is provided with the wireless communication module, so that the electronic equipment and the mechanical arm can perform wireless communication, the mechanical arm can directly acquire corresponding data from the electronic equipment, and the electronic equipment can also directly transmit the data to the mechanical arm.
As one way, the electronic device is provided with a data acquisition module capable of directly acquiring an external force load acting on the electronic device by a user. When the electronic equipment detects that a user is operating the electronic equipment, the external force load of the user acting on the electronic equipment is acquired through a data acquisition module arranged in the electronic equipment. And then the external force load obtained by the electronic equipment is sent to the mechanical arm, and the mechanical arm can calculate and obtain the motion parameters of each motor of the mechanical arm based on the inverse kinematics algorithm and the external force load stored in the mechanical arm in advance.
Optionally, when the electronic device detects that the user clicks the display screen of the electronic device or rotates the operation of the electronic device, it is determined that the user is operating the electronic device.
In another way, the electronic device may acquire a pre-stored inverse kinematics algorithm from the mechanical arm after acquiring an external force load acting on the electronic device by a user, and calculate the motion parameters of each motor of the mechanical arm through the inverse kinematics algorithm and the external force load. And then the electronic equipment can transmit the motion parameters of the motors of the mechanical arm to the mechanical arm so that the mechanical arm can control the motors of the mechanical arm to execute corresponding motions based on the motion parameters.
Step S320, obtaining a preset corresponding relation, wherein the preset corresponding relation is a corresponding relation between external force loads and motion parameters, and different external force loads correspond to different motion parameters.
In the embodiment of the application, in the interaction process of the mechanical arm and the electronic equipment, because the operation modes of the user on the electronic equipment are different, the external force load applied to the electronic equipment by the user is possibly different, and meanwhile, the mechanical arm connected with the electronic equipment is possibly in different postures under the action of the user. For example, when a user plays a gun shot game through an electronic device, the user operates more of the electronic device to click on the electronic device, and when the user plays a racing game through the electronic device, the user operates more of the electronic device to rotate the electronic device, and the magnitude and direction of the force acting on the electronic device by the operation of the click electronic device and the operation of the rotation electronic device may be different, the force acting on the electronic device by the operation of the click electronic device is more of the downward force, and the force acting on the electronic device by the operation of the rotation electronic device is more of the leftward or rightward force.
Wherein a downward force may cause the end of the arm connected to the electronic device to move in a direction toward the ground, and a leftward or rightward force may cause the end of the arm connected to the electronic device to translate in a leftward or rightward direction. Since the distal ends of the mechanical arms may move in different directions, the mechanical arms connected to the electronic device may be caused to be in different postures under the action of the user.
Therefore, when the corresponding relation between the external force load and the motion parameter is established, the corresponding relation between the external force load and the motion parameter can be established when the mechanical arm is in different postures under different scenes. For example, in an application scenario of the racing game simulation steering wheel, the mechanical arm corresponds to a gesture 1, a gesture 2, a gesture 3 and a gesture 4, and further when a corresponding relation between an external force load and a motion parameter is established, a corresponding relation between the external force load and the corresponding motion parameter when the mechanical arm is in the gesture 1, a corresponding relation between the external force load and the corresponding motion parameter when the mechanical arm is in the gesture 2, a corresponding relation between the external force load and the corresponding motion parameter when the mechanical arm is in the gesture 3, and a corresponding relation between the external force load and the corresponding motion parameter when the mechanical arm is in the gesture 4 are established.
As a way, the preset correspondence may be stored in a storage area of the electronic device, or may be stored in a storage area of the mechanical arm, and further may be obtained from the corresponding storage area when the preset correspondence needs to be obtained.
Step S330, determining a motion parameter corresponding to the external force load and triggering the electronic equipment to move based on the preset corresponding relation.
In the embodiment of the application, after the preset corresponding relation is obtained, the motion parameter corresponding to the external force load transmitted by the electronic equipment in a wireless communication mode can be determined by searching the preset corresponding relation.
And step 340, based on the motion parameters, controlling each motor of the mechanical arm to execute corresponding motion so as to apply force feedback to the electronic equipment.
In the embodiment of the application, when the electronic equipment detects that the user is operating the electronic equipment, the external force load applied to the electronic equipment by the user is acquired through the data acquisition module arranged in the electronic equipment. And then the external force load obtained by the electronic equipment is sent to the mechanical arm, and the mechanical arm can calculate the motion parameters of the motors of the mechanical arm based on a pre-stored inverse kinematics algorithm and the external force load in the mechanical arm.
After the electronic equipment also can obtain the external force load of the user acting on the electronic equipment, a prestored inverse kinematics algorithm is obtained from the mechanical arm, and the motion parameters of the motors of the mechanical arm are obtained through the inverse kinematics algorithm and the external force load calculation. The electronic device may then transmit the motion parameters of the motors of the robotic arm to the robotic arm, such that the robotic arm controls the motors of the robotic arm to perform corresponding movements based on the motion parameters, after the electronic equipment calculates the motion parameters of the motors of the mechanical arm, a control instruction can be sent to the mechanical arm, and the mechanical arm can control the motors of the mechanical arm to execute corresponding motions based on the control instruction sent by the electronic equipment so as to apply force feedback to the electronic equipment.
According to the motion control method provided by the application, firstly, the external force load transmitted by the electronic equipment through a wireless communication mode is received, then, the preset corresponding relation between the external force load and the motion parameters is obtained, the motion parameters which trigger the electronic equipment to move and correspond to the external force load are determined based on the preset corresponding relation, and finally, based on the motion parameters, the motors of the mechanical arm are controlled to execute corresponding motions so as to apply force feedback to the electronic equipment. Through the mode, after the electronic equipment is connected with the mechanical arm, the electronic equipment can apply load to the mechanical arm under the condition of external force action, so that the mechanical arm can give force feedback to the electronic equipment according to the received external force load, and further a user can provide more real experience for the user in the process of using the electronic equipment, and user experience is improved.
Referring to fig. 6, a motion control method provided by an embodiment of the present application is applied to a mechanical arm in an interaction system as shown in fig. 1, and the method includes:
Step S410, a first load when the mechanical arm is in the current gesture is obtained, wherein the first load is the load detected by each motor of the mechanical arm when the electronic equipment connected with the mechanical arm is acted by external force.
And S420, obtaining the size and the weight of each shaft of the mechanical arm.
In the embodiment of the application, each shaft of the mechanical arm can be understood as a connecting rod between each rotating joint of the mechanical arm. The dimensions of the axes of the robotic arm may include the length and center of gravity of the axes of the robotic arm.
As one way, before the mechanical arm is used, the size and weight of each shaft of the mechanical arm can be obtained through measuring, weighing, calculating and other processes, the size and weight of each shaft of the mechanical arm are stored as parameters, and when the size and weight of each shaft of the mechanical arm need to be obtained, the size and weight of each shaft of the mechanical arm can be obtained from a storage area in which the size and weight of each shaft of the mechanical arm are stored.
Alternatively, when the first load when the robot arm is in the current posture is acquired by the robot arm, the acquisition of the size and weight of each axis of the robot arm from the storage area in which the size and weight of each axis of the robot arm are stored may be started.
Alternatively, the robotic arm may be controlled to be in a plurality of different spatial poses. Under the condition that the connected electronic equipment has no external force, the size and the weight of each shaft of the mechanical arm are recorded when the mechanical arm is in each space posture.
Step S430, obtaining the movement speed of the mechanical arm when the mechanical arm is in the current gesture under the action of no external force of the electronic equipment.
In the embodiment of the application, the electronic equipment is clamped by the mechanical arm for interaction, but in the process of operating the electronic equipment without users, the current gesture of the mechanical arm, namely the position of each shaft of the mechanical arm in a three-dimensional space, is determined according to the angle of each motor included in the mechanical arm. Meanwhile, the motion speed of the mechanical arm can be read when the mechanical arm is in the current gesture.
And step S440, calculating a second load of each motor when the mechanical arm is in the current gesture based on the size and the weight and the movement speed.
In the embodiment of the application, after the size and the weight of each shaft of the mechanical arm and the movement speed of the mechanical arm are obtained, the load borne by each motor included in the mechanical arm can be calculated by the weight and the size of each shaft of the mechanical arm through a moment calculation formula by combining the current gesture of the mechanical arm and the movement speed of the mechanical arm. The calculated load is the load generated by the gravity of the mechanical arm in the operation process of the electronic equipment under the action of no external force.
Wherein the moment (torque) is the product (M) of the force (F) and the moment arm (L). I.e. m=f·l. The moment is a physical quantity describing the rotation effect of an object, and the rotation state of the object is changed to determine the action of the moment.
When the object is rotated about the fixed axis, the moment has only two possible directions, and can therefore be represented by signs. It is generally prescribed that the moment for rotating the object in the counterclockwise direction is positive and the moment for rotating the object in the clockwise direction is negative. The resultant of the several moments acting on the rotating object with the fixed shaft is thus equal to the algebraic sum of them. This algebraic sum will determine whether the object is in equilibrium or in non-equilibrium.
Optionally, step S430 and step S440 may be repeated, so that the second load of each motor of the mechanical arm may be determined when the mechanical arm is in different postures of the electronic device under the action of no external force. When the electronic equipment is determined to be in different postures under the action of no external force, the corresponding relation between the posture of the mechanical arm and the second load of each motor of the mechanical arm can be established, so that the second load of each motor of the mechanical arm corresponding to the current posture of the mechanical arm can be found directly through the corresponding relation after the current posture of the mechanical arm is determined.
And S450, determining the external force load of each motor of the mechanical arm based on the first load and the second load, wherein the second load is the load detected by each motor of the mechanical arm when the electronic equipment connected with the mechanical arm has no external force effect and the mechanical arm is in the current gesture.
And step S460, if the external force load exceeds a load threshold, determining a displacement direction and a distance for triggering the electronic equipment to move based on the external force load.
In the embodiment of the application, when the external force load is determined to be more than or equal to the external force threshold value, the displacement direction and the distance for triggering the electronic equipment to move are determined through the external force load. The displacement direction and the distance are parameters for moving the electronic equipment, which are preset, and different external force loads correspond to different displacement directions and distances.
And S470, determining the rotation angle of each motor of the mechanical arm based on the inverse kinematics algorithm of the mechanical arm and the displacement direction and distance.
In the embodiment of the present application, inverse kinematics is a process of determining parameters of a joint movable object to be set to achieve a desired posture. Applications of inverse kinematics algorithms include interactive manipulation, animation control and collision avoidance.
Optionally, the current gesture of the mechanical arm can be mapped to each axis of the mechanical arm through an inverse kinematics algorithm of the mechanical arm, so that the effect of controlling the movement of the mechanical arm according to the external force applied to the mechanical arm by a user is achieved. Alternatively, different mechanical arms correspond to different inverse kinematics algorithms.
As one way, the inverse kinematics algorithm corresponding to the robot arm may be stored in the robot arm in advance when the robot arm is produced. And after the displacement direction and distance for triggering the electronic equipment to move are obtained, the corresponding inverse kinematics algorithm can be directly obtained, and the rotation angle of each motor of the mechanical arm is obtained based on the inverse kinematics algorithm and the displacement direction and distance for triggering the electronic equipment to move.
And step 480, based on the rotation angle, controlling each motor of the mechanical arm to execute corresponding movement so as to enable the electronic equipment to move the distance in the displacement direction.
In the embodiment of the application, after the rotation angle of each motor of the mechanical arm is calculated, each motor of the mechanical arm is controlled to rotate by a corresponding rotation angle so as to enable the electronic equipment to move by a corresponding distance in the displacement direction. For example, if the determined external force load is 10N, the corresponding moving direction is directly under the determined external force load, and the distance is 3mm, at this time, the rotation angle of each motor of the corresponding mechanical arm can be calculated based on the inverse kinematics algorithm of the corresponding mechanical arm and the displacement direction and distance, and then each motor of the mechanical arm can be controlled to rotate by a corresponding rotation angle, so that the electronic device moves directly under the determined external force load by 3mm.
According to the motion control method, first, the first load of the mechanical arm in the current posture is obtained, then the size and the weight of each shaft of the mechanical arm are obtained, the motion speed of the mechanical arm is obtained when the electronic equipment is in the current posture under the action of no external force, the second load of each motor of the mechanical arm in the current posture is calculated based on the size, the weight and the motion speed, the external force load of each motor of the mechanical arm is determined based on the first load and the second load, if the external force load exceeds a load threshold value, the displacement direction and the distance for triggering the electronic equipment to move are determined based on the external force load, the rotation angle of each motor of the mechanical arm is determined based on the inverse kinematics algorithm of the mechanical arm and the displacement direction and the distance, and the corresponding motion of each motor of the mechanical arm is controlled based on the rotation angle so that the electronic equipment moves in the displacement direction by the corresponding distance. Through the mode, after the electronic equipment is connected with the mechanical arm, the electronic equipment can apply load to the mechanical arm under the condition of external force action, so that the mechanical arm can give force feedback to the electronic equipment according to the received external force load, and further a user can provide more real experience for the user in the process of using the electronic equipment, and user experience is improved.
Referring to fig. 7, a motion control apparatus 500 according to an embodiment of the present application is provided, where the apparatus 500 includes:
The load obtaining unit 510 is configured to obtain an external force load obtained when the mechanical arm is in the current posture, where the external force load is a load applied to the mechanical arm by an electronic device connected to the mechanical arm under the action of an external force.
In one mode, the load obtaining unit 510 is specifically configured to obtain a first load when the mechanical arm is in a current posture, where the first load is a load detected by each motor of the mechanical arm when the electronic device connected to the mechanical arm is under an external force, and determine, based on the first load and a second load, an external force load of each motor of the mechanical arm, where the second load is a load detected by each motor of the mechanical arm when the electronic device connected to the mechanical arm is in the current posture and the mechanical arm is not under an external force.
Optionally, the load obtaining unit 510 is further configured to obtain a size and a weight of each axis of the mechanical arm, obtain a movement speed of the mechanical arm when the mechanical arm is in the current posture under no external force, and calculate a second load of each motor when the mechanical arm is in the current posture based on the size and the weight and the movement speed.
As another way, the load obtaining unit 510 is further configured to receive an external load transmitted by the electronic device through a wireless communication manner.
And a parameter determining unit 520 for determining a feedback parameter based on the external force load.
As one way, the parameter determining unit 520 is specifically configured to determine, based on the external load, a motion parameter that triggers the electronic device to perform motion if the external load exceeds a load threshold, where the load threshold is different when the mechanical arm is in different postures.
Optionally, the parameter determining unit 520 is further configured to obtain a preset correspondence, where the preset correspondence is a correspondence between an external force load and a motion parameter, different external force loads correspond to different motion parameters, and determine, based on the preset correspondence, a motion parameter corresponding to the external force load, where the motion parameter triggers the electronic device to perform motion.
And the feedback unit 530 is used for controlling the mechanical arm to apply force feedback to the electronic equipment based on the feedback parameters.
As one way, the feedback unit 530 is specifically configured to control each motor of the mechanical arm to perform a corresponding motion based on the motion parameter, so as to apply feedback to the electronic device.
Optionally, the feedback unit 530 is specifically configured to determine, based on the external load, a feedback force that triggers the electronic device to perform the motion if the external load does not exceed the load threshold.
In another way, the feedback unit 530 is specifically configured to determine a rotation angle of each motor of the mechanical arm based on an inverse kinematics algorithm of the mechanical arm and the displacement direction and distance, and control each motor of the mechanical arm to perform a corresponding movement based on the rotation angle so as to move the electronic device by the distance in the displacement direction.
Referring to fig. 8, an embodiment of the present application provides a mechanical arm 600, where the mechanical arm 600 includes a rotational joint 610, a connecting rod 620 between the rotational joints, and a motor 630 driving the rotational joint 610. The motor 630 is configured to obtain an external force load obtained when the mechanical arm is in a current posture. The revolute joint 610 is configured to determine a feedback parameter based on the external load, and control the mechanical arm to apply force feedback to the electronic device based on the feedback parameter.
It should be noted that, in the present application, the device embodiment and the foregoing method embodiment correspond to each other, and specific principles in the device embodiment may refer to the content in the foregoing method embodiment, which is not described herein again.
An electronic device according to the present application will be described with reference to fig. 9.
Referring to fig. 9, based on the above-mentioned motion control method and apparatus, another electronic device 800 connected to a mechanical arm capable of executing the above-mentioned motion control method is provided in the embodiment of the present application. The electronic device 800 includes one or more (only one shown) processors 802, memory 804, and a network module 806 coupled to each other. The memory 804 stores therein a program capable of executing the contents of the foregoing embodiments, and the processor 802 can execute the program stored in the memory 804.
Wherein the processor 802 may include one or more processing cores. The processor 802 utilizes various interfaces and lines to connect various portions of the overall electronic device 800, perform various functions of the electronic device 800, and process data by executing or executing instructions, programs, code sets, or instruction sets stored in the memory 804, and invoking data stored in the memory 804. Alternatively, the processor 802 may be implemented in hardware in at least one of digital signal Processing (DIGITAL SIGNAL Processing, DSP), field-Programmable gate array (Field-Programmable GATE ARRAY, FPGA), programmable logic array (Programmable Logic Array, PLA). The processor 802 may integrate one or a combination of several of a central processing unit (Central Processing Unit, CPU), an image processor (Graphics Processing Unit, GPU), and a modem, etc. The CPU mainly processes an operating system, a user interface, an application program and the like, the GPU is used for rendering and drawing display contents, and the modem is used for processing wireless communication. It will be appreciated that the modem may not be integrated into the processor 802 and may be implemented solely by a single communication chip.
The Memory 804 may include random access Memory (Random Access Memory, RAM) or Read-Only Memory (ROM). Memory 804 may be used to store instructions, programs, code, sets of codes, or instruction sets. The memory 804 may include a stored program area that may store instructions for implementing an operating system, instructions for implementing at least one function (e.g., a touch function, a sound playing function, an image playing function, etc.), instructions for implementing the various method embodiments described below, etc., and a stored data area. The storage data area may also store data created by the electronic device 800 in use (e.g., phonebook, audiovisual data, chat log data), and the like.
The network module 806 is configured to receive and transmit electromagnetic waves, and to implement mutual conversion between electromagnetic waves and electrical signals, so as to communicate with a communication network or other devices, such as an audio playback device. The network module 806 may include various existing circuit elements for performing these functions, such as an antenna, a radio frequency transceiver, a digital signal processor, an encryption/decryption chip, a Subscriber Identity Module (SIM) card, memory, and the like. The network module 806 may communicate with various networks such as the internet, intranets, wireless networks, or with other devices via wireless networks. The wireless network may include a cellular telephone network, a wireless local area network, or a metropolitan area network. For example, the network module 806 may interact with base stations.
Referring to fig. 10, a block diagram of a computer readable storage medium according to an embodiment of the present application is shown. The computer readable storage medium 900 has stored therein program code that can be invoked by a processor to perform the methods described in the method embodiments described above.
The computer readable storage medium 900 may be an electronic memory such as a flash memory, an EEPROM (electrically erasable programmable read only memory), an EPROM, a hard disk, or a ROM. Optionally, computer readable storage medium 900 includes non-volatile computer readable media (non-transitory computer-readable storage medium). The computer readable storage medium 900 has storage space for program code 910 that performs any of the method steps described above. The program code can be read from or written to one or more computer program products. Program code 910 may be compressed, for example, in a suitable form.
According to the motion control method, the motion control device, the mechanical arm, the interaction system and the storage medium, the external force load obtained when the mechanical arm is in the current gesture is firstly obtained, the external force load is the load applied to the mechanical arm by electronic equipment connected with the mechanical arm under the action of external force, and then the feedback parameter is determined based on the external force load, so that the mechanical arm is controlled to apply force feedback to the electronic equipment according to the feedback parameter. Through the mode, after the electronic equipment is connected with the mechanical arm, the electronic equipment can apply load to the mechanical arm under the condition of external force action, so that the mechanical arm can give force feedback to the electronic equipment according to the received external force load, and further a user can provide more real experience for the user in the process of using the electronic equipment, and user experience is improved.
The embodiments of the present invention have been described above with reference to the accompanying drawings, but the present invention is not limited to the above-described embodiments, which are merely illustrative and not restrictive, and many forms may be made by those having ordinary skill in the art without departing from the spirit of the present invention and the scope of the claims, which are to be protected by the present invention.
Claims (11)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111454235.4A CN114179080B (en) | 2021-12-01 | 2021-12-01 | Motion control method, motion control device, mechanical arm, interaction system and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111454235.4A CN114179080B (en) | 2021-12-01 | 2021-12-01 | Motion control method, motion control device, mechanical arm, interaction system and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN114179080A CN114179080A (en) | 2022-03-15 |
CN114179080B true CN114179080B (en) | 2024-12-17 |
Family
ID=80603176
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202111454235.4A Active CN114179080B (en) | 2021-12-01 | 2021-12-01 | Motion control method, motion control device, mechanical arm, interaction system and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN114179080B (en) |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103600354A (en) * | 2013-11-08 | 2014-02-26 | 北京卫星环境工程研究所 | Spacecraft mechanical arm flexible follow-up control gravity compensation method |
CN110695809A (en) * | 2019-09-18 | 2020-01-17 | 安徽工程大学 | A non-structural free-form surface grinding device |
CN111475025A (en) * | 2020-04-08 | 2020-07-31 | 腾讯科技(深圳)有限公司 | Tactile feedback equipment, electronic equipment and robot system |
Family Cites Families (12)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US5734373A (en) * | 1993-07-16 | 1998-03-31 | Immersion Human Interface Corporation | Method and apparatus for controlling force feedback interface systems utilizing a host computer |
US6004134A (en) * | 1994-05-19 | 1999-12-21 | Exos, Inc. | Interactive simulation including force feedback |
JP2011206886A (en) * | 2010-03-30 | 2011-10-20 | Yaskawa Electric Corp | Device and method for controlling robot |
JP5962020B2 (en) * | 2012-01-17 | 2016-08-03 | セイコーエプソン株式会社 | Robot control apparatus, robot system, robot, and robot control method |
CN103640022A (en) * | 2013-11-13 | 2014-03-19 | 北京卫星环境工程研究所 | Flexible follow-up control method for spacecraft mechanical arm |
US9919422B1 (en) * | 2016-01-06 | 2018-03-20 | X Development Llc | Methods and systems to provide mechanical feedback during movement of a robotic system |
CN106527177B (en) * | 2016-10-26 | 2019-07-12 | 北京控制工程研究所 | The multi-functional one-stop remote operating control design case of one kind and analogue system and method |
DK3538328T5 (en) * | 2016-11-10 | 2020-09-28 | Cognibotics Ab | System and procedure for instructing a robot |
CN108582069A (en) * | 2018-04-17 | 2018-09-28 | 上海达野智能科技有限公司 | Robot drags teaching system and method, storage medium, operating system |
US20200282558A1 (en) * | 2019-03-07 | 2020-09-10 | LinkDyn Robotics Inc. | System and method for controlling a robot with torque-controllable actuators |
CN113183150B (en) * | 2021-04-09 | 2023-05-02 | 周先军 | Bionic hand control optimization method and system and electronic equipment |
CN113664869A (en) * | 2021-09-29 | 2021-11-19 | 宁波睿达医疗器械有限公司 | Manipulator, manipulator control method and system |
-
2021
- 2021-12-01 CN CN202111454235.4A patent/CN114179080B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103600354A (en) * | 2013-11-08 | 2014-02-26 | 北京卫星环境工程研究所 | Spacecraft mechanical arm flexible follow-up control gravity compensation method |
CN110695809A (en) * | 2019-09-18 | 2020-01-17 | 安徽工程大学 | A non-structural free-form surface grinding device |
CN111475025A (en) * | 2020-04-08 | 2020-07-31 | 腾讯科技(深圳)有限公司 | Tactile feedback equipment, electronic equipment and robot system |
Also Published As
Publication number | Publication date |
---|---|
CN114179080A (en) | 2022-03-15 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN113119098B (en) | Mechanical arm control method, mechanical arm control device and terminal equipment | |
WO2022021686A1 (en) | Method and apparatus for controlling virtual object, and storage medium and electronic apparatus | |
CN111383309B (en) | Skeleton animation driving method, device and storage medium | |
CN108771866B (en) | Virtual object control method and device in virtual reality | |
US10747325B2 (en) | Systems and methods for long-range interactions for virtual reality | |
CN108351705B (en) | Apparatus, method and device for transforming augmented reality objects in physical and digital environments | |
CN109983424B (en) | Method and device for selecting object in virtual reality scene and virtual reality equipment | |
WO2023016385A1 (en) | Processing method and apparatus for processing audio data, and mobile device and audio system | |
CN112121406A (en) | Object control method and device, storage medium, electronic device | |
CN107194871A (en) | A kind of image processing method and mobile terminal | |
CN114179080B (en) | Motion control method, motion control device, mechanical arm, interaction system and storage medium | |
CN115641392A (en) | Data processing method, device, server and medium for virtual reality system | |
CN107145706A (en) | Method and device for evaluating performance parameters of virtual reality VR equipment fusion algorithm | |
CN113112613B (en) | Model display method and device, electronic equipment and storage medium | |
CN114454981A (en) | Jumping motion control method and device of biped robot and biped robot | |
CN111632372A (en) | Virtual object control method, device, equipment and storage medium | |
CN117284364A (en) | Road sense simulation method, device, module, electronic equipment and storage medium | |
CN113813607B (en) | Game view angle switching method and device, storage medium and electronic equipment | |
US10684689B2 (en) | Cross-platform dynamic haptic effect design tool for augmented or virtual reality environments | |
CN110328689B (en) | Robot balance detection method, device and equipment and robot | |
US20220111290A1 (en) | Haptic engine for spatial computing | |
CN112802163B (en) | Animation adjustment method and device in game and electronic terminal | |
WO2020052378A1 (en) | Object control method and apparatus, storage medium and electronic apparatus | |
CN107930124B (en) | Method and device for matching movement between doll models, terminal equipment and storage medium | |
CN112948273A (en) | Game resource testing method, related device, equipment and storage medium |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |