Skip to content

Commit

Permalink
Merge pull request #115 from flamingchickens1540/2020-updates
Browse files Browse the repository at this point in the history
Update things to 2020
  • Loading branch information
liamjwang authored Jan 2, 2020
2 parents 024a3d7 + aeb5096 commit 97ab944
Show file tree
Hide file tree
Showing 86 changed files with 1,808 additions and 5,529 deletions.
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -162,3 +162,6 @@ gradle-app.setting

# motion profiles
*.csv

# zack's discord plugin
.idea/discord.xml
32 changes: 0 additions & 32 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,40 +12,18 @@ A common library of useful classes and systems intended to be used for all Team

[Javadoc hosted on Github Pages](https://flamingchickens1540.github.io/ROOSTER)

#### Drive Code

`org.team1540.rooster.drive`

Advanced closed-loop drive code for a tank drive.

#### Drive Pipeline System

`org.team1540.rooster.drive.pipeline`

A flexible system for controlling a robot drive. More docs [here](docs/Drive%20Pipelines.md), with a specific section on motion profiling [here](docs/Motion%20Profiling.md).

#### Power Management

`org.team1540.rooster.power`

A flexible, dynamic power management system. Uses a centralized `PowerManager` that takes `PowerManageable`s, including the default implementation `ChickenSubsystem`.

#### Preferences

`org.team1540.rooster.preferencemanager`

A system to easily set tuning fields through WPILib `Preferences`.

#### Testing

`org.team1540.rooster.testers`

Various classes for testing common things.
- `BurnoutTester` for testing if motors are burned out.
- `EncoderTester` for testing if motors have working encoders attached.
- `SimpleControllersTester` for easily running motors.
- `ControllersMultiTester` for automatically running multiple tests across motor groups.

#### Triggers

`org.team1540.rooster.triggers`
Expand All @@ -54,7 +32,6 @@ Simple triggers that extend WPILib's joystick binding functionality.

- `AxisButton` allows using a joystick axis (triggers or joysticks) as a button–the button will trigger when the axis passes a user-defined threshold.
- `DPadButton` and `StrictDPadButton` allow using any axis of a controller D-Pad as a button.
- `SimpleButton` allows using a generic `BooleanSupplier` as a button.

#### Utilities

Expand All @@ -66,15 +43,6 @@ Functions and classes for common tasks.
- Capping an output
- Inverting an input/output depending on a boolean

#### Utility Classes

`org.team1540.rooster.util`

Classes (mostly WPILib `Commands`) to make life easier.

- `AsyncCommand` to execute a command in a separate thread on a loop.
- `SimpleCommand`/`SimpleLoopCommand` to quickly create a one-shot or loop command from a lambda.
- `SimpleConditionalCommand` to quickly create a `ConditionalCommand` from a lambda.

### Installation

Expand Down
34 changes: 23 additions & 11 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -3,10 +3,13 @@ import edu.wpi.first.gradlerio.GradleRIOPlugin
plugins {
id "java"
id "maven"
id "edu.wpi.first.GradleRIO" version "2019.1.1"
id "org.jetbrains.kotlin.jvm" version "1.3.0"
id "edu.wpi.first.GradleRIO" version "2020.1.1"
id "org.jetbrains.kotlin.jvm" version "1.3.50"
id "com.palantir.git-version" version "0.12.2"
}

group "org.team1540"
version gitVersion()

// Maven/Jitpack configuration
task sourcesJar(type: Jar, dependsOn: classes) {
Expand All @@ -19,6 +22,13 @@ task javadocJar(type: Jar, dependsOn: javadoc) {
from javadoc.destinationDir
}


install {
doLast {
System.out.println("Installing with version " + gitVersion())
}
}

artifacts {
archives sourcesJar
archives javadocJar
Expand Down Expand Up @@ -47,14 +57,20 @@ repositories {

dependencies {
// FRC dependencies
compile wpi.deps.wpilib()
compile wpi.deps.vendor.java()
implementation wpi.deps.wpilib()
nativeZip wpi.deps.wpilibJni(wpi.platforms.roborio)
nativeDesktopZip wpi.deps.wpilibJni(wpi.platforms.desktop)

implementation wpi.deps.vendor.java()
nativeZip wpi.deps.vendor.jni(wpi.platforms.roborio)
nativeDesktopZip wpi.deps.vendor.jni(wpi.platforms.desktop)

// Non-FRC dependencies
compile 'org.jetbrains:annotations:16.0.3'
compile "org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.3.0"
compile "org.jetbrains.kotlin:kotlin-stdlib-jdk8:1.3.50"

compile 'org.slf4j:slf4j-log4j12:1.6.1'
compile 'log4j:log4j:1.2.16'

compile "com.google.guava:guava:27.0-jre"
compile "org.apache.commons:commons-math3:3.6.1"
Expand All @@ -73,7 +89,7 @@ sourceSets {
}

configurations {
testbotsCompile.extendsFrom compile
testbotsImplementation.extendsFrom implementation
testbotsRuntimeOnly.extendsFrom runtimeOnly
}

Expand Down Expand Up @@ -139,13 +155,9 @@ jar {
}
}

simulateJava.dependsOn.removeAll()
simulateJava.dependsOn(extractTestJNI)
simulateJava.dependsOn(jar)

// wrapper

wrapper {
gradleVersion = '5.0'
gradleVersion = '6.0.1'
distributionType = Wrapper.DistributionType.ALL
}
Loading

0 comments on commit 97ab944

Please sign in to comment.