Unfortunately this is not possible, as the reset button is hardwired to instantly cut all power, it’s like pulling the plug on your PC while it’s running.
If we could have software control over the button, we would have disabled it a long time ago due to the damage it may cause.