Class Restart

java.lang.Object
tuwien.auto.calimero.tools.Restart
All Implemented Interfaces:
Runnable

public class Restart extends Object implements Runnable
Restart performs a basic restart or master reset of a KNX interface or KNX device. The tool supports network access using KNXnet/IP, KNX IP, USB, FT1.2, and TP-UART.

Run the tool by using either main(String[]) or Runnable.run().

  • Constructor Details

    • Restart

      public Restart(String[] args)
      Creates a new Restart object using the supplied arguments.
      Parameters:
      args - options for the tool, see main(String[])
      Throws:
      tuwien.auto.calimero.KNXIllegalArgumentException - on missing or wrong formatted option value
  • Method Details

    • main

      public static void main(String... args)
      Entry point for running this tool from the command line. A communication device, host, or port identifier has to be supplied to specify the endpoint for KNX network access.
      To show the usage message of this tool, use the command line option --help (or -h).
      Command line options are treated case sensitive. Available options are (see below for restart type options):
      • --help -h show help message
      • --version show tool/library version and exit
      • --localhost id  local IP/host name
      • --localport number  local UDP port (default system assigned)
      • --port -p number  UDP port on host (default 3671)
      • --nat -n enable Network Address Translation
      • --ft12 -f use FT1.2 serial communication
      • --usb -u use KNX USB communication
      • --tpuart use TP-UART communication
      • --medium -m id  KNX medium [tp1|p110|rf|knxip] (defaults to tp1)
      • --domain address  domain address on open KNX medium (PL or RF)
      • --knx-address -k KNX address  KNX device address of local endpoint
      • --yes -y  automatic yes to reset confirmation
      The --knx-address option is only necessary if an access protocol is selected that directly communicates with the KNX network, i.e., KNX IP or TP-UART. The selected KNX individual address shall be unique in a network, and the subnetwork address (area and line) should be set to match the network configuration.

      The supported restart types are (select at most one):

      • --basic  basic restart without confirmation [default]
      • --confirmed  basic restart with confirmation
      • --factory-reset  factory reset (used with channel)
      • --reset-address  reset device address to its default
      • --reset-app  application program memory to default application
      • --reset-params  reset application parameter memory (used with channel)
      • --reset-links  reset links (used with channel)
      • --factory-keep-addr  factory reset without resetting device addresses (used with channel)
      Parameters:
      args - command line arguments for the tool
    • run

      public void run()
      Specified by:
      run in interface Runnable
    • onCompletion

      protected void onCompletion(Exception thrown, boolean canceled)
      Called by this tool on completion.
      Parameters:
      thrown - the thrown exception if operation completed due to a raised exception, null otherwise
      canceled - whether the operation got canceled before its planned end