| 256 | |
| 257 | |
| 258 | uint32_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 |