Title says almost all.
I've been toying a bit with idea of adding a very lightweight http server to n900 to serve the primary data of the device so that development of the UI can be done nicely on PC while still accessing the real data. One might argue that just pulling the data to PC would solve this and using the existing APIs. Well, yeah, but that's also laborious if you are not linux developer, whereas this approach works beautifully for any web runtime developers as well as developers of qt quick apps.
Doing this on web paradigm allows reuse of many learnings from my past life and creates a very flexible middle layer between the data itself and the UI.
As the first thing to serve as the proof of concept, I created an ATOM image http service on the device. It follows directly the format of flickr, so any code written to show flickr images can be converted to showing n900 images - either on the pc or on the device itself. Data is retrieved from tracker and thumbnails are also trackers pre-generated thumbs.
And here's the beef of course. Once the UI code is working nice and all, it can be just copied to the device and it'll just work. As a demo, here's vanila n900 (no overclocking) running both the server and qt quick application without any noticeable lag. Of course the devices thumsbs suck, as they don't have an aspect-ratio retained version available.
Web server also works as a very nice access control layer between a runtime that can be now very sandboxed. Not that I care.
Hi, thats really nice ... could you share the code, please?
ReplyDeleteFirst I thought it was stupid, but with your example, I really like the idea of exposing phone data via HTTP.
ReplyDeleteOoh! Didn't even think of using a mobile web server as a component to developing like this. It's so simple.
ReplyDelete