Cam sometimes reset

Hello,

Sometimes the camera resets itself, removing all files on it. Do you know a reason for it to happened ?
I also sometimes have my files corrupted, but this might happen because I shutdown the cam while a file is opened.

Yeah, if you’re using the internal flash drive we only have 3 big erase sectors of about 32kb each. If you power off the system you can loose 32kb of data which could include the file allocation table for the drive which would destroy everything.

Please use an SD card for a file system that’s safer to write if power will turn off randomly.

If the changes are not written/flushed the file system will be corrupted. The next time you power up the cam it re-creates the FS if it’s corrupted.

I made sure not to shutdown while writting, but the cam still sometimes reset (default files are put back in, main and selftest I think). It may happen because I physically disconnect the cam when it’s connect to the IDE, do you know anything about that ?

If you are using the internal flash drive and just wrote a file please make sure to execute the rest OpenMV cam command from the IDE. This makes sure to flush the fat file system buffer. Alternatively if you use an SD card most problems go away.