Pathweaver labview

Is it possible to use pathweaver in labview and if so does anyone have example code or could walk me through how to use it?

Start with CTRE Example for Motion Profile…

That example is using motion profile to control one speed controller so therefore only one wheel.
It takes a input a tab delimited file whose columns are Wheel Rotations, Velocity and time interval.
The example converts the raw values into encoder values.

You then use a program like Pathweaver to generate the input file with the values you want.

To drive a robot you need a path for the right motor and a path for the left.

It’s not too hard but can be hard to initially understand how all the pieces fit together.

PathWeaver doesn’t export this type of file anymore. It exports a JSON that is compatible with the new WPILib trajectory generation system and is therefore not compatible with LabVIEW.

You could use an older version of PathWeaver from 2019 to generate CSV files that are compatible with the Talon SRX.

Good to know.
I use PathPlanner myself.

But, for PathWeaver would it be that difficult to write a program in Python or JS to convert the JSON to a CSV? Does the JSON have the relevant information?

No, the JSON only contains time, pose, velocity, acceleration and curvature data and not individual encoder positions for the left and right sides. Although it could be possible to get the desired values from this, it is not natively supported and would take a bit of work.

See this post …

It isn’t PathWeaver, but it does a similar thing.

This might interest you too.