GPS and SD card problem

But you're still reading two characters, when you're only certain there's one to read.
Did you mean to store the character, and use the stored character for the print and the encode?