diff --git a/components/src/main/java/com/opensourcewithslu/components/controllers/ActiveBuzzerController.java b/components/src/main/java/com/opensourcewithslu/components/controllers/ActiveBuzzerController.java index d25c60de..cb98dc20 100644 --- a/components/src/main/java/com/opensourcewithslu/components/controllers/ActiveBuzzerController.java +++ b/components/src/main/java/com/opensourcewithslu/components/controllers/ActiveBuzzerController.java @@ -37,7 +37,7 @@ public void disableActiveBuzzer(){ } /** - * Emits an beep sound from the active buzzer. + * Emits a beep sound from the active buzzer. */ @Get("/beepTone") public void playBeepTone(){ diff --git a/components/src/main/java/com/opensourcewithslu/components/controllers/PIRSensorController.java b/components/src/main/java/com/opensourcewithslu/components/controllers/PIRSensorController.java index defb9557..7c37c0a9 100644 --- a/components/src/main/java/com/opensourcewithslu/components/controllers/PIRSensorController.java +++ b/components/src/main/java/com/opensourcewithslu/components/controllers/PIRSensorController.java @@ -2,7 +2,7 @@ import com.opensourcewithslu.inputdevices.PIRSensorHelper; import com.opensourcewithslu.outputdevices.RGBLEDHelper; -import com.opensourcewithslu.utilities.MultipinConfiguration; +import com.opensourcewithslu.utilities.MultiPinConfiguration; import com.pi4j.io.gpio.digital.DigitalInput; import io.micronaut.http.annotation.Controller; import io.micronaut.http.annotation.Get; @@ -24,7 +24,7 @@ public class PIRSensorController { * @param rgbLed A MultiPinConfiguration object. */ public PIRSensorController(@Named("pir-sensor")DigitalInput pirSensor, - @Named("rgb-led-2")MultipinConfiguration rgbLed) { + @Named("rgb-led-2") MultiPinConfiguration rgbLed) { this.pirSensorHelper = new PIRSensorHelper(pirSensor); this.rgbledHelper = new RGBLEDHelper(rgbLed); } diff --git a/components/src/main/java/com/opensourcewithslu/components/controllers/RotaryEncoderController.java b/components/src/main/java/com/opensourcewithslu/components/controllers/RotaryEncoderController.java index e083d769..b9d857e9 100644 --- a/components/src/main/java/com/opensourcewithslu/components/controllers/RotaryEncoderController.java +++ b/components/src/main/java/com/opensourcewithslu/components/controllers/RotaryEncoderController.java @@ -1,7 +1,7 @@ package com.opensourcewithslu.components.controllers; import com.opensourcewithslu.inputdevices.RotaryEncoderHelper; -import com.opensourcewithslu.utilities.MultipinConfiguration; +import com.opensourcewithslu.utilities.MultiPinConfiguration; import io.micronaut.http.annotation.Controller; import io.micronaut.http.annotation.Get; import jakarta.inject.Named; @@ -11,7 +11,7 @@ public class RotaryEncoderController { private final RotaryEncoderHelper encoderHelper; - public RotaryEncoderController(@Named("rotary-encoder")MultipinConfiguration rotaryEncoder){ + public RotaryEncoderController(@Named("rotary-encoder") MultiPinConfiguration rotaryEncoder){ this.encoderHelper = new RotaryEncoderHelper(rotaryEncoder); } diff --git a/components/src/main/java/com/opensourcewithslu/components/controllers/lcdController.java b/components/src/main/java/com/opensourcewithslu/components/controllers/lcdController.java index 343f884f..f1a5bb9a 100644 --- a/components/src/main/java/com/opensourcewithslu/components/controllers/lcdController.java +++ b/components/src/main/java/com/opensourcewithslu/components/controllers/lcdController.java @@ -37,10 +37,10 @@ public String writeDataAtPos(@PathVariable String text, @PathVariable int line, return "Text written at line " + line + ", position " + pos + ": " + text + "\n"; } - @Get("/write/character/{charvalue}") - public String writeCharacter(@PathVariable char charvalue) { - lcdHelper.writeCharacter(charvalue); - return "Character '" + charvalue + "' written to LCD\n"; + @Get("/write/character/{charValue}") + public String writeCharacter(@PathVariable char charValue) { + lcdHelper.writeCharacter(charValue); + return "Character '" + charValue + "' written to LCD\n"; } @Get("/backlight/{state}") diff --git a/components/src/main/java/com/opensourcewithslu/components/controllers/rgbController.java b/components/src/main/java/com/opensourcewithslu/components/controllers/rgbController.java index 0e9e5e68..b8a912b3 100644 --- a/components/src/main/java/com/opensourcewithslu/components/controllers/rgbController.java +++ b/components/src/main/java/com/opensourcewithslu/components/controllers/rgbController.java @@ -1,7 +1,7 @@ package com.opensourcewithslu.components.controllers; import com.opensourcewithslu.outputdevices.RGBLEDHelper; -import com.opensourcewithslu.utilities.MultipinConfiguration; +import com.opensourcewithslu.utilities.MultiPinConfiguration; import io.micronaut.http.annotation.Controller; import io.micronaut.http.annotation.Get; import jakarta.inject.Named; @@ -11,7 +11,7 @@ public class rgbController { private final RGBLEDHelper rgbledHelper; - public rgbController(@Named("rgb-led") MultipinConfiguration rgbLed){ + public rgbController(@Named("rgb-led") MultiPinConfiguration rgbLed){ this.rgbledHelper = new RGBLEDHelper(rgbLed); } diff --git a/components/src/main/resources/application.yml b/components/src/main/resources/application.yml index 59b97e31..62e25669 100644 --- a/components/src/main/resources/application.yml +++ b/components/src/main/resources/application.yml @@ -14,27 +14,6 @@ pi4j: # tag::pwm[] pwm: - red-pwm: # <1> - name: red # <2> - address: 17 # <3> - pwmType: SOFTWARE # <4> - provider: pigpio-pwm # <5> - initial: 0 # <6> - shutdown: 0 # <7> - blue-pwm: - name: blue - address: 18 - pwmType: SOFTWARE - provider: pigpio-pwm - initial: 0 - shutdown: 0 - green-pwm: - name: green - address: 27 - pwmType: SOFTWARE - provider: pigpio-pwm - initial: 0 - shutdown: 0 active-buzzer: name: active-buzzer address: 17 @@ -165,7 +144,7 @@ pi4j: provider: pigpio-digital-input # end::multiInput[] - # tag::multipwm[] + # tag::multiPWM[] multi-pwm: rgb-led: # <.> name: RGB LED # <.> @@ -181,22 +160,5 @@ pi4j: provider: pigpio-pwm initials: 0, 0, 0 shutdowns: 0, 0, 0 - # end::multipwm[] - + # end::multiPWM[] -# clk: -# name: CLK Output -# address: 23 -# debounce: 500 -# pull: PULL_UP -# shutdown: LOW -# initial: HIGH -# provider: pigpio-digital-input -# dt: -# name: DT Output -# address: 24 -# debounce: 500 -# pull: PULL_UP -# shutdown: LOW -# initial: HIGH -# provider: pigpio-digital-input \ No newline at end of file diff --git a/pi4micronaut-utils/build.gradle b/pi4micronaut-utils/build.gradle index 49b64260..47b6b259 100644 --- a/pi4micronaut-utils/build.gradle +++ b/pi4micronaut-utils/build.gradle @@ -7,7 +7,7 @@ plugins { } group = 'io.github.oss-slu' -version = 'v1.0' +version = 'v1.1' apply plugin: 'maven-publish' apply plugin: 'signing' @@ -93,7 +93,7 @@ publishing { mavenJava(MavenPublication) { groupId = 'io.github.oss-slu' artifactId = 'pi4micronaut-utils' - version = 'v1.0' + version = 'v1.1' from components.java artifact sourcesJar diff --git a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/inputdevices/RotaryEncoderHelper.java b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/inputdevices/RotaryEncoderHelper.java index 228c97a8..5dfa42b4 100644 --- a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/inputdevices/RotaryEncoderHelper.java +++ b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/inputdevices/RotaryEncoderHelper.java @@ -1,6 +1,6 @@ package com.opensourcewithslu.inputdevices; -import com.opensourcewithslu.utilities.MultipinConfiguration; +import com.opensourcewithslu.utilities.MultiPinConfiguration; import com.pi4j.io.gpio.digital.DigitalInput; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -23,10 +23,10 @@ public class RotaryEncoderHelper { /** * The RotaryEncoderHelper constructor. - * @param multiPin A {@link com.opensourcewithslu.utilities.MultipinConfiguration} Object. + * @param multiPin A {@link com.opensourcewithslu.utilities.MultiPinConfiguration} Object. */ //tag::const[] - public RotaryEncoderHelper(MultipinConfiguration multiPin) + public RotaryEncoderHelper(MultiPinConfiguration multiPin) //end::const[] { DigitalInput[] allPins = (DigitalInput[]) multiPin.getComponents(); diff --git a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/outputdevices/RGBLEDHelper.java b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/outputdevices/RGBLEDHelper.java index 6c380253..393c5dbc 100644 --- a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/outputdevices/RGBLEDHelper.java +++ b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/outputdevices/RGBLEDHelper.java @@ -1,6 +1,6 @@ package com.opensourcewithslu.outputdevices; -import com.opensourcewithslu.utilities.MultipinConfiguration; +import com.opensourcewithslu.utilities.MultiPinConfiguration; import com.pi4j.io.pwm.Pwm; import org.slf4j.Logger; import org.slf4j.LoggerFactory; @@ -19,10 +19,10 @@ public class RGBLEDHelper { /** * The RGBLEDHelper constructor. - * @param pwm A {@link com.opensourcewithslu.utilities.MultipinConfiguration} Object. + * @param pwm A {@link com.opensourcewithslu.utilities.MultiPinConfiguration} Object. */ //tag::const[] - public RGBLEDHelper(MultipinConfiguration pwm) + public RGBLEDHelper(MultiPinConfiguration pwm) //end::const[] { log.info("Init rgb"); diff --git a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/DigitalInputConfiguration.java b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/DigitalInputConfiguration.java index 8fbf916f..a2d3579b 100644 --- a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/DigitalInputConfiguration.java +++ b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/DigitalInputConfiguration.java @@ -53,12 +53,12 @@ public void setName(String name) { /** * Gets the current debounce value for the component. - * @return Long type representing the debounce of the component. + * @return Long type representing to debounce of the component. */ public Long getDebounce() { return debounce; } /** - * Sets the debounce of the component. Replaces existing debounce. + * Sets to debounce of the component. Replaces existing debounce. * @param debounce New debounce of type Long, */ public void setDebounce(Long debounce) { this.debounce = debounce; } diff --git a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/DigitalOutputConfiguration.java b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/DigitalOutputConfiguration.java index 608e2d71..5b47e07f 100644 --- a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/DigitalOutputConfiguration.java +++ b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/DigitalOutputConfiguration.java @@ -1,6 +1,5 @@ package com.opensourcewithslu.utilities; -import com.pi4j.io.gpio.digital.DigitalOutput; import com.pi4j.io.gpio.digital.DigitalState; import io.micronaut.context.annotation.EachProperty; import io.micronaut.context.annotation.Parameter; diff --git a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/MultiPinConfigs/DigitalInputMultiPinConfiguration.java b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/MultiPinConfigs/DigitalInputMultiPinConfiguration.java index d2aea12b..6737f29d 100644 --- a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/MultiPinConfigs/DigitalInputMultiPinConfiguration.java +++ b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/MultiPinConfigs/DigitalInputMultiPinConfiguration.java @@ -3,12 +3,14 @@ import com.pi4j.io.gpio.digital.PullResistance; import io.micronaut.context.annotation.EachProperty; import io.micronaut.context.annotation.Parameter; +import io.micronaut.context.annotation.Prototype; import java.util.Arrays; /** * This class handles the configuration of a digital input component that has multiple pins. */ +@Prototype @EachProperty("pi4j.multi-digital-input") public class DigitalInputMultiPinConfiguration { private final String id; @@ -23,7 +25,7 @@ public class DigitalInputMultiPinConfiguration { * @param id The configuration id as defined in the application.yml */ public DigitalInputMultiPinConfiguration(@Parameter String id){ - this.id = id + "Multipin"; + this.id = id + "MultiPin"; } /** @@ -106,7 +108,7 @@ public long[] getDebounces() { /** * Sets the debounces for the component. Replaces all the existing debounces. - * @param debounces String representing the dounces for the component. Each debounce seperated by a comma. + * @param debounces String representing the debounces for the component. Each debounce seperated by a comma. */ public void setDebounces(String debounces) { debounces = debounces.replaceAll("\\s", ""); diff --git a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/MultiPinConfigs/PwmMultiPinConfiguration.java b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/MultiPinConfigs/PwmMultiPinConfiguration.java index 73089631..caf5e4c4 100644 --- a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/MultiPinConfigs/PwmMultiPinConfiguration.java +++ b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/MultiPinConfigs/PwmMultiPinConfiguration.java @@ -1,21 +1,17 @@ package com.opensourcewithslu.utilities.MultiPinConfigs; -import com.opensourcewithslu.utilities.Pi4JMultipinFactory; -import com.pi4j.io.gpio.digital.PullResistance; import com.pi4j.io.pwm.PwmType; import io.micronaut.context.annotation.EachProperty; import io.micronaut.context.annotation.Parameter; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; - +import io.micronaut.context.annotation.Prototype; import java.util.Arrays; /** * This class handles the configuration of a PWM device that has multiple pins. */ +@Prototype @EachProperty("pi4j.multi-pwm") public class PwmMultiPinConfiguration { - private static final Logger log = LoggerFactory.getLogger(PwmMultiPinConfiguration.class); private final String id; private String name; private int[] addresses; @@ -29,7 +25,7 @@ public class PwmMultiPinConfiguration { * @param id The configuration id as defined in the application.yml */ public PwmMultiPinConfiguration(@Parameter String id){ - this.id = id + "Multipin"; + this.id = id + "MultiPin"; } /** @@ -86,26 +82,26 @@ public PwmType[] getPwmTypes() { * @param pwmTypes String of PWM types separated by commas. Software should be formatted as SOFTWARE. Hardware as HARDWARE. */ public void setPwmTypes(String pwmTypes) { - String[] pwms = pwmTypes.split(","); - PwmType[] all_pwms = new PwmType[pwms.length]; + String[] PWMs = pwmTypes.split(","); + PwmType[] all_PWMs = new PwmType[PWMs.length]; - for(int i = 0; i < pwms.length; i++){ - if(pwms[i].trim().equals("SOFTWARE")){ - all_pwms[i] = PwmType.SOFTWARE; + for(int i = 0; i < PWMs.length; i++){ + if(PWMs[i].trim().equals("SOFTWARE")){ + all_PWMs[i] = PwmType.SOFTWARE; } else{ - all_pwms[i] = PwmType.HARDWARE; + all_PWMs[i] = PwmType.HARDWARE; } } - this.pwmTypes = all_pwms; + this.pwmTypes = all_PWMs; } /** * Gets the initial states that the component is in when first initialized. * @return Array of integers representing the initial state for each pin. */ - public int[] getInitals() { + public int[] getInitials() { return initials; } diff --git a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/MultipinConfiguration.java b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/MultiPinConfiguration.java similarity index 65% rename from pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/MultipinConfiguration.java rename to pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/MultiPinConfiguration.java index d6ebbe60..afa8edde 100644 --- a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/MultipinConfiguration.java +++ b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/MultiPinConfiguration.java @@ -1,28 +1,22 @@ package com.opensourcewithslu.utilities; -import com.pi4j.io.gpio.digital.DigitalState; -import com.pi4j.io.gpio.digital.PullResistance; -import io.micronaut.context.annotation.EachProperty; import io.micronaut.context.annotation.Parameter; import io.micronaut.context.annotation.Prototype; -import java.util.Arrays; -import java.util.List; - /** - * Class for configuring multipin components. + * Class for configuring multiPin components. */ @Prototype -public class MultipinConfiguration { +public class MultiPinConfiguration { private final String id; private final Object[] components; /** - * The MultipinConfiguration constructor. + * The MultiPinConfiguration constructor. * @param id The configuration id as defined in the application.yml - * @param components The array of components that are a part of the multipin component. + * @param components The array of components that are a part of the multiPin component. */ - public MultipinConfiguration(String id, Object[] components){ + public MultiPinConfiguration(@Parameter String id, Object[] components){ this.id = id; this.components = components; } diff --git a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/Pi4JFactory.java b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/Pi4JFactory.java index 87213723..ef612a63 100644 --- a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/Pi4JFactory.java +++ b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/Pi4JFactory.java @@ -117,7 +117,7 @@ public Pwm createPwm(PwmConfiguration config, Context pi4jContext) { .address(config.getAddress()) .pwmType(config.getPwmType()) .provider(config.getProvider()) - .initial(config.getInital()) + .initial(config.getInitial()) .shutdown(config.getShutdown()) .build() ); diff --git a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/Pi4JMultipinFactory.java b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/Pi4JMultiPinFactory.java similarity index 67% rename from pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/Pi4JMultipinFactory.java rename to pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/Pi4JMultiPinFactory.java index c28950a4..980708be 100644 --- a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/Pi4JMultipinFactory.java +++ b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/Pi4JMultiPinFactory.java @@ -7,35 +7,36 @@ import com.pi4j.io.pwm.Pwm; import io.micronaut.context.annotation.EachBean; import io.micronaut.context.annotation.Factory; -import io.micronaut.context.annotation.Prototype; +import jakarta.inject.Singleton; /** - * The Pi4JMultipinFactory class is responsible for creating all the beans for all multi pin components that are being used. + * The Pi4JMultiPinFactory class is responsible for creating all the beans for all multi pin components that are being used. */ -@Prototype +@Singleton @Factory -public class Pi4JMultipinFactory { +public class Pi4JMultiPinFactory { /** - * Default constructor for Pi4JMultipinFactory. + * Default constructor for Pi4JMultiPinFactory. */ - public Pi4JMultipinFactory() { } + public Pi4JMultiPinFactory() { } /** - * Creates a MultipinConfiguration object for a multi pin digital input component. + * Creates a MultiPinConfiguration object for a multi pin digital input component. * @param config {@link DigitalInputMultiPinConfiguration} Object. * @param pi4jContext The Pi4J {@link Context}. - * @return A MultipinConfiguration object. + * @return A MultiPinConfiguration object. */ + @Singleton @EachBean(DigitalInputMultiPinConfiguration.class) - public MultipinConfiguration multiPinInput(DigitalInputMultiPinConfiguration config, Context pi4jContext){ + public MultiPinConfiguration multiPinInput(DigitalInputMultiPinConfiguration config, Context pi4jContext){ int[] addresses = config.getAddresses(); DigitalInput[] allInputs = new DigitalInput[addresses.length]; for(int i = 0; i < addresses.length; i++){ var inputConfigBuilder = DigitalInput.newConfigBuilder(pi4jContext) - .id(config.getId() + String.valueOf(i)) + .id(config.getId() + i) .name(config.getName()) .address(config.getAddresses()[i]) .debounce(config.getDebounces()[i]) @@ -45,34 +46,35 @@ public MultipinConfiguration multiPinInput(DigitalInputMultiPinConfiguration con allInputs[i] = pi4jContext.create(inputConfigBuilder); } - return new MultipinConfiguration(config.getId(), allInputs); + return new MultiPinConfiguration(config.getId(), allInputs); } /** - * Creates a MultipinConfiguration object for a multi pin pwm component. + * Creates a MultiPinConfiguration object for a multi pin pwm component. * @param config {@link PwmMultiPinConfiguration} Object. * @param pi4jContext The Pi4J {@link Context}. - * @return A MultipinConfiguration object. + * @return A MultiPinConfiguration object. */ + @Singleton @EachBean(PwmMultiPinConfiguration.class) - public MultipinConfiguration multiPinPwm(PwmMultiPinConfiguration config, Context pi4jContext){ + public MultiPinConfiguration multiPinPwm(PwmMultiPinConfiguration config, Context pi4jContext){ int[] addresses = config.getAddresses(); - Pwm[] allPwms = new Pwm[addresses.length]; + Pwm[] allPWMs = new Pwm[addresses.length]; for(int i = 0; i < addresses.length; i++){ var pwmConfigBuilder = Pwm.newConfigBuilder(pi4jContext) - .id(config.getId() + String.valueOf(i)) + .id(config.getId() + i) .name(config.getName()) .address(config.getAddresses()[i]) .pwmType(config.getPwmTypes()[i]) - .initial(config.getInitals()[i]) + .initial(config.getInitials()[i]) .shutdown(config.getShutdowns()[i]) .provider(config.getProvider()); - allPwms[i] = pi4jContext.create(pwmConfigBuilder); + allPWMs[i] = pi4jContext.create(pwmConfigBuilder); } String multiPinId = config.getId().substring(0, config.getId().length() - 8); - return new MultipinConfiguration(multiPinId, allPwms); + return new MultiPinConfiguration(multiPinId, allPWMs); } } diff --git a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/PwmConfiguration.java b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/PwmConfiguration.java index 64bb6b52..760c8b52 100644 --- a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/PwmConfiguration.java +++ b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/PwmConfiguration.java @@ -16,7 +16,7 @@ public class PwmConfiguration { private int address; private PwmType pwmType; private String provider; - private int inital; + private int initial; private int shutdown; /** @@ -71,16 +71,16 @@ public void setAddress(int address) { * Gets the initial state that the component is in when first initialized. * @return The state as an integer. */ - public int getInital() { - return inital; + public int getInitial() { + return initial; } /** * Sets the initial state that the component will be in when first initialized. - * @param inital The startup state as an integer. + * @param initial The startup state as an integer. */ - public void setInital(int inital) { - this.inital = inital; + public void setInitial(int initial) { + this.initial = initial; } /** diff --git a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/SpiConfiguration.java b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/SpiConfiguration.java index 2f6d7282..731bbf64 100644 --- a/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/SpiConfiguration.java +++ b/pi4micronaut-utils/src/main/java/com/opensourcewithslu/utilities/SpiConfiguration.java @@ -6,7 +6,7 @@ import io.micronaut.context.annotation.Prototype; /** - * This class handles the configuration of a SPI component. + * This class handles the configuration of an SPI component. */ @Prototype @EachProperty("pi4j.spi")