![]() |
1516X Push Back 1.0
1516X's robot code for the 2025-2026 VEX Robotics Competition
|
#include "main.h"#include "globals.h"#include "pros/misc.h"#include "lemlib/api.hpp"#include "lemlib/util.hpp"#include "MCL.h"#include "pros/motors.h"#include "pros/rtos.hpp"#include <cmath>#include "colorSort.h"Go to the source code of this file.
Functions | |
| void | intake (int power=12000) |
| void | outtake (int power=12000) |
| void | score_bottomgoal (int power=12000) |
| void | score_longgoal (int power=12000, Color allianceColor=Color::RED) |
| void | intake_stop () |
| void | score_midgoal (int power=12000) |
| void | score_longgoal_auton (int power=12000, Color allianceColor=Color::RED) |
| void | intake_to_basket () |
| void | resting_state (bool trapDoor_commanded=false) |
| void | matchload_state (bool state) |
| void | longgoal_prep () |
| void | reset_odometry () |
| void | matchload_wiggle (int time=1000, int speed=100) |
| void | MCL_reset (bool x=true, bool y=true) |
| void | fusion_loop_fn (void *ignore) |
| void | enable_fused_odometry (bool enable) |
| void | relativeMotion (float expected_x, float expected_y, float expected_theta, float distance, int timeout_ms, bool forw=true, float earlyExit=0) |
| void | matchload_counter (int balls, int time_ms) |
Variables | |
| pros::Task * | fusionTask = nullptr |
| void enable_fused_odometry | ( | bool | enable | ) |
Definition at line 170 of file autonFunctions.cpp.
References fusion_loop_fn(), and fusionTask.
| void fusion_loop_fn | ( | void * | ignore | ) |
Definition at line 148 of file autonFunctions.cpp.
References chassis, MCL::particle_mutex, MCL::X, and MCL::Y.
Referenced by enable_fused_odometry().
| void intake | ( | int | power = 12000 | ) |
Definition at line 12 of file autonFunctions.cpp.
References intakeMotor(), and topMotor().
Referenced by awp_auton(), carry_auton(), intake_to_basket(), left_auton(), opcontrol(), right_auton(), score_longgoal(), and score_midgoal().
| void intake_stop | ( | ) |
Definition at line 46 of file autonFunctions.cpp.
References intakeMotor(), and topMotor().
Referenced by awp_auton(), carry_auton(), left_auton(), matchload_counter(), resting_state(), and right_auton().
| void intake_to_basket | ( | ) |
Definition at line 80 of file autonFunctions.cpp.
References intake(), and topMotor().
Referenced by opcontrol().
| void longgoal_prep | ( | ) |
Definition at line 112 of file autonFunctions.cpp.
| void matchload_counter | ( | int | balls, |
| int | time_ms ) |
Definition at line 195 of file autonFunctions.cpp.
References frontDistance(), and intake_stop().
| void matchload_state | ( | bool | state | ) |
Definition at line 97 of file autonFunctions.cpp.
References matchload().
Referenced by awp_auton(), carry_auton(), left_auton(), and right_auton().
| void matchload_wiggle | ( | int | time = 1000, |
| int | speed = 100 ) |
Definition at line 122 of file autonFunctions.cpp.
References leftMotors, and rightMotors.
| void MCL_reset | ( | bool | x = true, |
| bool | y = true ) |
Definition at line 137 of file autonFunctions.cpp.
References chassis, MCL::particle_mutex, MCL::X, and MCL::Y.
| void outtake | ( | int | power = 12000 | ) |
Definition at line 19 of file autonFunctions.cpp.
References intakeMotor().
Referenced by opcontrol(), and score_midgoal().
| void relativeMotion | ( | float | expected_x, |
| float | expected_y, | ||
| float | expected_theta, | ||
| float | distance, | ||
| int | timeout_ms, | ||
| bool | forw = true, | ||
| float | earlyExit = 0 ) |
Definition at line 184 of file autonFunctions.cpp.
References chassis.
Referenced by right_auton().
| void reset_odometry | ( | ) |
Definition at line 117 of file autonFunctions.cpp.
| void resting_state | ( | bool | trapDoor_commanded = false | ) |
Definition at line 88 of file autonFunctions.cpp.
References descore(), intake_stop(), topMotor(), and trapDoor().
Referenced by awp_auton(), left_auton(), opcontrol(), and right_auton().
| void score_bottomgoal | ( | int | power = 12000 | ) |
Definition at line 24 of file autonFunctions.cpp.
References intakeMotor().
| void score_longgoal | ( | int | power = 12000, |
| Color | allianceColor = Color::RED ) |
Definition at line 29 of file autonFunctions.cpp.
References allianceColor, color_sort_enable, get_color(), intake(), and topMotor().
Referenced by opcontrol(), and score_longgoal_auton().
| void score_longgoal_auton | ( | int | power = 12000, |
| Color | allianceColor = Color::RED ) |
Definition at line 73 of file autonFunctions.cpp.
References allianceColor, leftMotors, rightMotors, and score_longgoal().
Referenced by awp_auton(), carry_auton(), left_auton(), and right_auton().
| void score_midgoal | ( | int | power = 12000 | ) |
Definition at line 52 of file autonFunctions.cpp.
References allianceColor, color_sort_enable, get_color(), intake(), midgoal_first, outtake(), topMotor(), and trapDoor().
Referenced by awp_auton(), and opcontrol().
| pros::Task* fusionTask = nullptr |
Definition at line 146 of file autonFunctions.cpp.
Referenced by enable_fused_odometry().