Device encryption fails, but no error I am trying to encrypt my android device (Samsung S3, Modified 4.1.2). I have set a password and made sure my device is plugged in and charged over 80%.

When I select the encryption option, the screen shows a wired-diagram of an Android figure and then restarts after about 10s. There are no errors and I can still use my device, but it clearly has not been encrypted.

I've retried multiple times with the same results. Can anyone help?

Thanks

EDIT (possible explanation)... 
My device is currently encrypting. I decided to try with my SIM card removed. I had a SIM lock setup, so I'm wondering if that was interrupting the encryption when the phone restarted. 
Although I am curious, I am not going to go as far as unencrypting, removing the SIM lock and trying again, so I can't be certain that was the cause.
There was a similar issue in Android 4.2 whereby encryption failed as described if the phone was plugged into a computer's USB port, but worked if plugged into a charger. I don't know when this bug first appeared or whether it has been fixed in a more recent version, but it's worth trying a plain charger.