Class XpaThrottle

    • Method Detail

      • setIsForward

        public void setIsForward​(boolean forward)
        Implementing functions should override this function, but should either make a call to super.setIsForward() to notify the listeners, or should notify the listeners themselves.
        Specified by:
        setIsForward in interface Throttle
        Overrides:
        setIsForward in class AbstractThrottle
        Parameters:
        forward - true if forward; false otherwise
      • setFunction

        public void setFunction​(int func,
                                boolean value)
        Set Loco Function and send to Layout.
        Specified by:
        setFunction in interface Throttle
        Overrides:
        setFunction in class AbstractThrottle
        Parameters:
        func - Function Number, 0-28
        value - New Function State. True on, false off.
      • sendFunctionGroup1

        public void sendFunctionGroup1()
        Send the message to set the state of functions F0, F1, F2, F3, F4.

        This is used in the setFn implementations provided in this class, but a real implementation needs to be provided.

        Overrides:
        sendFunctionGroup1 in class AbstractThrottle
      • sendFunctionGroup2

        public void sendFunctionGroup2()
        Send the message to set the state of functions F5, F6, F7, F8.

        This is used in the setFn implementations provided in this class, but a real implementation needs to be provided.

        Overrides:
        sendFunctionGroup2 in class AbstractThrottle
      • sendFunctionGroup3

        public void sendFunctionGroup3()
        Send the message to set the state of functions F9, F10, F11, F12.

        This is used in the setFn implementations provided in this class, but a real implementation needs to be provided.

        Overrides:
        sendFunctionGroup3 in class AbstractThrottle
      • getLocoAddress

        public LocoAddress getLocoAddress()
        Locomotive address. The exact format is defined by the specific implementation, as subclasses of LocoAddress will contain different information.

        This is an unbound property.

        Returns:
        The locomotive address