Package com.grt192.mechanism

Examples of com.grt192.mechanism.GRTRobotBase


  }

  protected void notifyTemperatureChange() {
    for (int i = 0; i < powerListeners.size(); i++) {
      ((JagPowerListener) powerListeners.elementAt(i))
          .temperatureChanged(new JagPowerEvent(this,
              JagPowerEvent.TEMPERATURE_CHANGE, getState("Temperature")));
    }
  }
View Full Code Here


    }

    /** Notifies all listeners that the voltage has changed */
    protected void notifyVoltageChange() {
        for (int i = 0; i < powerListeners.size(); i++) {
            ((JagPowerListener) powerListeners.elementAt(i)).voltageChanged(new JagPowerEvent(this,
                    JagPowerEvent.VOLTAGE_CHANGE, getState(VOLTAGE)));
        }
    }
View Full Code Here

    }

    /** Notifies all listeners that current has changed */
    protected void notifyCurrentChange() {
        for (int i = 0; i < powerListeners.size(); i++) {
            ((JagPowerListener) powerListeners.elementAt(i)).currentChanged(new JagPowerEvent(this,
                    JagPowerEvent.CURRENT_CHANGE, getState(CURRENT)));
        }
    }
View Full Code Here

    }

    /* Notifies all listeners that temperature has changed */
    protected void notifyTemperatureChange() {
        for (int i = 0; i < powerListeners.size(); i++) {
            ((JagPowerListener) powerListeners.elementAt(i)).temperatureChanged(new JagPowerEvent(this,
                    JagPowerEvent.TEMPERATURE_CHANGE, getState(TEMPERATURE)));
        }
    }
View Full Code Here

  protected void notifyLeftSwitch(boolean pressed) {
    for (int i = 0; i < switchListeners.size(); i++) {
      if (pressed)
        ((JagSwitchListener) switchListeners.elementAt(i))
            .leftSwitchPressed(new JagSwitchEvent(this,
                JagSwitchEvent.LEFT_PRESSED, "leftSwitch"));
      else
        ((JagSwitchListener) switchListeners.elementAt(i))
            .leftSwitchReleased(new JagSwitchEvent(this,
                JagSwitchEvent.LEFT_RELEASED, "leftSwitch"));
    }
  }
View Full Code Here

  protected void notifyRightSwitch(boolean pressed) {
    for (int i = 0; i < switchListeners.size(); i++) {
      if (pressed)
        ((JagSwitchListener) switchListeners.elementAt(i))
            .rightSwitchPressed(new JagSwitchEvent(this,
                JagSwitchEvent.RIGHT_PRESSED, "rightSwitch"));
      else
        ((JagSwitchListener) switchListeners.elementAt(i))
            .rightSwitchReleased(new JagSwitchEvent(this,
                JagSwitchEvent.RIGHT_RELEASED, "rightSwitch"));
    }
  }
View Full Code Here

        }
    }

    private void notifyListeners(boolean present) {
        for (int i = 0; i < lineStateListeners.size(); i++) {
                ((LineTrackerListener) lineStateListeners.elementAt(i)).lineStateChange(new LineTraceEvent(this, present));
        }
    }
View Full Code Here

    }

    protected void notifyLeftXAxisChange() {
        for (int i = 0; i < joystickListeners.size(); i++) {
            ((XboxJoystickListener) joystickListeners.elementAt(i)).leftXAxisMoved(
                    new XboxJoystickEvent(this,
                    XboxJoystickEvent.DEFAULT,
                    getState("leftXValue")));
        }
    }
View Full Code Here

    }

    protected void notifyLeftYAxisChange() {
        for (int i = 0; i < joystickListeners.size(); i++) {
            ((XboxJoystickListener) joystickListeners.elementAt(i)).leftYAxisMoved(
                    new XboxJoystickEvent(this,
                    XboxJoystickEvent.DEFAULT,
                    getState("leftYValue")));
        }
//        System.out.println(getState("l"))
    }
View Full Code Here

//        System.out.println(getState("l"))
    }
      protected void notifyRightXAxisChange() {
        for (int i = 0; i < joystickListeners.size(); i++) {
            ((XboxJoystickListener) joystickListeners.elementAt(i)).rightXAxisMoved(
                    new XboxJoystickEvent(this,
                    XboxJoystickEvent.DEFAULT,
                    getState("rightXValue")));
        }
    }
View Full Code Here

TOP

Related Classes of com.grt192.mechanism.GRTRobotBase

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.