24 #ifndef __INTERFACES_JACOINTERFACE_H_ 25 #define __INTERFACES_JACOINTERFACE_H_ 27 #include <interface/interface.h> 28 #include <interface/message.h> 29 #include <interface/field_iterator.h> 47 typedef struct __attribute__((packed)) {
48 int64_t timestamp_sec;
49 int64_t timestamp_usec;
69 } JacoInterface_data_t;
71 JacoInterface_data_t *data;
79 typedef struct __attribute__((packed)) {
80 int64_t timestamp_sec;
81 int64_t timestamp_usec;
82 } CalibrateMessage_data_t;
84 CalibrateMessage_data_t *data;
92 virtual Message * clone()
const;
99 typedef struct __attribute__((packed)) {
100 int64_t timestamp_sec;
101 int64_t timestamp_usec;
102 } RetractMessage_data_t;
104 RetractMessage_data_t *data;
112 virtual Message * clone()
const;
119 typedef struct __attribute__((packed)) {
120 int64_t timestamp_sec;
121 int64_t timestamp_usec;
122 } StopMessage_data_t;
124 StopMessage_data_t *data;
132 virtual Message * clone()
const;
139 typedef struct __attribute__((packed)) {
140 int64_t timestamp_sec;
141 int64_t timestamp_usec;
148 } CartesianGotoMessage_data_t;
150 CartesianGotoMessage_data_t *data;
153 CartesianGotoMessage(
const float ini_x,
const float ini_y,
const float ini_z,
const float ini_e1,
const float ini_e2,
const float ini_e3);
160 void set_x(
const float new_x);
163 void set_y(
const float new_y);
166 void set_z(
const float new_z);
169 void set_e1(
const float new_e1);
170 size_t maxlenof_e1()
const;
172 void set_e2(
const float new_e2);
173 size_t maxlenof_e2()
const;
175 void set_e3(
const float new_e3);
176 size_t maxlenof_e3()
const;
177 virtual Message * clone()
const;
184 typedef struct __attribute__((packed)) {
185 int64_t timestamp_sec;
186 int64_t timestamp_usec;
193 } AngularGotoMessage_data_t;
195 AngularGotoMessage_data_t *data;
198 AngularGotoMessage(
const float ini_j1,
const float ini_j2,
const float ini_j3,
const float ini_j4,
const float ini_j5,
const float ini_j6);
205 void set_j1(
const float new_j1);
206 size_t maxlenof_j1()
const;
208 void set_j2(
const float new_j2);
209 size_t maxlenof_j2()
const;
211 void set_j3(
const float new_j3);
212 size_t maxlenof_j3()
const;
214 void set_j4(
const float new_j4);
215 size_t maxlenof_j4()
const;
217 void set_j5(
const float new_j5);
218 size_t maxlenof_j5()
const;
220 void set_j6(
const float new_j6);
221 size_t maxlenof_j6()
const;
222 virtual Message * clone()
const;
229 typedef struct __attribute__((packed)) {
230 int64_t timestamp_sec;
231 int64_t timestamp_usec;
235 } MoveGripperMessage_data_t;
237 MoveGripperMessage_data_t *data;
240 MoveGripperMessage(
const float ini_finger1,
const float ini_finger2,
const float ini_finger3);
255 virtual Message * clone()
const;
262 typedef struct __attribute__((packed)) {
263 int64_t timestamp_sec;
264 int64_t timestamp_usec;
266 } SetPlannerParamsMessage_data_t;
268 SetPlannerParamsMessage_data_t *data;
277 char * params()
const;
278 void set_params(
const char * new_params);
279 size_t maxlenof_params()
const;
280 virtual Message * clone()
const;
287 typedef struct __attribute__((packed)) {
288 int64_t timestamp_sec;
289 int64_t timestamp_usec;
291 } JoystickPushMessage_data_t;
293 JoystickPushMessage_data_t *data;
302 uint32_t button()
const;
303 void set_button(
const uint32_t new_button);
304 size_t maxlenof_button()
const;
305 virtual Message * clone()
const;
312 typedef struct __attribute__((packed)) {
313 int64_t timestamp_sec;
314 int64_t timestamp_usec;
315 } JoystickReleaseMessage_data_t;
317 JoystickReleaseMessage_data_t *data;
325 virtual Message * clone()
const;
342 void set_x(
const float new_x);
345 void set_y(
const float new_y);
348 void set_z(
const float new_z);
360 float joints(
unsigned int index)
const;
361 void set_joints(
unsigned int index,
const float new_joints);
373 uint32_t
msgid()
const;
374 void set_msgid(
const uint32_t new_msgid);
385 virtual const char *
enum_tostring(
const char *enumtype,
int val)
const;
float z() const
Get z value.
size_t maxlenof_finger3() const
Get maximum length of finger3 value.
size_t maxlenof_connected() const
Get maximum length of connected value.
size_t maxlenof_finger1() const
Get maximum length of finger1 value.
void set_y(const float new_y)
Set y value.
size_t maxlenof_joints() const
Get maximum length of joints value.
Base class for all messages passed through interfaces in Fawkes BlackBoard.
size_t maxlenof_z() const
Get maximum length of z value.
Fawkes library namespace.
SetPlannerParamsMessage Fawkes BlackBoard Interface Message.
void set_finger1(const float new_finger1)
Set finger1 value.
float finger2() const
Get finger2 value.
size_t maxlenof_msgid() const
Get maximum length of msgid value.
virtual Message * create_message(const char *type) const
Create message based on type name.
MoveGripperMessage Fawkes BlackBoard Interface Message.
bool is_final() const
Get final value.
size_t maxlenof_finger2() const
Get maximum length of finger2 value.
Base class for all Fawkes BlackBoard interfaces.
uint32_t error_code() const
Get error_code value.
static const uint32_t ERROR_NO_IK
ERROR_NO_IK constant.
size_t maxlenof_error_code() const
Get maximum length of error_code value.
void set_connected(const bool new_connected)
Set connected value.
float euler3() const
Get euler3 value.
static const uint32_t ERROR_NONE
ERROR_NONE constant.
size_t maxlenof_initialized() const
Get maximum length of initialized value.
float euler2() const
Get euler2 value.
float finger1() const
Get finger1 value.
const char * type() const
Get type of interface.
float x() const
Get x value.
static const uint32_t ERROR_UNSPECIFIC
ERROR_UNSPECIFIC constant.
float * joints() const
Get joints value.
uint32_t msgid() const
Get msgid value.
CalibrateMessage Fawkes BlackBoard Interface Message.
StopMessage Fawkes BlackBoard Interface Message.
void set_error_code(const uint32_t new_error_code)
Set error_code value.
void set_initialized(const bool new_initialized)
Set initialized value.
size_t maxlenof_x() const
Get maximum length of x value.
float euler1() const
Get euler1 value.
bool is_initialized() const
Get initialized value.
void set_joints(unsigned int index, const float new_joints)
Set joints value at given index.
virtual const char * enum_tostring(const char *enumtype, int val) const
Convert arbitrary enum value to string.
void set_finger3(const float new_finger3)
Set finger3 value.
virtual bool message_valid(const Message *message) const
Check if message is valid and can be enqueued.
size_t maxlenof_euler3() const
Get maximum length of euler3 value.
void set_final(const bool new_final)
Set final value.
JoystickPushMessage Fawkes BlackBoard Interface Message.
void set_euler3(const float new_euler3)
Set euler3 value.
void set_z(const float new_z)
Set z value.
void set_msgid(const uint32_t new_msgid)
Set msgid value.
JacoInterface Fawkes BlackBoard Interface.
AngularGotoMessage Fawkes BlackBoard Interface Message.
void set_euler1(const float new_euler1)
Set euler1 value.
JoystickReleaseMessage Fawkes BlackBoard Interface Message.
size_t maxlenof_final() const
Get maximum length of final value.
bool is_connected() const
Get connected value.
float finger3() const
Get finger3 value.
CartesianGotoMessage Fawkes BlackBoard Interface Message.
RetractMessage Fawkes BlackBoard Interface Message.
virtual void copy_values(const Interface *other)
Copy values from other interface.
void set_finger2(const float new_finger2)
Set finger2 value.
static const uint32_t ERROR_PLANNING
ERROR_PLANNING constant.
float y() const
Get y value.
size_t maxlenof_euler2() const
Get maximum length of euler2 value.
size_t maxlenof_y() const
Get maximum length of y value.
void set_x(const float new_x)
Set x value.
void set_euler2(const float new_euler2)
Set euler2 value.
size_t maxlenof_euler1() const
Get maximum length of euler1 value.