I have full access to AOSP code and need to have some data (integer number) persisted after factory reset.
I guess the best option would be to read/write to a file, but I don’t know where to store it to be safe from factory reset?
I am also open to using other methods, like props, but I haven’t found anything that would help me with this.
The data must be saved on the device (no cloud etc).