Subversion Repositories idreammicro-arduino

Compare Revisions

Ignore whitespace Rev 19 → Rev 9

/trunk/libraries/Eeprom24C128_256/Eeprom24C128_256.cpp
137,7 → 137,7
){
// Write first page if not aligned.
byte notAlignedLength = 0;
byte pageOffset = address % EEPROM__PAGE_SIZE;
word pageOffset = address % EEPROM__PAGE_SIZE;
if (pageOffset > 0)
{
notAlignedLength = EEPROM__PAGE_SIZE - pageOffset;
253,13 → 253,13
byte bufferCount = length / EEPROM__WR_BUFFER_SIZE;
for (byte i = 0; i < bufferCount; i++)
{
byte offset = i * EEPROM__WR_BUFFER_SIZE;
word offset = i * EEPROM__WR_BUFFER_SIZE;
writeBuffer(address + offset, EEPROM__WR_BUFFER_SIZE, p_data + offset);
}
 
// Write remaining bytes.
byte remainingBytes = length % EEPROM__WR_BUFFER_SIZE;
byte offset = length - remainingBytes;
word offset = length - remainingBytes;
writeBuffer(address + offset, remainingBytes, p_data + offset);
}
 
327,3 → 327,4
}
}
}