You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
CreateiveRobotics edited this page Mar 7, 2020
·
2 revisions
boolgetInt(iType &myIvar)
Try and convert the next item in the payload into an int. If the attempt was sucesfull the result will be written to the myIvar variable, and the method will return true.
This will work with signed and unsigned values, and eight, sixteen or thirty two bit ints. The method will first attept to convert the String to an normal int, before casting it to the specific type included in the argument.
example:
int myInt;
if(cmd.getInt(myInt)){
cmd.print("Success, my int is: ");
cmd.println(myInt);
}