1516b Over Under 2.0
Codebase for 1516b over under season
Loading...
Searching...
No Matches
intake.cpp
Go to the documentation of this file.
1#include "robot/intake.h"
2#include "api.h"
3#include "globals.h"
4
5using namespace Robot::Globals;
6
7void Robot::Intake::run(){
8 if (controller.get_digital(pros::E_CONTROLLER_DIGITAL_L1)) {
9 IntakeMotor.move(127);
10 }
11 else if (controller.get_digital(pros::E_CONTROLLER_DIGITAL_R1)) {
12 IntakeMotor.move(-127);
13 }
14 else {
15 IntakeMotor.brake();
16 }
17}
The Intake class represents a robot intake system.
Definition intake.h:8
void run()
Runs the main function of the intake system.
Definition intake.cpp:7
Contains global variables and type definitions for the Robot namespace.
Definition globals.cpp:18
pros::Controller controller
pros::Motor IntakeMotor
Contains all objects generated by the 1516B team - Contains all of the subsystems,...
Definition globals.cpp:17