Package com.pi4j.io.gpio
Class SimulatedGpioProvider
- java.lang.Object
-
- com.pi4j.io.gpio.GpioProviderBase
-
- com.pi4j.io.gpio.SimulatedGpioProvider
-
- All Implemented Interfaces:
GpioProvider
public class SimulatedGpioProvider extends GpioProviderBase implements GpioProvider
A simulator to aid in development of RI Pi systems using a standard PC dev environment. To use the simulator you need two environment variables: The standard PI4J platform statement MUST point to the simulator: PI4J_PLATFORM=Simulated A second environment variable that defines the platform that is to be simulated. SimulatedPlatform={Real Platform's Name} e.g. SimultatedPlatform=RaspberryPi GPIO Provider If you don't provide a value for theSimulatedPlatform the system assumes that you want to use the raspberry pi platform: RaspiGpioProvider- Author:
- bsutton
-
-
Field Summary
Fields Modifier and Type Field Description static String
NAME
-
Fields inherited from class com.pi4j.io.gpio.GpioProviderBase
cache, DEFAULT_CACHE_SIZE, isshutdown, listeners
-
-
Constructor Summary
Constructors Constructor Description SimulatedGpioProvider()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getName()
void
setAnalogValue(Pin pin, double value)
void
setState(Pin pin, PinState state)
-
Methods inherited from class com.pi4j.io.gpio.GpioProviderBase
addListener, dispatchPinAnalogValueChangeEvent, dispatchPinDigitalStateChangeEvent, export, export, getMode, getPinCache, getPullResistance, getPwm, getState, getValue, hasPin, isExported, isShutdown, removeAllListeners, removeListener, setMode, setPullResistance, setPwm, setPwmRange, setValue, shutdown, unexport
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.pi4j.io.gpio.GpioProvider
addListener, export, export, getMode, getPullResistance, getPwm, getState, getValue, hasPin, isExported, isShutdown, removeAllListeners, removeListener, setMode, setPullResistance, setPwm, setPwmRange, setValue, shutdown, unexport
-
-
-
-
Field Detail
-
NAME
public static String NAME
-
-
Method Detail
-
getName
public String getName()
- Specified by:
getName
in interfaceGpioProvider
- Specified by:
getName
in classGpioProviderBase
-
setState
public void setState(Pin pin, PinState state)
- Specified by:
setState
in interfaceGpioProvider
- Overrides:
setState
in classGpioProviderBase
-
setAnalogValue
public void setAnalogValue(Pin pin, double value)
-
-