Unfortunately if you have a forgotten/unknown device passcode, or have a disabled device (device unavailable or lockout screen), you have no option but to erase the device. However, you can eventually restore the data and settings from a backup you made before the device was disabled. If you end up having to use a computer and you do not have one, borrow one from a friend, or go to an Apple Retail Store or Apple Authorized Service Provider. You can also use a PC with iTunes. You will likely also need your Apple ID and password. All Apple mobile devices follow the same general procedure but the link below and other links off it provide system and model specific instructions:
If you see an iPhone or iPad unavailable message or Security Lockout screen - Apple Support