Fawkes API  Fawkes Development Version
NaoJointPositionInterface.cpp
1 
2 /***************************************************************************
3  * NaoJointPositionInterface.cpp - Fawkes BlackBoard Interface - NaoJointPositionInterface
4  *
5  * Templated created: Thu Oct 12 10:49:19 2006
6  * Copyright 2008-2011 Tim Niemueller
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. A runtime exception applies to
14  * this software (see LICENSE.GPL_WRE file mentioned below for details).
15  *
16  * This program is distributed in the hope that it will be useful,
17  * but WITHOUT ANY WARRANTY; without even the implied warranty of
18  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19  * GNU Library General Public License for more details.
20  *
21  * Read the full text in the LICENSE.GPL_WRE file in the doc directory.
22  */
23 
24 #include <interfaces/NaoJointPositionInterface.h>
25 
26 #include <core/exceptions/software.h>
27 
28 #include <map>
29 #include <string>
30 #include <cstring>
31 #include <cstdlib>
32 
33 namespace fawkes {
34 
35 /** @class NaoJointPositionInterface <interfaces/NaoJointPositionInterface.h>
36  * NaoJointPositionInterface Fawkes BlackBoard Interface.
37  *
38  This interface provides access to Nao joint positions and movements.
39 
40  * @ingroup FawkesInterfaces
41  */
42 
43 
44 /** SERVO_head_yaw constant */
46 /** SERVO_head_pitch constant */
48 /** SERVO_l_shoulder_pitch constant */
50 /** SERVO_l_shoulder_roll constant */
52 /** SERVO_l_elbow_yaw constant */
54 /** SERVO_l_elbow_roll constant */
56 /** SERVO_l_wrist_yaw constant */
58 /** SERVO_l_hand constant */
59 const uint32_t NaoJointPositionInterface::SERVO_l_hand = 128u;
60 /** SERVO_l_hip_yaw_pitch constant */
62 /** SERVO_l_hip_roll constant */
64 /** SERVO_l_hip_pitch constant */
66 /** SERVO_l_knee_pitch constant */
68 /** SERVO_l_ankle_pitch constant */
70 /** SERVO_l_ankle_roll constant */
72 /** SERVO_r_shoulder_pitch constant */
74 /** SERVO_r_shoulder_roll constant */
76 /** SERVO_r_elbow_yaw constant */
77 const uint32_t NaoJointPositionInterface::SERVO_r_elbow_yaw = 65536u;
78 /** SERVO_r_elbow_roll constant */
79 const uint32_t NaoJointPositionInterface::SERVO_r_elbow_roll = 131072u;
80 /** SERVO_r_wrist_yaw constant */
81 const uint32_t NaoJointPositionInterface::SERVO_r_wrist_yaw = 262144u;
82 /** SERVO_r_hand constant */
83 const uint32_t NaoJointPositionInterface::SERVO_r_hand = 524288u;
84 /** SERVO_r_hip_yaw_pitch constant */
85 const uint32_t NaoJointPositionInterface::SERVO_r_hip_yaw_pitch = 1048576u;
86 /** SERVO_r_hip_roll constant */
87 const uint32_t NaoJointPositionInterface::SERVO_r_hip_roll = 2097152u;
88 /** SERVO_r_hip_pitch constant */
89 const uint32_t NaoJointPositionInterface::SERVO_r_hip_pitch = 4194304u;
90 /** SERVO_r_knee_pitch constant */
91 const uint32_t NaoJointPositionInterface::SERVO_r_knee_pitch = 8388608u;
92 /** SERVO_r_ankle_pitch constant */
93 const uint32_t NaoJointPositionInterface::SERVO_r_ankle_pitch = 16777216u;
94 /** SERVO_r_ankle_roll constant */
95 const uint32_t NaoJointPositionInterface::SERVO_r_ankle_roll = 33554432u;
96 /** SERVO_min constant */
97 const uint32_t NaoJointPositionInterface::SERVO_min = 1u;
98 /** SERVO_max constant */
99 const uint32_t NaoJointPositionInterface::SERVO_max = 33554432u;
100 
101 /** Constructor */
102 NaoJointPositionInterface::NaoJointPositionInterface() : Interface()
103 {
104  data_size = sizeof(NaoJointPositionInterface_data_t);
105  data_ptr = malloc(data_size);
106  data = (NaoJointPositionInterface_data_t *)data_ptr;
107  data_ts = (interface_data_ts_t *)data_ptr;
108  memset(data_ptr, 0, data_size);
109  enum_map_RobotType[(int)ROBOTYPE_ACADEMIC] = "ROBOTYPE_ACADEMIC";
110  enum_map_RobotType[(int)ROBOTYPE_ROBOCUP] = "ROBOTYPE_ROBOCUP";
111  add_fieldinfo(IFT_ENUM, "robot_type", 1, &data->robot_type, "RobotType", &enum_map_RobotType);
112  add_fieldinfo(IFT_UINT8, "robot_version", 4, &data->robot_version);
113  add_fieldinfo(IFT_FLOAT, "head_yaw", 1, &data->head_yaw);
114  add_fieldinfo(IFT_FLOAT, "head_pitch", 1, &data->head_pitch);
115  add_fieldinfo(IFT_FLOAT, "l_shoulder_pitch", 1, &data->l_shoulder_pitch);
116  add_fieldinfo(IFT_FLOAT, "l_shoulder_roll", 1, &data->l_shoulder_roll);
117  add_fieldinfo(IFT_FLOAT, "l_elbow_yaw", 1, &data->l_elbow_yaw);
118  add_fieldinfo(IFT_FLOAT, "l_elbow_roll", 1, &data->l_elbow_roll);
119  add_fieldinfo(IFT_FLOAT, "l_wrist_yaw", 1, &data->l_wrist_yaw);
120  add_fieldinfo(IFT_FLOAT, "l_hand", 1, &data->l_hand);
121  add_fieldinfo(IFT_FLOAT, "l_hip_yaw_pitch", 1, &data->l_hip_yaw_pitch);
122  add_fieldinfo(IFT_FLOAT, "l_hip_roll", 1, &data->l_hip_roll);
123  add_fieldinfo(IFT_FLOAT, "l_hip_pitch", 1, &data->l_hip_pitch);
124  add_fieldinfo(IFT_FLOAT, "l_knee_pitch", 1, &data->l_knee_pitch);
125  add_fieldinfo(IFT_FLOAT, "l_ankle_pitch", 1, &data->l_ankle_pitch);
126  add_fieldinfo(IFT_FLOAT, "l_ankle_roll", 1, &data->l_ankle_roll);
127  add_fieldinfo(IFT_FLOAT, "r_shoulder_pitch", 1, &data->r_shoulder_pitch);
128  add_fieldinfo(IFT_FLOAT, "r_shoulder_roll", 1, &data->r_shoulder_roll);
129  add_fieldinfo(IFT_FLOAT, "r_elbow_yaw", 1, &data->r_elbow_yaw);
130  add_fieldinfo(IFT_FLOAT, "r_elbow_roll", 1, &data->r_elbow_roll);
131  add_fieldinfo(IFT_FLOAT, "r_wrist_yaw", 1, &data->r_wrist_yaw);
132  add_fieldinfo(IFT_FLOAT, "r_hand", 1, &data->r_hand);
133  add_fieldinfo(IFT_FLOAT, "r_hip_yaw_pitch", 1, &data->r_hip_yaw_pitch);
134  add_fieldinfo(IFT_FLOAT, "r_hip_roll", 1, &data->r_hip_roll);
135  add_fieldinfo(IFT_FLOAT, "r_hip_pitch", 1, &data->r_hip_pitch);
136  add_fieldinfo(IFT_FLOAT, "r_knee_pitch", 1, &data->r_knee_pitch);
137  add_fieldinfo(IFT_FLOAT, "r_ankle_pitch", 1, &data->r_ankle_pitch);
138  add_fieldinfo(IFT_FLOAT, "r_ankle_roll", 1, &data->r_ankle_roll);
139  add_fieldinfo(IFT_INT32, "time", 1, &data->time);
140  add_messageinfo("SetServoMessage");
141  add_messageinfo("SetServosMessage");
142  add_messageinfo("MoveServoMessage");
143  add_messageinfo("MoveServosMessage");
144  unsigned char tmp_hash[] = {0x87, 0x3b, 0x41, 0x5d, 0x94, 0x57, 0x82, 0x55, 0x3, 0xbb, 0x3e, 0xf, 0x89, 0x50, 0x6b, 0x46};
145  set_hash(tmp_hash);
146 }
147 
148 /** Destructor */
149 NaoJointPositionInterface::~NaoJointPositionInterface()
150 {
151  free(data_ptr);
152 }
153 /** Convert RobotType constant to string.
154  * @param value value to convert to string
155  * @return constant value as string.
156  */
157 const char *
158 NaoJointPositionInterface::tostring_RobotType(RobotType value) const
159 {
160  switch (value) {
161  case ROBOTYPE_ACADEMIC: return "ROBOTYPE_ACADEMIC";
162  case ROBOTYPE_ROBOCUP: return "ROBOTYPE_ROBOCUP";
163  default: return "UNKNOWN";
164  }
165 }
166 /* Methods */
167 /** Get robot_type value.
168  * Robot type.
169  * @return robot_type value
170  */
172 NaoJointPositionInterface::robot_type() const
173 {
174  return (NaoJointPositionInterface::RobotType)data->robot_type;
175 }
176 
177 /** Get maximum length of robot_type value.
178  * @return length of robot_type value, can be length of the array or number of
179  * maximum number of characters for a string
180  */
181 size_t
182 NaoJointPositionInterface::maxlenof_robot_type() const
183 {
184  return 1;
185 }
186 
187 /** Set robot_type value.
188  * Robot type.
189  * @param new_robot_type new robot_type value
190  */
191 void
192 NaoJointPositionInterface::set_robot_type(const RobotType new_robot_type)
193 {
194  data->robot_type = new_robot_type;
195  data_changed = true;
196 }
197 
198 /** Get robot_version value.
199  *
200  Robot version. Fields are in ascending array index major, minor, micro and
201  patch level. Currently only the first two are used by Aldebaran, but due to
202  struct alignment we add two extra bytes.
203 
204  * @return robot_version value
205  */
206 uint8_t *
207 NaoJointPositionInterface::robot_version() const
208 {
209  return data->robot_version;
210 }
211 
212 /** Get robot_version value at given index.
213  *
214  Robot version. Fields are in ascending array index major, minor, micro and
215  patch level. Currently only the first two are used by Aldebaran, but due to
216  struct alignment we add two extra bytes.
217 
218  * @param index index of value
219  * @return robot_version value
220  * @exception Exception thrown if index is out of bounds
221  */
222 uint8_t
223 NaoJointPositionInterface::robot_version(unsigned int index) const
224 {
225  if (index > 4) {
226  throw Exception("Index value %u out of bounds (0..4)", index);
227  }
228  return data->robot_version[index];
229 }
230 
231 /** Get maximum length of robot_version value.
232  * @return length of robot_version value, can be length of the array or number of
233  * maximum number of characters for a string
234  */
235 size_t
236 NaoJointPositionInterface::maxlenof_robot_version() const
237 {
238  return 4;
239 }
240 
241 /** Set robot_version value.
242  *
243  Robot version. Fields are in ascending array index major, minor, micro and
244  patch level. Currently only the first two are used by Aldebaran, but due to
245  struct alignment we add two extra bytes.
246 
247  * @param new_robot_version new robot_version value
248  */
249 void
250 NaoJointPositionInterface::set_robot_version(const uint8_t * new_robot_version)
251 {
252  memcpy(data->robot_version, new_robot_version, sizeof(uint8_t) * 4);
253  data_changed = true;
254 }
255 
256 /** Set robot_version value at given index.
257  *
258  Robot version. Fields are in ascending array index major, minor, micro and
259  patch level. Currently only the first two are used by Aldebaran, but due to
260  struct alignment we add two extra bytes.
261 
262  * @param new_robot_version new robot_version value
263  * @param index index for of the value
264  */
265 void
266 NaoJointPositionInterface::set_robot_version(unsigned int index, const uint8_t new_robot_version)
267 {
268  if (index > 4) {
269  throw Exception("Index value %u out of bounds (0..4)", index);
270  }
271  data->robot_version[index] = new_robot_version;
272  data_changed = true;
273 }
274 /** Get head_yaw value.
275  * Head yaw
276  * @return head_yaw value
277  */
278 float
279 NaoJointPositionInterface::head_yaw() const
280 {
281  return data->head_yaw;
282 }
283 
284 /** Get maximum length of head_yaw value.
285  * @return length of head_yaw value, can be length of the array or number of
286  * maximum number of characters for a string
287  */
288 size_t
289 NaoJointPositionInterface::maxlenof_head_yaw() const
290 {
291  return 1;
292 }
293 
294 /** Set head_yaw value.
295  * Head yaw
296  * @param new_head_yaw new head_yaw value
297  */
298 void
299 NaoJointPositionInterface::set_head_yaw(const float new_head_yaw)
300 {
301  data->head_yaw = new_head_yaw;
302  data_changed = true;
303 }
304 
305 /** Get head_pitch value.
306  * Head pitch
307  * @return head_pitch value
308  */
309 float
310 NaoJointPositionInterface::head_pitch() const
311 {
312  return data->head_pitch;
313 }
314 
315 /** Get maximum length of head_pitch value.
316  * @return length of head_pitch value, can be length of the array or number of
317  * maximum number of characters for a string
318  */
319 size_t
320 NaoJointPositionInterface::maxlenof_head_pitch() const
321 {
322  return 1;
323 }
324 
325 /** Set head_pitch value.
326  * Head pitch
327  * @param new_head_pitch new head_pitch value
328  */
329 void
330 NaoJointPositionInterface::set_head_pitch(const float new_head_pitch)
331 {
332  data->head_pitch = new_head_pitch;
333  data_changed = true;
334 }
335 
336 /** Get l_shoulder_pitch value.
337  * Left shoulder pitch
338  * @return l_shoulder_pitch value
339  */
340 float
341 NaoJointPositionInterface::l_shoulder_pitch() const
342 {
343  return data->l_shoulder_pitch;
344 }
345 
346 /** Get maximum length of l_shoulder_pitch value.
347  * @return length of l_shoulder_pitch value, can be length of the array or number of
348  * maximum number of characters for a string
349  */
350 size_t
351 NaoJointPositionInterface::maxlenof_l_shoulder_pitch() const
352 {
353  return 1;
354 }
355 
356 /** Set l_shoulder_pitch value.
357  * Left shoulder pitch
358  * @param new_l_shoulder_pitch new l_shoulder_pitch value
359  */
360 void
361 NaoJointPositionInterface::set_l_shoulder_pitch(const float new_l_shoulder_pitch)
362 {
363  data->l_shoulder_pitch = new_l_shoulder_pitch;
364  data_changed = true;
365 }
366 
367 /** Get l_shoulder_roll value.
368  * Left shoulder roll
369  * @return l_shoulder_roll value
370  */
371 float
372 NaoJointPositionInterface::l_shoulder_roll() const
373 {
374  return data->l_shoulder_roll;
375 }
376 
377 /** Get maximum length of l_shoulder_roll value.
378  * @return length of l_shoulder_roll value, can be length of the array or number of
379  * maximum number of characters for a string
380  */
381 size_t
382 NaoJointPositionInterface::maxlenof_l_shoulder_roll() const
383 {
384  return 1;
385 }
386 
387 /** Set l_shoulder_roll value.
388  * Left shoulder roll
389  * @param new_l_shoulder_roll new l_shoulder_roll value
390  */
391 void
392 NaoJointPositionInterface::set_l_shoulder_roll(const float new_l_shoulder_roll)
393 {
394  data->l_shoulder_roll = new_l_shoulder_roll;
395  data_changed = true;
396 }
397 
398 /** Get l_elbow_yaw value.
399  * Left elbow yaw
400  * @return l_elbow_yaw value
401  */
402 float
403 NaoJointPositionInterface::l_elbow_yaw() const
404 {
405  return data->l_elbow_yaw;
406 }
407 
408 /** Get maximum length of l_elbow_yaw value.
409  * @return length of l_elbow_yaw value, can be length of the array or number of
410  * maximum number of characters for a string
411  */
412 size_t
413 NaoJointPositionInterface::maxlenof_l_elbow_yaw() const
414 {
415  return 1;
416 }
417 
418 /** Set l_elbow_yaw value.
419  * Left elbow yaw
420  * @param new_l_elbow_yaw new l_elbow_yaw value
421  */
422 void
423 NaoJointPositionInterface::set_l_elbow_yaw(const float new_l_elbow_yaw)
424 {
425  data->l_elbow_yaw = new_l_elbow_yaw;
426  data_changed = true;
427 }
428 
429 /** Get l_elbow_roll value.
430  * Left elbow roll
431  * @return l_elbow_roll value
432  */
433 float
434 NaoJointPositionInterface::l_elbow_roll() const
435 {
436  return data->l_elbow_roll;
437 }
438 
439 /** Get maximum length of l_elbow_roll value.
440  * @return length of l_elbow_roll value, can be length of the array or number of
441  * maximum number of characters for a string
442  */
443 size_t
444 NaoJointPositionInterface::maxlenof_l_elbow_roll() const
445 {
446  return 1;
447 }
448 
449 /** Set l_elbow_roll value.
450  * Left elbow roll
451  * @param new_l_elbow_roll new l_elbow_roll value
452  */
453 void
454 NaoJointPositionInterface::set_l_elbow_roll(const float new_l_elbow_roll)
455 {
456  data->l_elbow_roll = new_l_elbow_roll;
457  data_changed = true;
458 }
459 
460 /** Get l_wrist_yaw value.
461  * Left wrist yaw
462  * @return l_wrist_yaw value
463  */
464 float
465 NaoJointPositionInterface::l_wrist_yaw() const
466 {
467  return data->l_wrist_yaw;
468 }
469 
470 /** Get maximum length of l_wrist_yaw value.
471  * @return length of l_wrist_yaw value, can be length of the array or number of
472  * maximum number of characters for a string
473  */
474 size_t
475 NaoJointPositionInterface::maxlenof_l_wrist_yaw() const
476 {
477  return 1;
478 }
479 
480 /** Set l_wrist_yaw value.
481  * Left wrist yaw
482  * @param new_l_wrist_yaw new l_wrist_yaw value
483  */
484 void
485 NaoJointPositionInterface::set_l_wrist_yaw(const float new_l_wrist_yaw)
486 {
487  data->l_wrist_yaw = new_l_wrist_yaw;
488  data_changed = true;
489 }
490 
491 /** Get l_hand value.
492  * Left hand
493  * @return l_hand value
494  */
495 float
496 NaoJointPositionInterface::l_hand() const
497 {
498  return data->l_hand;
499 }
500 
501 /** Get maximum length of l_hand value.
502  * @return length of l_hand value, can be length of the array or number of
503  * maximum number of characters for a string
504  */
505 size_t
506 NaoJointPositionInterface::maxlenof_l_hand() const
507 {
508  return 1;
509 }
510 
511 /** Set l_hand value.
512  * Left hand
513  * @param new_l_hand new l_hand value
514  */
515 void
516 NaoJointPositionInterface::set_l_hand(const float new_l_hand)
517 {
518  data->l_hand = new_l_hand;
519  data_changed = true;
520 }
521 
522 /** Get l_hip_yaw_pitch value.
523  * Left hip yaw pitch
524  * @return l_hip_yaw_pitch value
525  */
526 float
527 NaoJointPositionInterface::l_hip_yaw_pitch() const
528 {
529  return data->l_hip_yaw_pitch;
530 }
531 
532 /** Get maximum length of l_hip_yaw_pitch value.
533  * @return length of l_hip_yaw_pitch value, can be length of the array or number of
534  * maximum number of characters for a string
535  */
536 size_t
537 NaoJointPositionInterface::maxlenof_l_hip_yaw_pitch() const
538 {
539  return 1;
540 }
541 
542 /** Set l_hip_yaw_pitch value.
543  * Left hip yaw pitch
544  * @param new_l_hip_yaw_pitch new l_hip_yaw_pitch value
545  */
546 void
547 NaoJointPositionInterface::set_l_hip_yaw_pitch(const float new_l_hip_yaw_pitch)
548 {
549  data->l_hip_yaw_pitch = new_l_hip_yaw_pitch;
550  data_changed = true;
551 }
552 
553 /** Get l_hip_roll value.
554  * Left hip roll
555  * @return l_hip_roll value
556  */
557 float
558 NaoJointPositionInterface::l_hip_roll() const
559 {
560  return data->l_hip_roll;
561 }
562 
563 /** Get maximum length of l_hip_roll value.
564  * @return length of l_hip_roll value, can be length of the array or number of
565  * maximum number of characters for a string
566  */
567 size_t
568 NaoJointPositionInterface::maxlenof_l_hip_roll() const
569 {
570  return 1;
571 }
572 
573 /** Set l_hip_roll value.
574  * Left hip roll
575  * @param new_l_hip_roll new l_hip_roll value
576  */
577 void
578 NaoJointPositionInterface::set_l_hip_roll(const float new_l_hip_roll)
579 {
580  data->l_hip_roll = new_l_hip_roll;
581  data_changed = true;
582 }
583 
584 /** Get l_hip_pitch value.
585  * Left hip pitch
586  * @return l_hip_pitch value
587  */
588 float
589 NaoJointPositionInterface::l_hip_pitch() const
590 {
591  return data->l_hip_pitch;
592 }
593 
594 /** Get maximum length of l_hip_pitch value.
595  * @return length of l_hip_pitch value, can be length of the array or number of
596  * maximum number of characters for a string
597  */
598 size_t
599 NaoJointPositionInterface::maxlenof_l_hip_pitch() const
600 {
601  return 1;
602 }
603 
604 /** Set l_hip_pitch value.
605  * Left hip pitch
606  * @param new_l_hip_pitch new l_hip_pitch value
607  */
608 void
609 NaoJointPositionInterface::set_l_hip_pitch(const float new_l_hip_pitch)
610 {
611  data->l_hip_pitch = new_l_hip_pitch;
612  data_changed = true;
613 }
614 
615 /** Get l_knee_pitch value.
616  * Left knee pitch
617  * @return l_knee_pitch value
618  */
619 float
620 NaoJointPositionInterface::l_knee_pitch() const
621 {
622  return data->l_knee_pitch;
623 }
624 
625 /** Get maximum length of l_knee_pitch value.
626  * @return length of l_knee_pitch value, can be length of the array or number of
627  * maximum number of characters for a string
628  */
629 size_t
630 NaoJointPositionInterface::maxlenof_l_knee_pitch() const
631 {
632  return 1;
633 }
634 
635 /** Set l_knee_pitch value.
636  * Left knee pitch
637  * @param new_l_knee_pitch new l_knee_pitch value
638  */
639 void
640 NaoJointPositionInterface::set_l_knee_pitch(const float new_l_knee_pitch)
641 {
642  data->l_knee_pitch = new_l_knee_pitch;
643  data_changed = true;
644 }
645 
646 /** Get l_ankle_pitch value.
647  * Left ankle pitch
648  * @return l_ankle_pitch value
649  */
650 float
651 NaoJointPositionInterface::l_ankle_pitch() const
652 {
653  return data->l_ankle_pitch;
654 }
655 
656 /** Get maximum length of l_ankle_pitch value.
657  * @return length of l_ankle_pitch value, can be length of the array or number of
658  * maximum number of characters for a string
659  */
660 size_t
661 NaoJointPositionInterface::maxlenof_l_ankle_pitch() const
662 {
663  return 1;
664 }
665 
666 /** Set l_ankle_pitch value.
667  * Left ankle pitch
668  * @param new_l_ankle_pitch new l_ankle_pitch value
669  */
670 void
671 NaoJointPositionInterface::set_l_ankle_pitch(const float new_l_ankle_pitch)
672 {
673  data->l_ankle_pitch = new_l_ankle_pitch;
674  data_changed = true;
675 }
676 
677 /** Get l_ankle_roll value.
678  * Left ankle roll
679  * @return l_ankle_roll value
680  */
681 float
682 NaoJointPositionInterface::l_ankle_roll() const
683 {
684  return data->l_ankle_roll;
685 }
686 
687 /** Get maximum length of l_ankle_roll value.
688  * @return length of l_ankle_roll value, can be length of the array or number of
689  * maximum number of characters for a string
690  */
691 size_t
692 NaoJointPositionInterface::maxlenof_l_ankle_roll() const
693 {
694  return 1;
695 }
696 
697 /** Set l_ankle_roll value.
698  * Left ankle roll
699  * @param new_l_ankle_roll new l_ankle_roll value
700  */
701 void
702 NaoJointPositionInterface::set_l_ankle_roll(const float new_l_ankle_roll)
703 {
704  data->l_ankle_roll = new_l_ankle_roll;
705  data_changed = true;
706 }
707 
708 /** Get r_shoulder_pitch value.
709  * Right shoulder pitch
710  * @return r_shoulder_pitch value
711  */
712 float
713 NaoJointPositionInterface::r_shoulder_pitch() const
714 {
715  return data->r_shoulder_pitch;
716 }
717 
718 /** Get maximum length of r_shoulder_pitch value.
719  * @return length of r_shoulder_pitch value, can be length of the array or number of
720  * maximum number of characters for a string
721  */
722 size_t
723 NaoJointPositionInterface::maxlenof_r_shoulder_pitch() const
724 {
725  return 1;
726 }
727 
728 /** Set r_shoulder_pitch value.
729  * Right shoulder pitch
730  * @param new_r_shoulder_pitch new r_shoulder_pitch value
731  */
732 void
733 NaoJointPositionInterface::set_r_shoulder_pitch(const float new_r_shoulder_pitch)
734 {
735  data->r_shoulder_pitch = new_r_shoulder_pitch;
736  data_changed = true;
737 }
738 
739 /** Get r_shoulder_roll value.
740  * Right shoulder roll
741  * @return r_shoulder_roll value
742  */
743 float
744 NaoJointPositionInterface::r_shoulder_roll() const
745 {
746  return data->r_shoulder_roll;
747 }
748 
749 /** Get maximum length of r_shoulder_roll value.
750  * @return length of r_shoulder_roll value, can be length of the array or number of
751  * maximum number of characters for a string
752  */
753 size_t
754 NaoJointPositionInterface::maxlenof_r_shoulder_roll() const
755 {
756  return 1;
757 }
758 
759 /** Set r_shoulder_roll value.
760  * Right shoulder roll
761  * @param new_r_shoulder_roll new r_shoulder_roll value
762  */
763 void
764 NaoJointPositionInterface::set_r_shoulder_roll(const float new_r_shoulder_roll)
765 {
766  data->r_shoulder_roll = new_r_shoulder_roll;
767  data_changed = true;
768 }
769 
770 /** Get r_elbow_yaw value.
771  * Right elbow yaw
772  * @return r_elbow_yaw value
773  */
774 float
775 NaoJointPositionInterface::r_elbow_yaw() const
776 {
777  return data->r_elbow_yaw;
778 }
779 
780 /** Get maximum length of r_elbow_yaw value.
781  * @return length of r_elbow_yaw value, can be length of the array or number of
782  * maximum number of characters for a string
783  */
784 size_t
785 NaoJointPositionInterface::maxlenof_r_elbow_yaw() const
786 {
787  return 1;
788 }
789 
790 /** Set r_elbow_yaw value.
791  * Right elbow yaw
792  * @param new_r_elbow_yaw new r_elbow_yaw value
793  */
794 void
795 NaoJointPositionInterface::set_r_elbow_yaw(const float new_r_elbow_yaw)
796 {
797  data->r_elbow_yaw = new_r_elbow_yaw;
798  data_changed = true;
799 }
800 
801 /** Get r_elbow_roll value.
802  * Right elbow roll
803  * @return r_elbow_roll value
804  */
805 float
806 NaoJointPositionInterface::r_elbow_roll() const
807 {
808  return data->r_elbow_roll;
809 }
810 
811 /** Get maximum length of r_elbow_roll value.
812  * @return length of r_elbow_roll value, can be length of the array or number of
813  * maximum number of characters for a string
814  */
815 size_t
816 NaoJointPositionInterface::maxlenof_r_elbow_roll() const
817 {
818  return 1;
819 }
820 
821 /** Set r_elbow_roll value.
822  * Right elbow roll
823  * @param new_r_elbow_roll new r_elbow_roll value
824  */
825 void
826 NaoJointPositionInterface::set_r_elbow_roll(const float new_r_elbow_roll)
827 {
828  data->r_elbow_roll = new_r_elbow_roll;
829  data_changed = true;
830 }
831 
832 /** Get r_wrist_yaw value.
833  * Right wrist yaw
834  * @return r_wrist_yaw value
835  */
836 float
837 NaoJointPositionInterface::r_wrist_yaw() const
838 {
839  return data->r_wrist_yaw;
840 }
841 
842 /** Get maximum length of r_wrist_yaw value.
843  * @return length of r_wrist_yaw value, can be length of the array or number of
844  * maximum number of characters for a string
845  */
846 size_t
847 NaoJointPositionInterface::maxlenof_r_wrist_yaw() const
848 {
849  return 1;
850 }
851 
852 /** Set r_wrist_yaw value.
853  * Right wrist yaw
854  * @param new_r_wrist_yaw new r_wrist_yaw value
855  */
856 void
857 NaoJointPositionInterface::set_r_wrist_yaw(const float new_r_wrist_yaw)
858 {
859  data->r_wrist_yaw = new_r_wrist_yaw;
860  data_changed = true;
861 }
862 
863 /** Get r_hand value.
864  * Right hand
865  * @return r_hand value
866  */
867 float
868 NaoJointPositionInterface::r_hand() const
869 {
870  return data->r_hand;
871 }
872 
873 /** Get maximum length of r_hand value.
874  * @return length of r_hand value, can be length of the array or number of
875  * maximum number of characters for a string
876  */
877 size_t
878 NaoJointPositionInterface::maxlenof_r_hand() const
879 {
880  return 1;
881 }
882 
883 /** Set r_hand value.
884  * Right hand
885  * @param new_r_hand new r_hand value
886  */
887 void
888 NaoJointPositionInterface::set_r_hand(const float new_r_hand)
889 {
890  data->r_hand = new_r_hand;
891  data_changed = true;
892 }
893 
894 /** Get r_hip_yaw_pitch value.
895  * Right hip yaw pitch
896  * @return r_hip_yaw_pitch value
897  */
898 float
899 NaoJointPositionInterface::r_hip_yaw_pitch() const
900 {
901  return data->r_hip_yaw_pitch;
902 }
903 
904 /** Get maximum length of r_hip_yaw_pitch value.
905  * @return length of r_hip_yaw_pitch value, can be length of the array or number of
906  * maximum number of characters for a string
907  */
908 size_t
909 NaoJointPositionInterface::maxlenof_r_hip_yaw_pitch() const
910 {
911  return 1;
912 }
913 
914 /** Set r_hip_yaw_pitch value.
915  * Right hip yaw pitch
916  * @param new_r_hip_yaw_pitch new r_hip_yaw_pitch value
917  */
918 void
919 NaoJointPositionInterface::set_r_hip_yaw_pitch(const float new_r_hip_yaw_pitch)
920 {
921  data->r_hip_yaw_pitch = new_r_hip_yaw_pitch;
922  data_changed = true;
923 }
924 
925 /** Get r_hip_roll value.
926  * Right hip roll
927  * @return r_hip_roll value
928  */
929 float
930 NaoJointPositionInterface::r_hip_roll() const
931 {
932  return data->r_hip_roll;
933 }
934 
935 /** Get maximum length of r_hip_roll value.
936  * @return length of r_hip_roll value, can be length of the array or number of
937  * maximum number of characters for a string
938  */
939 size_t
940 NaoJointPositionInterface::maxlenof_r_hip_roll() const
941 {
942  return 1;
943 }
944 
945 /** Set r_hip_roll value.
946  * Right hip roll
947  * @param new_r_hip_roll new r_hip_roll value
948  */
949 void
950 NaoJointPositionInterface::set_r_hip_roll(const float new_r_hip_roll)
951 {
952  data->r_hip_roll = new_r_hip_roll;
953  data_changed = true;
954 }
955 
956 /** Get r_hip_pitch value.
957  * Right hip pitch
958  * @return r_hip_pitch value
959  */
960 float
961 NaoJointPositionInterface::r_hip_pitch() const
962 {
963  return data->r_hip_pitch;
964 }
965 
966 /** Get maximum length of r_hip_pitch value.
967  * @return length of r_hip_pitch value, can be length of the array or number of
968  * maximum number of characters for a string
969  */
970 size_t
971 NaoJointPositionInterface::maxlenof_r_hip_pitch() const
972 {
973  return 1;
974 }
975 
976 /** Set r_hip_pitch value.
977  * Right hip pitch
978  * @param new_r_hip_pitch new r_hip_pitch value
979  */
980 void
981 NaoJointPositionInterface::set_r_hip_pitch(const float new_r_hip_pitch)
982 {
983  data->r_hip_pitch = new_r_hip_pitch;
984  data_changed = true;
985 }
986 
987 /** Get r_knee_pitch value.
988  * Right knee pitch
989  * @return r_knee_pitch value
990  */
991 float
992 NaoJointPositionInterface::r_knee_pitch() const
993 {
994  return data->r_knee_pitch;
995 }
996 
997 /** Get maximum length of r_knee_pitch value.
998  * @return length of r_knee_pitch value, can be length of the array or number of
999  * maximum number of characters for a string
1000  */
1001 size_t
1002 NaoJointPositionInterface::maxlenof_r_knee_pitch() const
1003 {
1004  return 1;
1005 }
1006 
1007 /** Set r_knee_pitch value.
1008  * Right knee pitch
1009  * @param new_r_knee_pitch new r_knee_pitch value
1010  */
1011 void
1012 NaoJointPositionInterface::set_r_knee_pitch(const float new_r_knee_pitch)
1013 {
1014  data->r_knee_pitch = new_r_knee_pitch;
1015  data_changed = true;
1016 }
1017 
1018 /** Get r_ankle_pitch value.
1019  * Right ankle pitch
1020  * @return r_ankle_pitch value
1021  */
1022 float
1023 NaoJointPositionInterface::r_ankle_pitch() const
1024 {
1025  return data->r_ankle_pitch;
1026 }
1027 
1028 /** Get maximum length of r_ankle_pitch value.
1029  * @return length of r_ankle_pitch value, can be length of the array or number of
1030  * maximum number of characters for a string
1031  */
1032 size_t
1033 NaoJointPositionInterface::maxlenof_r_ankle_pitch() const
1034 {
1035  return 1;
1036 }
1037 
1038 /** Set r_ankle_pitch value.
1039  * Right ankle pitch
1040  * @param new_r_ankle_pitch new r_ankle_pitch value
1041  */
1042 void
1043 NaoJointPositionInterface::set_r_ankle_pitch(const float new_r_ankle_pitch)
1044 {
1045  data->r_ankle_pitch = new_r_ankle_pitch;
1046  data_changed = true;
1047 }
1048 
1049 /** Get r_ankle_roll value.
1050  * Right ankle roll
1051  * @return r_ankle_roll value
1052  */
1053 float
1054 NaoJointPositionInterface::r_ankle_roll() const
1055 {
1056  return data->r_ankle_roll;
1057 }
1058 
1059 /** Get maximum length of r_ankle_roll value.
1060  * @return length of r_ankle_roll value, can be length of the array or number of
1061  * maximum number of characters for a string
1062  */
1063 size_t
1064 NaoJointPositionInterface::maxlenof_r_ankle_roll() const
1065 {
1066  return 1;
1067 }
1068 
1069 /** Set r_ankle_roll value.
1070  * Right ankle roll
1071  * @param new_r_ankle_roll new r_ankle_roll value
1072  */
1073 void
1074 NaoJointPositionInterface::set_r_ankle_roll(const float new_r_ankle_roll)
1075 {
1076  data->r_ankle_roll = new_r_ankle_roll;
1077  data_changed = true;
1078 }
1079 
1080 /** Get time value.
1081  *
1082  Current reference time in ms. For real hardware this is the DCM time.
1083  Times in messages are always offsets to the current time and the current
1084  time is added before executing the command.
1085 
1086  * @return time value
1087  */
1088 int32_t
1089 NaoJointPositionInterface::time() const
1090 {
1091  return data->time;
1092 }
1093 
1094 /** Get maximum length of time value.
1095  * @return length of time value, can be length of the array or number of
1096  * maximum number of characters for a string
1097  */
1098 size_t
1099 NaoJointPositionInterface::maxlenof_time() const
1100 {
1101  return 1;
1102 }
1103 
1104 /** Set time value.
1105  *
1106  Current reference time in ms. For real hardware this is the DCM time.
1107  Times in messages are always offsets to the current time and the current
1108  time is added before executing the command.
1109 
1110  * @param new_time new time value
1111  */
1112 void
1113 NaoJointPositionInterface::set_time(const int32_t new_time)
1114 {
1115  data->time = new_time;
1116  data_changed = true;
1117 }
1118 
1119 /* =========== message create =========== */
1120 Message *
1121 NaoJointPositionInterface::create_message(const char *type) const
1122 {
1123  if ( strncmp("SetServoMessage", type, __INTERFACE_MESSAGE_TYPE_SIZE) == 0 ) {
1124  return new SetServoMessage();
1125  } else if ( strncmp("SetServosMessage", type, __INTERFACE_MESSAGE_TYPE_SIZE) == 0 ) {
1126  return new SetServosMessage();
1127  } else if ( strncmp("MoveServoMessage", type, __INTERFACE_MESSAGE_TYPE_SIZE) == 0 ) {
1128  return new MoveServoMessage();
1129  } else if ( strncmp("MoveServosMessage", type, __INTERFACE_MESSAGE_TYPE_SIZE) == 0 ) {
1130  return new MoveServosMessage();
1131  } else {
1132  throw UnknownTypeException("The given type '%s' does not match any known "
1133  "message type for this interface type.", type);
1134  }
1135 }
1136 
1137 
1138 /** Copy values from other interface.
1139  * @param other other interface to copy values from
1140  */
1141 void
1142 NaoJointPositionInterface::copy_values(const Interface *other)
1143 {
1144  const NaoJointPositionInterface *oi = dynamic_cast<const NaoJointPositionInterface *>(other);
1145  if (oi == NULL) {
1146  throw TypeMismatchException("Can only copy values from interface of same type (%s vs. %s)",
1147  type(), other->type());
1148  }
1149  memcpy(data, oi->data, sizeof(NaoJointPositionInterface_data_t));
1150 }
1151 
1152 const char *
1153 NaoJointPositionInterface::enum_tostring(const char *enumtype, int val) const
1154 {
1155  if (strcmp(enumtype, "RobotType") == 0) {
1156  return tostring_RobotType((RobotType)val);
1157  }
1158  throw UnknownTypeException("Unknown enum type %s", enumtype);
1159 }
1160 
1161 /* =========== messages =========== */
1162 /** @class NaoJointPositionInterface::SetServoMessage <interfaces/NaoJointPositionInterface.h>
1163  * SetServoMessage Fawkes BlackBoard Interface Message.
1164  *
1165 
1166  */
1167 
1168 
1169 /** Constructor with initial values.
1170  * @param ini_servo initial value for servo
1171  * @param ini_value initial value for value
1172  * @param ini_time initial value for time
1173  */
1174 NaoJointPositionInterface::SetServoMessage::SetServoMessage(const uint32_t ini_servo, const float ini_value, const int32_t ini_time) : Message("SetServoMessage")
1175 {
1176  data_size = sizeof(SetServoMessage_data_t);
1177  data_ptr = malloc(data_size);
1178  memset(data_ptr, 0, data_size);
1179  data = (SetServoMessage_data_t *)data_ptr;
1181  data->servo = ini_servo;
1182  data->value = ini_value;
1183  data->time = ini_time;
1184  enum_map_RobotType[(int)ROBOTYPE_ACADEMIC] = "ROBOTYPE_ACADEMIC";
1185  enum_map_RobotType[(int)ROBOTYPE_ROBOCUP] = "ROBOTYPE_ROBOCUP";
1186  add_fieldinfo(IFT_UINT32, "servo", 1, &data->servo);
1187  add_fieldinfo(IFT_FLOAT, "value", 1, &data->value);
1188  add_fieldinfo(IFT_INT32, "time", 1, &data->time);
1189 }
1190 /** Constructor */
1192 {
1193  data_size = sizeof(SetServoMessage_data_t);
1194  data_ptr = malloc(data_size);
1195  memset(data_ptr, 0, data_size);
1196  data = (SetServoMessage_data_t *)data_ptr;
1198  enum_map_RobotType[(int)ROBOTYPE_ACADEMIC] = "ROBOTYPE_ACADEMIC";
1199  enum_map_RobotType[(int)ROBOTYPE_ROBOCUP] = "ROBOTYPE_ROBOCUP";
1200  add_fieldinfo(IFT_UINT32, "servo", 1, &data->servo);
1201  add_fieldinfo(IFT_FLOAT, "value", 1, &data->value);
1202  add_fieldinfo(IFT_INT32, "time", 1, &data->time);
1203 }
1204 
1205 /** Destructor */
1207 {
1208  free(data_ptr);
1209 }
1210 
1211 /** Copy constructor.
1212  * @param m message to copy from
1213  */
1215 {
1216  data_size = m->data_size;
1217  data_ptr = malloc(data_size);
1218  memcpy(data_ptr, m->data_ptr, data_size);
1219  data = (SetServoMessage_data_t *)data_ptr;
1221 }
1222 
1223 /* Methods */
1224 /** Get servo value.
1225  * A concatenated list of SERVO_* constants to
1226  define the servos that should execute the movement. The list shall consist of
1227  binary or'ed SERVO_* constants.
1228  * @return servo value
1229  */
1230 uint32_t
1232 {
1233  return data->servo;
1234 }
1235 
1236 /** Get maximum length of servo value.
1237  * @return length of servo value, can be length of the array or number of
1238  * maximum number of characters for a string
1239  */
1240 size_t
1242 {
1243  return 1;
1244 }
1245 
1246 /** Set servo value.
1247  * A concatenated list of SERVO_* constants to
1248  define the servos that should execute the movement. The list shall consist of
1249  binary or'ed SERVO_* constants.
1250  * @param new_servo new servo value
1251  */
1252 void
1254 {
1255  data->servo = new_servo;
1256 }
1257 
1258 /** Get value value.
1259  * Servo value to set for servos.
1260  * @return value value
1261  */
1262 float
1264 {
1265  return data->value;
1266 }
1267 
1268 /** Get maximum length of value value.
1269  * @return length of value value, can be length of the array or number of
1270  * maximum number of characters for a string
1271  */
1272 size_t
1274 {
1275  return 1;
1276 }
1277 
1278 /** Set value value.
1279  * Servo value to set for servos.
1280  * @param new_value new value value
1281  */
1282 void
1284 {
1285  data->value = new_value;
1286 }
1287 
1288 /** Get time value.
1289  *
1290  Current reference time in ms. For real hardware this is the DCM time.
1291  Times in messages are always offsets to the current time and the current
1292  time is added before executing the command.
1293 
1294  * @return time value
1295  */
1296 int32_t
1298 {
1299  return data->time;
1300 }
1301 
1302 /** Get maximum length of time value.
1303  * @return length of time value, can be length of the array or number of
1304  * maximum number of characters for a string
1305  */
1306 size_t
1308 {
1309  return 1;
1310 }
1311 
1312 /** Set time value.
1313  *
1314  Current reference time in ms. For real hardware this is the DCM time.
1315  Times in messages are always offsets to the current time and the current
1316  time is added before executing the command.
1317 
1318  * @param new_time new time value
1319  */
1320 void
1322 {
1323  data->time = new_time;
1324 }
1325 
1326 /** Clone this message.
1327  * Produces a message of the same type as this message and copies the
1328  * data to the new message.
1329  * @return clone of this message
1330  */
1331 Message *
1333 {
1335 }
1336 /** @class NaoJointPositionInterface::SetServosMessage <interfaces/NaoJointPositionInterface.h>
1337  * SetServosMessage Fawkes BlackBoard Interface Message.
1338  *
1339 
1340  */
1341 
1342 
1343 /** Constructor with initial values.
1344  * @param ini_head_yaw initial value for head_yaw
1345  * @param ini_head_pitch initial value for head_pitch
1346  * @param ini_l_shoulder_pitch initial value for l_shoulder_pitch
1347  * @param ini_l_shoulder_roll initial value for l_shoulder_roll
1348  * @param ini_l_elbow_yaw initial value for l_elbow_yaw
1349  * @param ini_l_elbow_roll initial value for l_elbow_roll
1350  * @param ini_l_hip_yaw_pitch initial value for l_hip_yaw_pitch
1351  * @param ini_l_hip_roll initial value for l_hip_roll
1352  * @param ini_l_hip_pitch initial value for l_hip_pitch
1353  * @param ini_l_knee_pitch initial value for l_knee_pitch
1354  * @param ini_l_ankle_pitch initial value for l_ankle_pitch
1355  * @param ini_l_ankle_roll initial value for l_ankle_roll
1356  * @param ini_l_wrist_yaw initial value for l_wrist_yaw
1357  * @param ini_l_hand initial value for l_hand
1358  * @param ini_r_shoulder_pitch initial value for r_shoulder_pitch
1359  * @param ini_r_shoulder_roll initial value for r_shoulder_roll
1360  * @param ini_r_elbow_yaw initial value for r_elbow_yaw
1361  * @param ini_r_elbow_roll initial value for r_elbow_roll
1362  * @param ini_r_wrist_yaw initial value for r_wrist_yaw
1363  * @param ini_r_hand initial value for r_hand
1364  * @param ini_r_hip_yaw_pitch initial value for r_hip_yaw_pitch
1365  * @param ini_r_hip_roll initial value for r_hip_roll
1366  * @param ini_r_hip_pitch initial value for r_hip_pitch
1367  * @param ini_r_knee_pitch initial value for r_knee_pitch
1368  * @param ini_r_ankle_pitch initial value for r_ankle_pitch
1369  * @param ini_r_ankle_roll initial value for r_ankle_roll
1370  * @param ini_time initial value for time
1371  */
1372 NaoJointPositionInterface::SetServosMessage::SetServosMessage(const float ini_head_yaw, const float ini_head_pitch, const float ini_l_shoulder_pitch, const float ini_l_shoulder_roll, const float ini_l_elbow_yaw, const float ini_l_elbow_roll, const float ini_l_hip_yaw_pitch, const float ini_l_hip_roll, const float ini_l_hip_pitch, const float ini_l_knee_pitch, const float ini_l_ankle_pitch, const float ini_l_ankle_roll, const float ini_l_wrist_yaw, const float ini_l_hand, const float ini_r_shoulder_pitch, const float ini_r_shoulder_roll, const float ini_r_elbow_yaw, const float ini_r_elbow_roll, const float ini_r_wrist_yaw, const float ini_r_hand, const float ini_r_hip_yaw_pitch, const float ini_r_hip_roll, const float ini_r_hip_pitch, const float ini_r_knee_pitch, const float ini_r_ankle_pitch, const float ini_r_ankle_roll, const int32_t ini_time) : Message("SetServosMessage")
1373 {
1374  data_size = sizeof(SetServosMessage_data_t);
1375  data_ptr = malloc(data_size);
1376  memset(data_ptr, 0, data_size);
1377  data = (SetServosMessage_data_t *)data_ptr;
1379  data->head_yaw = ini_head_yaw;
1380  data->head_pitch = ini_head_pitch;
1381  data->l_shoulder_pitch = ini_l_shoulder_pitch;
1382  data->l_shoulder_roll = ini_l_shoulder_roll;
1383  data->l_elbow_yaw = ini_l_elbow_yaw;
1384  data->l_elbow_roll = ini_l_elbow_roll;
1385  data->l_hip_yaw_pitch = ini_l_hip_yaw_pitch;
1386  data->l_hip_roll = ini_l_hip_roll;
1387  data->l_hip_pitch = ini_l_hip_pitch;
1388  data->l_knee_pitch = ini_l_knee_pitch;
1389  data->l_ankle_pitch = ini_l_ankle_pitch;
1390  data->l_ankle_roll = ini_l_ankle_roll;
1391  data->l_wrist_yaw = ini_l_wrist_yaw;
1392  data->l_hand = ini_l_hand;
1393  data->r_shoulder_pitch = ini_r_shoulder_pitch;
1394  data->r_shoulder_roll = ini_r_shoulder_roll;
1395  data->r_elbow_yaw = ini_r_elbow_yaw;
1396  data->r_elbow_roll = ini_r_elbow_roll;
1397  data->r_wrist_yaw = ini_r_wrist_yaw;
1398  data->r_hand = ini_r_hand;
1399  data->r_hip_yaw_pitch = ini_r_hip_yaw_pitch;
1400  data->r_hip_roll = ini_r_hip_roll;
1401  data->r_hip_pitch = ini_r_hip_pitch;
1402  data->r_knee_pitch = ini_r_knee_pitch;
1403  data->r_ankle_pitch = ini_r_ankle_pitch;
1404  data->r_ankle_roll = ini_r_ankle_roll;
1405  data->time = ini_time;
1406  enum_map_RobotType[(int)ROBOTYPE_ACADEMIC] = "ROBOTYPE_ACADEMIC";
1407  enum_map_RobotType[(int)ROBOTYPE_ROBOCUP] = "ROBOTYPE_ROBOCUP";
1408  add_fieldinfo(IFT_FLOAT, "head_yaw", 1, &data->head_yaw);
1409  add_fieldinfo(IFT_FLOAT, "head_pitch", 1, &data->head_pitch);
1410  add_fieldinfo(IFT_FLOAT, "l_shoulder_pitch", 1, &data->l_shoulder_pitch);
1411  add_fieldinfo(IFT_FLOAT, "l_shoulder_roll", 1, &data->l_shoulder_roll);
1412  add_fieldinfo(IFT_FLOAT, "l_elbow_yaw", 1, &data->l_elbow_yaw);
1413  add_fieldinfo(IFT_FLOAT, "l_elbow_roll", 1, &data->l_elbow_roll);
1414  add_fieldinfo(IFT_FLOAT, "l_hip_yaw_pitch", 1, &data->l_hip_yaw_pitch);
1415  add_fieldinfo(IFT_FLOAT, "l_hip_roll", 1, &data->l_hip_roll);
1416  add_fieldinfo(IFT_FLOAT, "l_hip_pitch", 1, &data->l_hip_pitch);
1417  add_fieldinfo(IFT_FLOAT, "l_knee_pitch", 1, &data->l_knee_pitch);
1418  add_fieldinfo(IFT_FLOAT, "l_ankle_pitch", 1, &data->l_ankle_pitch);
1419  add_fieldinfo(IFT_FLOAT, "l_ankle_roll", 1, &data->l_ankle_roll);
1420  add_fieldinfo(IFT_FLOAT, "l_wrist_yaw", 1, &data->l_wrist_yaw);
1421  add_fieldinfo(IFT_FLOAT, "l_hand", 1, &data->l_hand);
1422  add_fieldinfo(IFT_FLOAT, "r_shoulder_pitch", 1, &data->r_shoulder_pitch);
1423  add_fieldinfo(IFT_FLOAT, "r_shoulder_roll", 1, &data->r_shoulder_roll);
1424  add_fieldinfo(IFT_FLOAT, "r_elbow_yaw", 1, &data->r_elbow_yaw);
1425  add_fieldinfo(IFT_FLOAT, "r_elbow_roll", 1, &data->r_elbow_roll);
1426  add_fieldinfo(IFT_FLOAT, "r_wrist_yaw", 1, &data->r_wrist_yaw);
1427  add_fieldinfo(IFT_FLOAT, "r_hand", 1, &data->r_hand);
1428  add_fieldinfo(IFT_FLOAT, "r_hip_yaw_pitch", 1, &data->r_hip_yaw_pitch);
1429  add_fieldinfo(IFT_FLOAT, "r_hip_roll", 1, &data->r_hip_roll);
1430  add_fieldinfo(IFT_FLOAT, "r_hip_pitch", 1, &data->r_hip_pitch);
1431  add_fieldinfo(IFT_FLOAT, "r_knee_pitch", 1, &data->r_knee_pitch);
1432  add_fieldinfo(IFT_FLOAT, "r_ankle_pitch", 1, &data->r_ankle_pitch);
1433  add_fieldinfo(IFT_FLOAT, "r_ankle_roll", 1, &data->r_ankle_roll);
1434  add_fieldinfo(IFT_INT32, "time", 1, &data->time);
1435 }
1436 /** Constructor */
1438 {
1439  data_size = sizeof(SetServosMessage_data_t);
1440  data_ptr = malloc(data_size);
1441  memset(data_ptr, 0, data_size);
1442  data = (SetServosMessage_data_t *)data_ptr;
1444  enum_map_RobotType[(int)ROBOTYPE_ACADEMIC] = "ROBOTYPE_ACADEMIC";
1445  enum_map_RobotType[(int)ROBOTYPE_ROBOCUP] = "ROBOTYPE_ROBOCUP";
1446  add_fieldinfo(IFT_FLOAT, "head_yaw", 1, &data->head_yaw);
1447  add_fieldinfo(IFT_FLOAT, "head_pitch", 1, &data->head_pitch);
1448  add_fieldinfo(IFT_FLOAT, "l_shoulder_pitch", 1, &data->l_shoulder_pitch);
1449  add_fieldinfo(IFT_FLOAT, "l_shoulder_roll", 1, &data->l_shoulder_roll);
1450  add_fieldinfo(IFT_FLOAT, "l_elbow_yaw", 1, &data->l_elbow_yaw);
1451  add_fieldinfo(IFT_FLOAT, "l_elbow_roll", 1, &data->l_elbow_roll);
1452  add_fieldinfo(IFT_FLOAT, "l_hip_yaw_pitch", 1, &data->l_hip_yaw_pitch);
1453  add_fieldinfo(IFT_FLOAT, "l_hip_roll", 1, &data->l_hip_roll);
1454  add_fieldinfo(IFT_FLOAT, "l_hip_pitch", 1, &data->l_hip_pitch);
1455  add_fieldinfo(IFT_FLOAT, "l_knee_pitch", 1, &data->l_knee_pitch);
1456  add_fieldinfo(IFT_FLOAT, "l_ankle_pitch", 1, &data->l_ankle_pitch);
1457  add_fieldinfo(IFT_FLOAT, "l_ankle_roll", 1, &data->l_ankle_roll);
1458  add_fieldinfo(IFT_FLOAT, "l_wrist_yaw", 1, &data->l_wrist_yaw);
1459  add_fieldinfo(IFT_FLOAT, "l_hand", 1, &data->l_hand);
1460  add_fieldinfo(IFT_FLOAT, "r_shoulder_pitch", 1, &data->r_shoulder_pitch);
1461  add_fieldinfo(IFT_FLOAT, "r_shoulder_roll", 1, &data->r_shoulder_roll);
1462  add_fieldinfo(IFT_FLOAT, "r_elbow_yaw", 1, &data->r_elbow_yaw);
1463  add_fieldinfo(IFT_FLOAT, "r_elbow_roll", 1, &data->r_elbow_roll);
1464  add_fieldinfo(IFT_FLOAT, "r_wrist_yaw", 1, &data->r_wrist_yaw);
1465  add_fieldinfo(IFT_FLOAT, "r_hand", 1, &data->r_hand);
1466  add_fieldinfo(IFT_FLOAT, "r_hip_yaw_pitch", 1, &data->r_hip_yaw_pitch);
1467  add_fieldinfo(IFT_FLOAT, "r_hip_roll", 1, &data->r_hip_roll);
1468  add_fieldinfo(IFT_FLOAT, "r_hip_pitch", 1, &data->r_hip_pitch);
1469  add_fieldinfo(IFT_FLOAT, "r_knee_pitch", 1, &data->r_knee_pitch);
1470  add_fieldinfo(IFT_FLOAT, "r_ankle_pitch", 1, &data->r_ankle_pitch);
1471  add_fieldinfo(IFT_FLOAT, "r_ankle_roll", 1, &data->r_ankle_roll);
1472  add_fieldinfo(IFT_INT32, "time", 1, &data->time);
1473 }
1474 
1475 /** Destructor */
1477 {
1478  free(data_ptr);
1479 }
1480 
1481 /** Copy constructor.
1482  * @param m message to copy from
1483  */
1485 {
1486  data_size = m->data_size;
1487  data_ptr = malloc(data_size);
1488  memcpy(data_ptr, m->data_ptr, data_size);
1489  data = (SetServosMessage_data_t *)data_ptr;
1491 }
1492 
1493 /* Methods */
1494 /** Get head_yaw value.
1495  * Head yaw
1496  * @return head_yaw value
1497  */
1498 float
1500 {
1501  return data->head_yaw;
1502 }
1503 
1504 /** Get maximum length of head_yaw value.
1505  * @return length of head_yaw value, can be length of the array or number of
1506  * maximum number of characters for a string
1507  */
1508 size_t
1510 {
1511  return 1;
1512 }
1513 
1514 /** Set head_yaw value.
1515  * Head yaw
1516  * @param new_head_yaw new head_yaw value
1517  */
1518 void
1520 {
1521  data->head_yaw = new_head_yaw;
1522 }
1523 
1524 /** Get head_pitch value.
1525  * Head pitch
1526  * @return head_pitch value
1527  */
1528 float
1530 {
1531  return data->head_pitch;
1532 }
1533 
1534 /** Get maximum length of head_pitch value.
1535  * @return length of head_pitch value, can be length of the array or number of
1536  * maximum number of characters for a string
1537  */
1538 size_t
1540 {
1541  return 1;
1542 }
1543 
1544 /** Set head_pitch value.
1545  * Head pitch
1546  * @param new_head_pitch new head_pitch value
1547  */
1548 void
1550 {
1551  data->head_pitch = new_head_pitch;
1552 }
1553 
1554 /** Get l_shoulder_pitch value.
1555  * Left shoulder pitch
1556  * @return l_shoulder_pitch value
1557  */
1558 float
1560 {
1561  return data->l_shoulder_pitch;
1562 }
1563 
1564 /** Get maximum length of l_shoulder_pitch value.
1565  * @return length of l_shoulder_pitch value, can be length of the array or number of
1566  * maximum number of characters for a string
1567  */
1568 size_t
1570 {
1571  return 1;
1572 }
1573 
1574 /** Set l_shoulder_pitch value.
1575  * Left shoulder pitch
1576  * @param new_l_shoulder_pitch new l_shoulder_pitch value
1577  */
1578 void
1580 {
1581  data->l_shoulder_pitch = new_l_shoulder_pitch;
1582 }
1583 
1584 /** Get l_shoulder_roll value.
1585  * Left shoulder roll
1586  * @return l_shoulder_roll value
1587  */
1588 float
1590 {
1591  return data->l_shoulder_roll;
1592 }
1593 
1594 /** Get maximum length of l_shoulder_roll value.
1595  * @return length of l_shoulder_roll value, can be length of the array or number of
1596  * maximum number of characters for a string
1597  */
1598 size_t
1600 {
1601  return 1;
1602 }
1603 
1604 /** Set l_shoulder_roll value.
1605  * Left shoulder roll
1606  * @param new_l_shoulder_roll new l_shoulder_roll value
1607  */
1608 void
1610 {
1611  data->l_shoulder_roll = new_l_shoulder_roll;
1612 }
1613 
1614 /** Get l_elbow_yaw value.
1615  * Left elbow yaw
1616  * @return l_elbow_yaw value
1617  */
1618 float
1620 {
1621  return data->l_elbow_yaw;
1622 }
1623 
1624 /** Get maximum length of l_elbow_yaw value.
1625  * @return length of l_elbow_yaw value, can be length of the array or number of
1626  * maximum number of characters for a string
1627  */
1628 size_t
1630 {
1631  return 1;
1632 }
1633 
1634 /** Set l_elbow_yaw value.
1635  * Left elbow yaw
1636  * @param new_l_elbow_yaw new l_elbow_yaw value
1637  */
1638 void
1640 {
1641  data->l_elbow_yaw = new_l_elbow_yaw;
1642 }
1643 
1644 /** Get l_elbow_roll value.
1645  * Left elbow roll
1646  * @return l_elbow_roll value
1647  */
1648 float
1650 {
1651  return data->l_elbow_roll;
1652 }
1653 
1654 /** Get maximum length of l_elbow_roll value.
1655  * @return length of l_elbow_roll value, can be length of the array or number of
1656  * maximum number of characters for a string
1657  */
1658 size_t
1660 {
1661  return 1;
1662 }
1663 
1664 /** Set l_elbow_roll value.
1665  * Left elbow roll
1666  * @param new_l_elbow_roll new l_elbow_roll value
1667  */
1668 void
1670 {
1671  data->l_elbow_roll = new_l_elbow_roll;
1672 }
1673 
1674 /** Get l_hip_yaw_pitch value.
1675  * Left hip yaw pitch
1676  * @return l_hip_yaw_pitch value
1677  */
1678 float
1680 {
1681  return data->l_hip_yaw_pitch;
1682 }
1683 
1684 /** Get maximum length of l_hip_yaw_pitch value.
1685  * @return length of l_hip_yaw_pitch value, can be length of the array or number of
1686  * maximum number of characters for a string
1687  */
1688 size_t
1690 {
1691  return 1;
1692 }
1693 
1694 /** Set l_hip_yaw_pitch value.
1695  * Left hip yaw pitch
1696  * @param new_l_hip_yaw_pitch new l_hip_yaw_pitch value
1697  */
1698 void
1700 {
1701  data->l_hip_yaw_pitch = new_l_hip_yaw_pitch;
1702 }
1703 
1704 /** Get l_hip_roll value.
1705  * Left hip roll
1706  * @return l_hip_roll value
1707  */
1708 float
1710 {
1711  return data->l_hip_roll;
1712 }
1713 
1714 /** Get maximum length of l_hip_roll value.
1715  * @return length of l_hip_roll value, can be length of the array or number of
1716  * maximum number of characters for a string
1717  */
1718 size_t
1720 {
1721  return 1;
1722 }
1723 
1724 /** Set l_hip_roll value.
1725  * Left hip roll
1726  * @param new_l_hip_roll new l_hip_roll value
1727  */
1728 void
1730 {
1731  data->l_hip_roll = new_l_hip_roll;
1732 }
1733 
1734 /** Get l_hip_pitch value.
1735  * Left hip pitch
1736  * @return l_hip_pitch value
1737  */
1738 float
1740 {
1741  return data->l_hip_pitch;
1742 }
1743 
1744 /** Get maximum length of l_hip_pitch value.
1745  * @return length of l_hip_pitch value, can be length of the array or number of
1746  * maximum number of characters for a string
1747  */
1748 size_t
1750 {
1751  return 1;
1752 }
1753 
1754 /** Set l_hip_pitch value.
1755  * Left hip pitch
1756  * @param new_l_hip_pitch new l_hip_pitch value
1757  */
1758 void
1760 {
1761  data->l_hip_pitch = new_l_hip_pitch;
1762 }
1763 
1764 /** Get l_knee_pitch value.
1765  * Left knee pitch
1766  * @return l_knee_pitch value
1767  */
1768 float
1770 {
1771  return data->l_knee_pitch;
1772 }
1773 
1774 /** Get maximum length of l_knee_pitch value.
1775  * @return length of l_knee_pitch value, can be length of the array or number of
1776  * maximum number of characters for a string
1777  */
1778 size_t
1780 {
1781  return 1;
1782 }
1783 
1784 /** Set l_knee_pitch value.
1785  * Left knee pitch
1786  * @param new_l_knee_pitch new l_knee_pitch value
1787  */
1788 void
1790 {
1791  data->l_knee_pitch = new_l_knee_pitch;
1792 }
1793 
1794 /** Get l_ankle_pitch value.
1795  * Left ankle pitch
1796  * @return l_ankle_pitch value
1797  */
1798 float
1800 {
1801  return data->l_ankle_pitch;
1802 }
1803 
1804 /** Get maximum length of l_ankle_pitch value.
1805  * @return length of l_ankle_pitch value, can be length of the array or number of
1806  * maximum number of characters for a string
1807  */
1808 size_t
1810 {
1811  return 1;
1812 }
1813 
1814 /** Set l_ankle_pitch value.
1815  * Left ankle pitch
1816  * @param new_l_ankle_pitch new l_ankle_pitch value
1817  */
1818 void
1820 {
1821  data->l_ankle_pitch = new_l_ankle_pitch;
1822 }
1823 
1824 /** Get l_ankle_roll value.
1825  * Left ankle roll
1826  * @return l_ankle_roll value
1827  */
1828 float
1830 {
1831  return data->l_ankle_roll;
1832 }
1833 
1834 /** Get maximum length of l_ankle_roll value.
1835  * @return length of l_ankle_roll value, can be length of the array or number of
1836  * maximum number of characters for a string
1837  */
1838 size_t
1840 {
1841  return 1;
1842 }
1843 
1844 /** Set l_ankle_roll value.
1845  * Left ankle roll
1846  * @param new_l_ankle_roll new l_ankle_roll value
1847  */
1848 void
1850 {
1851  data->l_ankle_roll = new_l_ankle_roll;
1852 }
1853 
1854 /** Get l_wrist_yaw value.
1855  * Left wrist yaw
1856  * @return l_wrist_yaw value
1857  */
1858 float
1860 {
1861  return data->l_wrist_yaw;
1862 }
1863 
1864 /** Get maximum length of l_wrist_yaw value.
1865  * @return length of l_wrist_yaw value, can be length of the array or number of
1866  * maximum number of characters for a string
1867  */
1868 size_t
1870 {
1871  return 1;
1872 }
1873 
1874 /** Set l_wrist_yaw value.
1875  * Left wrist yaw
1876  * @param new_l_wrist_yaw new l_wrist_yaw value
1877  */
1878 void
1880 {
1881  data->l_wrist_yaw = new_l_wrist_yaw;
1882 }
1883 
1884 /** Get l_hand value.
1885  * Left hand
1886  * @return l_hand value
1887  */
1888 float
1890 {
1891  return data->l_hand;
1892 }
1893 
1894 /** Get maximum length of l_hand value.
1895  * @return length of l_hand value, can be length of the array or number of
1896  * maximum number of characters for a string
1897  */
1898 size_t
1900 {
1901  return 1;
1902 }
1903 
1904 /** Set l_hand value.
1905  * Left hand
1906  * @param new_l_hand new l_hand value
1907  */
1908 void
1910 {
1911  data->l_hand = new_l_hand;
1912 }
1913 
1914 /** Get r_shoulder_pitch value.
1915  * Right shoulder pitch
1916  * @return r_shoulder_pitch value
1917  */
1918 float
1920 {
1921  return data->r_shoulder_pitch;
1922 }
1923 
1924 /** Get maximum length of r_shoulder_pitch value.
1925  * @return length of r_shoulder_pitch value, can be length of the array or number of
1926  * maximum number of characters for a string
1927  */
1928 size_t
1930 {
1931  return 1;
1932 }
1933 
1934 /** Set r_shoulder_pitch value.
1935  * Right shoulder pitch
1936  * @param new_r_shoulder_pitch new r_shoulder_pitch value
1937  */
1938 void
1940 {
1941  data->r_shoulder_pitch = new_r_shoulder_pitch;
1942 }
1943 
1944 /** Get r_shoulder_roll value.
1945  * Right shoulder roll
1946  * @return r_shoulder_roll value
1947  */
1948 float
1950 {
1951  return data->r_shoulder_roll;
1952 }
1953 
1954 /** Get maximum length of r_shoulder_roll value.
1955  * @return length of r_shoulder_roll value, can be length of the array or number of
1956  * maximum number of characters for a string
1957  */
1958 size_t
1960 {
1961  return 1;
1962 }
1963 
1964 /** Set r_shoulder_roll value.
1965  * Right shoulder roll
1966  * @param new_r_shoulder_roll new r_shoulder_roll value
1967  */
1968 void
1970 {
1971  data->r_shoulder_roll = new_r_shoulder_roll;
1972 }
1973 
1974 /** Get r_elbow_yaw value.
1975  * Right elbow yaw
1976  * @return r_elbow_yaw value
1977  */
1978 float
1980 {
1981  return data->r_elbow_yaw;
1982 }
1983 
1984 /** Get maximum length of r_elbow_yaw value.
1985  * @return length of r_elbow_yaw value, can be length of the array or number of
1986  * maximum number of characters for a string
1987  */
1988 size_t
1990 {
1991  return 1;
1992 }
1993 
1994 /** Set r_elbow_yaw value.
1995  * Right elbow yaw
1996  * @param new_r_elbow_yaw new r_elbow_yaw value
1997  */
1998 void
2000 {
2001  data->r_elbow_yaw = new_r_elbow_yaw;
2002 }
2003 
2004 /** Get r_elbow_roll value.
2005  * Right elbow roll
2006  * @return r_elbow_roll value
2007  */
2008 float
2010 {
2011  return data->r_elbow_roll;
2012 }
2013 
2014 /** Get maximum length of r_elbow_roll value.
2015  * @return length of r_elbow_roll value, can be length of the array or number of
2016  * maximum number of characters for a string
2017  */
2018 size_t
2020 {
2021  return 1;
2022 }
2023 
2024 /** Set r_elbow_roll value.
2025  * Right elbow roll
2026  * @param new_r_elbow_roll new r_elbow_roll value
2027  */
2028 void
2030 {
2031  data->r_elbow_roll = new_r_elbow_roll;
2032 }
2033 
2034 /** Get r_wrist_yaw value.
2035  * Right wrist yaw
2036  * @return r_wrist_yaw value
2037  */
2038 float
2040 {
2041  return data->r_wrist_yaw;
2042 }
2043 
2044 /** Get maximum length of r_wrist_yaw value.
2045  * @return length of r_wrist_yaw value, can be length of the array or number of
2046  * maximum number of characters for a string
2047  */
2048 size_t
2050 {
2051  return 1;
2052 }
2053 
2054 /** Set r_wrist_yaw value.
2055  * Right wrist yaw
2056  * @param new_r_wrist_yaw new r_wrist_yaw value
2057  */
2058 void
2060 {
2061  data->r_wrist_yaw = new_r_wrist_yaw;
2062 }
2063 
2064 /** Get r_hand value.
2065  * Right hand
2066  * @return r_hand value
2067  */
2068 float
2070 {
2071  return data->r_hand;
2072 }
2073 
2074 /** Get maximum length of r_hand value.
2075  * @return length of r_hand value, can be length of the array or number of
2076  * maximum number of characters for a string
2077  */
2078 size_t
2080 {
2081  return 1;
2082 }
2083 
2084 /** Set r_hand value.
2085  * Right hand
2086  * @param new_r_hand new r_hand value
2087  */
2088 void
2090 {
2091  data->r_hand = new_r_hand;
2092 }
2093 
2094 /** Get r_hip_yaw_pitch value.
2095  * Right hip yaw pitch
2096  * @return r_hip_yaw_pitch value
2097  */
2098 float
2100 {
2101  return data->r_hip_yaw_pitch;
2102 }
2103 
2104 /** Get maximum length of r_hip_yaw_pitch value.
2105  * @return length of r_hip_yaw_pitch value, can be length of the array or number of
2106  * maximum number of characters for a string
2107  */
2108 size_t
2110 {
2111  return 1;
2112 }
2113 
2114 /** Set r_hip_yaw_pitch value.
2115  * Right hip yaw pitch
2116  * @param new_r_hip_yaw_pitch new r_hip_yaw_pitch value
2117  */
2118 void
2120 {
2121  data->r_hip_yaw_pitch = new_r_hip_yaw_pitch;
2122 }
2123 
2124 /** Get r_hip_roll value.
2125  * Right hip roll
2126  * @return r_hip_roll value
2127  */
2128 float
2130 {
2131  return data->r_hip_roll;
2132 }
2133 
2134 /** Get maximum length of r_hip_roll value.
2135  * @return length of r_hip_roll value, can be length of the array or number of
2136  * maximum number of characters for a string
2137  */
2138 size_t
2140 {
2141  return 1;
2142 }
2143 
2144 /** Set r_hip_roll value.
2145  * Right hip roll
2146  * @param new_r_hip_roll new r_hip_roll value
2147  */
2148 void
2150 {
2151  data->r_hip_roll = new_r_hip_roll;
2152 }
2153 
2154 /** Get r_hip_pitch value.
2155  * Right hip pitch
2156  * @return r_hip_pitch value
2157  */
2158 float
2160 {
2161  return data->r_hip_pitch;
2162 }
2163 
2164 /** Get maximum length of r_hip_pitch value.
2165  * @return length of r_hip_pitch value, can be length of the array or number of
2166  * maximum number of characters for a string
2167  */
2168 size_t
2170 {
2171  return 1;
2172 }
2173 
2174 /** Set r_hip_pitch value.
2175  * Right hip pitch
2176  * @param new_r_hip_pitch new r_hip_pitch value
2177  */
2178 void
2180 {
2181  data->r_hip_pitch = new_r_hip_pitch;
2182 }
2183 
2184 /** Get r_knee_pitch value.
2185  * Right knee pitch
2186  * @return r_knee_pitch value
2187  */
2188 float
2190 {
2191  return data->r_knee_pitch;
2192 }
2193 
2194 /** Get maximum length of r_knee_pitch value.
2195  * @return length of r_knee_pitch value, can be length of the array or number of
2196  * maximum number of characters for a string
2197  */
2198 size_t
2200 {
2201  return 1;
2202 }
2203 
2204 /** Set r_knee_pitch value.
2205  * Right knee pitch
2206  * @param new_r_knee_pitch new r_knee_pitch value
2207  */
2208 void
2210 {
2211  data->r_knee_pitch = new_r_knee_pitch;
2212 }
2213 
2214 /** Get r_ankle_pitch value.
2215  * Right ankle pitch
2216  * @return r_ankle_pitch value
2217  */
2218 float
2220 {
2221  return data->r_ankle_pitch;
2222 }
2223 
2224 /** Get maximum length of r_ankle_pitch value.
2225  * @return length of r_ankle_pitch value, can be length of the array or number of
2226  * maximum number of characters for a string
2227  */
2228 size_t
2230 {
2231  return 1;
2232 }
2233 
2234 /** Set r_ankle_pitch value.
2235  * Right ankle pitch
2236  * @param new_r_ankle_pitch new r_ankle_pitch value
2237  */
2238 void
2240 {
2241  data->r_ankle_pitch = new_r_ankle_pitch;
2242 }
2243 
2244 /** Get r_ankle_roll value.
2245  * Right ankle roll
2246  * @return r_ankle_roll value
2247  */
2248 float
2250 {
2251  return data->r_ankle_roll;
2252 }
2253 
2254 /** Get maximum length of r_ankle_roll value.
2255  * @return length of r_ankle_roll value, can be length of the array or number of
2256  * maximum number of characters for a string
2257  */
2258 size_t
2260 {
2261  return 1;
2262 }
2263 
2264 /** Set r_ankle_roll value.
2265  * Right ankle roll
2266  * @param new_r_ankle_roll new r_ankle_roll value
2267  */
2268 void
2270 {
2271  data->r_ankle_roll = new_r_ankle_roll;
2272 }
2273 
2274 /** Get time value.
2275  *
2276  Current reference time in ms. For real hardware this is the DCM time.
2277  Times in messages are always offsets to the current time and the current
2278  time is added before executing the command.
2279 
2280  * @return time value
2281  */
2282 int32_t
2284 {
2285  return data->time;
2286 }
2287 
2288 /** Get maximum length of time value.
2289  * @return length of time value, can be length of the array or number of
2290  * maximum number of characters for a string
2291  */
2292 size_t
2294 {
2295  return 1;
2296 }
2297 
2298 /** Set time value.
2299  *
2300  Current reference time in ms. For real hardware this is the DCM time.
2301  Times in messages are always offsets to the current time and the current
2302  time is added before executing the command.
2303 
2304  * @param new_time new time value
2305  */
2306 void
2308 {
2309  data->time = new_time;
2310 }
2311 
2312 /** Clone this message.
2313  * Produces a message of the same type as this message and copies the
2314  * data to the new message.
2315  * @return clone of this message
2316  */
2317 Message *
2319 {
2321 }
2322 /** @class NaoJointPositionInterface::MoveServoMessage <interfaces/NaoJointPositionInterface.h>
2323  * MoveServoMessage Fawkes BlackBoard Interface Message.
2324  *
2325 
2326  */
2327 
2328 
2329 /** Constructor with initial values.
2330  * @param ini_servo initial value for servo
2331  * @param ini_value initial value for value
2332  * @param ini_speed initial value for speed
2333  */
2334 NaoJointPositionInterface::MoveServoMessage::MoveServoMessage(const uint32_t ini_servo, const float ini_value, const float ini_speed) : Message("MoveServoMessage")
2335 {
2336  data_size = sizeof(MoveServoMessage_data_t);
2337  data_ptr = malloc(data_size);
2338  memset(data_ptr, 0, data_size);
2339  data = (MoveServoMessage_data_t *)data_ptr;
2341  data->servo = ini_servo;
2342  data->value = ini_value;
2343  data->speed = ini_speed;
2344  enum_map_RobotType[(int)ROBOTYPE_ACADEMIC] = "ROBOTYPE_ACADEMIC";
2345  enum_map_RobotType[(int)ROBOTYPE_ROBOCUP] = "ROBOTYPE_ROBOCUP";
2346  add_fieldinfo(IFT_UINT32, "servo", 1, &data->servo);
2347  add_fieldinfo(IFT_FLOAT, "value", 1, &data->value);
2348  add_fieldinfo(IFT_FLOAT, "speed", 1, &data->speed);
2349 }
2350 /** Constructor */
2352 {
2353  data_size = sizeof(MoveServoMessage_data_t);
2354  data_ptr = malloc(data_size);
2355  memset(data_ptr, 0, data_size);
2356  data = (MoveServoMessage_data_t *)data_ptr;
2358  enum_map_RobotType[(int)ROBOTYPE_ACADEMIC] = "ROBOTYPE_ACADEMIC";
2359  enum_map_RobotType[(int)ROBOTYPE_ROBOCUP] = "ROBOTYPE_ROBOCUP";
2360  add_fieldinfo(IFT_UINT32, "servo", 1, &data->servo);
2361  add_fieldinfo(IFT_FLOAT, "value", 1, &data->value);
2362  add_fieldinfo(IFT_FLOAT, "speed", 1, &data->speed);
2363 }
2364 
2365 /** Destructor */
2367 {
2368  free(data_ptr);
2369 }
2370 
2371 /** Copy constructor.
2372  * @param m message to copy from
2373  */
2375 {
2376  data_size = m->data_size;
2377  data_ptr = malloc(data_size);
2378  memcpy(data_ptr, m->data_ptr, data_size);
2379  data = (MoveServoMessage_data_t *)data_ptr;
2381 }
2382 
2383 /* Methods */
2384 /** Get servo value.
2385  *
2386  A concatenated list of SERVO_* constants to define the servos
2387  that should execute the movement. The list shall consist of
2388  binary or'ed SERVO_* constants.
2389 
2390  * @return servo value
2391  */
2392 uint32_t
2394 {
2395  return data->servo;
2396 }
2397 
2398 /** Get maximum length of servo value.
2399  * @return length of servo value, can be length of the array or number of
2400  * maximum number of characters for a string
2401  */
2402 size_t
2404 {
2405  return 1;
2406 }
2407 
2408 /** Set servo value.
2409  *
2410  A concatenated list of SERVO_* constants to define the servos
2411  that should execute the movement. The list shall consist of
2412  binary or'ed SERVO_* constants.
2413 
2414  * @param new_servo new servo value
2415  */
2416 void
2418 {
2419  data->servo = new_servo;
2420 }
2421 
2422 /** Get value value.
2423  * Servo value to set for servos.
2424  * @return value value
2425  */
2426 float
2428 {
2429  return data->value;
2430 }
2431 
2432 /** Get maximum length of value value.
2433  * @return length of value value, can be length of the array or number of
2434  * maximum number of characters for a string
2435  */
2436 size_t
2438 {
2439  return 1;
2440 }
2441 
2442 /** Set value value.
2443  * Servo value to set for servos.
2444  * @param new_value new value value
2445  */
2446 void
2448 {
2449  data->value = new_value;
2450 }
2451 
2452 /** Get speed value.
2453  *
2454  Fraction of max speed in range [0.0..1.0].
2455 
2456  * @return speed value
2457  */
2458 float
2460 {
2461  return data->speed;
2462 }
2463 
2464 /** Get maximum length of speed value.
2465  * @return length of speed value, can be length of the array or number of
2466  * maximum number of characters for a string
2467  */
2468 size_t
2470 {
2471  return 1;
2472 }
2473 
2474 /** Set speed value.
2475  *
2476  Fraction of max speed in range [0.0..1.0].
2477 
2478  * @param new_speed new speed value
2479  */
2480 void
2482 {
2483  data->speed = new_speed;
2484 }
2485 
2486 /** Clone this message.
2487  * Produces a message of the same type as this message and copies the
2488  * data to the new message.
2489  * @return clone of this message
2490  */
2491 Message *
2493 {
2495 }
2496 /** @class NaoJointPositionInterface::MoveServosMessage <interfaces/NaoJointPositionInterface.h>
2497  * MoveServosMessage Fawkes BlackBoard Interface Message.
2498  *
2499 
2500  */
2501 
2502 
2503 /** Constructor with initial values.
2504  * @param ini_speed initial value for speed
2505  * @param ini_head_yaw initial value for head_yaw
2506  * @param ini_head_pitch initial value for head_pitch
2507  * @param ini_l_shoulder_pitch initial value for l_shoulder_pitch
2508  * @param ini_l_shoulder_roll initial value for l_shoulder_roll
2509  * @param ini_l_elbow_yaw initial value for l_elbow_yaw
2510  * @param ini_l_elbow_roll initial value for l_elbow_roll
2511  * @param ini_l_wrist_yaw initial value for l_wrist_yaw
2512  * @param ini_l_hand initial value for l_hand
2513  * @param ini_l_hip_yaw_pitch initial value for l_hip_yaw_pitch
2514  * @param ini_l_hip_roll initial value for l_hip_roll
2515  * @param ini_l_hip_pitch initial value for l_hip_pitch
2516  * @param ini_l_knee_pitch initial value for l_knee_pitch
2517  * @param ini_l_ankle_pitch initial value for l_ankle_pitch
2518  * @param ini_l_ankle_roll initial value for l_ankle_roll
2519  * @param ini_r_shoulder_pitch initial value for r_shoulder_pitch
2520  * @param ini_r_shoulder_roll initial value for r_shoulder_roll
2521  * @param ini_r_elbow_yaw initial value for r_elbow_yaw
2522  * @param ini_r_elbow_roll initial value for r_elbow_roll
2523  * @param ini_r_wrist_yaw initial value for r_wrist_yaw
2524  * @param ini_r_hand initial value for r_hand
2525  * @param ini_r_hip_yaw_pitch initial value for r_hip_yaw_pitch
2526  * @param ini_r_hip_roll initial value for r_hip_roll
2527  * @param ini_r_hip_pitch initial value for r_hip_pitch
2528  * @param ini_r_knee_pitch initial value for r_knee_pitch
2529  * @param ini_r_ankle_pitch initial value for r_ankle_pitch
2530  * @param ini_r_ankle_roll initial value for r_ankle_roll
2531  */
2532 NaoJointPositionInterface::MoveServosMessage::MoveServosMessage(const float ini_speed, const float ini_head_yaw, const float ini_head_pitch, const float ini_l_shoulder_pitch, const float ini_l_shoulder_roll, const float ini_l_elbow_yaw, const float ini_l_elbow_roll, const float ini_l_wrist_yaw, const float ini_l_hand, const float ini_l_hip_yaw_pitch, const float ini_l_hip_roll, const float ini_l_hip_pitch, const float ini_l_knee_pitch, const float ini_l_ankle_pitch, const float ini_l_ankle_roll, const float ini_r_shoulder_pitch, const float ini_r_shoulder_roll, const float ini_r_elbow_yaw, const float ini_r_elbow_roll, const float ini_r_wrist_yaw, const float ini_r_hand, const float ini_r_hip_yaw_pitch, const float ini_r_hip_roll, const float ini_r_hip_pitch, const float ini_r_knee_pitch, const float ini_r_ankle_pitch, const float ini_r_ankle_roll) : Message("MoveServosMessage")
2533 {
2534  data_size = sizeof(MoveServosMessage_data_t);
2535  data_ptr = malloc(data_size);
2536  memset(data_ptr, 0, data_size);
2537  data = (MoveServosMessage_data_t *)data_ptr;
2539  data->speed = ini_speed;
2540  data->head_yaw = ini_head_yaw;
2541  data->head_pitch = ini_head_pitch;
2542  data->l_shoulder_pitch = ini_l_shoulder_pitch;
2543  data->l_shoulder_roll = ini_l_shoulder_roll;
2544  data->l_elbow_yaw = ini_l_elbow_yaw;
2545  data->l_elbow_roll = ini_l_elbow_roll;
2546  data->l_wrist_yaw = ini_l_wrist_yaw;
2547  data->l_hand = ini_l_hand;
2548  data->l_hip_yaw_pitch = ini_l_hip_yaw_pitch;
2549  data->l_hip_roll = ini_l_hip_roll;
2550  data->l_hip_pitch = ini_l_hip_pitch;
2551  data->l_knee_pitch = ini_l_knee_pitch;
2552  data->l_ankle_pitch = ini_l_ankle_pitch;
2553  data->l_ankle_roll = ini_l_ankle_roll;
2554  data->r_shoulder_pitch = ini_r_shoulder_pitch;
2555  data->r_shoulder_roll = ini_r_shoulder_roll;
2556  data->r_elbow_yaw = ini_r_elbow_yaw;
2557  data->r_elbow_roll = ini_r_elbow_roll;
2558  data->r_wrist_yaw = ini_r_wrist_yaw;
2559  data->r_hand = ini_r_hand;
2560  data->r_hip_yaw_pitch = ini_r_hip_yaw_pitch;
2561  data->r_hip_roll = ini_r_hip_roll;
2562  data->r_hip_pitch = ini_r_hip_pitch;
2563  data->r_knee_pitch = ini_r_knee_pitch;
2564  data->r_ankle_pitch = ini_r_ankle_pitch;
2565  data->r_ankle_roll = ini_r_ankle_roll;
2566  enum_map_RobotType[(int)ROBOTYPE_ACADEMIC] = "ROBOTYPE_ACADEMIC";
2567  enum_map_RobotType[(int)ROBOTYPE_ROBOCUP] = "ROBOTYPE_ROBOCUP";
2568  add_fieldinfo(IFT_FLOAT, "speed", 1, &data->speed);
2569  add_fieldinfo(IFT_FLOAT, "head_yaw", 1, &data->head_yaw);
2570  add_fieldinfo(IFT_FLOAT, "head_pitch", 1, &data->head_pitch);
2571  add_fieldinfo(IFT_FLOAT, "l_shoulder_pitch", 1, &data->l_shoulder_pitch);
2572  add_fieldinfo(IFT_FLOAT, "l_shoulder_roll", 1, &data->l_shoulder_roll);
2573  add_fieldinfo(IFT_FLOAT, "l_elbow_yaw", 1, &data->l_elbow_yaw);
2574  add_fieldinfo(IFT_FLOAT, "l_elbow_roll", 1, &data->l_elbow_roll);
2575  add_fieldinfo(IFT_FLOAT, "l_wrist_yaw", 1, &data->l_wrist_yaw);
2576  add_fieldinfo(IFT_FLOAT, "l_hand", 1, &data->l_hand);
2577  add_fieldinfo(IFT_FLOAT, "l_hip_yaw_pitch", 1, &data->l_hip_yaw_pitch);
2578  add_fieldinfo(IFT_FLOAT, "l_hip_roll", 1, &data->l_hip_roll);
2579  add_fieldinfo(IFT_FLOAT, "l_hip_pitch", 1, &data->l_hip_pitch);
2580  add_fieldinfo(IFT_FLOAT, "l_knee_pitch", 1, &data->l_knee_pitch);
2581  add_fieldinfo(IFT_FLOAT, "l_ankle_pitch", 1, &data->l_ankle_pitch);
2582  add_fieldinfo(IFT_FLOAT, "l_ankle_roll", 1, &data->l_ankle_roll);
2583  add_fieldinfo(IFT_FLOAT, "r_shoulder_pitch", 1, &data->r_shoulder_pitch);
2584  add_fieldinfo(IFT_FLOAT, "r_shoulder_roll", 1, &data->r_shoulder_roll);
2585  add_fieldinfo(IFT_FLOAT, "r_elbow_yaw", 1, &data->r_elbow_yaw);
2586  add_fieldinfo(IFT_FLOAT, "r_elbow_roll", 1, &data->r_elbow_roll);
2587  add_fieldinfo(IFT_FLOAT, "r_wrist_yaw", 1, &data->r_wrist_yaw);
2588  add_fieldinfo(IFT_FLOAT, "r_hand", 1, &data->r_hand);
2589  add_fieldinfo(IFT_FLOAT, "r_hip_yaw_pitch", 1, &data->r_hip_yaw_pitch);
2590  add_fieldinfo(IFT_FLOAT, "r_hip_roll", 1, &data->r_hip_roll);
2591  add_fieldinfo(IFT_FLOAT, "r_hip_pitch", 1, &data->r_hip_pitch);
2592  add_fieldinfo(IFT_FLOAT, "r_knee_pitch", 1, &data->r_knee_pitch);
2593  add_fieldinfo(IFT_FLOAT, "r_ankle_pitch", 1, &data->r_ankle_pitch);
2594  add_fieldinfo(IFT_FLOAT, "r_ankle_roll", 1, &data->r_ankle_roll);
2595 }
2596 /** Constructor */
2598 {
2599  data_size = sizeof(MoveServosMessage_data_t);
2600  data_ptr = malloc(data_size);
2601  memset(data_ptr, 0, data_size);
2602  data = (MoveServosMessage_data_t *)data_ptr;
2604  enum_map_RobotType[(int)ROBOTYPE_ACADEMIC] = "ROBOTYPE_ACADEMIC";
2605  enum_map_RobotType[(int)ROBOTYPE_ROBOCUP] = "ROBOTYPE_ROBOCUP";
2606  add_fieldinfo(IFT_FLOAT, "speed", 1, &data->speed);
2607  add_fieldinfo(IFT_FLOAT, "head_yaw", 1, &data->head_yaw);
2608  add_fieldinfo(IFT_FLOAT, "head_pitch", 1, &data->head_pitch);
2609  add_fieldinfo(IFT_FLOAT, "l_shoulder_pitch", 1, &data->l_shoulder_pitch);
2610  add_fieldinfo(IFT_FLOAT, "l_shoulder_roll", 1, &data->l_shoulder_roll);
2611  add_fieldinfo(IFT_FLOAT, "l_elbow_yaw", 1, &data->l_elbow_yaw);
2612  add_fieldinfo(IFT_FLOAT, "l_elbow_roll", 1, &data->l_elbow_roll);
2613  add_fieldinfo(IFT_FLOAT, "l_wrist_yaw", 1, &data->l_wrist_yaw);
2614  add_fieldinfo(IFT_FLOAT, "l_hand", 1, &data->l_hand);
2615  add_fieldinfo(IFT_FLOAT, "l_hip_yaw_pitch", 1, &data->l_hip_yaw_pitch);
2616  add_fieldinfo(IFT_FLOAT, "l_hip_roll", 1, &data->l_hip_roll);
2617  add_fieldinfo(IFT_FLOAT, "l_hip_pitch", 1, &data->l_hip_pitch);
2618  add_fieldinfo(IFT_FLOAT, "l_knee_pitch", 1, &data->l_knee_pitch);
2619  add_fieldinfo(IFT_FLOAT, "l_ankle_pitch", 1, &data->l_ankle_pitch);
2620  add_fieldinfo(IFT_FLOAT, "l_ankle_roll", 1, &data->l_ankle_roll);
2621  add_fieldinfo(IFT_FLOAT, "r_shoulder_pitch", 1, &data->r_shoulder_pitch);
2622  add_fieldinfo(IFT_FLOAT, "r_shoulder_roll", 1, &data->r_shoulder_roll);
2623  add_fieldinfo(IFT_FLOAT, "r_elbow_yaw", 1, &data->r_elbow_yaw);
2624  add_fieldinfo(IFT_FLOAT, "r_elbow_roll", 1, &data->r_elbow_roll);
2625  add_fieldinfo(IFT_FLOAT, "r_wrist_yaw", 1, &data->r_wrist_yaw);
2626  add_fieldinfo(IFT_FLOAT, "r_hand", 1, &data->r_hand);
2627  add_fieldinfo(IFT_FLOAT, "r_hip_yaw_pitch", 1, &data->r_hip_yaw_pitch);
2628  add_fieldinfo(IFT_FLOAT, "r_hip_roll", 1, &data->r_hip_roll);
2629  add_fieldinfo(IFT_FLOAT, "r_hip_pitch", 1, &data->r_hip_pitch);
2630  add_fieldinfo(IFT_FLOAT, "r_knee_pitch", 1, &data->r_knee_pitch);
2631  add_fieldinfo(IFT_FLOAT, "r_ankle_pitch", 1, &data->r_ankle_pitch);
2632  add_fieldinfo(IFT_FLOAT, "r_ankle_roll", 1, &data->r_ankle_roll);
2633 }
2634 
2635 /** Destructor */
2637 {
2638  free(data_ptr);
2639 }
2640 
2641 /** Copy constructor.
2642  * @param m message to copy from
2643  */
2645 {
2646  data_size = m->data_size;
2647  data_ptr = malloc(data_size);
2648  memcpy(data_ptr, m->data_ptr, data_size);
2649  data = (MoveServosMessage_data_t *)data_ptr;
2651 }
2652 
2653 /* Methods */
2654 /** Get speed value.
2655  *
2656  Fraction of max speed in range [0.0..1.0].
2657 
2658  * @return speed value
2659  */
2660 float
2662 {
2663  return data->speed;
2664 }
2665 
2666 /** Get maximum length of speed value.
2667  * @return length of speed value, can be length of the array or number of
2668  * maximum number of characters for a string
2669  */
2670 size_t
2672 {
2673  return 1;
2674 }
2675 
2676 /** Set speed value.
2677  *
2678  Fraction of max speed in range [0.0..1.0].
2679 
2680  * @param new_speed new speed value
2681  */
2682 void
2684 {
2685  data->speed = new_speed;
2686 }
2687 
2688 /** Get head_yaw value.
2689  * Head yaw
2690  * @return head_yaw value
2691  */
2692 float
2694 {
2695  return data->head_yaw;
2696 }
2697 
2698 /** Get maximum length of head_yaw value.
2699  * @return length of head_yaw value, can be length of the array or number of
2700  * maximum number of characters for a string
2701  */
2702 size_t
2704 {
2705  return 1;
2706 }
2707 
2708 /** Set head_yaw value.
2709  * Head yaw
2710  * @param new_head_yaw new head_yaw value
2711  */
2712 void
2714 {
2715  data->head_yaw = new_head_yaw;
2716 }
2717 
2718 /** Get head_pitch value.
2719  * Head pitch
2720  * @return head_pitch value
2721  */
2722 float
2724 {
2725  return data->head_pitch;
2726 }
2727 
2728 /** Get maximum length of head_pitch value.
2729  * @return length of head_pitch value, can be length of the array or number of
2730  * maximum number of characters for a string
2731  */
2732 size_t
2734 {
2735  return 1;
2736 }
2737 
2738 /** Set head_pitch value.
2739  * Head pitch
2740  * @param new_head_pitch new head_pitch value
2741  */
2742 void
2744 {
2745  data->head_pitch = new_head_pitch;
2746 }
2747 
2748 /** Get l_shoulder_pitch value.
2749  * Left shoulder pitch
2750  * @return l_shoulder_pitch value
2751  */
2752 float
2754 {
2755  return data->l_shoulder_pitch;
2756 }
2757 
2758 /** Get maximum length of l_shoulder_pitch value.
2759  * @return length of l_shoulder_pitch value, can be length of the array or number of
2760  * maximum number of characters for a string
2761  */
2762 size_t
2764 {
2765  return 1;
2766 }
2767 
2768 /** Set l_shoulder_pitch value.
2769  * Left shoulder pitch
2770  * @param new_l_shoulder_pitch new l_shoulder_pitch value
2771  */
2772 void
2774 {
2775  data->l_shoulder_pitch = new_l_shoulder_pitch;
2776 }
2777 
2778 /** Get l_shoulder_roll value.
2779  * Left shoulder roll
2780  * @return l_shoulder_roll value
2781  */
2782 float
2784 {
2785  return data->l_shoulder_roll;
2786 }
2787 
2788 /** Get maximum length of l_shoulder_roll value.
2789  * @return length of l_shoulder_roll value, can be length of the array or number of
2790  * maximum number of characters for a string
2791  */
2792 size_t
2794 {
2795  return 1;
2796 }
2797 
2798 /** Set l_shoulder_roll value.
2799  * Left shoulder roll
2800  * @param new_l_shoulder_roll new l_shoulder_roll value
2801  */
2802 void
2804 {
2805  data->l_shoulder_roll = new_l_shoulder_roll;
2806 }
2807 
2808 /** Get l_elbow_yaw value.
2809  * Left elbow yaw
2810  * @return l_elbow_yaw value
2811  */
2812 float
2814 {
2815  return data->l_elbow_yaw;
2816 }
2817 
2818 /** Get maximum length of l_elbow_yaw value.
2819  * @return length of l_elbow_yaw value, can be length of the array or number of
2820  * maximum number of characters for a string
2821  */
2822 size_t
2824 {
2825  return 1;
2826 }
2827 
2828 /** Set l_elbow_yaw value.
2829  * Left elbow yaw
2830  * @param new_l_elbow_yaw new l_elbow_yaw value
2831  */
2832 void
2834 {
2835  data->l_elbow_yaw = new_l_elbow_yaw;
2836 }
2837 
2838 /** Get l_elbow_roll value.
2839  * Left elbow roll
2840  * @return l_elbow_roll value
2841  */
2842 float
2844 {
2845  return data->l_elbow_roll;
2846 }
2847 
2848 /** Get maximum length of l_elbow_roll value.
2849  * @return length of l_elbow_roll value, can be length of the array or number of
2850  * maximum number of characters for a string
2851  */
2852 size_t
2854 {
2855  return 1;
2856 }
2857 
2858 /** Set l_elbow_roll value.
2859  * Left elbow roll
2860  * @param new_l_elbow_roll new l_elbow_roll value
2861  */
2862 void
2864 {
2865  data->l_elbow_roll = new_l_elbow_roll;
2866 }
2867 
2868 /** Get l_wrist_yaw value.
2869  * Left wrist yaw
2870  * @return l_wrist_yaw value
2871  */
2872 float
2874 {
2875  return data->l_wrist_yaw;
2876 }
2877 
2878 /** Get maximum length of l_wrist_yaw value.
2879  * @return length of l_wrist_yaw value, can be length of the array or number of
2880  * maximum number of characters for a string
2881  */
2882 size_t
2884 {
2885  return 1;
2886 }
2887 
2888 /** Set l_wrist_yaw value.
2889  * Left wrist yaw
2890  * @param new_l_wrist_yaw new l_wrist_yaw value
2891  */
2892 void
2894 {
2895  data->l_wrist_yaw = new_l_wrist_yaw;
2896 }
2897 
2898 /** Get l_hand value.
2899  * Left hand
2900  * @return l_hand value
2901  */
2902 float
2904 {
2905  return data->l_hand;
2906 }
2907 
2908 /** Get maximum length of l_hand value.
2909  * @return length of l_hand value, can be length of the array or number of
2910  * maximum number of characters for a string
2911  */
2912 size_t
2914 {
2915  return 1;
2916 }
2917 
2918 /** Set l_hand value.
2919  * Left hand
2920  * @param new_l_hand new l_hand value
2921  */
2922 void
2924 {
2925  data->l_hand = new_l_hand;
2926 }
2927 
2928 /** Get l_hip_yaw_pitch value.
2929  * Left hip yaw pitch
2930  * @return l_hip_yaw_pitch value
2931  */
2932 float
2934 {
2935  return data->l_hip_yaw_pitch;
2936 }
2937 
2938 /** Get maximum length of l_hip_yaw_pitch value.
2939  * @return length of l_hip_yaw_pitch value, can be length of the array or number of
2940  * maximum number of characters for a string
2941  */
2942 size_t
2944 {
2945  return 1;
2946 }
2947 
2948 /** Set l_hip_yaw_pitch value.
2949  * Left hip yaw pitch
2950  * @param new_l_hip_yaw_pitch new l_hip_yaw_pitch value
2951  */
2952 void
2954 {
2955  data->l_hip_yaw_pitch = new_l_hip_yaw_pitch;
2956 }
2957 
2958 /** Get l_hip_roll value.
2959  * Left hip roll
2960  * @return l_hip_roll value
2961  */
2962 float
2964 {
2965  return data->l_hip_roll;
2966 }
2967 
2968 /** Get maximum length of l_hip_roll value.
2969  * @return length of l_hip_roll value, can be length of the array or number of
2970  * maximum number of characters for a string
2971  */
2972 size_t
2974 {
2975  return 1;
2976 }
2977 
2978 /** Set l_hip_roll value.
2979  * Left hip roll
2980  * @param new_l_hip_roll new l_hip_roll value
2981  */
2982 void
2984 {
2985  data->l_hip_roll = new_l_hip_roll;
2986 }
2987 
2988 /** Get l_hip_pitch value.
2989  * Left hip pitch
2990  * @return l_hip_pitch value
2991  */
2992 float
2994 {
2995  return data->l_hip_pitch;
2996 }
2997 
2998 /** Get maximum length of l_hip_pitch value.
2999  * @return length of l_hip_pitch value, can be length of the array or number of
3000  * maximum number of characters for a string
3001  */
3002 size_t
3004 {
3005  return 1;
3006 }
3007 
3008 /** Set l_hip_pitch value.
3009  * Left hip pitch
3010  * @param new_l_hip_pitch new l_hip_pitch value
3011  */
3012 void
3014 {
3015  data->l_hip_pitch = new_l_hip_pitch;
3016 }
3017 
3018 /** Get l_knee_pitch value.
3019  * Left knee pitch
3020  * @return l_knee_pitch value
3021  */
3022 float
3024 {
3025  return data->l_knee_pitch;
3026 }
3027 
3028 /** Get maximum length of l_knee_pitch value.
3029  * @return length of l_knee_pitch value, can be length of the array or number of
3030  * maximum number of characters for a string
3031  */
3032 size_t
3034 {
3035  return 1;
3036 }
3037 
3038 /** Set l_knee_pitch value.
3039  * Left knee pitch
3040  * @param new_l_knee_pitch new l_knee_pitch value
3041  */
3042 void
3044 {
3045  data->l_knee_pitch = new_l_knee_pitch;
3046 }
3047 
3048 /** Get l_ankle_pitch value.
3049  * Left ankle pitch
3050  * @return l_ankle_pitch value
3051  */
3052 float
3054 {
3055  return data->l_ankle_pitch;
3056 }
3057 
3058 /** Get maximum length of l_ankle_pitch value.
3059  * @return length of l_ankle_pitch value, can be length of the array or number of
3060  * maximum number of characters for a string
3061  */
3062 size_t
3064 {
3065  return 1;
3066 }
3067 
3068 /** Set l_ankle_pitch value.
3069  * Left ankle pitch
3070  * @param new_l_ankle_pitch new l_ankle_pitch value
3071  */
3072 void
3074 {
3075  data->l_ankle_pitch = new_l_ankle_pitch;
3076 }
3077 
3078 /** Get l_ankle_roll value.
3079  * Left ankle roll
3080  * @return l_ankle_roll value
3081  */
3082 float
3084 {
3085  return data->l_ankle_roll;
3086 }
3087 
3088 /** Get maximum length of l_ankle_roll value.
3089  * @return length of l_ankle_roll value, can be length of the array or number of
3090  * maximum number of characters for a string
3091  */
3092 size_t
3094 {
3095  return 1;
3096 }
3097 
3098 /** Set l_ankle_roll value.
3099  * Left ankle roll
3100  * @param new_l_ankle_roll new l_ankle_roll value
3101  */
3102 void
3104 {
3105  data->l_ankle_roll = new_l_ankle_roll;
3106 }
3107 
3108 /** Get r_shoulder_pitch value.
3109  * Right shoulder pitch
3110  * @return r_shoulder_pitch value
3111  */
3112 float
3114 {
3115  return data->r_shoulder_pitch;
3116 }
3117 
3118 /** Get maximum length of r_shoulder_pitch value.
3119  * @return length of r_shoulder_pitch value, can be length of the array or number of
3120  * maximum number of characters for a string
3121  */
3122 size_t
3124 {
3125  return 1;
3126 }
3127 
3128 /** Set r_shoulder_pitch value.
3129  * Right shoulder pitch
3130  * @param new_r_shoulder_pitch new r_shoulder_pitch value
3131  */
3132 void
3134 {
3135  data->r_shoulder_pitch = new_r_shoulder_pitch;
3136 }
3137 
3138 /** Get r_shoulder_roll value.
3139  * Right shoulder roll
3140  * @return r_shoulder_roll value
3141  */
3142 float
3144 {
3145  return data->r_shoulder_roll;
3146 }
3147 
3148 /** Get maximum length of r_shoulder_roll value.
3149  * @return length of r_shoulder_roll value, can be length of the array or number of
3150  * maximum number of characters for a string
3151  */
3152 size_t
3154 {
3155  return 1;
3156 }
3157 
3158 /** Set r_shoulder_roll value.
3159  * Right shoulder roll
3160  * @param new_r_shoulder_roll new r_shoulder_roll value
3161  */
3162 void
3164 {
3165  data->r_shoulder_roll = new_r_shoulder_roll;
3166 }
3167 
3168 /** Get r_elbow_yaw value.
3169  * Right elbow yaw
3170  * @return r_elbow_yaw value
3171  */
3172 float
3174 {
3175  return data->r_elbow_yaw;
3176 }
3177 
3178 /** Get maximum length of r_elbow_yaw value.
3179  * @return length of r_elbow_yaw value, can be length of the array or number of
3180  * maximum number of characters for a string
3181  */
3182 size_t
3184 {
3185  return 1;
3186 }
3187 
3188 /** Set r_elbow_yaw value.
3189  * Right elbow yaw
3190  * @param new_r_elbow_yaw new r_elbow_yaw value
3191  */
3192 void
3194 {
3195  data->r_elbow_yaw = new_r_elbow_yaw;
3196 }
3197 
3198 /** Get r_elbow_roll value.
3199  * Right elbow roll
3200  * @return r_elbow_roll value
3201  */
3202 float
3204 {
3205  return data->r_elbow_roll;
3206 }
3207 
3208 /** Get maximum length of r_elbow_roll value.
3209  * @return length of r_elbow_roll value, can be length of the array or number of
3210  * maximum number of characters for a string
3211  */
3212 size_t
3214 {
3215  return 1;
3216 }
3217 
3218 /** Set r_elbow_roll value.
3219  * Right elbow roll
3220  * @param new_r_elbow_roll new r_elbow_roll value
3221  */
3222 void
3224 {
3225  data->r_elbow_roll = new_r_elbow_roll;
3226 }
3227 
3228 /** Get r_wrist_yaw value.
3229  * Right wrist yaw
3230  * @return r_wrist_yaw value
3231  */
3232 float
3234 {
3235  return data->r_wrist_yaw;
3236 }
3237 
3238 /** Get maximum length of r_wrist_yaw value.
3239  * @return length of r_wrist_yaw value, can be length of the array or number of
3240  * maximum number of characters for a string
3241  */
3242 size_t
3244 {
3245  return 1;
3246 }
3247 
3248 /** Set r_wrist_yaw value.
3249  * Right wrist yaw
3250  * @param new_r_wrist_yaw new r_wrist_yaw value
3251  */
3252 void
3254 {
3255  data->r_wrist_yaw = new_r_wrist_yaw;
3256 }
3257 
3258 /** Get r_hand value.
3259  * Right hand
3260  * @return r_hand value
3261  */
3262 float
3264 {
3265  return data->r_hand;
3266 }
3267 
3268 /** Get maximum length of r_hand value.
3269  * @return length of r_hand value, can be length of the array or number of
3270  * maximum number of characters for a string
3271  */
3272 size_t
3274 {
3275  return 1;
3276 }
3277 
3278 /** Set r_hand value.
3279  * Right hand
3280  * @param new_r_hand new r_hand value
3281  */
3282 void
3284 {
3285  data->r_hand = new_r_hand;
3286 }
3287 
3288 /** Get r_hip_yaw_pitch value.
3289  * Right hip yaw pitch
3290  * @return r_hip_yaw_pitch value
3291  */
3292 float
3294 {
3295  return data->r_hip_yaw_pitch;
3296 }
3297 
3298 /** Get maximum length of r_hip_yaw_pitch value.
3299  * @return length of r_hip_yaw_pitch value, can be length of the array or number of
3300  * maximum number of characters for a string
3301  */
3302 size_t
3304 {
3305  return 1;
3306 }
3307 
3308 /** Set r_hip_yaw_pitch value.
3309  * Right hip yaw pitch
3310  * @param new_r_hip_yaw_pitch new r_hip_yaw_pitch value
3311  */
3312 void
3314 {
3315  data->r_hip_yaw_pitch = new_r_hip_yaw_pitch;
3316 }
3317 
3318 /** Get r_hip_roll value.
3319  * Right hip roll
3320  * @return r_hip_roll value
3321  */
3322 float
3324 {
3325  return data->r_hip_roll;
3326 }
3327 
3328 /** Get maximum length of r_hip_roll value.
3329  * @return length of r_hip_roll value, can be length of the array or number of
3330  * maximum number of characters for a string
3331  */
3332 size_t
3334 {
3335  return 1;
3336 }
3337 
3338 /** Set r_hip_roll value.
3339  * Right hip roll
3340  * @param new_r_hip_roll new r_hip_roll value
3341  */
3342 void
3344 {
3345  data->r_hip_roll = new_r_hip_roll;
3346 }
3347 
3348 /** Get r_hip_pitch value.
3349  * Right hip pitch
3350  * @return r_hip_pitch value
3351  */
3352 float
3354 {
3355  return data->r_hip_pitch;
3356 }
3357 
3358 /** Get maximum length of r_hip_pitch value.
3359  * @return length of r_hip_pitch value, can be length of the array or number of
3360  * maximum number of characters for a string
3361  */
3362 size_t
3364 {
3365  return 1;
3366 }
3367 
3368 /** Set r_hip_pitch value.
3369  * Right hip pitch
3370  * @param new_r_hip_pitch new r_hip_pitch value
3371  */
3372 void
3374 {
3375  data->r_hip_pitch = new_r_hip_pitch;
3376 }
3377 
3378 /** Get r_knee_pitch value.
3379  * Right knee pitch
3380  * @return r_knee_pitch value
3381  */
3382 float
3384 {
3385  return data->r_knee_pitch;
3386 }
3387 
3388 /** Get maximum length of r_knee_pitch value.
3389  * @return length of r_knee_pitch value, can be length of the array or number of
3390  * maximum number of characters for a string
3391  */
3392 size_t
3394 {
3395  return 1;
3396 }
3397 
3398 /** Set r_knee_pitch value.
3399  * Right knee pitch
3400  * @param new_r_knee_pitch new r_knee_pitch value
3401  */
3402 void
3404 {
3405  data->r_knee_pitch = new_r_knee_pitch;
3406 }
3407 
3408 /** Get r_ankle_pitch value.
3409  * Right ankle pitch
3410  * @return r_ankle_pitch value
3411  */
3412 float
3414 {
3415  return data->r_ankle_pitch;
3416 }
3417 
3418 /** Get maximum length of r_ankle_pitch value.
3419  * @return length of r_ankle_pitch value, can be length of the array or number of
3420  * maximum number of characters for a string
3421  */
3422 size_t
3424 {
3425  return 1;
3426 }
3427 
3428 /** Set r_ankle_pitch value.
3429  * Right ankle pitch
3430  * @param new_r_ankle_pitch new r_ankle_pitch value
3431  */
3432 void
3434 {
3435  data->r_ankle_pitch = new_r_ankle_pitch;
3436 }
3437 
3438 /** Get r_ankle_roll value.
3439  * Right ankle roll
3440  * @return r_ankle_roll value
3441  */
3442 float
3444 {
3445  return data->r_ankle_roll;
3446 }
3447 
3448 /** Get maximum length of r_ankle_roll value.
3449  * @return length of r_ankle_roll value, can be length of the array or number of
3450  * maximum number of characters for a string
3451  */
3452 size_t
3454 {
3455  return 1;
3456 }
3457 
3458 /** Set r_ankle_roll value.
3459  * Right ankle roll
3460  * @param new_r_ankle_roll new r_ankle_roll value
3461  */
3462 void
3464 {
3465  data->r_ankle_roll = new_r_ankle_roll;
3466 }
3467 
3468 /** Clone this message.
3469  * Produces a message of the same type as this message and copies the
3470  * data to the new message.
3471  * @return clone of this message
3472  */
3473 Message *
3475 {
3477 }
3478 /** Check if message is valid and can be enqueued.
3479  * @param message Message to check
3480  * @return true if the message is valid, false otherwise.
3481  */
3482 bool
3484 {
3485  const SetServoMessage *m0 = dynamic_cast<const SetServoMessage *>(message);
3486  if ( m0 != NULL ) {
3487  return true;
3488  }
3489  const SetServosMessage *m1 = dynamic_cast<const SetServosMessage *>(message);
3490  if ( m1 != NULL ) {
3491  return true;
3492  }
3493  const MoveServoMessage *m2 = dynamic_cast<const MoveServoMessage *>(message);
3494  if ( m2 != NULL ) {
3495  return true;
3496  }
3497  const MoveServosMessage *m3 = dynamic_cast<const MoveServosMessage *>(message);
3498  if ( m3 != NULL ) {
3499  return true;
3500  }
3501  return false;
3502 }
3503 
3504 /// @cond INTERNALS
3505 EXPORT_INTERFACE(NaoJointPositionInterface)
3506 /// @endcond
3507 
3508 
3509 } // end namespace fawkes
static const uint32_t SERVO_l_shoulder_roll
SERVO_l_shoulder_roll constant.
void set_r_wrist_yaw(const float new_r_wrist_yaw)
Set r_wrist_yaw value.
size_t maxlenof_head_yaw() const
Get maximum length of head_yaw value.
size_t maxlenof_r_elbow_roll() const
Get maximum length of r_elbow_roll value.
void set_r_hip_pitch(const float new_r_hip_pitch)
Set r_hip_pitch value.
NaoJointPositionInterface Fawkes BlackBoard Interface.
size_t maxlenof_l_hip_roll() const
Get maximum length of l_hip_roll value.
void set_head_pitch(const float new_head_pitch)
Set head_pitch value.
static const uint32_t SERVO_l_ankle_roll
SERVO_l_ankle_roll constant.
SetServoMessage Fawkes BlackBoard Interface Message.
void set_l_hip_roll(const float new_l_hip_roll)
Set l_hip_roll value.
void set_l_hip_yaw_pitch(const float new_l_hip_yaw_pitch)
Set l_hip_yaw_pitch value.
void * data_ptr
Pointer to memory that contains local data.
Definition: message.h:124
static const uint32_t SERVO_min
SERVO_min constant.
size_t maxlenof_r_shoulder_roll() const
Get maximum length of r_shoulder_roll value.
size_t maxlenof_value() const
Get maximum length of value value.
void set_r_elbow_yaw(const float new_r_elbow_yaw)
Set r_elbow_yaw value.
size_t maxlenof_l_elbow_yaw() const
Get maximum length of l_elbow_yaw value.
size_t maxlenof_r_hip_roll() const
Get maximum length of r_hip_roll value.
Base class for all messages passed through interfaces in Fawkes BlackBoard.
Definition: message.h:44
size_t maxlenof_l_hip_pitch() const
Get maximum length of l_hip_pitch value.
static const uint32_t SERVO_l_hip_yaw_pitch
SERVO_l_hip_yaw_pitch constant.
size_t maxlenof_speed() const
Get maximum length of speed value.
SetServosMessage Fawkes BlackBoard Interface Message.
void set_l_hip_pitch(const float new_l_hip_pitch)
Set l_hip_pitch value.
void set_servo(const uint32_t new_servo)
Set servo value.
static const uint32_t SERVO_r_hip_roll
SERVO_r_hip_roll constant.
void set_l_ankle_pitch(const float new_l_ankle_pitch)
Set l_ankle_pitch value.
size_t maxlenof_head_pitch() const
Get maximum length of head_pitch value.
size_t maxlenof_l_hand() const
Get maximum length of l_hand value.
void set_l_elbow_roll(const float new_l_elbow_roll)
Set l_elbow_roll value.
void set_l_knee_pitch(const float new_l_knee_pitch)
Set l_knee_pitch value.
void set_value(const float new_value)
Set value value.
size_t maxlenof_r_hip_roll() const
Get maximum length of r_hip_roll value.
size_t maxlenof_l_shoulder_roll() const
Get maximum length of l_shoulder_roll value.
static const uint32_t SERVO_max
SERVO_max constant.
size_t maxlenof_speed() const
Get maximum length of speed value.
void set_speed(const float new_speed)
Set speed value.
size_t maxlenof_l_knee_pitch() const
Get maximum length of l_knee_pitch value.
size_t maxlenof_time() const
Get maximum length of time value.
Fawkes library namespace.
void set_r_knee_pitch(const float new_r_knee_pitch)
Set r_knee_pitch value.
size_t maxlenof_l_hip_pitch() const
Get maximum length of l_hip_pitch value.
void set_l_wrist_yaw(const float new_l_wrist_yaw)
Set l_wrist_yaw value.
void set_time(const int32_t new_time)
Set time value.
static const uint32_t SERVO_l_wrist_yaw
SERVO_l_wrist_yaw constant.
Timestamp data, must be present and first entries for each interface data structs! This leans on time...
Definition: message.h:129
void set_l_elbow_yaw(const float new_l_elbow_yaw)
Set l_elbow_yaw value.
size_t maxlenof_l_ankle_pitch() const
Get maximum length of l_ankle_pitch value.
size_t maxlenof_r_knee_pitch() const
Get maximum length of r_knee_pitch value.
void set_r_shoulder_roll(const float new_r_shoulder_roll)
Set r_shoulder_roll value.
size_t maxlenof_l_shoulder_pitch() const
Get maximum length of l_shoulder_pitch value.
void set_l_knee_pitch(const float new_l_knee_pitch)
Set l_knee_pitch value.
void set_r_ankle_roll(const float new_r_ankle_roll)
Set r_ankle_roll value.
MoveServosMessage Fawkes BlackBoard Interface Message.
size_t maxlenof_r_knee_pitch() const
Get maximum length of r_knee_pitch value.
void set_r_elbow_roll(const float new_r_elbow_roll)
Set r_elbow_roll value.
float l_shoulder_pitch() const
Get l_shoulder_pitch value.
size_t maxlenof_l_hip_yaw_pitch() const
Get maximum length of l_hip_yaw_pitch value.
void set_l_ankle_roll(const float new_l_ankle_roll)
Set l_ankle_roll value.
void set_l_shoulder_roll(const float new_l_shoulder_roll)
Set l_shoulder_roll value.
void set_r_ankle_pitch(const float new_r_ankle_pitch)
Set r_ankle_pitch value.
size_t maxlenof_value() const
Get maximum length of value value.
size_t maxlenof_r_elbow_yaw() const
Get maximum length of r_elbow_yaw value.
void set_l_wrist_yaw(const float new_l_wrist_yaw)
Set l_wrist_yaw value.
void set_r_shoulder_pitch(const float new_r_shoulder_pitch)
Set r_shoulder_pitch value.
static const uint32_t SERVO_l_elbow_yaw
SERVO_l_elbow_yaw constant.
size_t maxlenof_l_elbow_roll() const
Get maximum length of l_elbow_roll value.
size_t maxlenof_r_elbow_roll() const
Get maximum length of r_elbow_roll value.
void set_l_ankle_roll(const float new_l_ankle_roll)
Set l_ankle_roll value.
Base class for all Fawkes BlackBoard interfaces.
Definition: interface.h:79
size_t maxlenof_l_elbow_yaw() const
Get maximum length of l_elbow_yaw value.
void set_l_hand(const float new_l_hand)
Set l_hand value.
size_t maxlenof_r_shoulder_pitch() const
Get maximum length of r_shoulder_pitch value.
virtual Message * clone() const
Clone this message.
size_t maxlenof_l_ankle_roll() const
Get maximum length of l_ankle_roll value.
virtual Message * clone() const
Clone this message.
float r_shoulder_pitch() const
Get r_shoulder_pitch value.
size_t maxlenof_l_wrist_yaw() const
Get maximum length of l_wrist_yaw value.
void set_r_elbow_roll(const float new_r_elbow_roll)
Set r_elbow_roll value.
void set_value(const float new_value)
Set value value.
size_t maxlenof_servo() const
Get maximum length of servo value.
Academic version with 25 DoF and touch sensors.
float l_shoulder_roll() const
Get l_shoulder_roll value.
size_t maxlenof_r_hand() const
Get maximum length of r_hand value.
size_t maxlenof_r_ankle_roll() const
Get maximum length of r_ankle_roll value.
static const uint32_t SERVO_l_ankle_pitch
SERVO_l_ankle_pitch constant.
message_data_ts_t * data_ts
data timestamp aliasing pointer
Definition: message.h:133
void set_r_hip_yaw_pitch(const float new_r_hip_yaw_pitch)
Set r_hip_yaw_pitch value.
size_t maxlenof_r_shoulder_pitch() const
Get maximum length of r_shoulder_pitch value.
unsigned int data_size
Size of memory needed to hold all data.
Definition: message.h:125
virtual bool message_valid(const Message *message) const
Check if message is valid and can be enqueued.
size_t maxlenof_r_ankle_roll() const
Get maximum length of r_ankle_roll value.
static const uint32_t SERVO_l_shoulder_pitch
SERVO_l_shoulder_pitch constant.
size_t maxlenof_r_wrist_yaw() const
Get maximum length of r_wrist_yaw value.
void set_l_hip_yaw_pitch(const float new_l_hip_yaw_pitch)
Set l_hip_yaw_pitch value.
void set_l_hand(const float new_l_hand)
Set l_hand value.
void set_r_shoulder_roll(const float new_r_shoulder_roll)
Set r_shoulder_roll value.
size_t maxlenof_l_hand() const
Get maximum length of l_hand value.
size_t maxlenof_r_hip_pitch() const
Get maximum length of r_hip_pitch value.
size_t maxlenof_time() const
Get maximum length of time value.
static const uint32_t SERVO_l_knee_pitch
SERVO_l_knee_pitch constant.
size_t maxlenof_r_hip_yaw_pitch() const
Get maximum length of r_hip_yaw_pitch value.
void set_l_elbow_roll(const float new_l_elbow_roll)
Set l_elbow_roll value.
const char * type() const
Get type of interface.
Definition: interface.cpp:651
static const uint32_t SERVO_r_hand
SERVO_r_hand constant.
static const uint32_t SERVO_r_ankle_roll
SERVO_r_ankle_roll constant.
void set_r_elbow_yaw(const float new_r_elbow_yaw)
Set r_elbow_yaw value.
virtual Message * clone() const
Clone this message.
Base class for exceptions in Fawkes.
Definition: exception.h:36
void set_servo(const uint32_t new_servo)
Set servo value.
virtual Message * clone() const
Clone this message.
size_t maxlenof_r_hip_yaw_pitch() const
Get maximum length of r_hip_yaw_pitch value.
float r_shoulder_roll() const
Get r_shoulder_roll value.
size_t maxlenof_head_pitch() const
Get maximum length of head_pitch value.
void set_head_yaw(const float new_head_yaw)
Set head_yaw value.
void set_l_shoulder_roll(const float new_l_shoulder_roll)
Set l_shoulder_roll value.
void set_r_ankle_roll(const float new_r_ankle_roll)
Set r_ankle_roll value.
void set_r_ankle_pitch(const float new_r_ankle_pitch)
Set r_ankle_pitch value.
void set_head_pitch(const float new_head_pitch)
Set head_pitch value.
size_t maxlenof_l_hip_roll() const
Get maximum length of l_hip_roll value.
size_t maxlenof_l_shoulder_pitch() const
Get maximum length of l_shoulder_pitch value.
static const uint32_t SERVO_r_ankle_pitch
SERVO_r_ankle_pitch constant.
void set_r_hip_roll(const float new_r_hip_roll)
Set r_hip_roll value.
static const uint32_t SERVO_r_elbow_yaw
SERVO_r_elbow_yaw constant.
size_t maxlenof_l_shoulder_roll() const
Get maximum length of l_shoulder_roll value.
static const uint32_t SERVO_l_elbow_roll
SERVO_l_elbow_roll constant.
static const uint32_t SERVO_r_knee_pitch
SERVO_r_knee_pitch constant.
static const uint32_t SERVO_l_hand
SERVO_l_hand constant.
void set_r_hip_roll(const float new_r_hip_roll)
Set r_hip_roll value.
size_t maxlenof_l_wrist_yaw() const
Get maximum length of l_wrist_yaw value.
float field
Definition: types.h:45
float r_shoulder_pitch() const
Get r_shoulder_pitch value.
static const uint32_t SERVO_r_elbow_roll
SERVO_r_elbow_roll constant.
void set_r_hip_yaw_pitch(const float new_r_hip_yaw_pitch)
Set r_hip_yaw_pitch value.
float l_shoulder_pitch() const
Get l_shoulder_pitch value.
32 bit integer field
Definition: types.h:41
static const uint32_t SERVO_r_shoulder_pitch
SERVO_r_shoulder_pitch constant.
static const uint32_t SERVO_head_pitch
SERVO_head_pitch constant.
float r_hip_yaw_pitch() const
Get r_hip_yaw_pitch value.
size_t maxlenof_r_hand() const
Get maximum length of r_hand value.
size_t maxlenof_r_elbow_yaw() const
Get maximum length of r_elbow_yaw value.
void set_l_hip_roll(const float new_l_hip_roll)
Set l_hip_roll value.
void set_l_shoulder_pitch(const float new_l_shoulder_pitch)
Set l_shoulder_pitch value.
static const uint32_t SERVO_l_hip_pitch
SERVO_l_hip_pitch constant.
size_t maxlenof_r_shoulder_roll() const
Get maximum length of r_shoulder_roll value.
void set_r_shoulder_pitch(const float new_r_shoulder_pitch)
Set r_shoulder_pitch value.
void set_r_knee_pitch(const float new_r_knee_pitch)
Set r_knee_pitch value.
size_t maxlenof_r_ankle_pitch() const
Get maximum length of r_ankle_pitch value.
void set_l_shoulder_pitch(const float new_l_shoulder_pitch)
Set l_shoulder_pitch value.
void set_l_ankle_pitch(const float new_l_ankle_pitch)
Set l_ankle_pitch value.
size_t maxlenof_r_ankle_pitch() const
Get maximum length of r_ankle_pitch value.
size_t maxlenof_l_hip_yaw_pitch() const
Get maximum length of l_hip_yaw_pitch value.
MoveServoMessage Fawkes BlackBoard Interface Message.
void set_head_yaw(const float new_head_yaw)
Set head_yaw value.
void set_r_hand(const float new_r_hand)
Set r_hand value.
void set_l_elbow_yaw(const float new_l_elbow_yaw)
Set l_elbow_yaw value.
void set_speed(const float new_speed)
Set speed value.
size_t maxlenof_r_wrist_yaw() const
Get maximum length of r_wrist_yaw value.
static const uint32_t SERVO_r_hip_pitch
SERVO_r_hip_pitch constant.
static const uint32_t SERVO_r_hip_yaw_pitch
SERVO_r_hip_yaw_pitch constant.
void set_r_hip_pitch(const float new_r_hip_pitch)
Set r_hip_pitch value.
size_t maxlenof_l_ankle_pitch() const
Get maximum length of l_ankle_pitch value.
static const uint32_t SERVO_r_wrist_yaw
SERVO_r_wrist_yaw constant.
size_t maxlenof_servo() const
Get maximum length of servo value.
void set_r_wrist_yaw(const float new_r_wrist_yaw)
Set r_wrist_yaw value.
size_t maxlenof_r_hip_pitch() const
Get maximum length of r_hip_pitch value.
void add_fieldinfo(interface_fieldtype_t type, const char *name, size_t length, void *value, const char *enumtype=0, const interface_enum_map_t *enum_map=0)
Add an entry to the info list.
Definition: message.cpp:436
void set_l_hip_pitch(const float new_l_hip_pitch)
Set l_hip_pitch value.
float l_hip_yaw_pitch() const
Get l_hip_yaw_pitch value.
void set_r_hand(const float new_r_hand)
Set r_hand value.
size_t maxlenof_l_knee_pitch() const
Get maximum length of l_knee_pitch value.
size_t maxlenof_head_yaw() const
Get maximum length of head_yaw value.
static const uint32_t SERVO_head_yaw
SERVO_head_yaw constant.
void set_time(const int32_t new_time)
Set time value.
size_t maxlenof_l_ankle_roll() const
Get maximum length of l_ankle_roll value.
static const uint32_t SERVO_l_hip_roll
SERVO_l_hip_roll constant.
static const uint32_t SERVO_r_shoulder_roll
SERVO_r_shoulder_roll constant.
32 bit unsigned integer field
Definition: types.h:42
size_t maxlenof_l_elbow_roll() const
Get maximum length of l_elbow_roll value.
RobotType
Enumeration describing the actual version of the robot that&#39;s being used.