 // (r = radius, h = height, b = azimuth = base servo angle, handAngle = angle of hand from horizontal)
 int moveArmCoord( double radius_mm, double height_mm, double basAngle_d, double handAngle_d )
 {
+   if ( radius_mm < 0 ) return -4;
    DEBUG("moveArmCoord("); DEBUG(radius_mm); DEBUG(","); DEBUG(height_mm); DEBUG(","); DEBUG(basAngle_d); DEBUGln(")");
    /* Lengths from shoulder to wrist in cylindrical coordinates */
    double s2w_h = height_mm - BASE_HEIGHT - HAND*sin( radians( handAngle_d) );

   steps = max( steps, wDiff );
   DEBUG("Steps: "); DEBUGln(steps);
   
   if( steps < 2 )
   {
      ret_val = moveArm( basPulse, shlPulse, elbPulse, wriPulse );
   }
   else
   {

   if ( ( ret_val = servoWritePulse( ELB, elbPulse ) ) != 0 ) return ret_val;
   if ( ( ret_val = servoWritePulse( WRI, wriPulse ) ) != 0 ) return ret_val;
   
   //delay(g_moveDelay);
   
   return ret_val;
}
