Mario Simaremare
/
g3_waterplay
Salinity and temperature sensors are implemented in classes.
Tank.cpp
- Committer:
- mariosimaremare
- Date:
- 2016-06-17
- Revision:
- 4:d8914369bf82
- Parent:
- 3:7c648d1d8802
- Child:
- 6:931a7fe8fa52
File content as of revision 4:d8914369bf82:
/* * G3: WATERPLAY */ #include "Printer.h" #include "Tank.h" #include "mbed.h" Tank::Tank( Printer &printer, DRV8825 &salinitySyringe, DRV8825 &waterSyringe ): _printer(printer), _salinitySyringe(salinitySyringe), _waterSyringe(waterSyringe), _previous_direction_salt(-1), _previous_direction_pure(-1), _position_salt(14), _position_pure(27) { } void Tank::add(int type, int mililiters, int direction) { mililiters *= POSITION_MIN; }