Hi, I would like some help on my code using a the TEL0051 V3.0 GPS face shield. I am trying to simply get values at setup to be used in the loop section of the code. from what I got on the Serial monitor it is definitely wrong. I keep getting inf values for my variables I want displayed. I'm not sure is the hierarchy flow of my code is correct. I have posted the code and also the serial monitor. My guess is that the GPS does not read any satellites quick enough so the setup function and the rest of the code will display inf symbols. My serial monitor only outputs once, so it did not loop. Is there a way I can obtain the initial distance and bearing once as stored variables from the GPS? I just want the DC motors to move forward and stop when distance is equal to zero. The check 'if' statement is if the initial distance subtracted from the distance traveled. Am I doing any of this right or on the right track? Should I implement an odometry style of code where I would count the number of revolutions on my wheels and find the distance traveled that way and subtract the initial distance? I am purely using just the GPS, Uno, and a DC motor controller. I will be adding sensors later, but I need my code to work with only the GPS and motors. I've also linked the sites of the components I used.
GPS:
The Motor controller:
A picture of it soldered (best I could find to what I am using):
Please and Thank you for any help
P.S. I am working outside on this. Ask any standard question needed to help me please.
PrimaryCode2.ino (10 KB)