\input manualMacros.tex
\manBegin
\manPageInfo{RCCL Reference Manual}{}{}
\manTitle{setTime}{3}
\manSection{NAME}
{\rightskip=0ptplus1fil
{\tt \manName{setTime}}
-- explicitly set time for RCCL motion.
}
\manSection{USAGE}
\cverbatim
#include <rccl.h>

setTime (mnp, tau, sigma)
  MANIP *mnp;
  float tau, sigma;
@endcverbatim
\manSection{ARGUMENTS}
\manItem{{\tt mnp} --}
Manipulator reference structure.
\manItem{{\tt tau} --}
Transition time (milliseconds).
\manItem{{\tt sigma} --}
Path segment time (milliseconds).
\manSection{RESTRICTIONS}
This routine must be called from the planning level.
\manSection{DESCRIPTION}
This routine allows a program to explicitly set the transition and
path segment times for an RCCL motion.
It affects the next motion request only.

A {\it transition} is the period spent blending smoothly
from one motion to the next. In general, every motion
has a {\it start transition} and an {\it end transition}, where the
start transition is equivalent to the end transition of the previous motion.
A short transition time corresponds to a rapid acceleration from one
motion to the next.
The {\it path segment time} is
the total length of time for a motion, measured from the midpoint
of the start transition to the midpoint of the end transition.

{\tt setTime()} allows both the transition and path segment times
to be specified explicity. 
If these times are not specified, the trajectory generator
computes them automatically from the manipulator's acceleration and velocity
specifications (see {\tt setAccel(3)} and {\tt setSpeed(3)}).
{\tt tau} specifies {\it one half} of the total time for the 
{\it start} transition.
{\tt sigma} specifies the path segment time.
If either argument is given as
{\tt F_DEFAULT}, the corresponding time will be computed by the system
as usual.
If {\tt sigma} is given as {\tt F_UNDEF}, then the motion is set
to run indefinitely. {\tt sigma} cannot be set to 0.0.

\manSection{DIAGNOSTICS}
This routine returns {\tt -1} in the event of an error.
It will automatically abort the program if the option {\tt RCCL_ERROR_EXIT} is set
(see {\tt rcclSetOptions(3)}).
Error codes and messages are placed on the {\it errorStack} (q.v.). 
The following error codes may be set:

\manItem{{\tt ERange} --}
{\tt tau} was negative and not equal to {\tt F_DEFAULT},
or {\tt sigma} was non-positive and not equal to {\tt F_DEFAULT} or
{\tt F_UNDEF}.

The routine will abort the program if called from the control level.
\manSection{SEE ALSO}
\rightskip=0ptplus1fil
{\tt setSpeed(3)}, {\tt setAccel(3)}, {\tt move(3)}, {\tt
rcclSetOptions(3)}, {\tt errorStack(3)}.
\manEnd
\end
