001package jmri.jmrix.sprog.sprognano; 002 003import jmri.jmrix.sprog.SprogConstants.SprogMode; 004 005/** 006 * Implements SerialPortAdapter for the Sprog system. 007 * <p> 008 * This connects an SSPROG DCC SPROG Nano command station via a USB virtual 009 * serial com port. 010 * <p> 011 * The current implementation only handles the 9,600 baud rate, and does not use 012 * any other options at configuration time. 013 * 014 * @author Andrew Crosland Copyright (C) 2016 015 */ 016public class SprogNanoSerialDriverAdapter 017 extends jmri.jmrix.sprog.serialdriver.SerialDriverAdapter { 018 019 public SprogNanoSerialDriverAdapter() { 020 super(SprogMode.OPS); 021 options.put("TrackPowerState", new Option(Bundle.getMessage("OptionTrackPowerLabel"), 022 new String[]{Bundle.getMessage("PowerStateOff"), Bundle.getMessage("PowerStateOn")}, 023 true)); // first element (TrackPowerState) NOI18N 024 //Set the username to match name; once refactored to handle multiple connections or user setable names/prefixes then this can be removed 025 this.getSystemConnectionMemo().setUserName(Bundle.getMessage("SprogNanoCSTitle")); 026 } 027 028 // private final static Logger log = LoggerFactory.getLogger(SprogNanoSerialDriverAdapter.class); 029 030}