fadi ladhari
/
GPS_System_with_Google_Maps
hello_world
Fork of GPS_System_with_Google_Maps by
main.cpp
- Committer:
- fadi_lad
- Date:
- 2017-01-04
- Revision:
- 6:8cc48b05d20e
- Parent:
- 4:6ed9c8bb82c3
File content as of revision 6:8cc48b05d20e:
#include "mbed.h" #include "GPS.h" Serial pc(A4, SERIAL_RX); GPS ark(PA_9, PA_10); DigitalOut myled(LED1); int main() { while(1) { if( ark.sample() == 1) { myled=0; float latitude = ark.latitude; float longitude = ark.longitude; float utc =50000; pc.printf("latitude: %0.2f, longitude: %0.2f, utc: %f\r\n",latitude,longitude,utc); wait(1); } else { myled=1; } } }