Sunday, March 15, 2009

My initial tests with the GPS code gave me an area that was different than I anticipated. After a little bit of research, I realized that GPS data comes in degrees, arc-minutes, and arc-seconds. When I went back and looked at the code I noticed that the arc-seconds were being converted to get the correct data. Basically, the last four digits of the code needed to be converted to arc-seconds from the raw data the GPS receiver was collecting.

For instance, the software would tell me I was standing at...

+32° 52' 49.14", -117° 14' 19.48"

But the actual data that the program was using was...

32 52 8190, 117 14 3247

In order to fix this I needed to multiply the last 4 digits by .006 in order to get the correct position that the GPS was receiving. Later I added some code that would tell me the raw data the receiver was collecting along with the true GPS coordinates. This made it much easier to create the data I needed for my if statement to create the area that would set off the motor.

No comments:

Post a Comment