Fawkes API Fawkes Development Version
arm_dummy.h
1
2/***************************************************************************
3 * arm_dummy.h - Class for a Kinova Jaco arm, simulating a dummy arm
4 *
5 * Created: Mon Aug 04 19:58:22 2014
6 * Copyright 2014 Bahram Maleki-Fard
7 *
8 ****************************************************************************/
9
10/* This program is free software; you can redistribute it and/or modify
11 * it under the terms of the GNU General Public License as published by
12 * the Free Software Foundation; either version 2 of the License, or
13 * (at your option) any later version.
14 *
15 * This program is distributed in the hope that it will be useful,
16 * but WITHOUT ANY WARRANTY; without even the implied warranty of
17 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18 * GNU Library General Public License for more details.
19 *
20 * Read the full text in the LICENSE.GPL file in the doc directory.
21 */
22
23#ifndef _PLUGINS_JACO_ARM_DUMMY_H_
24#define _PLUGINS_JACO_ARM_DUMMY_H_
25
26#include "arm.h"
27#include "types.h"
28
29namespace fawkes {
30
31//class RefPtr;
32
33class JacoArmDummy : public JacoArm
34{
35public:
36 JacoArmDummy(const char *name);
37 virtual ~JacoArmDummy();
38
39 virtual void initialize();
40
41 virtual bool final();
42 virtual bool initialized();
43
44 virtual void get_joints(std::vector<float> &to) const;
45 virtual void get_coords(std::vector<float> &to);
46 virtual void get_fingers(std::vector<float> &to) const;
47
48 virtual void stop();
49 virtual void push_joystick(unsigned int button);
50 virtual void release_joystick();
51
52 virtual void goto_trajec(std::vector<std::vector<float>> *trajec, std::vector<float> &fingers);
53 virtual void
54 goto_joints(std::vector<float> &joints, std::vector<float> &fingers, bool followup = false);
55 virtual void goto_coords(std::vector<float> &coords, std::vector<float> &fingers);
56 virtual void goto_ready();
57 virtual void goto_retract();
58
59private:
60 std::vector<float> coords_;
61 std::vector<float> joints_;
62 std::vector<float> fingers_;
63
64 std::vector<float> pos_ready_;
65 std::vector<float> pos_retract_;
66};
67
68} // end of namespace fawkes
69
70#endif
Class for simulating a dummy Kinova Jaco Arm.
Definition: arm_dummy.h:34
virtual void goto_retract()
Move the arm to RETRACT position.
Definition: arm_dummy.cpp:193
virtual void release_joystick()
Simulate releasing the joystick of the Kinova Jaco arm.
Definition: arm_dummy.cpp:132
virtual void goto_ready()
Move the arm to READY position.
Definition: arm_dummy.cpp:187
virtual void goto_joints(std::vector< float > &joints, std::vector< float > &fingers, bool followup=false)
Move the arm to given configuration.
Definition: arm_dummy.cpp:163
virtual void goto_trajec(std::vector< std::vector< float > > *trajec, std::vector< float > &fingers)
Move the arm along the given trajectory.
Definition: arm_dummy.cpp:144
virtual ~JacoArmDummy()
Destructor.
Definition: arm_dummy.cpp:81
virtual void initialize()
Initialize the arm.
Definition: arm_dummy.cpp:86
JacoArmDummy(const char *name)
Constructor.
Definition: arm_dummy.cpp:55
virtual void get_coords(std::vector< float > &to)
Get the cartesian coordinates of the arm.
Definition: arm_dummy.cpp:104
virtual void stop()
Stop the current movement.
Definition: arm_dummy.cpp:122
virtual bool initialized()
Check if arm is initialized.
Definition: arm_dummy.cpp:98
virtual void push_joystick(unsigned int button)
Simulate a push of a button on the joystick of the Kinova Jaco arm.
Definition: arm_dummy.cpp:127
virtual void goto_coords(std::vector< float > &coords, std::vector< float > &fingers)
Move the arm to given configuration.
Definition: arm_dummy.cpp:180
virtual void get_joints(std::vector< float > &to) const
Get the joint angles of the arm.
Definition: arm_dummy.cpp:110
virtual void get_fingers(std::vector< float > &to) const
Get the position values of the fingers.
Definition: arm_dummy.cpp:116
Abstract class for a Kinova Jaco Arm that we want to control.
Definition: arm.h:36
Fawkes library namespace.