It's a feature not a bug. Not sure why they did this but all iPads come up into the lock screen state when they're unplugged. Somewhere deep in the dungeons of Apple there is guy who wrote that little bit of code.....
Anybody got an explanation as to why this was programmed into iOS? I've never seen this discussed before - it's something we've all come to accept without question, I guess.
A slightly more bizarre and potentially 'dangerous' feature is that, if you have a Bluetooth keyboard that you use with your iPad and the iPad is in sleep mode and you hit a key on the Bluetooth keyboard 'waking it up' then it wakes up the iPad too - but bypasses the lock screen and goes straight to the Home screen. If you've got your Autolock set to 'Never' you can easily find that your iPad battery has discharged completely without you noticed it.....
Tim