Chassis Model Help

I am attempting to make a three-encoder skid steer chassis model. I am doing exactly what the documentation shows, but it still says I am using a non-existing constructor. What am I doing wrong?

#include "main.h"
using namespace okapi;
pros::Motor LeftDriveFront(1);
pros::Motor LeftDriveBack(2);
pros::Motor RightDriveFront(3);
pros::Motor RightDriveBack(4);
pros::Imu Inertial(5);
pros::ADIEncoder LeftTrack(1, 2);
pros::ADIEncoder RightTrack(3, 4);
pros::ADIEncoder BackTrack(5, 6);


okapi::MotorGroup LeftDrive({1, 2});
okapi::MotorGroup RightDrive({3, 4});
static ThreeEncoderSkidSteerModel ControllerChassis(LeftDriveFront, RightDriveFront, LeftTrack, BackTrack, RightTrack, 100.0, 12000.0);

Here’s the documentation:
Capture

You are probably better off using the ChassisControllerBuilder than instantiating one directly:

https://okapilib.github.io/OkapiLib/md_docs_tutorials_walkthrough_chassisControllerBuilder.html

See also their notes about where to do this and what scope to use for the object:

https://okapilib.github.io/OkapiLib/md_docs_tutorials_concepts_builders-and-tasks.html

3 Likes