Automatic navigation method, server and storage medium
Technical Field
The present invention relates to the field of navigation, and in particular, to an automatic navigation method, a server, and a storage medium.
Background
Automated Guided Vehicles (AGVs) have become an important infrastructure in smart logistics, smart manufacturing, and digital factories. AGV can make things convenient for the transportation of mill, improves the production efficiency and the operating efficiency of mill. Common AGV navigation methods include magnetic stripe navigation, laser navigation, two-dimensional code navigation, and the like. Magnetic stripe navigation AGV price is cheap relatively, and the operation is reliable stable. However, the magnetic stripes need to be additionally laid in the application scene, the laying workload of the magnetic stripes is large, and the magnetic stripes can be laid only by modifying the application field. If the navigation path is changed, the magnetic strip needs to be laid again at the application field. And the bottom of the magnetic strip can be weakened due to long-term use, so that the magnetic strip is not favorable for repeated use. The AGV based on laser navigation is to construct an indoor complete map through a laser radar, obtain complete surrounding environment information, obtain the surrounding information in real time by utilizing laser scanning and realize algorithm navigation. The AGV of laser navigation does not need to lay a fixed track in an application field, and then when the laser navigation meets a large object or a wall, the positioning may be inaccurate, and the phenomenon of departing from a preset path may occur.
With the development of digital factories and intelligent factories, enterprises put higher demands on factory automation. At present, most of logistics robots operate under the condition of rail guidance, and a small part of logistics robots adopt relatively expensive laser radar trackless navigation and inertial navigation robots with high technical complexity. The rail guided navigation cannot adapt to the requirement of path change, and the laser navigation needs an additional reflecting plate. The mobile robot based on visual navigation can overcome the problems, and only a camera is required to be installed on the roof, so that accurate navigation is realized within the coverage range of the camera. However, the scheme based on the visual navigation has the problem that a camera covers a blind area, namely, the position and pose information of the AGV cannot be obtained in a place without the camera covering. When the AGV runs to a blind area covered by the camera, the server cannot acquire the pose information of the AGV, so that a control instruction cannot be provided for the AGV. Therefore, additional sensors are needed to assist in providing the pose information of the AGV, which in turn increases hardware costs.
Disclosure of Invention
In view of the above, it is desirable to provide an automatic navigation method, a server, and a storage medium, which can determine a heading angle and position information of an automatic guided vehicle when the automatic guided vehicle travels in a blind area of a camera in a navigation space, and control the automatic guided vehicle to travel along a virtual path according to the heading angle and position information.
The invention provides an automatic navigation method, which is applied to a server, wherein the server is in communication connection with at least one automatic guided vehicle, and the method comprises the following steps:
receiving the pulse quantity fed back by a wheel encoder arranged on the wheel of the automatic guided vehicle in the running process of the automatic guided vehicle;
calculating the pose information of the automatic guided vehicle at the moment k +1 according to the pulse number and the pose information of the automatic guided vehicle at the moment k, wherein the pose information comprises course angle information and position information;
and generating a control instruction according to the pose information of the automatic guided vehicle at the moment of k +1 and reference point information on a virtual path prestored in the server so as to control the automatic guided vehicle to walk on the corresponding virtual path in a navigation space.
Preferably, the calculating the pose information of the automatic guided vehicle at the time k +1 according to the pulse number and the pose information of the automatic guided vehicle at the time k comprises:
calculating the pulse number to obtain the running distance d of the right wheel after the automatic guided vehicle runs for a distanceRAnd the distance d traveled by the left wheelL;
According to the distance d traveled by the right wheel
RAnd the distance d traveled by the left wheel
LThe difference in distance between the two gives the course angle offset of the automated guided vehicle,
wherein R is the instantaneous center of curvature radius, and l is the lateral distance between the left and right wheels;
calculating course angle deviation delta theta of the automatic guided vehicle at the k moment according to the course angle deviationkAnd obtaining the course angle theta of the automatic guided vehicle at the moment k +1k+1=θk+Δθk;
According to the Euclidean distance D between the position of the automatic guided vehicle at the moment k and the position of the automatic guided vehicle at the moment k +1
k,k+1And position information (x) of the automated guided vehicle at time k
k,y
k) Obtaining the position information (x) of the automatic guided vehicle at the moment k +1
k+1,y
k+1) Wherein, in the step (A),
wherein the Δ θ
kThe theta is the course angle deviation of the automatic guided vehicle at the moment k
kAnd the heading angle of the automatic guided vehicle at the moment k is obtained.
Preferably, said right wheel travels a distance dR=de·NRThe distance d traveled by the left wheelL=de·NLWherein N isRNumber of pulses, N, fed back for a wheel encoder mounted on the right wheelLNumber of pulses fed back by a wheel encoder mounted on the left wheel, deFor the path distance represented by each pulse of the wheel encoder.
Preferably, the path distance d represented by each pulse of the wheel encoder iseCalculated by the following formula:
wherein N is
0The total number of pulses of the wheel encoder, r, is the radius of the left and right wheels of the automatic guided vehicle.
Preferably, the euclidean distance D between the position of the automated guided vehicle at time k and the position at time k +1k,k+1Calculated by the following formula:
wherein R is
kIs the instantaneous radius of curvature of the vehicle at time k, Delta theta
kAnd the course angle deviation of the automatic guided vehicle at the moment k is obtained.
Preferably, the heading angle offset Δ θ of the autonomous guided vehicle at time kkCalculated by the following formula:
wherein d is
R,k=d
e·N
R,kRepresents the distance traveled by the right wheel of the automated guided vehicle at time k, d
L,k=d
e·N
L,kIndicating the distance traveled by the left wheel of the automated guided vehicle at time k.
Preferably, the instantaneous radius of curvature R of the automated guided vehicle at time kkCalculated by the following formula:
preferably, the pose information of the automatic guided vehicle at the time k is position information of the automatic guided vehicle at the time k and heading angle information of the automatic guided vehicle at the time k calculated according to the pulse number, wherein the position information of the automatic guided vehicle at the time k is position information determined according to an image shot by a camera installed in a navigation space or initial position information of the automatic guided vehicle on the virtual path.
A second aspect of the present invention provides a server comprising:
a processor; and
a memory having stored therein a plurality of program modules that are loaded by the processor and execute the automated navigation method.
A third aspect of the present invention provides a storage medium having stored thereon at least one computer instruction for execution by a processor and loaded to perform the method of automated navigation.
Compared with the prior art, the automatic navigation method, the server and the storage medium in the scheme can calculate the course angle offset of the automatic guided vehicle and the position information of the automatic guided vehicle at the moment k +1 according to the pulse quantity fed back by the left wheel and the right wheel of the automatic guided vehicle and the position information of the automatic guided vehicle at the moment k, and then generate a control instruction according to the position information of the automatic guided vehicle at the moment k +1 and the reference point information prestored on the virtual path in the server to control the automatic guided vehicle to walk on the corresponding virtual path in the navigation space. Therefore, when the automatic guided vehicle runs to a blind area of the camera in the navigation space, the server can continuously acquire the pose information of the automatic guided vehicle and control the automatic guided vehicle to run on the virtual path.
Drawings
FIG. 1 is a diagram of an automatic navigation system according to an embodiment of the present invention.
Fig. 2 is a schematic diagram of a server in the automatic navigation system according to an embodiment of the present invention.
Fig. 3 is a schematic diagram of an automatic guided vehicle in the automatic navigation system according to an embodiment of the present invention.
FIG. 4 is a flowchart illustrating an automatic navigation method according to an embodiment of the present invention.
Description of the main elements
Automatic navigation system
|
10
|
Server
|
1
|
Automatic guiding vehicle
|
2
|
Network unit
|
11
|
Memory device
|
12
|
Processor with a memory having a plurality of memory cells
|
13
|
Battery with a battery cell
|
20
|
Walking unit
|
21
|
Left wheel
|
210
|
Right wheel
|
211
|
Wheel encoder
|
3
|
Controller
|
23
|
Wireless unit
|
22
|
Step (ii) of
|
S41~S43 |
The following detailed description will further illustrate the invention in conjunction with the above-described figures.
Detailed Description
Referring to fig. 1, a schematic diagram of an automatic navigation system 10 according to an embodiment of the invention is shown. The automatic navigation system 10 includes, but is not limited to, a server 1 and an automatic guided vehicle 2. In the present embodiment, the server 1 and the automatic guided vehicle 2 are connected by wireless communication. In the present embodiment, the server 1 controls the automatic guided vehicle 2 to navigate in the navigation space by estimating pose information of the automatic guided vehicle 2, which will be described in detail later. The pose information comprises position information and course angle information. The navigation space can be an indoor space (such as in a storage bin) or an outdoor space.
Referring to fig. 2, a schematic diagram of the server 1 in the automatic navigation system 10 according to an embodiment of the invention is shown. In the present embodiment, the server 1 includes, but is not limited to, a network unit 11, a memory 12, and a processor 13. The network unit 11, the memory 12 and the processor 13 are electrically connected to each other.
In this embodiment, the network unit 11 is configured to provide a network communication function for the server 1 through a wired or wireless network transmission manner. So that the server 1 can be network communicatively connected to the automated guided vehicle 2.
In the present embodiment, the memory 12 is used to store software programs and data installed in the server 1. In the present embodiment, the storage 12 may be an internal storage unit of the server 1, such as a hard disk or a memory of the server 1. In other embodiments, the memory 12 may also be an external storage device of the server 1, such as a plug-in hard disk, a Smart Media Card (SMC), a Secure Digital (SD) Card, a Flash memory Card (Flash Card), or the like provided on the server 1.
In the present embodiment, the memory 12 further stores a virtual map (e.g., an electronic map) of the navigation space, where the virtual map includes a plurality of virtual paths. The virtual path is composed of a reference point and a connection relation between the reference point and the reference point. The virtual path defines a plurality of reference points of the automatic guided vehicle 2 on the whole virtual path and position coordinates corresponding to each reference point, and the sequence of each automatic guided vehicle 2 passing through the plurality of reference points.
In the present embodiment, the memory 12 stores in advance the position coordinates of each reference point on the virtual path. The position coordinates of the respective reference points on the virtual path may refer to coordinates in a coordinate system (XOY) established based on an area where the entire navigation space is located.
In this embodiment, the processor 13 may be a Central Processing Unit (CPU), or other microprocessor or other data processing chip capable of executing control functions. The processor 13 is used to execute software program codes, arithmetic data, and the like.
Referring to fig. 3, a schematic diagram of an automatic guided vehicle in the automatic navigation system according to an embodiment of the invention is shown. In the present embodiment, the number of the automatic guided vehicle 2 may be one or more. The automatic guided vehicle 2 includes, but is not limited to, a battery 20, a traveling unit 21, a wireless unit 22, and a controller 23. The battery 20, the traveling unit 21, the wireless unit 22, and the controller 23 are electrically connected to each other.
In the present embodiment, the battery 20 is used to supply power to the traveling unit 21, the wireless unit 22, and the controller 23. The walking unit 21 is configured to walk according to the movement instruction received by the automatic guided vehicle 2. The walking unit 21 is a wheel type, and includes a left wheel 210 and a right wheel 211. The left wheel 210 and the right wheel 211 are respectively provided with a wheel encoder 3.
The wheel encoder 3 is used for returning the pulse number according to the number of wheel rotation turns in the running process of the automatic guided vehicle 2. In the prior art, the wheel encoder 3 may return a predetermined number of pulses, for example 28 ten thousand, when the wheel makes one revolution.
The wireless unit 22 is used to provide a network connection between the automated guided vehicle 2 and the server 1. The controller 23 is configured to receive a control instruction sent by the server 1 to control the walking unit 21 to walk along a virtual path.
In this embodiment, the automatic guided vehicle 2 may further include a charging unit (not shown) for providing power to the battery 20.
In the prior art, the server 1 may assist to control the automatic guided vehicle 2 to travel on the virtual path according to video or image information captured by a camera installed in the navigation space. However, when the automatic guided vehicle 2 travels to the blind area of the camera, the server 1 cannot confirm whether the automatic guided vehicle 2 still travels on the virtual path. Therefore, the server 1 in this scheme may collect pulse information sent by the wheel encoders 3 mounted on the wheels of the automatic guided vehicle 2, and estimate pose information of the automatic guided vehicle 2 at the next time according to the pulse information and pose information of the automatic guided vehicle 2 at the current time, so that when the automatic guided vehicle 2 travels to a blind area that cannot be covered by a camera in a navigation space, the pose information of the automatic guided vehicle 2 may be obtained, and a control instruction may be generated according to the pose information and reference point information on the virtual path to control the automatic guided vehicle 2 to travel on the virtual path. In this embodiment, the pose information includes position information and course angle information.
For example, after the pose information of the automated guided vehicle 2 at the time k is obtained, the server 1 receives the pulse number fed back by the wheel encoder 3 on the automated guided vehicle 2, and calculates the heading offset angle of the automated guided vehicle 2 according to the pulse number, and the pose information of the automated guided vehicle 2 at the time k +1 is obtained according to the position information and the heading offset angle in the pose information of the time k. And the position information of the automatic guided vehicle at the time k is position information determined according to an image shot by a camera arranged in a navigation space or initial position information of the automatic guided vehicle on the virtual path. The position information determined according to the image shot by the camera installed in the navigation space is the prior art, and is not described herein again. In this embodiment, the pose information of the automated guided vehicle 2 at the time k is the position information of the automated guided vehicle at the time k and the heading angle information of the automated guided vehicle at the time k calculated according to the number of pulses. And the position information of the automatic guided vehicle at the time k is position information determined according to an image shot by a camera installed in a navigation space or initial position information of the automatic guided vehicle on the virtual path.
Specifically, assume that the total number of pulses of the wheel encoder 3 is N
0And the radius of the left wheel 210 and the right wheel 211 of the automatic guided vehicle 2 is r, the path distance represented by each pulse can be calculated as follows:
let d be the distance traveled by the right wheel 211 of the automatic guided vehicle 2RThe left wheel 210 travels a distance dLThen, one can get: dR=de·NR,dL=de·NLWherein N isRIndicates the pulse number N fed back by the wheel encoder 3 of the right wheel 211 in the running process of the automatic guided vehicle 2LIndicating the number of pulses fed back by the wheel encoder 3 of the left wheel 210 during the driving of the automatic guided vehicle 2.
The heading angle deviation delta theta of the automatically guided vehicle 2 can be calculated from the difference in distance traveled by the left wheel 210 and the right wheel 211 of the automatically guided vehicle 2,
where R is the instantaneous center of curvature radius and l is the lateral distance between the left and right wheels.
Based on the theoretical derivation, the heading angle offset of the automated guided vehicle 2 at time k can be calculated as:
wherein d is
R,k=d
e·N
R,kRepresents the distance traveled by the right wheel 211 of the automatic guided vehicle 2 at time k, d
L,k=d
e·N
L,kIndicating the distance traveled by the left wheel 210 of the automated guided vehicle 2 at time k.
And at the next moment, i.e. at the moment k +1, the automatic primingThe heading angle of the guide vehicle 2 is thetak+1=θk+Δθk。
Based on Δ θ that has been calculatedk、dR,kAnd dL,kInstantaneous center of curvature radius R at time kkCan be expressed as:
suppose that the position information of the automatic guided vehicle 2 at the time k is (x)k,yk) And the position information at the time k +1 is (x)k+1,yk+1). The euclidean distance between the position at time k and the position at time k +1 is then:
based on the distance D between two pointsk,k+1And position information (x) of the automated guided vehicle 2 at time kk,yk) The position information (x) of the automated guided vehicle 2 at the time k +1 can be calculatedk+1,yk+1),
And finally, the server 1 generates a control instruction according to the position information at the moment of k +1 and the reference point information on the virtual path so as to control the automatic guided vehicle 2 to walk on the virtual path.
Referring to fig. 4, a flowchart of an automatic navigation method according to an embodiment of the invention is shown. The order of the steps in the flow chart may be changed, and some steps may be omitted or combined according to different requirements.
In step S41, the server 1 receives the pulse number fed back by the wheel encoder 3 during the driving of the automatic guided vehicle 2.
In the present embodiment, a wheel encoder 3 is attached to each of the left wheel 210 and the right wheel 211 of the automatic guided vehicle 2. The wheel encoder 3 is used for returning the pulse number according to the number of wheel rotation turns in the running process of the automatic guided vehicle 2. After the automatic guided vehicle 2 travels a certain distance, the server 1 may receive the pulse numbers fed back by the wheel encoders 3 on the left wheel 210 and the right wheel 211 respectively during the traveling of the automatic guided vehicle 2. Setting NRNumber of pulses, N, fed back by a wheel encoder 3 mounted on the right wheel 211LThe number of pulses fed back to the wheel encoder 3 mounted on the left wheel 210.
Step S42, the server 1 calculates the pose information of the automated guided vehicle 2 at the time k +1 according to the number of pulses and the pose information of the automated guided vehicle 2 at the time k, where the pose information includes course angle information and position information.
In this embodiment, the pose information of the automated guided vehicle 2 at the time k is the position information of the automated guided vehicle at the time k and the heading angle information of the automated guided vehicle at the time k calculated according to the number of pulses. And the position information of the automatic guided vehicle at the time k is position information determined according to an image shot by a camera installed in a navigation space or initial position information of the automatic guided vehicle on the virtual path. Specifically, the distance d traveled by the right wheel 211 after the automatic guided vehicle 2 travels a distance is calculated separatelyRAnd the distance d traveled by the left wheel 210L。
Assuming that the total number of pulses of the wheel encoder 3 is N
0And the radius of the left wheel 210 and the right wheel 211 of the automatic guided vehicle 2 is r, the path distance represented by each pulse can be calculated as follows:
then, after the automatic guided vehicle 2 travels a certain distance, the number of pulses fed back from the wheel encoder 3 installed on the right wheel 211 can be determined according to the number of pulses installed on the wheel encoderThe number of pulses fed back by the wheel encoder 3 of the left wheel 210 and the path distance represented by each pulse of the wheel encoder 3 respectively calculate the distance d traveled by the right wheel 211 of the automatic guided vehicle 2RA distance d from the left wheel 210LWherein d isR=de·NR,dL=de·NL。
The heading angle offset of the automatically guided vehicle 2 can be calculated from the difference in distance traveled by the left wheel 210 and the right wheel 211 of the automatically guided vehicle 2,
where R is the instantaneous center of curvature radius and l is the lateral distance between the left and right wheels.
Based on the theoretical derivation, the heading angle offset of the automated guided vehicle 2 at time k can be calculated as:
wherein d is
R,k=d
e·N
R,kRepresents the distance traveled by the right wheel 211 of the automatic guided vehicle 2 at time k, d
L,k=d
e·N
L,kIndicating the distance traveled by the left wheel 210 of the automated guided vehicle 2 at time k.
And at the next moment, i.e. at the moment k +1, the heading angle of the autonomous guided vehicle 2 is θk+1=θk+Δθk。
Based on Δ θ that has been calculatedk、dR,kAnd dL,kInstantaneous center of curvature radius R at time kkCan be expressed as:
suppose that the position information of the automatic guided vehicle 2 at the time k is (x)k,yk) And the position information at the time k +1 is (x)k+1,yk+1). The euclidean distance between the position at time k and the position at time k +1 is then:
based on the distance D between two pointsk,k+1And position information (x) of the automated guided vehicle 2 at time kk,yk) The position information (x) of the automated guided vehicle 2 at the time k +1 can be calculatedk+1,yk+1),
Step S43, the server 1 generates a control instruction according to the pose information of the automatic guided vehicle 2 at the time k +1 and the reference point information on the virtual path prestored in the server 1, so as to control the automatic guided vehicle 2 to walk on the corresponding virtual path in the navigation space.
For example, when the automated guided vehicle 2 travels to a blind area of a camera in a navigation space at the time k +1, the server 1 calculates a heading angle θ of the automated guided vehicle 2 at the time k +1k+1And position coordinates (x)k+1,yk+1) And according to said position coordinates (x)k+1,yk+1) And reference point coordinates (a, b) on the navigation path, generating a walking control command, and then sending the walking control command to the automatic guided vehicle 2 so as to guide the automatic guided vehicle 2 from the position coordinate point (x)k+1,yk+1) And walking to the reference point coordinates (a, b) according to the course angle. So that the automatic guided vehicle 2 can be continuously controlled to travel on the virtual path.
It is understood that the reference point on the virtual path is the reference point closest to the position coordinates of the automatic guided vehicle at the time k + 1.
Although the present invention has been described in detail with reference to the preferred embodiments, it will be understood by those skilled in the art that various changes may be made and equivalents may be substituted without departing from the spirit and scope of the invention.