Disclosure of Invention
The invention provides a battery grabbing method and device, which are used for solving the technical problems of poor battery positioning accuracy and low replacement efficiency of a power battery in the prior art.
The invention provides a battery grabbing method, which comprises the following steps:
determining the horizontal center position of the battery frame based on the position of a front wheel when the work machine carries out battery replacement parking and the position relation between the front wheel and the battery frame;
determining the horizontal center position of a hand grip for performing battery replacement operation based on the horizontal center position of the battery frame and a preset distance;
and adjusting the horizontal center position of the hand grip and the rotation angle of the hand grip relative to the battery frame based on the detection results of the battery frame by a plurality of distance sensors arranged at the periphery of the hand grip until the distance sensors detect the battery frame, and controlling the hand grip to grip the battery frame.
According to the battery grabbing method provided by the invention, when the working machine is parked for battery replacement, the walking direction of the hand grip is the advancing direction of the working machine, and the translation direction of the hand grip is the vertical direction of the advancing direction of the working machine.
According to the battery grabbing method provided by the invention, the grab handle is a rectangular frame and comprises a first short side, a first long side, a second short side and a second long side which are sequentially connected;
a first distance sensor is arranged at the middle point of the first short side;
a second distance sensor is arranged at the middle point of the second short side;
a third distance sensor and a fifth distance sensor are respectively arranged at the trisection point position on the first long side;
a fourth distance sensor and a sixth distance sensor are respectively arranged at the position of the trisection point on the second long edge;
when the hand grip is in an initial state, the first short side is parallel to the walking direction of the hand grip, and the first long side is parallel to the translation direction of the hand grip.
According to the battery grasping method provided by the present invention, the adjusting of the horizontal center position of the grip and the rotation angle of the grip with respect to the battery frame until the distance sensors detect the battery frame based on the detection results of the battery frame by the plurality of distance sensors provided around the grip includes:
if the first distance sensor, the third distance sensor and the fifth distance sensor detect the battery frame, and the second distance sensor, the fourth distance sensor and the sixth distance sensor do not detect the battery frame, controlling the horizontal center position of the hand grip to move in the translation direction until the second distance sensor detects the battery frame;
controlling the horizontal center position of the hand grip to move in the walking direction until the fourth distance sensor detects the battery frame;
determining the rotation direction of the hand grip based on the position of the sixth distance sensor relative to the battery frame, and adjusting the rotation angle of the hand grip relative to the battery frame based on the rotation direction until the sixth distance sensor detects the battery frame.
According to the battery grasping method provided by the present invention, the adjusting of the horizontal center position of the grip and the rotation angle of the grip with respect to the battery frame until the distance sensors detect the battery frame based on the detection results of the battery frame by the plurality of distance sensors provided around the grip includes:
if the first distance sensor, the third distance sensor and the fifth distance sensor detect the battery frame, and the second distance sensor, the fourth distance sensor and the sixth distance sensor do not detect the battery frame, controlling the horizontal center position of the hand grip to move in the walking direction until the fourth distance sensor detects the battery frame, and acquiring a first position of the fourth distance sensor;
continuously controlling the horizontal center position of the hand grip to move in the walking direction until the sixth distance sensor detects the battery frame, and acquiring the position of the sixth distance sensor and the second position of the fourth distance sensor;
determining a rotation angle adjustment amount and a rotation direction of the hand grip based on the first position and the second position of the fourth distance sensor and the position of the sixth distance sensor;
adjusting the hand grip based on the rotation angle adjustment amount and the rotation direction of the hand grip;
controlling the horizontal center position of the hand grip to move in the translation direction until the second distance sensor detects the battery frame;
and controlling the horizontal center position of the hand grip to move in the walking direction until the fourth distance sensor and the sixth distance sensor detect the battery frame again.
According to the battery capture method provided by the invention, the horizontal center position of the battery frame is determined based on the position of the front wheel when the work machine performs battery replacement parking and the position relationship between the front wheel and the battery frame, and the method comprises the following steps:
when the operation machine carries out battery replacement parking, determining the position of a front wheel based on a measurement optical axis shielded by the front wheel of the operation machine and the position of the measurement optical axis in a measurement light curtain;
the measuring light curtain is horizontally arranged in the battery replacement parking area.
The invention provides a battery gripping device, comprising:
the battery frame positioning unit is used for determining the horizontal center position of the battery frame based on the position of a front wheel when the work machine carries out battery replacement parking and the position relation between the front wheel and the battery frame;
the gripper positioning unit is used for determining the horizontal center position of a gripper for performing battery replacement operation based on the horizontal center position of the battery frame and a preset distance;
and the grabbing unit is used for adjusting the horizontal center position of the hand grab and the rotation angle of the hand grab relative to the battery frame based on the detection results of the battery frame by the plurality of distance sensors arranged at the periphery of the hand grab until the distance sensors detect the battery frame, and controlling the hand grab to grab the battery frame.
The invention provides an electronic device which comprises a memory, a processor and a computer program which is stored on the memory and can run on the processor, wherein the processor realizes the steps of the battery grabbing method when executing the program.
The invention provides a non-transitory computer readable storage medium having stored thereon a computer program which, when executed by a processor, implements the steps of the battery capture method.
The invention provides a computer program product comprising a computer program which, when executed by a processor, performs the steps of the battery capture method.
According to the battery grabbing method and device, the horizontal center position of the battery frame is determined according to the position of the front wheel when the operation machinery is used for battery replacement and parking and the position relation between the front wheel and the battery frame; further determining the horizontal center position of the gripper for performing battery replacement operation; according to the detection results of the plurality of distance sensors arranged on the periphery of the hand grip on the battery frame, the horizontal center position of the hand grip and the rotation angle of the hand grip relative to the battery frame are adjusted until the distance sensors detect the battery frame, so that the accuracy of battery gripping is improved, and the replacement efficiency of the power battery is improved.
Detailed Description
In order to make the objects, technical solutions and advantages of the present invention clearer, the technical solutions of the present invention will be clearly and completely described below with reference to the accompanying drawings, and it is obvious that the described embodiments are some, but not all embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention.
Fig. 1 is a schematic flow chart of a battery grasping method provided by the present invention, as shown in fig. 1, the method includes:
and step 110, determining the horizontal center position of the battery frame based on the position of the front wheel when the work machine performs battery replacement parking and the position relation between the front wheel and the battery frame.
Specifically, the working machine in the embodiment of the present invention is a machine device driven by a power battery, including an electric truck and the like. The power battery has a heavy weight and a high energy density, and therefore, a special battery replacement station needs to be built to perform battery replacement operation on the working machine.
Power batteries on work machines are typically assembled using a frame structure, which is a battery frame. The power battery on the operation machine can be replaced by positioning, grabbing, hoisting and other operations of the battery frame. The battery frame is generally arranged at the rear part of the vehicle head.
When the operation machinery enters the battery replacement station, the operation machinery needs to enter a designated battery replacement parking area, and the battery replacement operation is executed by a special battery replacement device. The battery replacing device generally comprises a gripper and a moving device, the gripper is arranged on the moving device and used for gripping a battery frame provided with the power battery, and the moving device is used for moving between a power battery storage place and a battery replacing parking area to complete the transportation of the power battery, for example, the moving device can be a guide rail trolley.
To replace the power battery on the working machine, the battery frame where the power battery is located needs to be positioned first. The battery frame itself does not have a positioning device, and the position of the battery frame can be determined according to the parking position of the working machine. For convenience of description, the position of the battery frame is represented by a horizontal center position of the battery frame. In the actual battery replacement process, the battery frame and the hand grip are not on the same horizontal plane. Generally, the hand grip is above the battery frame, and when the battery needs to be replaced, the hand grip moves downwards to contact with the battery frame, so that the battery frame is grabbed.
When the working machine is parked in the battery replacement mode, the position of the front wheel can be measured by a measuring light curtain or other position sensors arranged in the battery replacement parking area. The mechanical structure of the same type of working machine is fixed, that is, the position relationship between the front wheel and the battery frame on the working machine is determined at the time of manufacture and is not changed. Therefore, the horizontal center position of the battery frame can be determined by the positional relationship between the front wheels and the battery frame on the work machine, and the front wheel position. The position relationship between the front wheel and the battery frame can be obtained according to manufacturer data of the working machine or by a measurement and calibration mode.
And 120, determining the horizontal center position of the hand grip for performing the battery replacement operation based on the horizontal center position of the battery frame and the preset distance.
Specifically, the hand grip is a battery gripping device that matches the shape and size of the battery frame. For example, if the battery frame is rectangular, the hand grip is also rectangular, and the length and width thereof are the same as those of the battery frame. The grabbing structure is arranged on the grabbing hand, so that the battery frame can be grabbed when the grabbing hand is matched with the battery frame.
In an actual battery replacement operation, since the size of the working machine is often large, the parking position cannot be very accurate, and thus it is difficult to obtain an accurate value of the horizontal center position of the obtained battery frame. In view of this, the embodiment of the invention realizes the accurate matching between the gripper and the battery frame by adjusting the horizontal center position of the gripper, thereby realizing the accurate gripping of the battery.
Before the gripper is accurately matched with the battery frame, the horizontal center position of the gripper for performing battery replacement operation can be determined through the horizontal center position of the battery frame and the preset distance. The horizontal center position is an initial position of the hand grip before the battery positioning detection is carried out.
The preset distance is required to enable the battery frame and the hand grip to have larger contact ratio. Here, the preset distance may be set as needed. For example, the preset distance may be 100 mm. If the horizontal center position of the battery frame is known, then the position of 100mm apart from the hand grip along the moving direction of the hand grip can be used as the horizontal center position of the hand grip. For another example, the preset distance may be smaller than the length of the short side of the battery frame.
And step 130, adjusting the horizontal center position of the hand grip and the rotation angle of the hand grip relative to the battery frame based on the detection results of the plurality of distance sensors arranged on the periphery of the hand grip on the battery frame until the distance sensors detect the battery frame, and controlling the hand grip to grip the battery frame.
In particular, a plurality of distance sensors may be provided around the circumference of the hand grip. Because the distance between the horizontal center positions of the battery frame and the hand grip is a preset distance, the battery frame and the hand grip have larger contact ratio. In this case, if the measurement value of any one of the distance sensors is greater than the set detection threshold, it can be considered that the distance sensor does not detect the battery frame, and if the measurement value of any one of the distance sensors is less than the set detection threshold, it can be considered that the distance sensor detects the battery frame.
Since the plurality of distance sensors are arranged on the periphery of the hand grip, when all the distance sensors detect the battery frame, the battery frame is completely overlapped with the hand grip. Here, the perfect coincidence includes the horizontal center coincidence and the rotation angle of the grip with respect to the battery frame is zero.
If the partial distance sensors do not detect the battery frame, the battery frame and the hand grip are not completely overlapped, and at the moment, the horizontal center position of the hand grip and the rotation angle of the hand grip relative to the battery frame can be adjusted according to the detection results of the distance sensors until the distance sensors detect the battery frame.
According to the battery grabbing method provided by the embodiment of the invention, the horizontal center position of the battery frame is determined through the position of the front wheel when the operation machinery is used for battery replacement and parking and the position relation between the front wheel and the battery frame; further determining the horizontal center position of the gripper for performing battery replacement operation; according to the detection results of the plurality of distance sensors arranged on the periphery of the hand grip on the battery frame, the horizontal center position of the hand grip and the rotation angle of the hand grip relative to the battery frame are adjusted until the distance sensors detect the battery frame, so that the accuracy of battery gripping is improved, and the replacement efficiency of the power battery is improved.
Based on the above embodiment, when the work machine is parked for battery replacement, the traveling direction of the gripper is the advancing direction of the work machine, and the translational direction of the gripper is the direction perpendicular to the advancing direction of the work machine.
Specifically, a power exchange parking area of the working machine in the power exchange station can be set to improve the power exchange efficiency.
Here, the traveling direction of the gripper is defined as a direction in which the gripper moves from the front wheel to the rear wheel of the work machine, and the translational direction of the gripper is defined as a direction in which the gripper moves with respect to the side surface of the work machine. The battery replacement parking area can be arranged near the position of the gripper, so that the advancing direction of the operation machine is the walking direction of the gripper, and the vertical direction of the advancing direction of the operation machine is the translation direction of the gripper.
Fig. 2 is a layout diagram of the equipment of the power swapping station provided by the present invention, and as shown in fig. 2, thepower swapping device 210 includes ahand grip 211 and a movingdevice 212. Thework machine 220 includes a headstock 221, abattery frame 222, and acargo box 223.
The travel direction of thegripper 211 is defined as an X-axis, and the translation direction of thegripper 211 is defined as a Y-axis, and it can be seen that the X-axis is also the forward direction of thework machine 220, and the Y-axis is also a direction perpendicular to the forward direction of the work machine.
The initial position of themobile device 212 in theswapping device 210 can be taken as the coordinate origin O. A laser ranging sensor is installed at the origin of coordinates O for detecting the distance of thebattery frame 222 with respect to thegrip 211.
Based on any one of the above embodiments, the gripper is a rectangular frame, and comprises a first short side, a first long side, a second short side and a second long side which are connected in sequence;
a first distance sensor is arranged at the middle point of the first short edge;
a second distance sensor is arranged at the middle point of the second short side;
a third distance sensor and a fifth distance sensor are respectively arranged at the trisection point positions on the first long side;
a fourth distance sensor and a sixth distance sensor are respectively arranged at the position of the trisection point on the second long edge;
when the hand grip is in the initial state, the first short side is parallel to the walking direction of the hand grip, and the first long side is parallel to the translation direction of the hand grip.
Specifically, since the battery frame is mostly a rectangular frame, the hand grip may be a rectangular frame having the same shape and size as the battery frame.
The periphery of the hand grip can comprise a first short edge, a first long edge, a second short edge and a second long edge which are connected in sequence. 6 distance sensors are arranged on four edges of the hand grip.
Fig. 3 is a layout diagram of the distance sensors provided by the present invention, and as shown in fig. 3, a first distance sensor S1 is provided at a middle point of the first short side ab, a second distance sensor S2 is provided at a middle point of the second short side cd, a third distance sensor S3 and a fifth distance sensor S5 are respectively provided at trisections on the first long side ac, and a fourth distance sensor S4 and a sixth distance sensor S6 are respectively provided at trisections on the second long side bd.
The gripper can freely rotate on the horizontal plane, the initial state of the gripper can be that the first short edge is parallel to the walking direction of the gripper, the first long edge is parallel to the translation direction of the gripper, and at the moment, the rotation angle of the gripper can be considered to be zero.
Based on any of the above embodiments,step 130 includes:
if the first distance sensor, the third distance sensor and the fifth distance sensor detect the battery frame, and the second distance sensor, the fourth distance sensor and the sixth distance sensor do not detect the battery frame, controlling the horizontal center position of the hand grip to move in the translation direction until the second distance sensor detects the battery frame;
controlling the horizontal center position of the hand grip to move in the walking direction until the fourth distance sensor detects the battery frame;
and determining the rotation direction of the hand grip based on the position of the sixth distance sensor relative to the battery frame, and adjusting the rotation angle of the hand grip relative to the battery frame based on the rotation direction until the sixth distance sensor detects the battery frame.
Specifically, fig. 4 is a schematic diagram of the strategy of the step-by-step alignment method provided by the present invention, and as shown in fig. 4, the method first determines the initial horizontal position of the gripper. According to the fact that the first distance sensor S1, the third distance sensor S3 and the fifth distance sensor S5 detect the battery frame, and the second distance sensor S2, the fourth distance sensor S4 and the sixth distance sensor S6 do not detect the battery frame, the initial horizontal position of the hand grab is adjusted step by step, and the battery frame is positioned.
Fig. 5 is a schematic flow chart of the step-by-step alignment method provided by the present invention, and as shown in fig. 5, the step-by-step alignment method can be divided into three steps:
step one, determining the initial position of the hand grip
The initial horizontal center position of the hand grip is set in the X direction of the horizontal center position of the battery frame, and the position is deviated by 100mm to the tail part of the working machine.
Step two, action one
If the first, third and fifth distance sensors S1, S3 and S5 detect the battery frame and the second, fourth and sixth distance sensors S2, S4 and S6 do not detect the battery frame, controlling the horizontal center position of the gripper to move in the translation direction until the second distance sensor S2 detects the battery frame; the horizontal center position of the control finger is moved in the traveling direction until the fourth distance sensor S4 detects the battery frame.
Step three, action two
The rotation direction of the hand grip is determined to be clockwise according to the position of the sixth distance sensor S6 with respect to the battery frame, and the rotation angle of the hand grip with respect to the battery frame is adjusted according to the rotation direction until the sixth distance sensor S6 detects the battery frame. Up to this point, all the distance sensors detect the battery frame.
Based on any of the above embodiments,step 130 includes:
if the first distance sensor, the third distance sensor and the fifth distance sensor detect the battery frame, and the second distance sensor, the fourth distance sensor and the sixth distance sensor do not detect the battery frame, controlling the horizontal center position of the hand grip to move in the walking direction until the fourth distance sensor detects the battery frame, and acquiring a first position of the fourth distance sensor;
continuously controlling the horizontal center position of the hand grip to move in the walking direction until the sixth distance sensor detects the battery frame, and acquiring the position of the sixth distance sensor and the second position of the fourth distance sensor;
determining a rotation angle adjustment amount and a rotation direction of the hand grip based on the first position and the second position of the fourth distance sensor and the position of the sixth distance sensor;
adjusting the hand grip based on the rotation angle adjustment amount and the rotation direction of the hand grip;
controlling the horizontal center position of the hand grip to move in the translation direction until the second distance sensor detects the battery frame;
and controlling the horizontal center position of the hand grip to move in the walking direction until the fourth distance sensor and the sixth distance sensor detect the battery frame again.
Specifically, fig. 6 is a schematic diagram of a strategy of a calculation method provided by the present invention, and as shown in fig. 6, the method first determines an initial horizontal position of the hand grip. The battery frames are detected by the first, third and fifth distance sensors S1, S3 and S5, and the battery frames are not detected by the second, fourth and sixth distance sensors S2, S4 and S6, so that the rotation angle adjustment amount of the hand grip is determined by calculation, and after the rotation angle of the hand grip is adjusted and translated, the battery frames are positioned.
Fig. 7 is a schematic flow chart of the calculation method provided by the present invention, and as shown in fig. 7, the calculation method can be divided into four steps:
step one, determining the initial position of the hand grip
The initial horizontal center position of the hand grip is set in the X direction of the horizontal center position of the battery frame, and the position is deviated by 100mm to the tail part of the working machine.
Step two, action one
If the first, third and fifth distance sensors S1, S3 and S5 detect the battery frame and the second, fourth and sixth distance sensors S2, S4 and S6 do not detect the battery frame, controlling the horizontal center position of the gripper to move in the walking direction until the third and fourth distance sensors S3 and S4 detect the battery frame, and acquiring a first position P1 of the fourth distance sensor;
continuing to control the horizontal center position of the hand grip to move in the walking direction until the sixth distance sensor S6 detects the battery frame, and acquiring a position P3 of the sixth distance sensor S6 and a second position P2 of the fourth distance sensor;
the rotation angle adjustment amount and the rotation direction of the hand grip are determined according to the first and second positions P1 and P2 of the fourth distance sensor S4 and the position of the sixth distance sensor S6.
Here, since the traveling direction of the finger is the X axis and the straight line on which the cell frame is located is the Y axis, the line P1-P2 formed by the positions of the fourth distance sensor S4 before and after the movement of the finger in the traveling direction is perpendicular to the edge of the cell frame, that is, P1-P2-P3 forms a right triangle, the rotational angle adjustment amount of the finger can be obtained as · P1P3P2, and · P1P3P2 can be obtained by solving according to a trigonometric function. For example:
meanwhile, the rotating direction can be known to be clockwise.
Step three, action two
And adjusting the hand grip according to the rotation angle adjustment amount and the rotation direction of the hand grip. After the adjustment, none of the second, fourth, and sixth distance sensors S2, S4, and S6 detected the battery frame.
Step four, action three
Controlling the horizontal center position of the hand grip to move in the translation direction until the second distance sensor S2 detects the battery frame; the horizontal center position of the control grip is moved in the traveling direction until both the fourth distance sensor S4 and the sixth distance sensor S6 detect the battery frame again. Up to this point, all the distance sensors detect the battery frame.
Based on any of the above embodiments,step 110 may be preceded by:
when the operation machine is parked after the battery is replaced, determining the position of a front wheel based on a measurement optical axis shielded by the front wheel of the operation machine and the position of the measurement optical axis in a measurement light curtain;
wherein, the measuring light curtain is horizontally arranged in the battery replacement parking area.
Specifically, a measuring light curtain can be horizontally installed in the battery replacement parking area. The measuring light curtain comprises a plurality of measuring optical axes. The measuring optical axis starts from the transmitting end of the measuring light curtain and enters the receiving end of the measuring light curtain, and if the measuring optical axis is shielded, the receiving end cannot receive the corresponding measuring optical axis. The mounting position of each measuring optical axis can be obtained according to the mounting position of the measuring light curtain.
When the operation machine is parked after the electric exchange, the front wheel of the operation machine enters the measuring light curtain, a part of the measuring light axis can be shielded, for example, 40 measuring light axes are contained in the measuring light curtain, 10 th to 20 th measuring light axes are shielded by the front wheel, and the position of the front wheel can be obtained according to the mounting position of the shielded measuring light axis.
Based on any of the above embodiments, fig. 8 is a schematic structural diagram of a battery grasping apparatus provided by the present invention, as shown in fig. 8, the apparatus includes:
a batteryframe positioning unit 810, configured to determine a horizontal center position of a battery frame based on a position of a front wheel when the work machine performs battery replacement parking and a positional relationship between the front wheel and the battery frame;
the handgrip positioning unit 820 is used for determining the horizontal center position of a hand grip for performing battery replacement operation based on the horizontal center position of the battery frame and a preset distance;
and a graspingunit 830 for adjusting a horizontal center position of the hand grip and a rotation angle of the hand grip relative to the battery frame based on detection results of the plurality of distance sensors arranged around the hand grip on the battery frame until the distance sensors all detect the battery frame, and controlling the hand grip to grasp the battery frame.
According to the battery grabbing device provided by the embodiment of the invention, the horizontal center position of the battery frame is determined through the position of the front wheel when the operation machinery is used for battery replacement and parking and the position relation between the front wheel and the battery frame; further determining the horizontal center position of the gripper for performing battery replacement operation; according to the detection results of the plurality of distance sensors arranged on the periphery of the hand grip on the battery frame, the horizontal center position of the hand grip and the rotation angle of the hand grip relative to the battery frame are adjusted until the distance sensors detect the battery frame, so that the accuracy of battery gripping is improved, and the replacement efficiency of the power battery is improved.
Based on any embodiment, when the electric power changing parking is carried out on the working machine, the traveling direction of the gripper is the advancing direction of the working machine, and the translation direction of the gripper is the vertical direction of the advancing direction of the working machine.
Based on any one of the above embodiments, the gripper is a rectangular frame, and comprises a first short side, a first long side, a second short side and a second long side which are connected in sequence;
a first distance sensor is arranged at the middle point of the first short edge;
a second distance sensor is arranged at the middle point of the second short side;
a third distance sensor and a fifth distance sensor are respectively arranged at the trisection point positions on the first long side;
a fourth distance sensor and a sixth distance sensor are respectively arranged at the position of the trisection point on the second long edge;
when the hand grip is in the initial state, the first short side is parallel to the walking direction of the hand grip, and the first long side is parallel to the translation direction of the hand grip.
Based on any one of the above embodiments, the grasping unit is specifically configured to:
if the first distance sensor, the third distance sensor and the fifth distance sensor detect the battery frame, and the second distance sensor, the fourth distance sensor and the sixth distance sensor do not detect the battery frame, controlling the horizontal center position of the hand grip to move in the translation direction until the second distance sensor detects the battery frame;
controlling the horizontal center position of the hand grip to move in the walking direction until the fourth distance sensor detects the battery frame;
and determining the rotation direction of the hand grip based on the position of the sixth distance sensor relative to the battery frame, and adjusting the rotation angle of the hand grip relative to the battery frame based on the rotation direction until the sixth distance sensor detects the battery frame.
Based on any of the above embodiments, the grabbing unit is further specifically configured to:
if the first distance sensor, the third distance sensor and the fifth distance sensor detect the battery frame, and the second distance sensor, the fourth distance sensor and the sixth distance sensor do not detect the battery frame, controlling the horizontal center position of the hand grip to move in the walking direction until the fourth distance sensor detects the battery frame, and acquiring a first position of the fourth distance sensor;
continuously controlling the horizontal center position of the hand grip to move in the walking direction until the sixth distance sensor detects the battery frame, and acquiring the position of the sixth distance sensor and the second position of the fourth distance sensor;
determining a rotation angle adjustment amount and a rotation direction of the hand grip based on the first position and the second position of the fourth distance sensor and the position of the sixth distance sensor;
adjusting the hand grip based on the rotation angle adjustment amount and the rotation direction of the hand grip;
controlling the horizontal center position of the hand grip to move in the translation direction until the second distance sensor detects the battery frame;
and controlling the horizontal center position of the hand grip to move in the walking direction until the fourth distance sensor and the sixth distance sensor detect the battery frame again.
Based on any embodiment above, still include:
the front wheel positioning unit is used for determining the position of a front wheel based on a measurement optical axis shielded by the front wheel of the operation machine and the position of the measurement optical axis in the measurement light curtain when the operation machine is subjected to battery replacement parking;
wherein, the measuring light curtain is horizontally arranged in the battery replacement parking area.
Based on any of the above embodiments, fig. 9 is a schematic structural diagram of an electronic device provided by the present invention, and as shown in fig. 9, the electronic device may include: a Processor (Processor)910, a communication Interface (Communications Interface)920, a Memory (Memory)930, and a communication Bus (Communications Bus)940, wherein theProcessor 910, thecommunication Interface 920, and theMemory 930 are configured to communicate with each other via thecommunication Bus 940.Processor 910 may invoke logical commands inmemory 930 to perform the following method:
determining the horizontal center position of the battery frame based on the position of a front wheel when the work machine carries out battery replacement parking and the position relation between the front wheel and the battery frame; determining the horizontal center position of a hand grip for performing battery replacement operation based on the horizontal center position of the battery frame and a preset distance; and adjusting the horizontal center position of the hand grip and the rotation angle of the hand grip relative to the battery frame based on the detection results of the plurality of distance sensors arranged at the periphery of the hand grip on the battery frame until the distance sensors detect the battery frame, and controlling the hand grip to grip the battery frame.
In addition, the logic commands in thememory 930 may be implemented in the form of software functional units and stored in a computer readable storage medium when the logic commands are sold or used as independent products. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium and includes a plurality of commands for enabling a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present invention. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
The processor in the electronic device provided in the embodiment of the present invention may call a logic instruction in the memory to implement the method, and the specific implementation manner of the method is consistent with the implementation manner of the method, and the same beneficial effects may be achieved, which is not described herein again.
Embodiments of the present invention further provide a non-transitory computer-readable storage medium, on which a computer program is stored, where the computer program is implemented to perform the method provided in the foregoing embodiments when executed by a processor, and the method includes:
determining the horizontal center position of the battery frame based on the position of a front wheel when the work machine carries out battery replacement parking and the position relation between the front wheel and the battery frame; determining the horizontal center position of a hand grip for performing battery replacement operation based on the horizontal center position of the battery frame and a preset distance; and adjusting the horizontal center position of the hand grip and the rotation angle of the hand grip relative to the battery frame based on the detection results of the plurality of distance sensors arranged at the periphery of the hand grip on the battery frame until the distance sensors detect the battery frame, and controlling the hand grip to grip the battery frame.
When the computer program stored on the non-transitory computer readable storage medium provided in the embodiments of the present invention is executed, the method is implemented, and the specific implementation manner of the method is consistent with the implementation manner of the method, and the same beneficial effects can be achieved, which is not described herein again.
The embodiment of the invention also provides a computer program product, which comprises a computer program, and the computer program realizes the steps of the battery grabbing method when being executed by the processor.
The above-described embodiments of the apparatus are merely illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.
Through the above description of the embodiments, those skilled in the art will clearly understand that each embodiment can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware. With this understanding in mind, the above technical solutions may be embodied in the form of a software product, which can be stored in a computer-readable storage medium, such as ROM/RAM, magnetic disk, optical disk, etc., and includes commands for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the method according to the embodiments or some parts of the embodiments.
Finally, it should be noted that: the above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.