CityU Dream Development
Dependencies: mbed ros_lib_melodic
OmniWheel.cpp
- Committer:
- bensonsinsin998
- Date:
- 2021-02-25
- Revision:
- 0:c2b6f8b48076
File content as of revision 0:c2b6f8b48076:
// Mbed Library #include <vector> // Header File #include "OmniWheel.h" using namespace std; // Constructor OmniWheel::OmniWheel() { } // Destructor OmniWheel::~OmniWheel() { } // Function void OmniWheel::clear() { this->vel.clear(); this->rpm.clear(); this->pwm.clear(); } // -> Getter int OmniWheel::getWheelNum() { return this->wheel_num; } vector<double> OmniWheel::getVel() { return this->vel; } vector<double> OmniWheel::getRpm() { return this->rpm; } vector<double> OmniWheel::getPwm() { return this->pwm; } // -> Setter void OmniWheel::setWheelNum(int _wheel_num) { this->wheel_num = _wheel_num; } void OmniWheel::setVel(double _vel) { this->vel.push_back(_vel); } void OmniWheel::setRpm(double _rpm) { this->rpm.push_back(_rpm); } void OmniWheel::setPwm(double _pwm) { this->pwm.push_back(_pwm); }