If you’ve never heard of these … the Internet is a truly big place. Both of these are by Christophe Grenier:
https://www.cgsecurity.org/wiki/
https://en.wikipedia.org/wiki/PhotoRec
YMMV - but - I recently used Photorec to recover >50,000 of images (including jpg, png and RAW) from a Mac RAID drive that the Mac could no longer read - not even in a USB caddy.
Now obviously, this won’t blow anyone’s hair back on an SBC but it could be pretty useful in an emergency to pull valuable images from (say) a memory card attached to a USB card reader. It’s more than just photo recovery and can even scan for things as diverse as Skyrim save games and database files… pretty neat stuff. ![]()
I’ve not had any chance to run Testdisk but it’s highly respected and been developed for a number of years. Like PhotoRec it reads all manner of odd formats. God I love DietPi and I don’t care who knows it.