Java 类edu.wpi.first.wpilibj.util.BaseSystemNotInitializedException 实例源码

项目:snobot-2017    文件:RobotState.java   
public static boolean isDisabled() {
  if (m_impl != null) {
    return m_impl.isDisabled();
  } else {
    throw new BaseSystemNotInitializedException(Interface.class, RobotState.class);
  }
}
项目:snobot-2017    文件:RobotState.java   
public static boolean isEnabled() {
  if (m_impl != null) {
    return m_impl.isEnabled();
  } else {
    throw new BaseSystemNotInitializedException(Interface.class, RobotState.class);
  }
}
项目:snobot-2017    文件:RobotState.java   
public static boolean isOperatorControl() {
  if (m_impl != null) {
    return m_impl.isOperatorControl();
  } else {
    throw new BaseSystemNotInitializedException(Interface.class, RobotState.class);
  }
}
项目:snobot-2017    文件:RobotState.java   
public static boolean isAutonomous() {
  if (m_impl != null) {
    return m_impl.isAutonomous();
  } else {
    throw new BaseSystemNotInitializedException(Interface.class, RobotState.class);
  }
}
项目:snobot-2017    文件:RobotState.java   
public static boolean isTest() {
  if (m_impl != null) {
    return m_impl.isTest();
  } else {
    throw new BaseSystemNotInitializedException(Interface.class, RobotState.class);
  }
}
项目:snobot-2017    文件:Timer.java   
/**
 * Return the system clock time in seconds. Return the time from the FPGA hardware clock in
 * seconds since the FPGA started.
 *
 * @return Robot running time in seconds.
 */
@SuppressWarnings("AbbreviationAsWordInName")
public static double getFPGATimestamp() {
  if (impl != null) {
    return impl.getFPGATimestamp();
  } else {
    throw new BaseSystemNotInitializedException(StaticInterface.class, Timer.class);
  }
}
项目:snobot-2017    文件:Timer.java   
@SuppressWarnings("JavadocMethod")
public Timer() {
  if (impl != null) {
    m_timer = impl.newTimer();
  } else {
    throw new BaseSystemNotInitializedException(StaticInterface.class, Timer.class);
  }
}
项目:snobot-2017    文件:HLUsageReporting.java   
public static void reportScheduler() {
  if (impl != null) {
    impl.reportScheduler();
  } else {
    throw new BaseSystemNotInitializedException(Interface.class, HLUsageReporting.class);
  }
}
项目:snobot-2017    文件:HLUsageReporting.java   
public static void reportPIDController(int num) {
  if (impl != null) {
    impl.reportPIDController(num);
  } else {
    throw new BaseSystemNotInitializedException(Interface.class, HLUsageReporting.class);
  }
}
项目:snobot-2017    文件:HLUsageReporting.java   
public static void reportSmartDashboard() {
  if (impl != null) {
    impl.reportSmartDashboard();
  } else {
    throw new BaseSystemNotInitializedException(Interface.class, HLUsageReporting.class);
  }
}
项目:turtleshell    文件:PID.java   
private double getTime() {
    double time = System.currentTimeMillis() / 1000.0;
    try {
        time = Timer.getFPGATimestamp();
    } catch (BaseSystemNotInitializedException e) {
    }
    return time;
}
项目:RobotCode2018    文件:RobotStateF.java   
public static boolean isDisabled()
{
    if(m_impl != null) { return m_impl.isDisabled(); }
    else { throw new BaseSystemNotInitializedException(Interface.class, RobotStateF.class); }
}
项目:RobotCode2018    文件:RobotStateF.java   
public static boolean isEnabled()
{
    if(m_impl != null) { return m_impl.isEnabled(); }
    else { throw new BaseSystemNotInitializedException(Interface.class, RobotStateF.class); }
}
项目:RobotCode2018    文件:RobotStateF.java   
public static boolean isOperatorControl()
{
    if(m_impl != null) { return m_impl.isOperatorControl(); }
    else { throw new BaseSystemNotInitializedException(Interface.class, RobotStateF.class); }
}
项目:RobotCode2018    文件:RobotStateF.java   
public static boolean isAutonomous()
{
    if(m_impl != null) { return m_impl.isAutonomous(); }
    else { throw new BaseSystemNotInitializedException(Interface.class, RobotStateF.class); }
}
项目:RobotCode2018    文件:RobotStateF.java   
public static boolean isTest()
{
    if(m_impl != null) { return m_impl.isTest(); }
    else { throw new BaseSystemNotInitializedException(Interface.class, RobotStateF.class); }
}
项目:snobot-2017    文件:Timer.java   
/**
 * Return the approximate match time The FMS does not currently send the official match time to
 * the robots This returns the time since the enable signal sent from the Driver Station At the
 * beginning of autonomous, the time is reset to 0.0 seconds At the beginning of teleop, the time
 * is reset to +15.0 seconds If the robot is disabled, this returns 0.0 seconds Warning: This is
 * not an official time (so it cannot be used to argue with referees).
 *
 * @return Match time in seconds since the beginning of autonomous
 */
public static double getMatchTime() {
  if (impl != null) {
    return impl.getMatchTime();
  } else {
    throw new BaseSystemNotInitializedException(StaticInterface.class, Timer.class);
  }
}
项目:snobot-2017    文件:Timer.java   
/**
 * Pause the thread for a specified time. Pause the execution of the thread for a specified period
 * of time given in seconds. Motors will continue to run at their last assigned values, and
 * sensors will continue to update. Only the task containing the wait will pause until the wait
 * time is expired.
 *
 * @param seconds Length of time to pause
 */
public static void delay(final double seconds) {
  if (impl != null) {
    impl.delay(seconds);
  } else {
    throw new BaseSystemNotInitializedException(StaticInterface.class, Timer.class);
  }
}