I am really sorry to say that since you have mistakenly upgraded the iOS to 5.0.1. It upgraded the iPhone baseband too and this baseband is currently not unlock-able. One solution would be to install iPad Baseband using Redsn0w while jailbreaking, but in your case, your phone model is new so upgrading the baseband to iPad's baseband would crash your baseband chip and hence the phone would be unusable.
The serial number actually can be decoded to find your phone's exact build date. It is in this format: xxYzzAAAAAA where xx is factory code, Y is year and zz is week. In your case, 87 is phone's code, 1 is year (2011) and 40 is the week (40th week). So, 40th week of 2011. Remember, any phone models made after November/December of 2010 is likely to have the new baseband chip which when upgraded to iPad's baseband will crash.
So, I would suggest you this:
Hope this works!!
- Goto this website (since you were in Vodafone UK) and fill the form: Vodafone UK - Help - Unlock Code Request Form
- Wait till you get an e-mail with unlock instructions (actually it's easy, you just need to connect your phone to iTunes and viola!). It might take a week or so to get this email.
- In the meantime, uninstall ultrasn0w from Cydia.
- Then, restore your iPhone with iOS 5.0.1 using iTunes. After a complete restore, it will ask you to connect the phone to iTunes for activation. But, since you don't have the original SIM you can either wait until Vodafone unlocks your code or use the iClarified's guide to jailbreak and activate the phone.
- If activating through jailbreak, don't install ultrasn0w or corona untether. Just jailbreak your phone using Redsn0w 0.9.10b3 with cydia option (and no iPad Baseband!!). Your phone should be activated and you can use it as an iPod for a time being .
- When your phone is officially unlocked and when you get the confirmation e-mail, connect your iPhone to iTunes and it will be officially unlocked.
Unfortunately, as I now live in Spain, I no longer have a contract with Vodafone and no Vodafone SIM. I will contact them and explain that I have moved but I don't hold out much hope.
I guess my other options are: -
Wait for an iPad baseband solution
Wait for an unofficial jailbreak/unlock solution for 05.16.05
Sell it on ebay to someone with a UK Vodafone SIM
Use it as an expensive paperweight
Anyway, many thanks for all of your input - it really is greatly appreciated. If you have any bright ideas in the near future, please let me know.
Thanks again...