diff --git a/Arduino/Things/DRV8833.cpp b/Arduino/Things/DRV8833.cpp index 26cc8c1..d90492e 100644 --- a/Arduino/Things/DRV8833.cpp +++ b/Arduino/Things/DRV8833.cpp @@ -3,11 +3,9 @@ #include namespace RoboidControl { +namespace Arduino { -DRV8833Motor::DRV8833Motor(Participant* participant, - unsigned char pinIn1, - unsigned char pinIn2, - bool reverse) +DRV8833Motor::DRV8833Motor(Participant* participant, unsigned char pinIn1, unsigned char pinIn2, bool reverse) : Thing(participant) { this->pinIn1 = pinIn1; this->pinIn2 = pinIn2; @@ -47,7 +45,7 @@ void DRV8833Motor::SetAngularVelocity(Spherical velocity) { if (velocity.direction.horizontal.InDegrees() < 0) motorSpeed = -motorSpeed; if (this->reverse) - motorSpeed =-motorSpeed; + motorSpeed = -motorSpeed; // std::cout << "ang speed " << this->name << " = " << angularSpeed << " rpm " << rpm // << ", motor signal = " << (int)motorSignal << "\n"; @@ -118,4 +116,5 @@ DRV8833::DRV8833(Participant* participant, this->motorB->name = "Motor B"; } +} // namespace Arduino } // namespace RoboidControl \ No newline at end of file