Package com.opensourcewithslu.utilities
Class Pi4JMultiPinFactory
java.lang.Object
com.opensourcewithslu.utilities.Pi4JMultiPinFactory
The Pi4JMultiPinFactory class is responsible for creating all the beans for all multi pin components that are being used.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionmultiPinInput
(DigitalInputMultiPinConfiguration config, com.pi4j.context.Context pi4jContext) Creates a MultiPinConfiguration object for a multi pin digital input component.multiPinPwm
(PwmMultiPinConfiguration config, com.pi4j.context.Context pi4jContext) Creates a MultiPinConfiguration object for a multi pin pwm component.
-
Constructor Details
-
Pi4JMultiPinFactory
public Pi4JMultiPinFactory()Default constructor for Pi4JMultiPinFactory.
-
-
Method Details
-
multiPinInput
@Singleton @EachBean(DigitalInputMultiPinConfiguration.class) public MultiPinConfiguration multiPinInput(DigitalInputMultiPinConfiguration config, com.pi4j.context.Context pi4jContext) Creates a MultiPinConfiguration object for a multi pin digital input component.- Parameters:
config
-DigitalInputMultiPinConfiguration
Object.pi4jContext
- The Pi4JContext
.- Returns:
- A MultiPinConfiguration object.
-
multiPinPwm
@Singleton @EachBean(PwmMultiPinConfiguration.class) public MultiPinConfiguration multiPinPwm(PwmMultiPinConfiguration config, com.pi4j.context.Context pi4jContext) Creates a MultiPinConfiguration object for a multi pin pwm component.- Parameters:
config
-PwmMultiPinConfiguration
Object.pi4jContext
- The Pi4JContext
.- Returns:
- A MultiPinConfiguration object.
-