How to store gps values in EEPROM arduino? I have two successfully working individual programs,
1.GPS coordinate extract program.
2.EEPROM saving and reading program.
now all I want to do is combine them both, whenever GPS location is updated ,I want to save that latitude data to EEPROM memory repalcing the previously saved data, but I guess my program is unable to save it,its just showing blank spaces when reading EEPROM,please help me guys..here is my code.

#include &lt;SoftwareSerial.h&gt; 
#include &lt;TinyGPS++.h&gt;
#define RXPin 8
#define TXPin 9
#define GPSBaud 9600
#define ConsoleBaud 9600

// The serial connection to the GPS device
SoftwareSerial ss(RXPin, TXPin);

// The TinyGPS++ object
TinyGPSPlus gps;
#include &lt;EEPROM.h&gt;
int address = 0; 
int read_value = 0; 
char data;
void setup()
{
  Serial.begin(ConsoleBaud);
  ss.begin(GPSBaud);
  Serial.println("Previous value stored :");
  for(address = 0; address &lt; 25; address ++)        // read the entire EEPROM memory
  {  
    read_value = EEPROM.read(address);
    Serial.write(read_value);
  }
  Serial.println("\n");

}

void loop()
{

  while (ss.available() &gt; 0)
    gps.encode(ss.read());

  if (gps.location.isUpdated() || gps.altitude.isUpdated())
  {
    Serial.print("Location: "); 
    Serial.print(gps.location.lat(), 6);
    Serial.print(",");
    Serial.print(gps.location.lng(), 6);
    Serial.println("\n");

    data=(gps.location.lat(), 6);

    for(address = 0; address &lt; 25;  )
    {
      EEPROM.write(address, data); 
      address ++;
    }
  }
}
Consider TinyGPS++ over TinyGPS only if you are running on Due or processor which can take advantage of the higher precision of 64-bit “double” floating-point.

char data; should be double data;. You're wasting resources otherwise.

data=(gps.location.lat(), 6); isn't how you do it. You only need to specify precision when writing to Serial, like Serial.print(gps.location.lat(), 6);. Make it data = gps.location.lat();.

address ++; should be address = address &lt;=512-sizeof(address) ? (address + sizeof(data)): 0 ;

address &lt;=512-sizeof(address) ensures that the last value written to the EEPROM is written in it's entirety. 

Alternatively, I would recommend this to save you data structure directly to EEPROM, and what @jfpoilpret mentions.