Exploit database

GH-89786c7d19f1094f9762e90b692942e5

25wangj/ftcintothedeep16460

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 files22

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

TeamCode/src/main/java/org/firstinspires/ftc/teamcode/movement/CachingMotor.java

Java · 607 bytes
package org.firstinspires.ftc.teamcode.movement;
import com.qualcomm.robotcore.hardware.DcMotorEx;

import java.util.function.DoubleSupplier;

public class CachingMotor {
    public static final int steps = 20;
    public static final double refVoltage = 12;
    public final DcMotorEx motor;
    private DoubleSupplier voltage;
    public CachingMotor(DcMotorEx motor, DoubleSupplier voltage) {
        this.motor = motor;
        this.voltage = voltage;
    }
    public void setPower(double p) {
        motor.setPower((double)Math.round(p * steps * refVoltage / voltage.getAsDouble()) / steps);
    }
}