The EEPROM emulation code uses wear leveling algorithms to avoid “bricking” your device by frequently changing data.
In simple words: The 2KB EEPROM area gets moved across several flash pages to reduce erase cycles - which are causing flash wear - on each individual page.
@viraj, as @ScruffR pointed out, the STM32 doesn’t actually have built-in EEPROM. Instead, a portion of flash is used to emulate EEPROM. Since flash is not as robust as true EEPROM, extra flash is used along with “wear-leveling” logic to spread the number of flash page erases over multiple pages over time. So the 16KB and 64KB areas are really wear-leveling spaces for the emulation.
If you need a lot of EEPROM storage, you should consider using an I2C or SPI external device. You can also get OneWire devices to reduce pin count.
I have used external 128MB SPI flash along with SPIFFS (SPI flash file system) to store data in file format, much like SDFat but for SPI flash. SPIFFS implements wear-leveling and it works quite well. I believe the SPIFFS library is available on the web IDE.
I have been looking into this since our conversation last week over here but haven't found anything in Particle Dev or web IDE. Am I missing something or is it not up yet?