If your iPad requires you to input the device Passcode, this must be entered via the iPad's touch screen. To be clear, the device Passcode (when required) cannot be entered using an external keyboard.
If the iPad screen is damaged or broken - and you cannot enter the Passcode - your iPad will require repair or replacement.
iPad Repair & Service - Apple Support
For information, as documented by Apple in its Security Guide, with TouchID or FaceID enabled, you device Passcode is reportedly required in the following circumstances…
A passcode or password is also required if the device is in any of the following states:
• The device has just been turned on or restarted
• The user has logged out of their Mac account (or hasn’t yet logged in).
• The user hasn’t unlocked their device for more than 48 hours.
• The user hasn’t used their passcode or password to unlock their device for 156 hours (six and a half days), and the user hasn’t used a biometric to unlock their device in
4 hours.
• The device has received a remote lock command
• The user exited power off / Emergency SOS by pressing and holding either volume button and the Sleep/Wake button simultaneously for 2 seconds and then pressing Cancel.
• There were five unsuccessful biometric match attempts (though for usability, the device might offer entering a passcode or password instead of using biometrics after a smaller number of failures).
When Face ID with a mask is enabled on an iPhone, it’s available for the next 6.5 hours after one of the following user actions:
• Successful Face ID match attempt (with or without a mask)
• Device passcode validation
• Device unlock with Apple Watch
Any of these actions extends the period by an additional 6.5 hours when performed.