Package jmri

Interface CommandStation

    • Method Summary

      All Methods Instance Methods Abstract Methods Default Methods 
      Modifier and Type Method Description
      java.lang.String getSystemPrefix()  
      java.lang.String getUserName()  
      default void sendAccSignalDecoderPkt​(int address, int aspect, int count)
      As a shortcut, and to allow for command station types that cannot sent generic packets to the rails, we provide this method to specifically send Accessory Signal Decoder Packets.
      default void sendAltAccSignalDecoderPkt​(int address, int aspect, int count)
      As a shortcut, and to allow for command station types that cannot sent generic packets to the rails, we provide this method to specifically send the alternate form of Accessory Signal Decoder Packets.
      boolean sendPacket​(byte[] packet, int repeats)
      Send a specific packet to the rails.
    • Method Detail

      • sendPacket

        boolean sendPacket​(@Nonnull
                           byte[] packet,
                           int repeats)
        Send a specific packet to the rails.
        Parameters:
        packet - Byte array representing the packet, including the error-correction byte.
        repeats - Number of times to repeat the transmission.
        Returns:
        true if the operation succeeds, false otherwise.
      • sendAccSignalDecoderPkt

        default void sendAccSignalDecoderPkt​(int address,
                                             int aspect,
                                             int count)
        As a shortcut, and to allow for command station types that cannot sent generic packets to the rails, we provide this method to specifically send Accessory Signal Decoder Packets.

        It's equivalent to calling NmraPacket.accSignalDecoderPkt(int, int) and sending the resulting packet to the rails

        Parameters:
        address - The DCC signal decoder address to use
        aspect - The signal aspect to send
        count - the number of times to repeat the send
      • sendAltAccSignalDecoderPkt

        default void sendAltAccSignalDecoderPkt​(int address,
                                                int aspect,
                                                int count)
        As a shortcut, and to allow for command station types that cannot sent generic packets to the rails, we provide this method to specifically send the alternate form of Accessory Signal Decoder Packets.

        It's equivalent to calling NmraPacket.altAccSignalDecoderPkt(int, int) and sending the resulting packet to the rails

        Parameters:
        address - The DCC signal decoder address to use
        aspect - The signal aspect to send
        count - the number of times to repeat the send