When your iPhone/iPad is cracked or shattered by accident and left locked, it becomes important to get data off the broken device such as photos, videos, contacts, messages, etc. Here, this video tutorial will show you several methods to backup iPhone/iPad with broken and passcode-locked screen.
Quick guide:
#1 Check some of important data in iCloud.com like videos, pictures, contacts, notes, reminders when iPhone is broken and lokced
https://youtu.be/EiZf-I1qGrc?t=18s
#2 Recover data from broken/locked iPhone/iPad with iPhoneRecovery software if the iTunes detects your device on computer. Otherwise you'd better get your gadget repaired first.
https://youtu.be/EiZf-I1qGrc?t=50s
#3 Chances are that you’ve previously made a backup for iPhone/iPad with iTunes, then it would be easy to get back your files.
https://youtu.be/EiZf-I1qGrc?t=4m10s