mirror of
https://github.com/team2059/Dent
synced 2024-12-18 20:52:29 -05:00
Changed DIO Get if statement to a case
This commit is contained in:
parent
e70dd861ed
commit
4c9ce0b57b
@ -7,12 +7,15 @@ DIO::DIO(){
|
|||||||
void DIO::InitDefaultCommand(){
|
void DIO::InitDefaultCommand(){
|
||||||
}
|
}
|
||||||
bool DIO::Get(e_dioSig dioSig){
|
bool DIO::Get(e_dioSig dioSig){
|
||||||
if(dioSig == ELEVATORTOP){
|
switch (dioSig){
|
||||||
// The top elevator digitalinput was triggered
|
case ELEVATORTOP:
|
||||||
return elevatorTop->Get();
|
return elevatorTop->Get();
|
||||||
}else if(dioSig == ELEVATORBOTTOM){
|
break;
|
||||||
// The buttom elevator digitalinput was triggered
|
case ELEVATORBOTTOM:
|
||||||
return elevatorBottom->Get();
|
return elevatorBottom->Get();
|
||||||
}
|
break;
|
||||||
|
default:
|
||||||
return false;
|
return false;
|
||||||
|
break;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user