49 #include <visp3/robot/vpReflexTakktile2.h> 51 int main(
int argc,
char *argv[])
53 std::string opt_network_interface =
"eth0";
54 std::string opt_finger_file_name =
"yaml/finger_calibrate.yaml";
55 std::string opt_tactile_file_name =
"yaml/tactile_calibrate.yaml";
56 std::string opt_motor_file_name =
"yaml/motor_constants.yaml";
58 for (
int i = 0; i < argc; i++) {
59 if (std::string(argv[i]) ==
"--network")
60 opt_network_interface = std::string(argv[i + 1]);
61 else if (std::string(argv[i]) ==
"--finger")
62 opt_finger_file_name = std::string(argv[i + 1]);
63 else if (std::string(argv[i]) ==
"--tactile")
64 opt_tactile_file_name = atoi(argv[i + 1]);
65 else if (std::string(argv[i]) ==
"--motor")
66 opt_motor_file_name = atoi(argv[i + 1]);
67 else if (std::string(argv[i]) ==
"--help" || std::string(argv[i]) ==
"-h") {
68 std::cout <<
"\nUsage: " << argv[0]
69 <<
" [--network <interface name>] " 70 " [--finger <calib file name>]" 71 " [--tactile <calib file name>]" 72 " [--motor <constants file name>]" 75 std::cout <<
"Options:" << std::endl;
76 std::cout <<
" --network <interface name>" << std::endl;
77 std::cout <<
"\tNetwork interface name. Default: " << opt_network_interface << std::endl << std::endl;
78 std::cout <<
" --finger <calib file name>" << std::endl;
79 std::cout <<
"\tFinger calibration file name. Default: " << opt_finger_file_name << std::endl << std::endl;
80 std::cout <<
" --tactile <calib file name>" << std::endl;
81 std::cout <<
"\tTactile calibration file name. Default: " << opt_tactile_file_name << std::endl << std::endl;
82 std::cout <<
" --motor <constants file name>" << std::endl;
83 std::cout <<
"\tMotor constants file name. Default: " << opt_motor_file_name << std::endl << std::endl;
84 std::cout <<
" --help, -h" << std::endl;
85 std::cout <<
"\tPrint this helper." << std::endl;
90 #ifdef VISP_HAVE_TAKKTILE2 107 std::cout <<
"ViSP is not built to support Right Hand Reflex Takktile2 hand" << std::endl;
void setMotorConfigFile(const std::string &motor_file_name)
void setNetworkInterface(const std::string &network_interface="eth0")
void wait(int milliseconds)
void setFingerConfigFile(const std::string &finger_file_name)
void setTactileConfigFile(const std::string &tactile_file_name)