Exploit database

GH-b17710e90f720051740d459ad17d231e

4329/decode

GitHubNot listedPoC
Download repository ZIP

Sources for CVE-2019-11358

1,181 sources

Preferred order: Exploit-DB, Metasploit, then GitHub repositories by stars. Open preferred source

Repository files20

Files from this repository share one source choice. Supporting files may cover other vulnerabilities.

TeamCode/src/main/java/org/firstinspires/ftc/teamcode/command/ShootCommand.java

Java · 1,614 bytes
package org.firstinspires.ftc.teamcode.command;

import android.util.Log;

import com.arcrobotics.ftclib.command.CommandBase;

import org.firstinspires.ftc.teamcode.subsystem.LimeLightSubsystem;
import org.firstinspires.ftc.teamcode.subsystem.ShooterSubsystem;
import org.firstinspires.ftc.teamcode.subsystem.VoltageSubsystem;

public class ShootCommand extends CommandBase {
    private final ShooterSubsystem shooterSubsystem;
    private final LimeLightSubsystem limeLightSubsystem;
    private final boolean stopAfterShot;
    private final VoltageSubsystem voltageSubsystem;
    private double voltageCompensationFactor;

    public ShootCommand(ShooterSubsystem shooterSubsystem, LimeLightSubsystem limeLightSubsystem, boolean stopAfterShot, VoltageSubsystem voltageSubsystem) {
        this.shooterSubsystem = shooterSubsystem;
        this.limeLightSubsystem = limeLightSubsystem;
        this.stopAfterShot = stopAfterShot;
        this.voltageSubsystem = voltageSubsystem;
        addRequirements(shooterSubsystem);
    }

    @Override
    public void initialize() {
        voltageCompensationFactor = voltageSubsystem.getVoltageCompensationFactor();
    }

    @Override
    public void execute() {
        shooterSubsystem.shoot(limeLightSubsystem.getTargetVelocity(), voltageCompensationFactor);

    }

    @Override
    public void end(boolean interrupted) {
        Log.i("SHOOT", "ShootCommand ended! interruped was: " + interrupted);
        if (stopAfterShot) {
            shooterSubsystem.stop();
        }
    }

    @Override
    public boolean isFinished() {
        return false;
    }
}