Micro-sd card repair tool?

This is not related to the uConsole; next time you’ll get faster replies if you ask a general Linux user-group.

As has been previously said, a GParted live image is worth its weight in gold. The copy on my desk used to be a compact disc for i686 to use in place of my Windows XP installation, now it’s any architecture and contained in a Ventoy drive, and it’s still very useful. The trick is to use https://rufus.ie. MS Windows is not a great choice for filesystem maintenance as, while there is a plethora of exiting tools, the userland itself is buggy and brittle; Windows is simply too unstable to trust to do something so critical, and this really can’t be understated because it is the flash drive equivalent to sticking your videocassette into a VCR that has a nasty habit of shredding tapes.

What you might try is, using the GParted live image or another Linux system (*BSDs aren’t a great choice for their current lack of wide filesystem support), check smartctl(8) to see if your drive is toast or just corrupted, then use cfdisk(8) to rewrite the drive table, setting aside maybe 10GB of data (i.e. don’t let your partitions touch the last 10 gigabytes) for use by the block controller. testdisk(8) is also an option if there’s critical data you need back. After the table is written GParted may have an easier time accessing the drive, but if it doesn’t, the invocations mkfs.vfat -F 32 /path/to/boot; mkfs.ext4 -L ROOT /path/to/root; will probably still work and allow the drive to be used with Linux.

Your SD card is probably damaged but avoiding the damaged section of the drive will allow you to get further use out of it, especially using a read-only distro. It was probably corrupted by Windows reading or writing a particularly bad part of the block device and having poorly written logic for handling such an event - which is an uncharitable assumption, but describes the behavior I’ve seen quite a few times from the system.

This is what “the fuss” is about Linux - people evangelize it because the alternative is people constantly writing in with peripherals borked by a company that doesn’t and has never cared.