|
main
{ //Main Start
} //Main End
|
|
int press_lt;
main{
if(get_val(XB1_RT)){ //If RT/R2 is pressed..
press_lt = TRUE; //Variable 'press_lt' is set to TRUE
}
press_lt = FALSE; //Variable 'press_lt' is set to FALSE
if(press_lt) { //This line of code will never see 'press_lt'
set_val(XB1_LT, 100); //as TRUE so the code nested within the if
} //Statement will never be active
}
|
|
int press_lt;
main{
press_lt = FALSE; //Variable 'press_lt' is set to FALSE
if(get_val(XB1_RT)){ //If RT/R2 is pressed..
press_lt = TRUE; //Variable 'press_lt' is set to TRUE
}
if(press_lt) { //This line of code will see if 'press_lt'
set_val(XB1_LT, 100); //is TRUE so the code nested within the if
} //Statement could be activated
}
|
|
int press_lt;
main{
if(get_val(XB1_RT)){ //If RT/R2 is pressed..
press_lt = TRUE; //Variable 'press_lt' is set to TRUE
} else {
press_lt = FALSE; //Variable 'press_lt' is set to FALSE
}
if(press_lt) { //This line of code will see if 'press_lt'
set_val(XB1_LT, 100); //is TRUE so the code nested within the if
} //Statement could be activated
}
|