I wanted to learn some about path following, so I took the Pathfinder samples and created a path creation and simulation routine that runs on a PC (or a robot) in labview. Here is a link to the labview project files for anyone that is interested.
The two samples are very similar. The only difference is how they index into the arrays of the created path. One is sequential (and assumes the control loop doesn’t fall behind in time). The other indexed based on time offset.
I realize that pathfinder is old, and maybe something new is coming out for the upcoming season. Regardless it was helpful to me in showing how the path process works and to visually create paths and see the results.
The simulated robot has a lot of friction when turning, and I didn’t implement speed control in the drive system. (Did I say the samples are somewhat crude…) As such I implemented a crude gyro compensation. I didn’t implement encoder compensation.
The 2/19/2019 version of the DLL LIB and SO files are included. The DLL may need to be copied to the LABVIEW “resource” directory so it can be found while executing interactively.
Very cool. We actually did something similar in 2018 to plot paths on the field (see here) and we used it to generate a “playbook” of our autonomous routines (2018AutoPlaybook_6.pdf).
As a shameless plug, you might want to consider using our LabVIEW documentation generator so anyone with a web browser can see the code you’re sharing. I like seeing what other teams are doing in LabVIEW, but I rarely am on a PC with LabVIEW installed.
Thanks. I’ll look at your documentation LV document system and add code samples on the next version. (I guess that means I have to make the code neater.) I started working on closed loop speed control for the simulated robot and found some interesting things in the simulated encoders. I worked through most of them, but I’ve been side tracked on something else.
The original sample could easily be modified to output a comma separated text file, or other data file, to be read by a robot, in any language, for run time use.
I mostly thought is was fun to see the path, then see the simulated robot execute the path. (I was also doing this because I thought it might be useful to include a chapter on this…)
i updated the path creation sample utility to use the 2020 field and to output the path data to a text file, which could be used on a robot. This program is an executable that can be run without needing LabVIEW. The repository also contains the source project, which contains a number of other samples including a simulated robot that can execute the path. (Although as before, this implementation is somewhat simplistic.