I have stopped maintaining this prototype.
Nokia 5800 XpressMusic doesn’t have kinetic scrolling out of the box, nor does it have apps with kinetic scrolling. So while I was studying rapid prototyping, I created a prototype application for the 5800, with Flash Lite. The idea was to try and create a prototype of kinetic scrolling, some kind of component for future Flash Lite development and devise effective and smooth algorithms for the scrolling.
Update: Nokia 5800 now has kinetic scrolling, as of firmware v40! Go get it!
While I managed to create a prototype, I struggled with a smooth algorithm. Especially since Flash Lite’s performance was quite poor. But nevertheless, I gave it a shot and learned a lot. Of course, it was loads of fun too! I enjoyed it!
Starting with the Pseudo
Before starting anything else, I came up with some pseudo code to back-up the experiment. It was nothing fancy, really simple and straight forward stuff, pretty much something like this:
state = idle
start_time = 0
scroll_threshold = 20px
accel = 0
friction = 0.1
on_tap:
state = tapped
start_time = now()
start_location = location()
on_finger_move:
if state = holding
calculate_acceleration()
else if state = tapped
distance = abs(location() - start_location)
if distance > scroll_threshold
state = holding
on_release:
if state = tapped
this.run()
else if state = holding
add_event('update', this.kinetic_scroll())
kinetic_scroll()
// calculate the speed from acceleration and friction
The toughest cookie to crack here is the calculate_acceleration() -function, which I’ve foulishly abstracted away in the pseudo.
Algorithms and acceleration
I already mentioned earlier, that I struggled coming up with an algorithm for calculating the acceleration, all the while creating a smooth User Experience. The fact that someone might want to drag up and down consistently and release his finger after a while got me totally stuck. I had to actively calculate the current acceleration, I couldn’t quite get it working with Flash Lite and I couldn’t come up with a smoothly working version in the very short time I worked with the prototype. Mind you, I was tinkering with this prototype after work and only for a week. After that, my interest for the project vanished and I moved on to other projects… But I might pick this up again ;)
Phone Book.swf running
Download!
At the moment, my prototype only has very basic kinetic scrolling. If you just flick it, it’ll scroll ok. But if you drag it around, up and down, and only then release, it won’t budge. It’s very basic because this way I could demo it for my friends and not have weird things happen :)
Anyhow, I’ll supply the swf -flash files in a moment, which you can then upload to your 5800 or N97 and test-drive it. I’m also gonna publish the .fla files, even though the code is somewhat dirty.
Update: Here are the SWF –files! Just upload them to your phone and execute in the file manager! The program uses your contacts for test data and asks for your permission, just answer “Yes” :-)
Update: and here’s the .fla and .as -files. WARNING! My first Flash Lite and ActionScript code ever. I take no responsibility at all.
Download source .fla
ZIP, 48 KB
More?
If you want to read more about kinetic scrolling on Nokia devices, check out Gravity, the number one twitter client for S60 and Kinetic Scroll Component for Flash Lite, which came out while I was only drafting this post!
Also, any help or comments regarding the algorithm for calculating the acceleration are welcome!
Wow,,, this is so smooooooth and alive,,, i wish nokia will insert this code in thier apps and give us Kinetic Scroll on the 5800.
amazing work, keep it up
Man i loved it, keep going…hope nokia make the same in next firmware of 5800 :D
Thank you both for your encouraging comments! :)
I wish too that Nokia would implement something like this soon, kinetic scrolling rocks
I’m sorry, it didn’t work for me. My screen just flashes and then the application closes. Maybe this is because I have a different language in my phone.
same problem as ddenns, i select allow for this session, and it crashes.
saw the vid on youtube, very impressed
ddenns and mogensai:
Ouch, that’s bad :(
I only had my own 5800 to test with, so it’s no wonder there are problems. I think I’ll maybe look into that and post an update here if I find something that might be causing it – but I can’t test it properly because it’s working fine on mine.
I probably need to make it not work on my phone :)
doesn’t work on my 5800 just flash , ask me to access to my data and exit…
thanks!
doesn’t work on mine too! opens, asks to allow, i say allow, then closes.
could you make a widget version of it? or maybe a sis version? giving it permissions by default so that it doesn’t ask us again and again! :-D
wickeeeeedddd ^.^ thanks!
please ur app is impressive ….can u make a option button for call sms delete add contact.etc. in ur future release…
please tell me through mail…..as fast as u can bcoz i like ur idea very much…
u can even pack ur swf file to sis file for free from swfpack website……..
hi
i have one more idea….. can u make a kinetic scrolling music player application….bcoz
every one having nokia 5800 have 8 gb card in them so minimum of 1000 songs….people find t difficult,irritating, to use the scroll bar provided in the default nokia music player…..so if u can create a music player with flick scrolling it will be great…not 1 or 2 ..but millions of nokia 5800 users will download ur application…
u donot need to make a complete music app in the start only but first make a 1st version with basic play,pause function with the same ui of phone book u created…the u can expand to send options and so on…….. as u told me ur on ur holidays so donot take trouble 2 reply me immidiately… when ever u have time u can tell me wheather u can make this or not…. :D
(“Gravity” a twitter applications has crossed thousands of downloads bcoz of the only reason it supports kinetic scrolling in their app.)
okay can someone please tell me… which Format are these .fla files??
I tried Flash 5, Flash MX 2004, Flash 8, Flash CS3 …but still “unexpected format”
Please reply… thanks !
@Hasan:
They’re Flash CS3 format files.
Damn, I’ve experienced this myself too… An example .fla I found once could only be opened on my laptop, not on my desktop. I changed a few things in the example and saved it and then I could open it on my desktop!
Weird stuff, I could try opening the .fla files, change a few things and re-upload them here?
hi
please tell me….when are u going to release the phone book app. with call feature…and i did not get any reply 4m u regarding the music player app. i told u….
@i own nokia 5800:
Sorry, I’ve been a bit busy lately :) I will do an update prototype the soonest I can – promise! I have just come back from my holiday and there’s lots of stuff going on :)
About the music player – I agree that browsing the song list is a pain in the ass. It’s horrible. But Nokia is hopefully coming out with an update for the 5800 soon. Nokia has already showcased a soon-to-be-released update for N97, which has kinetic scrolling everywhere, even in the song list! I just hope they release the update for N97 soon and move on to 5800 next :)
If they don’t update the 5800, then I will get mad and try out if I can do it
@Arun and Stefano:
Damn! I don’t know what’s wrong with it – maybe somethings funny with Flash Lite on your phones? Dunno, hard to debug.
I’m not sure, but I think if I wanted to put this out as a .sis I’d need a Symbian Certificate and I don’t have one :(
Hello! Depressing klooper notwithstanding my english jer, buti danged nice re say gJ$)Kd!!!.
works for me, great job :D
Which programm did you use? Flash CS3?
@lol Flash CS4 actually! :)
Awesome scrolling!! just what every single person who owns a nokia 5800 needs. Please send this code to nokia so that they can learn how easy it can be to provide kinetic scrolling in 5800 they’re just providing dumb firmware updates without kinetic scrolling..
Please create some application using kinetic scrolling (may be an sms reader like iphone).
Really appreciate ur work. keep it up!!!
@Muhammad Usman:
Thank you!! It’s just a prototype though :) Jan Ole from mobileways.de has a much more alive kinetic scrolling on his app Gravity, I wish Nokia would get his source code and implement that one :)
Yeah, I agree with you on the dumb firmware updates. Nokia released just yesterday 31.0.101 firmware for the 5800 and there was nothing of interest in that updatel. I’m fed up with Nokia and I’m going to sell my Nokia 5800!
you don’t have to get it signed, just make an unsigned sis, and people with hacked phones (like me :) can install it… please.
another thing, i think the most important app on the 5800 that needs kinetic scrolling is the web browser, please consider this before thinking of applying kinetics on any other app on the 5800…
really appreciate your work. you’re a good man :)
it’s compatible with samsung i8910 Omnia ?
Haven’t tested, so I have no idea.
If you test it, let me know how it worked! :)
Hi…i got Omnia i8910 HD and Tested it…after i clicked on the SWF file..the Phone book list came out and it is scrolling nicely but can not select any name on my list to see the contents of the contact…
Ciao…
@MacjR388: sorry, this is just a prototype for kinetic scrolling, so you can’t interact with the contacts :/
i have a 5800.i want to install kinetic scroll in it.hoe can i do that?i have sent u a facebook request pls accept it.
i want to increase the speed of scrolling in my nokia 5800, can you tell me plz how to do it
the precious information u presented do help my research for our company, appreaciate that.
Who would like to support donate to Japan?
It’s’ extremely unfortunate as to what is taking place in Japan, so assist donate!
Japan demands your help!