Now here’s a nice hack Lance Fetters (ashikase) has been working on for some time now. The (perhaps somewhat useless but imho really cool) point is to make the icons on the SpringBoard rotate according to the device’s orientation. On an earlier version, he managed to hook into the SpringBoard to make the icons rotate smoothly by 90 degrees about every second. The slightly trickier part was to get an extension of SpringBoard to receive the accelerometer data. This basic concept seems to be working now, albeit a little sluggish; on initial testing it only worked for firmware 2.2 (on 2.1 it craps out after a few seconds; SpringBoard seems to kill the accelerometer), where it also gets killed on quitting apps. This definitely still needs some work. But that’s no reason not to show some previews, right?
So here’s a few little videos to demonstrate rotating SpringBoard icons (made with Cycorder on another iPhone; mind you, the quality isn’t Hollywood-proof). The first one uses 3D animated SpringBoard icons:
Even though the math is still a bit off, it’s very nice as a proof-of-concept.
The next version of this hack uses 2D animation for the icons:
There are still some issues on page flipping here. So I figured that can be avoided by using only 0, 90, 180 and 270 degree rotations, and gave it a try. After some fooling around, it seems to be working:
So while there are still some issues to sort out… we hope you enjoyed this little preview!
Btw, for the Five Column SpringBoard hack, visit Yanik Magnan aka Sakurina’s iPhone Hacks (and this thread at MacThemes).
[Edit:] I have refined the logic much more now, and have more or less duplicated the functionality of UIDeviceOrientation: the code knows whether the phone is pointed up, down (Y), left, or right (X), and if it’s facing up or down (Z), and can act on that knowledge accordingly. In this case, the icons rotate smoothly to the current device orientation, but they don’t rotate when the device is facing (almost) straight up or down, like when it is lying on a flat table. Otherwise, tiny differences (e.g. -0.0001 to 0.00001 and back to -0.00001 again over either X or Y axis) would lead to rotations, which is quite awkward behaviour. The native screen view rotation on the iPhone also works like this, as you’ll probably know (try it with the Safari or iPod apps, for example). Unlike the native automatic view rotation, rotating to an upside down view is allowed. It could be blocked, though, if that would be desirable for some reason.
Btw, the reason this logic has to be duplicated, and why accelerometer support has been trickier than with the regular iPhone app, is that there seems to be a bit of Münchhausen-esque circularity going on here: SpringBoard uses UIKit, but UIKit also depends on SpringBoard.
UIDeviceOrientation can apparently not be used when hooking SpringBoard, since SpringBoard actually is responsible for sending info about stuff like the device orientation and the raw accelerometer data to applications that are listening for it (i.e. apps that have registered themselves for such services which SpringBoard provides). If this were a normal application, we would of course just have used the much simpler method of just listening to UIDeviceOrientation, and acting on that. But since we basically are just intercepting calls from applications to SpringBoard and changing them a bit, we can’t tap into outgoing data like UIDeviceOrientation, and must roll our own version (actually, I’m not very sure at all this is all technically strictly correct, but it is how I understand it at this point). Turns out that this ‘obsolete’ bit of ancient accelerometer code on steike.com wasn’t so obsolete after all… it just needed to have slightly different values than before since this stuff seems to keep changing different firmware versions.
Next objectives: integrating the icon badges, the (dynamic) calendar icon contents, labels and perhaps the status bar. The latter two will also require some icon repositioning, like Saurik’s Five Icon Dock and Sakurina’s Five Column SpringBoard MobileSubstrate tweaks. Thus I expect that adding those will be slightly more complicated… To be continued !!
[Edit 2:] The icons in the dock (or ‘button bar’ in Apple’s under-the-hood terms) are now also joining in on the fun, like they should. Yay!
[Update:] So it seems that even without releasing it it still spreads like fire! Apple iPhone School somehow got their hands on a copy and posted a video, and even the frenchies are talking about it (here too)! Hopefully a first public release will be available in a week or so. Stay tuned!
[Update2:] Unlike some false rumours,
the project isn’t dead at all, I am still working on it whenever I can afford to, and am still making progress. But I don’t have much free time available to spend on this stuff, unfortunately, while I have many other (usually more important) things on my to-do list. I will be fixing up the website a bit first, and then probably send out the .deb for testing to all you who showed interest before putting it up on Cydia. Currently don’t have much need for beta testing by users, as I am quite aware of where the issues lie.
The current plan is to release a simple version of SpinBoard first, and later - hopefully - a more complete landscape mode SpringBoard tweak, with user configurable accelerometer support. I would also like to see how far it can be taken into a more extensive system-wide tweak that rotates the UI according to device orientation. I want to be reasonably sure first that at the very worst, it stops working, but that it doesn’t unexpectedly cripple or crash your precious devices. So I need to take out the crazy shit and buggy code first, while in the time I have been able to spend on it until now, I much preferred to add more of that instead.
I will also be posting a few video’s to show off some other tweaks that you guys may be interested in and will probably go around and up at about the same time. Useless, weird stuff, but quite pretty at times imho. Fun for at least a few minutes.
No Comments »
RSS feed for comments on this post. TrackBack URL.