As reported by @DieterHolz
Lots of our student teams combine the RPi with a GUI, for example, using JavaFX. For them, it is very convenient to start the app on the laptop without any Pi4J exceptions, to implement and test the GUI and application logic, without connections to sensors, etc.
Current solution:
pi4J = (BoardInfoHelper.runningOnRaspberryPi()) ?
Pi4J.newAutoContext() :
Pi4J.newContextBuilder()
.add(new MockDigitalInputProviderImpl())
.add(new MockDigitalOutputProviderImpl())
.add(new MockPwmProviderImpl())
.add(new MockSpiProviderImpl())
.add(new MockI2CProviderImpl())
.build();
It would be great if something like this is incorporated in newAutoContext or some similar method.
As reported by @DieterHolz
Lots of our student teams combine the RPi with a GUI, for example, using JavaFX. For them, it is very convenient to start the app on the laptop without any Pi4J exceptions, to implement and test the GUI and application logic, without connections to sensors, etc.
Current solution:
It would be great if something like this is incorporated in newAutoContext or some similar method.