Arduino UNO R3 with GPS Shield

hi i just get

Arduino UNO R3 and GPS Shield by iteadstudio v1.1

and i have some questions cuz this is the first time i use both Arduino and the GPS as my supervisor ask me to do it like this for my project

1 - regarding the connection
i connect VDD to 5v + i make the switch to 5v
GND to GND
SDA to A4
SCL to A5
INT1 & INT0 are off
rx & tx i didn`t change the position of the small pace >_< i dono if its do as jumper or somthing else !!
<< and i think all my problem just because of these to RX & TX as i didnt find clear info about connection for them

2 - reagrding the programing
i use the test code from iteadstudio

#include <SD.h>
const int chipSelect = 10;
void setup()
{
Serial.begin(9600);

pinMode(10, OUTPUT);
if (!SD.begin(chipSelect)) {

return;
}

}

void loop()
{
// make a string for assembling the data to log:
char index = 0;
char temp = 0;
String dataString = "";
// open the file. note that only one file can be open at a time,
// so you have to close this one before opening another.
/*
while(Serial.available())
{
File dataFile = SD.open("datalog.txt", FILE_WRITE);
if(dataFile)
{
temp = Serial.read();
dataString += String(temp);
dataFile.print(dataString);
dataString = "";
dataFile.close();
}
}
*/ 
File dataFile = SD.open("datalog.txt", FILE_WRITE);
if(dataFile)
{
while(Serial.available())
{
temp = Serial.read();
dataString += String(temp);
index++;
if(index>200)
break;
}
dataFile.print(dataString);
dataFile.close();
}
}

what i got in the txt file

is

RŒŒ§?HŒŒ
«@Œ?¥¥¥s«@)¥¥¤¥¥¥¥q«H!µ$€¥•
? RŒŒ§?HŒŒ
«@Œ?¥¥¥s«@)¥¥¥¥¥¥¥q«H!µ$€¥•
? RŒˆ§?HŒŒ
«@Œ?¥¥¥s«@)¥¥¥¥¥¥¥q«H!µ$€¥•
? RŒŒ§?HŒŒ
«@Œ?¥¥¥s«@)¥¥¥¥¥¥¥q«H!µ$€¥•
? RŒŒ§?HŒŒ
«@Œ?¥¥¥s«@)¥¥¥¥¥¥¥q«H!µ$€¥•
? RŒŒ§?HŒŒ
«@Œ?¥¥¥s«@)¥¥¥¥¥¥¥q«H!%%c«BŒ?®? RŒŒ§?HŒŒ
«@Œ?¥¥¥s«@)¥¥¥¥¥¥¥q«H!µ$€¥•
? RŒŒ§?HŒŒ
«@Œ?¥¥¥s«@)¥¥¥¥¥¥¥q«H!µ$€¥•
? RŒŒ§?HŒŒ
«@Œ?¥¥¥s«@)¥¥¥¥¥¥¥q«H!µ$€¥•
? RŒŒ§?HŒŒ
«@Œ?¥¥¥s«@)¥¥¥¥¥¥¥q«H!µ$€¥•
? RŒ§?HŒŒ
«@Œ?¥¥¥s«@)¥¥¥¥¥¥¥q«H!µ$€¥•
? RŒŒ§?HŒŒ
«@Œ?¥¥¥s«@)¥¥¥¥¥

!!! << dono y but this is what i got

i use the sample code of tiny gps libary but when i switch the serial monitor to see what i got from gps but its just nothing !! empty

i read this post

and i repeat reading it for 3 days =( but really i didn`t get where is my problem exactly i change the rate and the tx&rx postion
and iam stuck from 3 days just getting empty thing
also i try it when i move in car and outside home jusssst to get clear data or any thing !! but !!! nothing

so i home some1 can help me
as i need to finish some parts of my project before the university start so i hope u guys can help me with my problem =( and thanks

Yeah I get the same crap when i run my gps dongle from the usb at 9600

Any way try setting the serial port to 4800bps, that the usual speed for gps

Confirm:

from:

$PSRFTXT,Version:GSW3.2.4_3.1.00.12-SDK003P1.00a 
$PSRFTXT,Version2:F-GPS-03-0701231
$PSRFTXT,WAAS Disable
$PSRFTXT,TOW:  105921
$PSRFTXT,WK:   1538
$PSRFTXT,POS:  -2170399 4386065 4076920
$PSRFTXT,CLK:  95585
$PSRFTXT,CHNL: 12
$PSRFTXT,Baud rate: 4800

Check the last line. You have your answer mister.

this is the code i try to play with

#include <SoftwareSerial.h>

#include <TinyGPS.h>

/* This sample code demonstrates the normal use of a TinyGPS object.
   It requires the use of SoftwareSerial, and assumes that you have a
   4800-baud serial GPS device hooked up on pins 3(rx) and 4(tx).
*/

TinyGPS gps;
SoftwareSerial nss(3, 4);

static void gpsdump(TinyGPS &gps);
static bool feedgps();
static void print_float(float val, float invalid, int len, int prec);
static void print_int(unsigned long val, unsigned long invalid, int len);
static void print_date(TinyGPS &gps);
static void print_str(const char *str, int len);

void setup()
{
  Serial.begin(115200);
  nss.begin(4800);
  
  Serial.print("Testing TinyGPS library v. "); Serial.println(TinyGPS::library_version());
  Serial.println("by Mikal Hart");
  Serial.println();
  Serial.print("Sizeof(gpsobject) = "); Serial.println(sizeof(TinyGPS));
  Serial.println();
  Serial.println("Sats HDOP Latitude Longitude Fix  Date       Time       Date Alt     Course Speed Card  Distance Course Card  Chars Sentences Checksum");
  Serial.println("          (deg)    (deg)     Age                        Age  (m)     --- from GPS ----  ---- to London  ----  RX    RX        Fail");
  Serial.println("--------------------------------------------------------------------------------------------------------------------------------------");
}

void loop()
{
  bool newdata = false;
  unsigned long start = millis();
  
  // Every second we print an update
  while (millis() - start < 1000)
  {
    if (feedgps())
      newdata = true;
  }
  
  gpsdump(gps);
}

static void gpsdump(TinyGPS &gps)
{
  float flat, flon;
  unsigned long age, date, time, chars = 0;
  unsigned short sentences = 0, failed = 0;
  static const float LONDON_LAT = 51.508131, LONDON_LON = -0.128002;
  
  print_int(gps.satellites(), TinyGPS::GPS_INVALID_SATELLITES, 5);
  print_int(gps.hdop(), TinyGPS::GPS_INVALID_HDOP, 5);
  gps.f_get_position(&flat, &flon, &age);
  print_float(flat, TinyGPS::GPS_INVALID_F_ANGLE, 9, 5);
  print_float(flon, TinyGPS::GPS_INVALID_F_ANGLE, 10, 5);
  print_int(age, TinyGPS::GPS_INVALID_AGE, 5);

  print_date(gps);

  print_float(gps.f_altitude(), TinyGPS::GPS_INVALID_F_ALTITUDE, 8, 2);
  print_float(gps.f_course(), TinyGPS::GPS_INVALID_F_ANGLE, 7, 2);
  print_float(gps.f_speed_kmph(), TinyGPS::GPS_INVALID_F_SPEED, 6, 2);
  print_str(gps.f_course() == TinyGPS::GPS_INVALID_F_ANGLE ? "*** " : TinyGPS::cardinal(gps.f_course()), 6);
  print_int(flat == TinyGPS::GPS_INVALID_F_ANGLE ? 0UL : (unsigned long)TinyGPS::distance_between(flat, flon, LONDON_LAT, LONDON_LON) / 1000, 0xFFFFFFFF, 9);
  print_float(flat == TinyGPS::GPS_INVALID_F_ANGLE ? 0.0 : TinyGPS::course_to(flat, flon, 51.508131, -0.128002), TinyGPS::GPS_INVALID_F_ANGLE, 7, 2);
  print_str(flat == TinyGPS::GPS_INVALID_F_ANGLE ? "*** " : TinyGPS::cardinal(TinyGPS::course_to(flat, flon, LONDON_LAT, LONDON_LON)), 6);

  gps.stats(&chars, &sentences, &failed);
  print_int(chars, 0xFFFFFFFF, 6);
  print_int(sentences, 0xFFFFFFFF, 10);
  print_int(failed, 0xFFFFFFFF, 9);
  Serial.println();
}

static void print_int(unsigned long val, unsigned long invalid, int len)
{
  char sz[32];
  if (val == invalid)
    strcpy(sz, "*******");
  else
    sprintf(sz, "%ld", val);
  sz[len] = 0;
  for (int i=strlen(sz); i<len; ++i)
    sz[i] = ' ';
  if (len > 0) 
    sz[len-1] = ' ';
  Serial.print(sz);
  feedgps();
}

static void print_float(float val, float invalid, int len, int prec)
{
  char sz[32];
  if (val == invalid)
  {
    strcpy(sz, "*******");
    sz[len] = 0;
        if (len > 0) 
          sz[len-1] = ' ';
    for (int i=7; i<len; ++i)
        sz[i] = ' ';
    Serial.print(sz);
  }
  else
  {
    Serial.print(val, prec);
    int vi = abs((int)val);
    int flen = prec + (val < 0.0 ? 2 : 1);
    flen += vi >= 1000 ? 4 : vi >= 100 ? 3 : vi >= 10 ? 2 : 1;
    for (int i=flen; i<len; ++i)
      Serial.print(" ");
  }
  feedgps();
}

static void print_date(TinyGPS &gps)
{
  int year;
  byte month, day, hour, minute, second, hundredths;
  unsigned long age;
  gps.crack_datetime(&year, &month, &day, &hour, &minute, &second, &hundredths, &age);
  if (age == TinyGPS::GPS_INVALID_AGE)
    Serial.print("*******    *******    ");
  else
  {
    char sz[32];
    sprintf(sz, "%02d/%02d/%02d %02d:%02d:%02d   ",
        month, day, year, hour, minute, second);
    Serial.print(sz);
  }
  print_int(age, TinyGPS::GPS_INVALID_AGE, 5);
  feedgps();
}

static void print_str(const char *str, int len)
{
  int slen = strlen(str);
  for (int i=0; i<len; ++i)
    Serial.print(i<slen ? str[i] : ' ');
  feedgps();
}

static bool feedgps()
{
  while (nss.available())
  {
    if (gps.encode(nss.read()))
      return true;
  }
  return false;
}

and the is the serial monitor

as u see its 4800 !!

=(

Well now you not running the same code then up there. Gimme a minute ill check your new code.

Don't worry we will make the day. :slight_smile:

Have you tryed the up there code at 4800?

great i change the
Serial.begin(115200); to Serial.begin(4800);

and now i get this

Sats HDOP Latitude Longitude Fix Date Time Date Alt Course Speed Card Distance Course Card Chars Sentences Checksum
(deg) (deg) Age Age (m) --- from GPS ---- ---- to London ---- RX RX Fail

**** **** ******* ******* **** ******* ******* **** ******* ****** ***** *** 0 0.00 *** 47 0 0
**** **** ******* ******* **** ******* ******* **** ******* ****** ***** *** 0 0.00 *** 70 0 0

is this ok right now ?!

Whole lot of code, where did you get it? and does it have doc?

Yeah if you get this, it mean that you inside and you dont see satelite. You are on the right track

If you have a lap top, pull an extenction corde toward outside and bring you computer with you. you should have result with in 30 seconds

i go outside but till now nothing !! does it need to move in car =\ !! or if i just stand in one place it should get some data ?!

I'm not a shield fan, I prefere module. But I must admit that 25$ for the gps shield is not bad. You got it from them directly?

Well 0km/h is still a speed vector, so no you dont need to move.

Have you tryed you first code? Cause the new one is not perfect for debuging

no i pay around 80$ for the shield even the Arduino it self i pay 60$
=( cuz if i order it from the company direct i will wait for 2~3 weeks to get it + the chipment =( so i pay to finish my project
and till now i pay 270$ just for Arduino + gps + gsm + jumper !! and wait them to work perfect to finish my graduating project :slight_smile:

and thanks for ur help

once i get correct data i will replay soon :slight_smile:

Start by getting the raw data from the satellite, then you can play with the math of vector and position. You must learn to walk before you can run. :wink:

Your first code is easyer to work with

Well now it's personal, knowing that you are a student. lol

I will help you as much as possible, so dont give up

TheBlueDragon:
i go outside but till now nothing !! does it need to move in car =\ !! or if i just stand in one place it should get some data ?!

don't move until you get 1st datas, the fix will come faster than if you move your car
first fix can take several minutes, depending on the environment, the clouds...... next ones will be faster.

Your raw data should look like this:

$GPGGA,163003.000,0000.0000,N,00000.0000,E,0,00,0.0,0.0,M,0.0,M,,0000*6A
$GPGSA,A,1,,,,,,,,,,,,,0.0,0.0,0.0*30
$GPGSV,1,1,01,07,00,000,31*4D
$GPRMC,163003.000,V,0000.0000,N,00000.0000,E,000.0,000.0,170813,,,N*7D

So your first goal is to get that.

I'm inside so i get lots of nothing but you still can see what you should get

thanks bro ^^
thank u soooooooooo much ^
^

for the first code !! same issue

5…!1…4ô 1%!?¥%1?…%%%%c«H?)?1?1	15¥µ	5!!µ!¯?®?
???¥¥%†††Z±!¥??±%?±%!??i?±5¥?%c«B?¥%1?…!1…4ô 1†?¥±	5±¤¥1±…œ???­¦?@1†?%%1?!±†¯?®?$!?¥¥¥µµ!†Z±!¥±?±%?±%!??i?±5%?µk«B?%%1?!1†?? 1†?¥±	5?¤???1œ???­¶?@1†?%%1?…%1µ¥¥¤??¥¥¥µµ!†Z±!¥??±%??%!??i?±5%?µk«B?%%1?…!1…4ô 1%!?%•!5?´±1±…œ???­®?@1%!¥?	5?¤!?®?®?…???¥¥%???cZ±¥???%??%!??i±?%?µc«B?%•!5?$?†?? 1%!?%•!5±´?1±…œ??ç­¾?@1%!¥?	5±¤!?µ$¥¤?ï±¥¥¥1±±%$!±!¥±??%??%!??i?±5%?µc«B?%•!5±$?†?? 1%!?¥•!5!1%%${«H?-•5%a«@1%!¥¥	5!!¥!¥$®?$!??¥¥%???cZ±!¥±??%??%!??i?±5%?µc«B?¥•!5!!1…4ô 1%!?%•!5…ç?±…œç??­¦?@1%!¥?	5…%±?¥¥¤?便¥1±±%$!±!¥±?±%??%!??±?%?µc«B?%•!5…!1…4ô 1†?¥?	5!1???1œï?ç­¦\ 1†?%•!5!!¥!®?®?$!??¥¥%???cZ±!¥±??%??%!??i?±5%?µc«B?%•!5!!1…4ô 1†?¥¥	8?´?1±…$…%ç??­¾?@1†?¥•!5?¤!?®?®?…???¥¥%???
Z±!¥±??%??%!??i±?%?µs«B?¥•!5?$!†?ô 1%!?%•!5?´±%%%k«H1…%???­§?@1%!¥?	5?¤!?¥$¥¤…ï±¥¥¥1±±a«H!?¥±??%??%!??i?±5%?µc«B?%•!5?$!†?ô 1%!?%%1?…5%%%k«H?©¥1?1	15¥±	5?¤!?¥$¥¤?ï±¥¥¥1±±a«H!?¥???%??%!??i?±5%?µk«B?%%1?…!1…4ô 1†?¥±	5?¤?1±…œï??­¶?@1†?%%1?…%±±¥¥¤?ï±¥¥¥1±±a«H!?¥??±%??%!?…i?±5%?%s«B?%%1?…!1…4ô 1†?¥¥	5¥¤?1±…$…%??ç­¶?@1†?¥•!5¥¤!?¥$¥¤?ï±¥¥¥1±±a«H!?¥??±%??%!?…i?±%%?µc«B?¥•!5¥$!†?ô 1%!?%%1?!î?±…œî?ç­¾?@1%!¥±	5µ¤!†µ$¥¤?î?¥¥¥†††Z±!¥??±%?±%!??i?±5%¥¥$€!¥±	5µ$?†?? 1%!?%•!5¥¤???1
œ???­¾?@1%!¥?	5¥¤!†®?®?±???¥¥%†††Z±!¥???%?±%!??i?±5%?%s«B?%•!5¥$?†?ô 1%!?%%1?!ç?±…$…%ç??­¾?@1%!¥±	5µ¤!†¯?®?
??¥¥¥µµ!†Z±!¥???%?±%!±?i?±5%?%?!?H?¥±	5µ$1†?ô 1%!?%•!5?¤%%%s«H?©•5%a«@1%!¥?	5?¤!†¯?®?$!?¥¥¥µµ!†Z±!¥???%?±%!??i?±5%?%?!±H?¥?	5?$1†?? 1†?¥?	5?¤?1±…œî?ç­®?@1†?%•!5?¤!†®?®?…??¥¥¥µµ!†Z±!¥±?±%??%!??i?±5%¥¥$€!¥?	5?$1†?? 1†?¥?	5?¤???1$…%ï??­¦?@1†?%•!5?¤!†¯?®?
??¥¥¥µµ!†Z±!¥±?±%??%!??i?±5%¥¥$€!¥?	5?$1†?ô 1%!?¥%1?…ï?±…œï??­¦?@1%!¥µ	5?¤!†®?®?$!?¥¥¥µµ!†Z±!¥±?±%??%!??i?±5%¥¥$€!¥µ	5?$1†?? 1%!?%•!5±¤%%%{«H?©•5%y«@1%!¥?	5±¤!†®?®?…??¥¥¥µµ!†Z±!¥???%?±%!??i?±5%¥1$€!¥?	5±$1†?? 1†?¥?	5?¤?1±…Cœï??­¾?@1†?%•!5?¤!†¯?®?$!??¥¥%†††R??±?±?±?±
R?¥±???±??R?!¥???%??%!1…Iî±55?µ?µ{«B?%•!5?$1†?ô 1†?¥?	5±¤?1±…$…eî??­¾?@1†?%•#5±¤!†®?®?
??¥¥¥µµ!†R????±????R????±?±!¥±?Iï±5???%!??5cR?¥µ%5$€!¥?	5±$1†?? 1%!?%•!5±´?‡%%k«H‡R%q«@1%!¥?	5±¤!‡¯?®?$!?5?¥¥11%?R??±?±????
R?¥±???±!¥??Iï±5???%!??5k«H!5%µ?±c«B?%•!5±$±†?? 1%!?%%1?…¥%%%{«H?)?1%q«@1%!¥±	5?¤!?®?®?$!?5?¥¥51¥1$!?????????$!?¥????±?±R?!¥?%??%!??5s«H!5%µ?±k«B?%%1?…!%!c? 1%!?%•!5?¤???1cœ???­®?@1%!¥?	5?¤!?¯?®?$!?5?¥¥51¥1R????±?±??R?¥??????±$!?!¥±?±%?±%!??Iî±5%¥µ?±5$€!¥?	5?$1†?? 1%!?%%1?!??±…$…%???­¦?@1%!¥±	5µ¤??®?®?$!?5?¥¥55¥1R??±?????±
R?¥±?±?±??$!?!¥???%?±%!±…Iî±55?5?%!k«B?%%1?!1%!s? 1†?¥?	5?¤%%%k«H?©%?­¶

That still look like you have not change the serial.begin(9600) to serial.begin(4800).

:wink: