diff --git a/eu.heili/DigitalInput.java b/eu.heili/DigitalInput.java index 389e466..210b20d 100644 --- a/eu.heili/DigitalInput.java +++ b/eu.heili/DigitalInput.java @@ -20,19 +20,11 @@ public class DigitalInput { } public void setValue(int value) { - if(value > 0){ - this.value = true; - }else{ - this.value = false; - } + this.value = value > 0; } public void setValue(char value) { - if(value == 'H'){ - this.value = true; - }else{ - this.value = false; - } + this.value = value == 'H'; } public boolean getValue() {