Fixed bug reporting puck detection error
This commit is contained in:
@@ -63,16 +63,20 @@ public class PuckState {
|
||||
case Mechanical:
|
||||
if (this.mecSwitch ==SwitchState.On ) {
|
||||
basePlate.getPucks()[id - 1].detection = Puck.Detection.Present;
|
||||
} else {
|
||||
} else if (this.mecSwitch ==SwitchState.Off ) {
|
||||
basePlate.getPucks()[id - 1].detection = Puck.Detection.Empty;
|
||||
} else {
|
||||
basePlate.getPucks()[id - 1].detection = Puck.Detection.Error;
|
||||
}
|
||||
break;
|
||||
|
||||
case Inductive:
|
||||
if (this.indSwitch ==SwitchState.On ) {
|
||||
basePlate.getPucks()[id - 1].detection = Puck.Detection.Present;
|
||||
} else {
|
||||
} else if (this.indSwitch ==SwitchState.Off ) {
|
||||
basePlate.getPucks()[id - 1].detection = Puck.Detection.Empty;
|
||||
} else {
|
||||
basePlate.getPucks()[id - 1].detection = Puck.Detection.Error;
|
||||
}
|
||||
break;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user