-
Notifications
You must be signed in to change notification settings - Fork 11
Installing the API
To install the API, it can either be downloaded and copied directly into the project, or you can use it with Gradle/Maven.
The Maven repository is located at: https://nexus.otake.pw/repository/maven-public/ The group id is pw.otake.pseudoresonance
and the artifact name is pixy2-java-api
For FRC Gradle builds, this can be easily added by adding the following to build.gradle
in the project's root.
Add maven { url 'https://nexus.otake.pw/repository/maven-public/' }
under repositories
Add implementation 'pw.otake.pseudoresonance:pixy2-java-api:1.4.1'
under dependencies
Replace 1.4.1
with the current version of the API, found on the releases page.
Your build.gradle
should resemble this:
// Maven central needed for JUnit
repositories {
maven { url 'https://nexus.otake.pw/repository/maven-public/' }
}
// Defining my dependencies. In this case, WPILib (+ friends), and vendor libraries.
// Also defines JUnit 4.
dependencies {
implementation 'pw.otake.pseudoresonance:pixy2-java-api:1.4.1'
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)
testImplementation 'junit:junit:4.12'
simulation wpi.deps.sim.gui(wpi.platforms.desktop, false)
}
If there are issues using the repository, or you don't want to use it, the files can also be copied directly into the project and used, however I ask that you leave the file headers intact, so that others can find the project.