create Voltage Constrained Profile
fun createVoltageConstrainedProfile(length: Double, beginEndVel: Double, kV: Double, kA: Double, kS: Double, maxVoltage: (Double) -> Double, resolution: Double): CancelableProfile
Generates a complete voltage-constrained profile with cancellation capability. This creates forward and backward profiles, merges them, and adds cancellation constraints.
Return
CancelableProfile with optimal profile and cancellation constraints
Parameters
length
Total displacement length
begin End Vel
Beginning and ending velocity (must be same for feasibility)
k V
Velocity constant (velocity per unit voltage)
k A
Acceleration constant (acceleration per unit voltage)
k S
Static voltage offset (for static friction, etc.)
max Voltage
Function returning maximum voltage at each displacement
resolution
Sampling resolution for constraints