Unfortunately you are right when you say that the specification never describes a standard way to set PIN pending status again in the SIM used by a cellular modem
The recommended solution is a reset of the modem. When you write
Reset works, but it's very slow and seems to be a nasty solution
(Nowadays, it's even possible to logout from windows without
restarting the PC).
you probably refer to the host PC reset, and I agree that it might bee to slow. But you are not required to reset the host as long as you can reboot the modem.
You could either
- Remove its power supply, and this for sure will remove SIM's power supply as well. This depends of course on the way your device is connected to the host.
- Provide an AT command for the device reboot. Usually all vendors have a custom command performing this action. For example Telit modules support command
AT+REBOOT
that reboot both modem and SIM status.
A creative solution: +CFUN=4/+CFUN=1
I tried to find another solution on two of my Telit modems, belonging to GE910 and LE910 families. Only for the first one it worked. For this reason I cannot guarantee it will work for every cellular modem in the world.
As explained in the title, the solution consists in providing in sequence
AT+CFUN=4
AT+CFUN=1
+CFUN
command sets the phone functionality. The first command switches off RF, the second one restores full functionality mode.
But +CFUN=4
command is commonly used as some sort of power saving mode, so that powering off the SIM provides a further power consumption reduction. This is what happens in my GE910-QUAD module.
For this reason it might work also for the uspecified device you are using.