Skip to content

Commit 51d28e0

Browse files
committed
readme replace otg with ruckig
1 parent 1987e63 commit 51d28e0

File tree

1 file changed

+11
-12
lines changed

1 file changed

+11
-12
lines changed

README.md

Lines changed: 11 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -103,7 +103,7 @@ Within the control loop, you need to update the *current state* of the input par
103103

104104
The Ruckig Community Version includes built-in support for intermediate waypoints, using our cloud API for remote calculation. Of course, the Ruckig Pro version is fully local. To allocate the necessary memory for a variable number of waypoints beforehand, we need to pass the maximum number of waypoints to Ruckig via
105105
```.cpp
106-
Ruckig<6> otg {0.001, 8};
106+
Ruckig<6> ruckig {0.001, 8};
107107
InputParameter<6> input {8};
108108
OutputParameter<6> output {8};
109109
```
@@ -118,7 +118,7 @@ As soon as at least one intermediate positions is given, the Ruckig Community Ve
118118

119119
When using *intermediate positions*, both the underlying motion planning problem as well as its calculation changes significantly. In particular, there are some fundamental limitations for jerk-limited online trajectory generation regarding the usage of waypoints. Please find more information about these limitations [here](https://docs.ruckig.com/md_pages_2__intermediate__waypoints.html), and in general we recommend to use
120120
```.cpp
121-
input.intermediate_positions = otg.filter_intermediate_positions(input.intermediate_positions, {0.1, ...});
121+
input.intermediate_positions = ruckig.filter_intermediate_positions(input.intermediate_positions, {0.1, ...});
122122
```
123123
to filter waypoints according to a (high) threshold distance. Setting *interrupt_calculation_duration* makes sure to be real-time capable by refining the solution in the next control invocation. Note that this is a soft interruption of the calculation. Currently, no minimum or discrete durations are supported when using intermediate positions.
124124
@@ -257,7 +257,7 @@ When following an arbitrary signal with position, velocity, acceleration, and je
257257

258258
To use the tracking interface, construct
259259
```.cpp
260-
Trackig<1> otg {0.01}; // control cycle
260+
Trackig<1> trackig {0.01}; // control cycle
261261
```
262262
and set the current state as well as the kinematic constraints via
263263
```.cpp
@@ -270,17 +270,17 @@ input.max_jerk = {5.0};
270270
```
271271
Then, we can track a signal in an online manner within the real-time control loop
272272
```.cpp
273-
for (double t = 0; t < 10.0; t += otg.delta_time) {
273+
for (double t = 0; t < 10.0; t += trackig.delta_time) {
274274
auto target_state = signal(t); // signal returns position, velocity, and acceleration
275-
auto res = otg.update(target_state, input, output);
275+
auto res = trackig.update(target_state, input, output);
276276
// Make use of the smooth target motion here (e.g. output.new_position)
277277

278278
output.pass_to_input(input);
279279
}
280280
```
281281
Please find a complete example [here](https://github.com/pantor/ruckig/blob/main/examples/13_tracking.cpp). This functionality can also be used in an offline manner, e.g. when the entire signal is known beforehand. Here, we call the
282282
```.cpp
283-
smooth_trajectory = otg.calculate_trajectory(target_states, input);
283+
smooth_trajectory = trackig.calculate_trajectory(target_states, input);
284284
```
285285
method with the trajectory given as a `std::vector` of target states. The Tracking interface is available in the Ruckig Pro version.
286286

@@ -290,7 +290,7 @@ method with the trajectory given as a `std::vector` of target states. The Tracki
290290
So far, we have told Ruckig the number of DoFs as a template parameter. If you don't know the number of DoFs at compile-time, you can set the template parameter to `ruckig::DynamicDOFs` and pass the DoFs to the constructor:
291291

292292
```.cpp
293-
Ruckig<DynamicDOFs> otg {6, 0.001};
293+
Ruckig<DynamicDOFs> ruckig {6, 0.001};
294294
InputParameter<DynamicDOFs> input {6};
295295
OutputParameter<DynamicDOFs> output {6};
296296
```
@@ -307,7 +307,7 @@ Ruckig supports custom vector types to make interfacing with your code even easi
307307
```
308308
and then call the constructors with the `ruckig::EigenVector` parameter.
309309
```.cpp
310-
Ruckig<6, EigenVector> otg {0.001};
310+
Ruckig<6, EigenVector> ruckig {0.001};
311311
InputParameter<6, EigenVector> input;
312312
OutputParameter<6, EigenVector> output;
313313
```
@@ -333,11 +333,10 @@ The current test suite validates over 5.000.000.000 random trajectories as well
333333

334334
The Ruckig Pro version has additional tools to increase the numerical range and improve reliability. For example, the`position_scale` and `time_scale` parameter of the `Calculator` class change the internal representation of the input parameters.
335335
```.cpp
336-
Ruckig<1> otg;
337-
// Works also for Trackig<1> otg;
336+
Ruckig<1> ruckig; // Works also for Trackig
338337

339-
otg.calculator.position_scale = 1e2; // Scales all positions in the input parameters
340-
otg.calculator.time_scale = 1e3; // Scale all times in the input parameters
338+
ruckig.calculator.position_scale = 1e2; // Scales all positions in the input parameters
339+
ruckig.calculator.time_scale = 1e3; // Scale all times in the input parameters
341340
```
342341
This way, you can easily achieve the requirements above even for very high jerk limits or very long trajectories. Note that the scale parameters don't effect the resulting trajectory - they are for internal calculation only.
343342

0 commit comments

Comments
 (0)