\input manualMacros.tex
\manBegin
\manPageInfo{RCI Reference Manual}{}{}
\manTitle{zerograv}{1}
\manSection{NAME}
{\tt \manName{zerograv}}
-- RCI program to put the robot into zero gravity mode.
\manSection{USAGE}
\cverbatim
zerograv [<robotName>] [-sim[=<simaddr>]] [-on]
@endcverbatim
\manSection{DESCRIPTION}
This program is used to put the robot into {\it zerogravity} mode, where
its joints are put into current control mode and just enough current is
applied at each instant to balance to gravity loading of whatever position
the robot happens to be in. This allows the robot to be moved about and
positioned freely, as though it were a \$50,000 luxo-lamp.

\manInset{{\bf Warning:} This program will only work for a
particular robot 
if (1) a {\tt gravload} function is defined for that robot's
class and a pointer to it is contained in the {\tt KYN}
structure, and (2) the gravity loading coefficients for
the particular robot are known
and available in the {\tt KYN} structure as well. 
If these conditions are not met, then the robot may try to
put itself through the floor.}

\manSection{ARGUMENTS}
\manItem{{\tt robotName} --}
Optional robot name. If absent, the name is obtained from the system file
{\filefont \$RCCL/conf/defaultRobot}.
\manItem{{\tt -sim} --}
Causes the program to be run in simulator mode, in which it will attempt to 
connect to a robot simulator program (see {\tt robotsim}) instead of 
connecting to a real robot.
\manItem{}
If unqualified, the {\tt -sim} option causes the program to seek a simulator
running on the same machine under the same user name. A different simulator
can be specified by adding an address string {\tt <simaddr>},
as in {\tt -sim=<simaddr>}. For the format of this
address string, see {\tt simAddress(5)}.

\manItem{{\tt -on} --}
Leave the robot arm power on after the program has exited.

\manItem{{\tt -friction} --}
Increase the functionality of the program to provide
friction compensation for the joints. This can be
enabled or disabled for each joint interactively (disabled
is the default) and the compensation values themselves can
also be set.

\manSection{OPERATION}
The program is interactive. Commands are entered using the
{\it C-tree matcher}, an automatic command completion utility.
Full documentation on the C-tree matcher is given in the file
{\filefont doc/CtreeMatch.doc}.

The commands available are:
\manItem{{\tt show} --}
Show the current robot encoder values. If the robot is calibrated,
also show angle values. Show Coulomb friction terms
if the {\tt -friction} option was specified.
\manItem{{\tt hand open} --}
Open the robot gripper.
\manItem{{\tt hand close} --}
Close the robot gripper.

\manItem{{\tt frictionComp <jnt> on} --}
Enable friction compensation for joint number {\tt <jnt>} (or all
joints, if {\tt <jnt>} is given as {\tt all}).
When friction compensation is enabled for a particular joint,
the Coulomb friction term for that joint is used to make
it easier to ``move'' the joint in a particular direction
(although there will still be a ``sticking'' effect when the joint
changes directions). Initial values for the Coulomb
friction terms are taken from the {\tt coulFriction} 
field in the robot's {\tt KYN} structure (q.v.).

\manItem{{\tt frictionComp <jnt> off} --}
Disable friction compensation for joint number {\tt <jnt>} (or all
joints, if {\tt <jnt>} is given as {\tt all}).

\manItem{{\tt set frictionComp <jnt> <value>} --}
Set the Coulomb friction term for joint number {\tt <jnt>} to the
indicated value. Note that the final values
are {\it not} automatically written back into the robot's {\tt KYN}
structure.

\manItem{{\tt quit} --}
Exit the program.

\manEnd
\end
