MCPcopy Create free account
hub / github.com/RobTillaart/Arduino / clear

Method clear

libraries/FRAM_I2C/FRAM.cpp:258–269  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

256
257
258uint32_t FRAM::clear(uint8_t value)
259{
260 uint8_t buf[16];
261 for (uint8_t i = 0; i < 16; i++) buf[i] = value;
262 uint32_t start = 0;
263 uint32_t end = _sizeBytes;
264 for (uint32_t addr = start; addr < end; addr += 16)
265 {
266 _writeBlock(addr, buf, 16);
267 }
268 return end - start;
269}
270
271
272// EXPERIMENTAL - to be confirmed

Callers 1

unittestFunction · 0.45

Calls

no outgoing calls

Tested by 1

unittestFunction · 0.36