Remove these ads by
Signing UpStep 1: The Hardware
1. An Arduino (which ever you prefer. I stick to the uno, duemilanove, mega, and this bad boy )
2. A GPS module (I'm using the EM-406 from Sparkfun )
3. A matching way to hook the GPS module to the Arduino (I went with Sparkfun's GPS Shield )
4. And a microSD Sheild (Again from Sparkfun )
Some optional stuff:
5. Indicator LED (ok ok I won't force Sparkfun on you for this guy)
6. A nice hard weatherproof case (I used the Pelican 1010 which fit perfectly)
7. Battery (No point logging GPS data tethered to your computer)







































Visit Our Store »
Go Pro Today »




can u upload the full software plz
thanks
I am using your code but it is not printing any values to sd card. Do you know what might be the issue? it creates the text file and adds in "year,month,day,hour,minute,seconds,latitude,longitude,altitude(ft),speed(mph),course" but it does not actually print any values from the gps. The text file is blank besides that one line.
but, by changing as described below, I was successful.
NewSoftSerial nss(3, 2);
->
NewSoftSerial nss(0, 1);
For a first time, it was well constructed.
Now for my problem,
I'm not getting the log file header unless I have the Arduino connected to my computer USB and it is not logging any gps data.
The only thing I have different is the SD card shield, I'm using the Arduino wireless SD shield. http://arduino.cc/en/Main/ArduinoWirelessShield
At first I tried editing the SdFatConfig.h file to change the CS pin from 10 to 4 for my SD shield and that didn't work.
So I changed it back to pin 10 and modified the shield, ( cut the copper trace from pin 4 and connected it to the unused pin 10) still no luck.....
I really looking forward to getting this to work.
But still it doesn't work off the power plug only off the USB. I'm puzzled!
Everything is fine now with a 7.4v Li-Po
Hope this helps someone else in the future!
Thanks for the info and for trying out my instructable!!!!!
I didn't even know that Wireless SD Shield existed, its pretty cool.
In fact, you have stirred up an old project that I have had in mind for a while now :)
Anyways I''m glad you got this all figured out..
Thanks!
Jonnyboy323
Thanks for your patience.
thanx
Thanks for giving my instructable a try. I'll do my best to help you, just let me know after this if anything else isn't clear and I'll got back and update the steps. It is possible the libraries have updated and no longer compatible with my code. I'll have to start from scratch and test it.
But for now, I'll take these problems 1 at a time.
First off, what hardware/breakout boards are you using?
Second: Libraries....
Which libraries do the errors seem to be referring to?
You will need the NewSoftSerial and TinyGPS (links in step 3).
You will also need the SdFat library.
You can get this here: http://www.sparkfun.com/tutorials/172
While you are there PLEASE read the tutorial. I had a terrible time getting that shield working. Then of course after my struggle they seem to launch a tutorial.... It is extremely helpful. (especially when you start getting into some of the harder stuff like writing/reading data to/from the sd card.
Make sure all of these libraries are extracted in the libraries folder of Arduino.
Now onto the hardware.
The first thing I would do is make sure all of your components work individually. There are thousands of arduino tutorials out there. Once you are sure each one works, you can then use use the working code you have found and compare it to what I am doing here (and hopefully modify it to fit your needs!!!!) That is essentially what I did for this project. Just google everything (including the errors) and keep trying until things begin to work.
Lastly pins:
This is a chopped up quote from the sparkfun microSD tutorial I mentioned above. Its about 3/4 of the way down under the section labeled "I downloaded a FAT library for Arduino on my own from the Web but it's not working! Why not?"
"On Arduino, the default pins are D10 (CS), D11, (MOSI), D12 (MISO) and D13 (SCK). The microSD shield, however, uses pin D8 for the CS signal. If this is left unchanged, the library will not work. You'll need to read your libraries documentation to find out where the signals are defined and change the definition accordingly. For example, in the SdFat library the definition is located in the file named 'ArduinoPins.h' and to change the signal on line number 518 from: #define SS_PIN 10 to #define SS_PIN 8"
If the issue is with the gps module, then the look at this line in my code:
NewSoftSerial nss(3, 2); Look at the documentation on NewSoftSerial. I cant remember off the top of my head which is which but for the gps shield it has the option to change the tx/rx pins from 0 and 1 (which are the arduinos tx/rx pins) and 2 and 3 with a little switch. Just adjust the numbers to whatever pins you are using. If it doesn't work, try flipping them. That is one problem that I know I ran into.
Whew that was a lot. Hopefully thats enough to give you a push in the right direct. Just post anything else that comes up and I'll dig out this project to test these things. Please post your results either way!
Thanks again.
Jonnyboy323
I got it to work thank you , I wantted to ask if you were aware that your GPS readings is very inaccurate . Iv done some research and it seems where the problem is is where you convert the output to int. instead of keeping them as is and saving them like that . I have media tek gps and the best accuracy I get when using your code is +- 10km range but when using a GPS example from Arduino I get 3 foot accuracy .
Is there a way you code step away from converting the output to int? And just print them as floats . ? Iv tried but I can get it working then
Thanx for the post very helpfull
Thanks!
Jonnyboy323
Looking forward to your fix , I'm buzy with same setup . Please let me know if you got it fixed .
I tried re-uploading but it is still showing up as a .tmp file.
I do have 2 solutions for you however for now, until a moderator gets back to me:
1. Try a different browser. When I tried Internet Explorer it opened as a link and the full text showed. Simple Copy/Paste.
2. Change the filetype to .pde instead of .tmp and it opens just fine.
Thanks for your interest and sorry for the slight incontinence for now!