gusimplewhiteboard
wb_giraff_main_serial.h
Go to the documentation of this file.
1
9#ifndef wb_giraff_main_serial_h
10#define wb_giraff_main_serial_h
11
12#include <gu_util.h>
13
18{
21 Arc = 51
22};
23
28{
32};
33
39{
41 CONTROLLED_PROPERTY(float, velocity)
42
43
44 CONTROLLED_PROPERTY(enum Giraff_MovementType, movement_type)
45
46
47 CONTROLLED_PROPERTY(float, acceleration)
48
50 CONTROLLED_PROPERTY(float, position)
51
54
56 CONTROLLED_PROPERTY(float, head_angle)
57
59 CONTROLLED_PROPERTY(float, max_gear_ratio)
60
62 CONTROLLED_PROPERTY(float, gear_ratio_increments)
63
65 CONTROLLED_PROPERTY(float, gear_ratio_slowdown_dist)
66
68 CONTROLLED_PROPERTY(float, current_gear_ratio)
69
71 CONTROLLED_PROPERTY(int16_t, red_button_presses)
72
74 CONTROLLED_PROPERTY(int16_t, blue_button_presses)
75
77 CONTROLLED_PROPERTY(int16_t, dial_increments)
78
80 PROPERTY(int16_t, padding)
81
83 CONTROLLED_PROPERTY(int32_t, left_motor_encoder_ticks)
84
86 CONTROLLED_PROPERTY(int32_t, right_motor_encoder_ticks)
87
89 CONTROLLED_PROPERTY(int32_t, head_motor_encoder_ticks)
90
92 //CONTROLLED_PROPERTY(multiple, charger_data)
93
95 CONTROL_BIT(velocity)
96
98 CONTROL_BIT(movement_type)
99
101 CONTROL_BIT(acceleration)
102
104 CONTROL_BIT(position)
105
107 CONTROL_BIT(coord_type)
108
110 CONTROL_BIT(head_angle)
111
113 CONTROL_BIT(max_gear_ratio)
114
116 CONTROL_BIT(gear_ratio_increments)
117
119 CONTROL_BIT(gear_ratio_slowdown_dist)
120
122 CONTROL_BIT(current_gear_ratio)
123
125 CONTROL_BIT(red_button_presses)
126
128 CONTROL_BIT(blue_button_presses)
129
131 CONTROL_BIT(dial_increments)
132
134 CONTROL_BIT(left_motor_encoder_ticks)
135
137 CONTROL_BIT(right_motor_encoder_ticks)
138
140 CONTROL_BIT(head_motor_encoder_ticks)
141
143 PROPERTY(int16_t, padding2)
144
145#ifdef __cplusplus
150 {
151 memset(this, 0, sizeof(*this));
152 }
153#endif
154};
155
156#endif //_wb_giraff_main_serial_h
Serial interface for the main giraff board.
CONTROLLED_PROPERTY(float, velocity) CONTROLLED_PROPERTY(enum Giraff_MovementType
Giraff maximum velocity , Unit: m/s, Range: 0.0 / 150.0, Setter: Yes, Getter: Yes.
movement_type position head_angle gear_ratio_increments current_gear_ratio blue_button_presses padding right_motor_encoder_ticks padding2 wb_giraff_main_serial()
stuct constructor
Giraff_CoordType
Controls when position uses relative and absolute distances (absolute is based on odometry and is res...
@ BufferedAbsolute_Coords
Distances are absolute however commands are blocking and wait for previous commands to finish (buffer...
@ Relative_Coords
Distances passed to position are relative to the current position.
@ Absolute_Coords
Distances to be are relative to the odometry zero position (odometry is reset when this is toggled to...
Giraff_MovementType
/file wb_giraff_main_serial.h
@ Rotation
Giraff rotates when position is set (deg/sec)
@ Arc
Giraff arcs based on vg and position (position forward and backwards (m/s) and vg controls the wheel ...
@ Straight
Giraff moves forward and backwards via position (m/sec)