Team 4585's code for the 2018 Offseason event at AMES in Cottonwood High School.
This README explains setup instructions as well as the function for each class file in the code.
- Clone the repository
- Run
./gradlew
to download gradle and required libraries - Run
./gradlew tasks
to see available options
- Run
./gradlew eclipse
- Select the
2018PracticeBot
folder as import source in "File > Open Projects"
- Run
./gradlew idea
- Open
2018PracticeBot.ipr
file with IntelliJ
- Run
./gradlew build
to build the code. Use the--info
flag for more details - Run
./gradlew deploy
when connected to Driver Station to deploy to the robot using Powershell
- This is an abstract class that all the AutoTask modules inherit from. This will allow them to all be members of the task sequence lists.
- All of the AutoTaskXXX classes are implementations for various simple defined tasks. These all inherit from AutoTask and can be members of a task sequence list.
- AutoTaskApproach.java
- AutoTaskArmRotate.java
- AutoTaskFireTrigger.java
- AutoTaskRevTrackTo.java
- AutoTaskRotateTo.java
- AutoTaskTrackToward.java
- AutoTaskWaitForTime.java
- AutoTaskWaitForTrigger.java
- This is the class to control the hardware, motors, and sensors for the chassis to move the robot. It has sensors to report current heading, location, and velocity
- This is the class to make decisions about controlling the chassis. It has PID filters for the speed and turning.
- This is a class to serve for controlling directions. It will contain a value from 0 to 359. Multiple instances can be computed even over the wrap-around boundary.
- This is a base class for the different types of contact sensors we may implement. It can also be used as a contact sensor by itself.
- A base class for different types of distance sensors. It is an abstract class, so it cannot be instantiated by itself.
- This is the main operator of the autonomous code. It will coordinate all the values from various sensors and check what the current desired tasks are. It will then decide instructions to send to the various subsystems.
- This is code to run a PID evice that can rotate. It inherits from the regular PID class, but it takes into account moving over the bounary that wraps from 0 to 360.
- This is the main operator for the teleop code. It reads infromation from the joystick(s) and then sends instructions to the different subsystems on the robot.
- This reads the joysticks and may do some filtering on some of the values before they are passed on.
- This is an interface that the various subsystems on the robot will implement.
- This is a class that extends the basic PID class to work in 2 dimensions.
- This is an implementation of a PID filter that will allow us to speed up and slow down behaviours in a controlled way.
- This is similar to
Chassis.java
. It is the hardware control for the arm that was implemented on the T-Shirt cannon robot.
- This is the main class. It creates the major subsystems that the robot currently uses. It has the calls for the autonomous and teleop loops and distributes the calls to the subsystems.
- This is an abstract class that all of the sensors on the robot should inherit from.
- This is a class that will contain a list of pointers to all the sensors that we have instantiated. It will allow us to do common behaviour and monitor them all as a group.
- This is a static class that contains the names for all of the sensors. Having them all here ensures that they are all unique and that they are not lost.
- One type of distance measuring sensor. This inherits from
DistanceSensor.java
- This contains a list of
AutoTaskXXX
. This class is used to step through each successive task until they are completed.
- A specialized task list for tasks associated with the pivot arm.
- A specialized task list for tasks associated with the chassis.
- This is a class that can contain multiple tasks sequences, allowing coordination between different task lists.
- A type of task that doesn't do anything, but sets values that can trigger other task lists to continue.
- A consolidated list of all the wiring ports. This will allow us to easily change ports if needed and will help prevent conflicts in the code.