Modifications

Sauter à la navigation Sauter à la recherche
1 322 octets ajoutés ,  8 mai 2012 à 11:26
Ligne 127 : Ligne 127 :     
[[Fichier:GpsUltimateArduinowire.jpg]]
 
[[Fichier:GpsUltimateArduinowire.jpg]]
 +
 +
Next up, download the Adafruit GPS library. This library does a lot of the 'heavy lifting' required for receiving data from GPS modules, such as reading the steaming data in a background interrupt and automagically parsing it. [https://github.com/adafruit/Adafruit-GPS-Library To download it, visit the GitHub repository and click the DOWNLOADS button in the top right corner] , rename the uncompressed folder '''Adafruit_GPS'''. Check that the '''Adafruit_GPS''' folder contains '''Adafruit_GPS.cpp''' and '''Adafruit_GPS.h'''. Place the Adafruit_GPS library folder your <arduinosketchfolder>/libraries/ folder. You may need to create the libraries subfolder if its your first library. Restart the IDE.
 +
 +
Open up the File→Examples→Adafruit_GPS→echo sketch and upload it to the Arduino. Then open up the serial monitor. This sketch simply reads data from the software serial port (pins 2&3) and outputs that to the hardware serial port connected to USB.
 +
 +
You can configure the output you see by commenting/uncommenting lines in the setup() procedure. For example, we can ask the GPS to send different sentences, and change how often it sends data. 10 Hz (10 times a second) is the max speed, and is a lot of data. You may not be able to output "all data" at that speed because the 9600 baud rate is not fast enough.
    
== Source ==
 
== Source ==
29 837

modifications

Menu de navigation