Package jmri.jmrix.anyma
Class AnymaDMX_UsbLight
- java.lang.Object
-
- jmri.implementation.AbstractNamedBean
-
- jmri.implementation.AbstractLight
-
- jmri.implementation.AbstractVariableLight
-
- jmri.jmrix.anyma.AnymaDMX_UsbLight
-
- All Implemented Interfaces:
java.lang.Comparable<NamedBean>
,AnalogIO
,PropertyChangeProvider
,DigitalIO
,Light
,NamedBean
,VariableLight
public class AnymaDMX_UsbLight extends AbstractVariableLight
AnymaDMX_UsbLight.javaImplementation of the Light Object for anyma dmx
- Since:
- 4.9.6
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface jmri.AnalogIO
AnalogIO.AbsoluteOrRelative
-
Nested classes/interfaces inherited from interface jmri.NamedBean
NamedBean.BadNameException, NamedBean.BadSystemNameException, NamedBean.BadUserNameException, NamedBean.DisplayOptions, NamedBean.DuplicateSystemNameException
-
-
Field Summary
-
Fields inherited from class jmri.implementation.AbstractVariableLight
alarmSyncUpdate, internalClock, minuteChangeListener, mLastTransitionDate, mNextTransitionTs, mTransitionDuration, mTransitionTargetIntensity
-
Fields inherited from class jmri.implementation.AbstractLight
lightControlList, mActive, mCurrentIntensity, mEnabled, mMaxIntensity, mMinIntensity, mState
-
Fields inherited from class jmri.implementation.AbstractNamedBean
listenerRefs, mSystemName, register
-
Fields inherited from interface jmri.Light
FAST_CLOCK_CONTROL, INTERMEDIATE, NO_CONTROL, SENSOR_CONTROL, TIMED_ON_CONTROL, TRANSITIONING, TRANSITIONINGHIGHER, TRANSITIONINGLOWER, TRANSITIONINGTOFULLOFF, TRANSITIONINGTOFULLON, TURNOUT_STATUS_CONTROL, TWO_SENSOR_CONTROL
-
Fields inherited from interface jmri.NamedBean
DISPLAY_NAME_FORMAT, INCONSISTENT, PROPERTY_STATE, QUOTED_NAME_FORMAT, UNKNOWN
-
-
Constructor Summary
Constructors Constructor Description AnymaDMX_UsbLight(java.lang.String systemName, java.lang.String userName, AnymaDMX_SystemConnectionMemo memo)
Create a Light object, with both system and user names.AnymaDMX_UsbLight(java.lang.String systemName, AnymaDMX_SystemConnectionMemo memo)
Create a Light object, with only system name.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected void
doNewState(int oldState, int newState)
Implement the specific change of state needed by hardware.protected int
getNumberOfSteps()
Provide the number of steps available between min and max intensityprotected void
sendIntensity(double intensity)
Send a Dim/Bright commands to the hardware to reach a specific intensity.protected void
sendOnOffCommand(int newState)
Send a On/Off Command to the hardware-
Methods inherited from class jmri.implementation.AbstractVariableLight
describeState, getAbsoluteOrRelative, getCommandedAnalogValue, getCurrentIntensity, getMax, getMaxIntensity, getMin, getMinIntensity, getResolution, getState, getTargetIntensity, getTransitionTime, isTransitionAvailable, isTransitioning, newInternalMinute, notifyTargetIntensityChange, setCommandedAnalogValue, setMaxIntensity, setMinIntensity, setObservedAnalogValue, setState, setState, setTargetIntensity, setTransitionTime, startTransition
-
Methods inherited from class jmri.implementation.AbstractLight
activateLight, addLightControl, clearLightControls, deactivateLight, getBeanType, getEnabled, getLightControlList, getState, getUsageReport, notifyStateChange, setEnabled
-
Methods inherited from class jmri.implementation.AbstractNamedBean
addPropertyChangeListener, addPropertyChangeListener, addPropertyChangeListener, addPropertyChangeListener, compareSystemNameSuffix, dispose, equals, firePropertyChange, getComment, getDisplayName, getDisplayName, getListenerRef, getListenerRefs, getNumPropertyChangeListeners, getProperty, getPropertyChangeListeners, getPropertyChangeListeners, getPropertyChangeListenersByReference, getPropertyKeys, getSystemName, getUserName, hashCode, removeProperty, removePropertyChangeListener, removePropertyChangeListener, setComment, setProperty, setUserName, toString, toStringSuffix, updateListenerRef, vetoableChange
-
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
-
Methods inherited from interface jmri.AnalogIO
getKnownAnalogValue
-
Methods inherited from interface jmri.Light
activateLight, addLightControl, clearLightControls, deactivateLight, getCommandedState, getEnabled, getKnownState, getLightControlList, getState, setCommandedState, setEnabled
-
Methods inherited from interface jmri.NamedBean
addPropertyChangeListener, addPropertyChangeListener, compareSystemNameSuffix, compareTo, dispose, getBeanType, getComment, getDisplayName, getDisplayName, getListenerRef, getListenerRefs, getNumPropertyChangeListeners, getProperty, getPropertyChangeListenersByReference, getPropertyKeys, getRecommendedToolTip, getSystemName, getUsageReport, getUserName, removeProperty, setComment, setProperty, setUserName, toString, updateListenerRef, vetoableChange
-
Methods inherited from interface jmri.beans.PropertyChangeProvider
addPropertyChangeListener, addPropertyChangeListener, getPropertyChangeListeners, getPropertyChangeListeners, removePropertyChangeListener, removePropertyChangeListener
-
Methods inherited from interface jmri.VariableLight
isConsistentState, isConsistentValue, requestUpdateFromLayout
-
-
-
-
Constructor Detail
-
AnymaDMX_UsbLight
public AnymaDMX_UsbLight(java.lang.String systemName, AnymaDMX_SystemConnectionMemo memo)
Create a Light object, with only system name.- Parameters:
systemName
- the system name (previously validated)memo
- the system memo
-
AnymaDMX_UsbLight
public AnymaDMX_UsbLight(java.lang.String systemName, java.lang.String userName, AnymaDMX_SystemConnectionMemo memo)
Create a Light object, with both system and user names.- Parameters:
systemName
- the system name (previously validated)userName
- the user namememo
- the system memo
-
-
Method Detail
-
doNewState
protected void doNewState(int oldState, int newState)
Implement the specific change of state needed by hardware.- Overrides:
doNewState
in classAbstractLight
- Parameters:
oldState
- old statenewState
- new state
-
sendIntensity
protected void sendIntensity(double intensity)
Send a Dim/Bright commands to the hardware to reach a specific intensity.- Specified by:
sendIntensity
in classAbstractVariableLight
- Parameters:
intensity
- new intensity
-
sendOnOffCommand
protected void sendOnOffCommand(int newState)
Send a On/Off Command to the hardware- Specified by:
sendOnOffCommand
in classAbstractVariableLight
- Parameters:
newState
- new state
-
getNumberOfSteps
protected int getNumberOfSteps()
Provide the number of steps available between min and max intensity- Specified by:
getNumberOfSteps
in classAbstractVariableLight
- Returns:
- number of steps
-
-