Project

General

Profile

Revision a8480867

IDa84808670408804bf5ce08741a3b59130351928f
Parent 2814387f
Child 42e8c915

Added by Alex Zirbel over 12 years ago

Made a lot of changes to the general structure.

Applied object-orienting techniques to the code, cleaning it up considerably. Major design changes are as follows:

  • All separate node code (ie motors) are meant to only interface with hardware - doing as little logic as possible.
  • Instead, the logic is moved to a class (ie MotorControl) in libscout. PID and other tools should be located here. This significantly reduces dependencies.
  • Files can be included cross-package by being placed in /include/packagename, but this should be avoided to reduce dependencies.

A few formatting changes:

  • Comments should end with / always, not */
  • Use @ instead of \
  • No double newlines.

The motors node is revamped and pretty much correct at this point.

View differences:

scout/libscout/src/behavior.cpp
71 71
    msg.bl_speed = 125;
72 72
    msg.fr_speed = 125;
73 73
    msg.br_speed = 125;
74
    msg.which = 0;
75 74
    msg.units = MOTOR_ABSOLUTE;
76 75

  
77 76
    /* publish */

Also available in: Unified diff