Example of a real robot control, the Viper850 robot (arm, with 6 degrees of freedom).
#include <iostream>
#include <visp3/core/vpCameraParameters.h>
#include <visp3/core/vpConfig.h>
#include <visp3/core/vpDebug.h>
#include <visp3/robot/vpRobotViper850.h>
#ifdef VISP_HAVE_VIPER850
int main()
{
#ifdef ENABLE_VISP_NAMESPACE
#endif
try {
std::cout << "a test for vpRobotViper850 class..." << std::endl;
std::cout << "-- Default settings for Viper850 ---" << std::endl;
std::cout << viper850 << std::endl;
std::cout << cam << std::endl;
std::cout << "-- Settings associated to the Marlin F033C camera without "
"distortion ---"
<< std::endl;
std::cout << viper850 << std::endl;
std::cout << cam << std::endl;
std::cout << "-- Settings associated to the Marlin F033C camera with "
"distortion ------"
<< std::endl;
std::cout << viper850 << std::endl;
std::cout << cam << std::endl;
std::cout << "-- Current joint position:" << std::endl;
std::cout <<
" " << q.
t() << std::endl;
std::cout << "-- Current fMe:" << std::endl;
std::cout << "fMe:" << std::endl
<<
"\tt: " << t.
t() << std::endl
<< std::endl;
return EXIT_SUCCESS;
}
std::cout << "Catch an exception: " << e << std::endl;
return EXIT_FAILURE;
}
}
#else
int main()
{
std::cout << "The real Viper850 robot controller is not available." << std::endl;
return EXIT_SUCCESS;
}
#endif
Generic class defining intrinsic camera parameters.
@ perspectiveProjWithDistortion
Perspective projection with distortion model.
Implementation of column vector and the associated operations.
error that can be emitted by ViSP classes.
Implementation of an homogeneous matrix and operations on such kind of matrices.
void extract(vpRotationMatrix &R) const
static double deg(double rad)
Control of Irisa's Viper S850 robot named Viper850.
void getPosition(const vpRobot::vpControlFrameType frame, vpColVector &position) VP_OVERRIDE
Implementation of a rotation matrix and operations on such kind of matrices.
Implementation of a rotation vector as Euler angle minimal representation.
vpRzyzVector & buildFrom(const vpRotationMatrix &R)
Class that consider the case of a translation vector.
void getCameraParameters(vpCameraParameters &cam, const unsigned int &image_width, const unsigned int &image_height) const
@ TOOL_MARLIN_F033C_CAMERA
void get_fMe(const vpColVector &q, vpHomogeneousMatrix &fMe) const