Rewrote from Scratch for iOS 7 and 64bit