Package tuwien.auto.calimero.tools
Class Restart
java.lang.Object
tuwien.auto.calimero.tools.Restart
- All Implemented Interfaces:
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 Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic voidEntry point for running this tool from the command line.protected voidonCompletion(Exception thrown, boolean canceled) Called by this tool on completion.voidrun()
-
Constructor Details
-
Restart
Creates a new Restart object using the supplied arguments.- Parameters:
args- options for the tool, seemain(String[])- Throws:
tuwien.auto.calimero.KNXIllegalArgumentException- on missing or wrong formatted option value
-
-
Method Details
-
main
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 -hshow help message--versionshow tool/library version and exit--localhostid local IP/host name--localportnumber local UDP port (default system assigned)--port -pnumber UDP port on host (default 3671)--nat -nenable Network Address Translation--ft12 -fuse FT1.2 serial communication--usb -uuse KNX USB communication--tpuartuse TP-UART communication--medium -mid KNX medium [tp1|p110|rf|knxip] (defaults to tp1)--domainaddress domain address on open KNX medium (PL or RF)--knx-address -kKNX address KNX device address of local endpoint--yes -yautomatic yes to reset confirmation
--knx-addressoption 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):
--basicbasic restart without confirmation [default]--confirmedbasic restart with confirmation--factory-resetfactory reset (used with channel)--reset-addressreset device address to its default--reset-appapplication program memory to default application--reset-paramsreset application parameter memory (used with channel)--reset-linksreset links (used with channel)--factory-keep-addrfactory reset without resetting device addresses (used with channel)
- Parameters:
args- command line arguments for the tool
-
run
public void run() -
onCompletion
Called by this tool on completion.- Parameters:
thrown- the thrown exception if operation completed due to a raised exception,nullotherwisecanceled- whether the operation got canceled before its planned end
-