Pages: [1]   Go Down
Author Topic: u blox neo-6m and arduino uno problem  (Read 1140 times)
0 Members and 1 Guest are viewing this topic.
Offline Offline
Newbie
*
Karma: 0
Posts: 4
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello everyone. I'm trying to get data from gps module to my pc.

GPS: u blox neo-6m
Data Sheet:
https://www.google.co.il/url?sa=t&rct=j&q=&esrc=s&source=web&cd=1&ved=0CCsQFjAA&url=http%3A%2F%2Fwww.u-blox.com%2Fimages%2Fdownloads%2FProduct_Docs%2FNEO-6_DataSheet_(GPS.G6-HW-09005).pdf&ei=BsUUUvqoKIbm4QT6moGgCQ&usg=AFQjCNFQPsbBHHdHBNAz-EcYSB5T-bkWFA&sig2=72SnC3TA4PbFJTQICJ0zjQ&bvm=bv.50952593,d.bGE



I tried several configurations and connection for example I worked with software serial and I connected to Digits pins.  i also try worked with pins 0,1 for serial information. Also I downloaded all kinds of ready codes and in any case I can not get information similar to what I should get.
Examples of information that should get: $ GPGSV, 9,12,157,31,20,65,236,22,23,18,177,14,28,18, 261,20 * 7C

In the best case I have strings of numbers eg 1291858810812919222291280192291290128330176255
I use this code:

Quote
# include <SoftwareSerial.h>

SoftwareSerial gps = SoftwareSerial (4,3);

void setup ()
{
Serial.begin (9600);
gps.begin (4800);

}


void loop ()
{
while (gps.available ())
{
byte c = gps.read ();
Serial.print (c);

}
delay (100);
}





I really need help.
Thanks to those who can help.
Logged

0
Offline Offline
Full Member
***
Karma: 1
Posts: 185
www.rocketscream.com
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I think most uBlox GPS comes default at 9600 bps instead of 4800 bps like the rest.
I used both MAX-6Q and NEO-6M, both work at 9600 bps out of the box.
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 4
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

i just try to do that and Still recive strings of numbers......
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 4
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

now i get garvege like that: 

this garvege came after casting     Serial.write(byte(serialGps.read()));
what is the cast i need for propper data recive?
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 4
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

pls some help.... smiley-sad
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 21
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

I have exactly the same problem, sometimes I receive garvege like u and sometimes nothing.

I use Arduino example code :
Quote
/*
  Serial Event example
 
 When new serial data arrives, this sketch adds it to a String.
 When a newline is received, the loop prints the string and
 clears it.
 
 A good test for this is to try it with a GPS receiver
 that sends out NMEA 0183 sentences.
 
 Created 9 May 2011
 by Tom Igoe
 
 This example code is in the public domain.
 
 http://www.arduino.cc/en/Tutorial/SerialEvent
 
 */

String inputString = "";         // a string to hold incoming data
boolean stringComplete = false;  // whether the string is complete

void setup() {
  // initialize serial:
  Serial.begin(9600);
  // reserve 200 bytes for the inputString:
  inputString.reserve(200);
}

void loop() {
  // print the string when a newline arrives:
  if (stringComplete) {
    Serial.println(inputString);
    // clear the string:
    inputString = "";
    stringComplete = false;
  }
}

/*
  SerialEvent occurs whenever a new data comes in the
 hardware serial RX.  This routine is run between each
 time loop() runs, so using delay inside loop can delay
 response.  Multiple bytes of data may be available.
 */
void serialEvent() {
  while (Serial.available()) {
    // get the new byte:
    char inChar = (char)Serial.read();
    // add it to the inputString:
    inputString += inChar;
    // if the incoming character is a newline, set a flag
    // so the main loop can do something about it:
    if (inChar == '\n') {
      stringComplete = true;
    }
  }
}

Thanks for your help

Jean
Logged

Offline Offline
Newbie
*
Karma: 0
Posts: 1
View Profile
 Bigger Bigger  Smaller Smaller  Reset Reset

Hello i use the arduino uno and i folow this steps

Here:
http://www.ardushop.com/component/u-blox-neo-6m-gps-module-for-arduino-s-ide-sensor.html


but on code i use the adafruit libraries the ECHO example.

Good Luck




* Captura de tela 2013-11-28 19.56.35.png (912 KB, 1920x1080 - viewed 33 times.)
Logged

Pages: [1]   Go Up
Jump to: