Using the methods described here and in the linked post didn’t work: the dd ... commands all failed with the following
dd: /dev/block/bootdevice/by-name/modemst1: write error: No space left on device
4097+0 records in
4096+0 records out
2097152 bytes (2.0 M) copied, 0.108931 s, 18 M/s
What did work was deleting files /dev/block/bootdevice/by-name/modemst1 and /dev/block/bootdevice/by-name/modemst2 which I did via the terminal app in TWRP after mounting system and vendor. Doing it in an adb root` shell command would probably do the same
I think the error message is bogus. It still deletes the file. I somewhere read the explanation for it, but forgot the exact reason, so I am not going to put some speculation about it here.
Thanks. You may be right, but running the dd... commands did not fix the issue for me: the SIM card was still not detected after a reboot. Deleting the files manually via TWRP did fix it for me, so Iposted in case that happens for others. Anyway, the important thing is that issue is now fixed and my phone i working again.
What would be really intersting to know is why the modem files get corrupted in the first place. With that knowledge, it would eventuelly be possible to not let the problem arise at all.
If it’s any use to you in tracking down the cause, I have only encountered this problem very rarely. Until yesterday, the last time was at least two years ago. When I encountered the problem yesterday, I had been swapping SIMs in order to set up one of my test devices as an extra phone for my wife to use while her number is being ported to a new provider. So, in the space of a couple of hours, I swapped a couple of times between
the GifGaff SIM that was in the device before I started;
the EE SIM for the number which is being ported to…
… the new Lebara SIM to which the EE number will be ported (with luck, sometime today or tomorrow).
I seem to recall that when I first encountered the problem I was doing a lot of SIM-swapping and ROM-hopping (between /e/OS, LOS for microG, maybe ‘normal’ LineageOS, but I don’t recall the details, and I can’t find any notes about it in my journal
Trying the dd... approach (via adb root & adb shell - error No space left on device, via fastboot - error Erase operation not supported on partition) did not work. Deleting the files usng the TWRP terminal did work.
Pete maintains the lineageos 4 microg project (I also contribute there as able), and it is that build system that is used to create the unofficial iodé images. Here is the wiki on using it: