public void actionPerformed(ActionEvent e) {
try {
String host = preferences.getStringValue(HOSTNAME);
int port = preferences.getIntValue(PORT);
session = new SRCPSession(host, port, false);
session.getCommandChannel().addCommandDataListener(
AdHocRailway.this);
session.getInfoChannel().addInfoDataListener(AdHocRailway.this);
powerControl.setSession(session);
((SRCPTurnoutControlAdapter) turnoutControl)