Revision 14736c0c
Updated motors.cpp and motors.h with small stylistic changes.
scout/motors/src/motors.cpp | ||
---|---|---|
201 | 201 |
motors_query); |
202 | 202 |
|
203 | 203 |
/* Subscribe to the set_motors topic */ |
204 |
ros::Subscriber sub0 = n.subscribe("set_motors", 4, motors_set);
|
|
204 |
ros::Subscriber sub0 = n.subscribe("set_motors", QUEUE_SIZE, motors_set);
|
|
205 | 205 |
|
206 | 206 |
/* Initialize hardware for motors */ |
207 | 207 |
// Hardware init functions here |
scout/motors/src/motors.h | ||
---|---|---|
65 | 65 |
#define MOTOR_CMS 'c' |
66 | 66 |
#define MOTOR_ABSOLUTE 'a' |
67 | 67 |
|
68 |
/* The number of messages in the queue. If messages arrive faster than they are |
|
69 |
* handled, old ones are thrown out */ |
|
70 |
#define QUEUE_SIZE 4 |
|
71 |
|
|
68 | 72 |
|
69 | 73 |
/** @brief Initialize the motors module and driver. **/ |
70 | 74 |
int main(int argc, char **argv); |
Also available in: Unified diff