1) Backup everything you need. (e.g. contacts, applications, ...)
2) Do a hard reset. (*2767*3855# in dialpad) And let your phone boot up.
3) When it's booted up, just shut down your GSM.
4) Now wipe your cache partition. (Press volume up + volume down + start key (middle button) + power on/off key and keep holding them till a screen appears. When you see the screen use volume down and up to select Wipe cache partition and wait till it's done)
5) When it's done shut down your phone again.
6) Download flash program (odin) and
this FroYo 2.2 image. And make the program ready.
7) Connect your phone to your computer and start your phone. From the time you see odin Com port is yellow press the start button.
8) Let odin install the OS, don't remove USB till it says "PASS".
9) That's it. How fun with your FroYo on your Apollo (I5800)