This is probably a silly question, but I don't have an arduino at the moment nearby but I'm already writing a sketch which I'll need next week.
I have made a function boolean CheckAcknowledge() that waits for a serial acknowledge to check if a command is correctly executed. It will return 'true' when the acknowledge is correctly returned and false if it's not (response indicating that the command was not executed). If there is no response at all, it will timeout after 5 seconds, flag a global variable to mark this, and return a false.
Now my question: can I call this function -somewhere- without minding the response? I would like to use this function at some point just to flag the global variable, but I don't care whether it returns true or false. So, could I just call:
or should it always be something like:
boolean response = CheckAcknowledge();
Thanks a lot for the response!