changed mpu6050 code to class for better abstraction
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
#include "lights.h"
|
||||
#include "steeringCurves.h"
|
||||
#include "balancing.h"
|
||||
|
||||
#include "MPU6050.h"
|
||||
|
||||
#include "MC34933.h"
|
||||
#include "PWMFrequency.h"
|
||||
@@ -121,7 +121,7 @@ bool motorBrakeActive(motor_t motor)
|
||||
return getMotorptr(motor)->brakeActive();
|
||||
}
|
||||
|
||||
void drive()
|
||||
void drive(_mpu* mpu)
|
||||
{
|
||||
vehicleConfig* cfg = getConfigptr();
|
||||
|
||||
@@ -135,7 +135,7 @@ void drive()
|
||||
|
||||
case carwithMRSC:
|
||||
{
|
||||
mrsc(); // Car with MSRC stabilty control
|
||||
mrsc(mpu); // Car with MSRC stabilty control
|
||||
}
|
||||
break;
|
||||
|
||||
@@ -147,7 +147,7 @@ void drive()
|
||||
|
||||
case balancingthing:
|
||||
{
|
||||
balancing(); // Self balancing robot
|
||||
balancing(mpu); // Self balancing robot
|
||||
}
|
||||
break;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user