Chapter 13
else
{
initialize_serial_buffers;
}
}
On receiving an invalid command, the initialize_serial_buffers routine re-ini-
tializes the buffers that hold the command and response and thus prepares to
receive a new command.
initialize_serial_buffers:
command_index = 0
response_index = 0
received_command[0]= 0
return
void initialize_serial_buffers(void)
{
command_index = 0;
response_index = 0;
received_command[0]= '\0';
}