I want to get a detailed understanding of the serial.available command below.
if (false) {
while(Serial.available() == 0)
;
lstate = state = 0;
}
Most of my code experience is with C and working at the level of configuring the registers and reading data bytes right out of the UART. I have been trying to 'unwrap' serial.available to get a better understanding of how my Leonardo gets each data byte from the GPS (LEA-6) sensor. I found someone who wrote some arduino code to read and display the sensor data as it comes from my GPS. I was hoping I could follow this enough to allow me to write my own code from scratch so I could re-write the code on an ATMEGA 32. I realize the golden rule of programming is not to reinvent the wheel, but I want to understand what is going on. Any ideas?
Sincerely
Russ