CTRE Motion Profiling Get Point Number

This year my team is looking to use motion profiling but when the talon gets to a specific point we would like to run a command(e.g. spit cargo out). We have everything figured out except the part where we get how far the talon is into the profile. I know that I can get the target position, target aux, and target velocity and compare them to the points that I sent in but that seems a little bit much and I feel like the talon has a way to tell you what point number it is on. Does anyone know if there is a way to do this or do I have to take the long way around?

You have to take the long way around. You could do the amount of point in the buffer remain - number of points in the buffer, but that is assuming you do not move at the start until all points are loaded. You could also do it based on time. Start a clock on the rio when the talon starts the profile and then every x ms is associated to a point in the csv file. When you are between point x and y spit cargo out.