Showing results for 
Search instead for 
Did you mean: 

Executing a loop an x amount of times as motor moves



I am trying make a program that would acquire data for x amount of points over a surface area, but I am unsure how to execute a while loop an x amount of times during one line of movement. I don't want to sync it up with stopping the motor over that line since I'm trying to do this for speed and efficiency. In other words, in one continuous 1D movement, how do I acquire a set amount of times that are evenly spaced?


Is there a certain loop I could use or function? Are there variations in loop execution times? Some help would be appreciated. Code is attached. Some residual parts are in there from previous versions.


Thanks in advance.


0 Kudos
Message 1 of 1