Skip to content

Conversation

@joshuasrjc
Copy link
Collaborator

@joshuasrjc joshuasrjc commented Aug 13, 2016

  • Compiles on PC
  • Compiles on Teensy

Added

  • ArduinoDummy
    • A class with some Arduino dummy functions, so we don't have to use #ifdef blocks every time we want to call a function like digitalWrite().
  • Memory
    • Addresses 0-31 in the memory class are now used for motor calibration data. Added constants for address locations.
  • Motor
    • calibrate()
      • For each direction, calculates the lowest voltage that still turns the motor.
    • loadCalibration()
    • Loads the calibration data from memory.
    • saveCalibration()
      • Saves the calibration data to memory.
    • setVoltage()
      • Where setMovement() takes a value between -1 and 1, setVoltage() takes an int between 0 and 255. It directly sets the PWM pin, but not lower than the minimum calibrated voltage.
  • RobotIO
    • calibrateMotors()
      • Calibrates the left and right motors, and saves the data.
  • Timer
    • sleep()
      • Sleeps for a given number of seconds.

Changed

  • Controller::debug() now calls testMotors() instead of mapMaze()
  • As long as speed != 0, Motor::setMovement() will move at the slowest calibrated speed.
  • MouseBot::robotIO is now public.

Removed

  • A bunch of #ifdef blocks from Motor.cpp

blhough and others added 8 commits July 17, 2016 17:15
[x] Compiles on PC

[x] Compiles on Teensy

### Added
* ArduinoDummy

* A class with some Arduino dummy functions, so we don't have to use
#ifdef blocks every time we want to call a function like
digitalWrite().

* Memory
  * Addresses 0-31 in the memory class are now
used for motor calibration data. Added constants for address
locations.

* Motor
    * calibrate()
        * For each direction,
calculates the lowest voltage that still turns the motor.
    *
loadCalibration()
        * Loads the calibration data from memory.

* saveCalibration()
        * Saves the calibration data to memory.

* setVoltage()
        * Where setMovement() takes a value between -1
and 1, setVoltage() takes an int between 0 and 255. It directly sets the
PWM pin, but not lower than the minimum calibrated voltage.
* RobotIO

* calibrateMotors()
        * Calibrates the left and right motors, and
saves the data.
* Timer
    * sleep()
        * Sleeps for a given
number of seconds.
# Changed
* Controller::debug() now calls
testMotors() instead of mapMaze()
* As long as speed != 0,
Motor::setMovement() will move at the slowest calibrated speed.
*
MouseBot::robotIO is now public.

# Removed
* A bunch of #ifdef blocks
from Motor.cpp
leftMotor.setMaxSpeed(1.0f);
timer.start();
pid.start(millimeters);
float avgMove = 10000000000000000000000000000000000000.0f;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I hate this line

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It's getting removed in the next pull request.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants