SPI EEPROM & GPS logging
i have got exact same chip eeprom stated on website tutorial spieeprom. got hardware interfacing , work using code provided.
http://www.arduino.cc/en/tutorial/spieeprom
now appreciate understand how store "long int" number instead of "char" shown in code. website seems can write 128 bytes @ time , since in example used char (which 1 byte) spi transfered in following code:
for (int i=0;i<128;i++)
{
spi_transfer(buffer); //write data byte
}
how change long int (which 4 bytes, 32 bits). how addressing affected?
ps: want store "latitude, longitude" comes out of tinygps library functions.
any sample code or nudge in right direction explain eeprom addressing , storage appreciated.
thanks
http://www.arduino.cc/en/tutorial/spieeprom
now appreciate understand how store "long int" number instead of "char" shown in code. website seems can write 128 bytes @ time , since in example used char (which 1 byte) spi transfered in following code:
for (int i=0;i<128;i++)
{
spi_transfer(buffer); //write data byte
}
how change long int (which 4 bytes, 32 bits). how addressing affected?
ps: want store "latitude, longitude" comes out of tinygps library functions.
any sample code or nudge in right direction explain eeprom addressing , storage appreciated.
thanks
Arduino Forum > Forum 2005-2010 (read only) > Software > Interfacing > SPI EEPROM & GPS logging
arduino
Comments
Post a Comment