Showing posts with label mobile. Show all posts
Showing posts with label mobile. Show all posts

2011-11-13

App Camp 2011, first day

So, App Camp kicked off at about 6pm on Friday with a greeting from Andrius Kubilius, the prime minister of Lithuania, followed by Rimantas Žylius, the minister of economy. The politicians were wearing jeans and jackets, no ties already. Kubilius reminded us on numerous occasions that it's the XXIst century, confessed that he wouldn't be able to make a mobile app, and asked for an app that would solve the budget deficit issue. The MC commented that the PM is not as tech-naive as he presents himself, as he's using both and iPad and a Samsung Galaxy Tab, because, as he tells, the apps are different on these. Žylius reminded us that everything is possible, if even he could become a cabinet minister.

Several short keynotes by foreign guests and local mobile community tycoons were followed by the app pitches. Each team had 60 seconds to present their idea to attract collaborators. Most of them have been pretty good, the presenters were successful in conveying their idea and getting people interested.

There were several recurring themes: 3 pitches for apps for fishermen, 3 pitches for loyalty system apps (with the promise of ridding your wallet of all these loyalty cards), a coulple of GPS adventure games geared to get geeks of their monitors, a couple of variations on the where to go for lunch theme.

Other app ideas that I found noteworthy: an egg cooking simulator for small kids, rules of the road reader & quiz, onboard Java IDE, location-based hitchhiking hookup, mobile app based on the sviesoforai.lt traffic congestion IS, a mobile app to report places of environmental concern for green NGOs to take care of, GPS taxi meter to tell if you're getting ripped off, a mobile confession app that uploads the audio to a CMS for a priest to listen to and grant penance over the air. A game to learn the map by navigating Lithuania and Europe by choosing the direction by the names of the adjacent towns. The prize for the best pitch (Samsung Galaxy S II) was awarded to the guy operating a clothing swap web site, who promissed his collaborators access to a database of 100k girls in Lithuania with names, profile photos, clothes sizes, and contact details :) That's the team I joined!

Then there was time for networking over soft drinks and light snacks. Later, beer appeared, too. It appeared that a lot of the app ideas were proposed by marketers willing to promote the idea and looking for devs to implement it for free. Undecided developers were floating from one circle to the next, looking for a good app idea to invest their weekend in.

My clothes swap team consists of 4 developers and a designer. At 9am on Sunday the development began with brainstorming over coffee and cinnamon buns. We were driven off the premises at 10pm. We have a working app with the main functionality fleshed out, but perhaps it's too early for screenshots yet. If interested, the code is on GitHub: https://github.com/alga/AppCamp16. My team mates who have some iOS experience, but have not dealt with Android before, commented how easy developing for Android is.

Vilnius - ŠnipiškėsThe whole event is held in the airy, light, inspiring spaces of the National Gallery of Art, one of my favourite buildings of all. The venue was a substantial factor in my decision to come and participate. I'm very glad I came, and not only because of the building. I'm looking forward to the next day (which is quite soon already, time to catch some sleep!)

2011-09-19

Updating Samsung Galaxy S SCL GT-I9003 to Gingerbread in Ubuntu


So, I came across the news on the net that Android Gingerbread 2.3.4 update has been made available by Samsung to GT-I9003 phones. Apparently, it was being rolled out on a country or region basis via Samsung's Kies application. First I tried updating the phone with Kies in Virtualbox, but that didn't quite work, I could not get Kies to connect to the device. (Might be the reason was that the phone was not in Kies USB mode). Then I tried booting the OEM Windows Vista on the laptop. Vista had worked after I copied the partition from another hard drive, but now it refused to boot. Apparently, system could come up from hibernation, but depended on the hard drive unique ID in order to boot. Some web browsing, several reboots and trials later, I repaired the Vista boot configuration with the help of a warez Vista DVD. The laptop's recovery partition is useless -- basically it offers restoring from an external backup made earlier or a "factory reset". No Windows recovery, no command prompt.

So, turns out Samsung Kies sucks on real Windows as much as it does on Virtualbox. Granted, it did connect to my phone, but I could get more out of it than a backup of the 7 contacts in my phone's memory (the rest are synch'ed with Google). But backing up the 300 photos I have made Kies show a progress bar for 15 mins and then choke. And worst of all, there was no update of any kind offered! I wasted about 10 minutes staring at progress bars waiting for it to install, and then some 30 more minutes staring at progress bars waiting for the backups to fail.

So then I looked again at flashing the phone myself. I got the firmware from samfirmware.com, found the instructions for flashing with the leaked proprietary Samsung Windows flasher called Odin, got the Open Source flasher Heimdall (Debian packages worked fine), found an encouraging blog post on how to use it.

The firmware from Samfirmware is a RAR archive (password: samfirmware.com) containing a tar:

-rwxrwx--- 1 alga alga 191658005 2011-09-19 01:23 I9003XXKPH_I9003XXKPH_I9003SERKPH.rar
-rw-rw-r-- 1 alga alga 353699840 2011-08-10 09:53 I9003XXKPH_I9003XXKPH_I9003SERKPH_HOME.tar

Inside the tar, there are the firmware images:

$ tar xvvf I9003XXKPH_I9003XXKPH_I9003SERKPH_HOME.tar
-rwxr--r-- jonghoon/na-cdma-sw 262144 2011-08-09 15:19 boot.bin
-rwxr--r-- jonghoon/na-cdma-sw 1310720 2011-08-09 15:19 Sbl.bin
-rwxr--r-- jonghoon/na-cdma-sw 618496 2011-08-09 15:19 param.lfs
-rwxr--r-- jonghoon/na-cdma-sw 5787648 2011-08-09 15:19 normalboot.img
-rwxr--r-- jonghoon/na-cdma-sw 324751360 2011-08-09 15:19 system.rfs
-rwxr--r-- jonghoon/na-cdma-sw 12582912 2011-08-08 06:23 modem.bin
-rwxr--r-- jonghoon/na-cdma-sw 8378368 2011-08-09 15:20 cache.rfs

Apart from these, you need a partition table image (*.pit, latona_20110114.pit in my case), that can be downloaded from the Samfirmware site, too.

The phone needs to be placed in download mode. Everyone on the internet says this can be done by holding down Volume Down, Home, and Power buttons at the same time, but this did not work for me. An alternative is to use adb:

$ adb reset download

Then the flash command is as follows:

$ heimdall detect
Device detected
$ heimdall flash --pit latona_20110114.pit --primary-boot boot.bin --secondary-boot Sbl.bin --normal-boot normalboot.img --cache cache.rfs --modem modem.bin --param param.lfs --system system.rfs

About 2 tense minutes of progress counters uploading these files, a long reboot, and presto! The phone boots up into Android 2.3.4 Gingerbread!

The heimdall flash command can be run with the --repartition flag or without it. Repartitioning is needed if the partition layout is different, or, as one forum post suggests, a filesystem type changed. However, it seems that the partition layout is the same for all GT-I9003 versions (Samfirmware suggests the same pit file), so just flashing the partition images is OK.

Looking at other firmware archives, it looks like the number of images and their names vary. You just need to match up the files you have with the heimdall option flags (in other words, partition names of your phone). The heimdall print-pit can be useful here, it prints out the actual partition layout of the device.

The nice thing about flashing Android updates is that none of the user data was overwritten -- the system lives on separate partitions from installed programs and their data. Although, of course, there is a risk that something goes wrong, so it's wise to back up data before flashing.

Now, speaking of Gingerbread, it seems that most of the goodies added in it Samsung had already forward-ported in their Froyo firmware. I hope that they fixed the stability issues. My phone used to crash often with a black screen on Froyo when sitting idle.

2011-03-29

Android FTW

Finally, I got an Android phone. It's a Samsung Galaxy S SCL. Got it at the end of Friday, had the whole weekend to play.




Small, posh box. Quality accessories. A charger the size of a matchbox, practically just the plug. Earbuds with rubbery thick wires that do not tangle up. The device is slick, the UI is fast and smooth.

The UI is all translated, with a couple of amusing bugs. One of them is that the Bluetooth menu is, in fact, Italian, not Lithuanian (it, lt, big deal!) "Impostazioni Bluetooth. Ricerca dispositivi." Then there are some usual cases where the translator did not quite get what they're translating. "Build number" in the system information is translated as "Sukurti numerį" (literally "create a number").

The Android Market is amazing. I found everything I needed: an ssh client, a PasswordSafe program, a fb2/html/txt book reader, an OpenStreetMap based vector map program with address search and routing, an app for WindGuru and Windfinder, a virtual drum kit like my bro had on iPhone4, etc. Usually there are more that one choice for each particular type of app. But I'm going to write my own fuel log app anyway, as the one that does everything I want and a bit more is castrated in the free version.

Turns out, with Android it's even harder to hide your data from Google. Just enter your Google account creds once, say in the Google Talk app, and look, your address book is sync'ed with your Google account too! It can all be turned off, of course, but still. That's my current tinfoil hat conspiracy theory as to why Google invested in Android -- to gob up everyone's address books!

I tried avoiding feeding all my data to Google. I played with SyncEvolution for two hours trying to fish out the data from my Symbian phone. In the end it worked, I had the phonebook on the laptop as a directory with 350 vcards. Now it's just a matter of adding the new device, and pyushing it up there, right? Bzzzt, what do you mean Android not supported!? Turns out it's true. Android has no SyncML support built in. There are apps that might or might not work over the network, but Bluetooth, here and now, is out of the question.

I went to the Android Market and looked for a phonebook import app. Found one that did exactly what I needed -- filled the address book from a directory with vCards. A couple of minutes, and here we have it! But wait, all non-ascii characters got mangled, double-UTF-8-encoded. Good job the app is GPL, bzr repo available at the author's web site. Another half-hour, and I have the SDK all set up with Eclipse integration. A quick look at the source, a couple of recompiles and reruns, one offending line commented out, and the phonebook is all imported. Only later I found that the standard phone book app has the vCard import/export too, perhaps even without bugs! The patch for the import app is still to be sent.

Anyway, now I'm diving into Android dev tutorials and reading Bloch's Effective Java.

2010-11-15

Mobile Monday Vilnius (Nov 2010)

A couple of hours ago I participated in the Mobile Monday event. It was quite cramped, also it was quite fun. There were four 15 minute presentations. Here's a summary:

Omnitel
: smarphones are, like, selling, and, like, their market share is, like, increasing. Over 50% of the phones we sell nowadays "have an operating system".

Microsoft: Windows Phone 7. We realised that our mobile OS offering is crap, so we took a fresh start. We're going to give a shot at the exercise we failed at back in 1985: try to imitate what Apple is doing! See, it's all touchy and slidy and aesthetically appealing! Apps are the key, so please go and download our SDK for free! Castrated Visual Studio, emulators, templates, everything is free! Then you can submit apps to our app store, we'll review them, and then you will be able to make moneys! The platform you use to develop apps is a mix of our browser bling platform and our gaming console toolkit!

Then there was a 15 minute breather break, as the air got quite stuffy.

Nokia: Yeah, well, we realised that we had a lot of stuff (a slide with logos for Java, Python, Qt, Maemo, Meego, Symbian, and some more) so we decided to get our story straight: Qt (pronounced "cute")!!! It's the new Java, write once, run anywhere!!! Symbian, Meego, it's all irrelevant, Qt is what you'll develop your apps in! Also, we have an app store we call OVI. We will sell your Qt apps there. It's really cool, the customer is billed on their mobile bill, we have agreements with most of the providers in the world. It will cost you more, but with no credit cards involved, customers have a lower barrier to buy. Also, we encourage and invite local apps and local services, create a great local app, we will put in on the featured page for your locale, and you'll be RRRRRich!

Some guy: Mobile web. A lot of people use web on their mobile. Uhhh. So we should develop mobile versions of our sites. But having http://m.* in front of URLs kinda sucks, and people disregard these, just go to the main site and pan and zoom. CSS3 and HTML5 is the answer. Apple has a lot of nice demos of that! But wait, they're only drafts now. And Javascript is the answer! Thanks, bye.

Then there was a panel with the presenters FINALLY taking questions.
Audience: MS guy, what are the hidden costs in your platform?
MS guy: it's free! Download with one click, install, develop your content, submit!
Audience: but come on now, how much does it cost in reality?
MS guy: I'm telling you, it's really free.
Audience: What about VisualStudio?
MS guy: We give you a special version we call "Visual Studio Express" for free! Well, if you want to experiment with the look&feel, you need to cash out for the full blown one, but to summarize it's free.
Audience: Nokia, the Symbian Foundation has fallen apart, what do you make of it?
Nokia guy: Symbian, Shmimbian, it's all irrelevant, Cute is the answer!
Audience: What about the horrible signing process?
Nokia guy: we fixed it! If you submit an app for review to our OVI store, we'll sign it for you! And Qt is the new thing!
Audience: what about the market share? How much market do you gather your plaform has?
Nokia guy: Frankly, I don't know and don't care. And as I said, platforms are a thing of the past, Qt is the king.
MS: We hope we will get some market share! PLZ help, but sorry, you need to get someone abroad to buy you a phone and then submit an app for you. Anyways.
Omnitel: Weeeel, obviously, S60 is by far the moooost popular smartphone platform in Lithuania, then there is Apple, and Android is rising, and RIM is also showing promise...

Then the questions were over and there was some shmoozing over wine and finger food. By then it was pas 8pm, so the crowd dissipated quickly.

2008-06-19

Huawei E220 USB HSDPA modem on Linux

Tested on Ubuntu Hardy. When you plug the modem in, things happen:


[ 1872.829603] usb 5-2: new full speed USB device using uhci_hcd and address 11
[ 1872.988741] usb 5-2: configuration #1 chosen from 1 choice
[ 1872.998189] usb-storage: probe of 5-2:1.0 failed with error -5
[ 1872.998226] airprime 5-2:1.0: GSM modem (1-port) converter detected
[ 1872.998441] usb 5-2: GSM modem (1-port) converter now attached to ttyUSB0
[ 1873.006403] usb-storage: probe of 5-2:1.1 failed with error -5
[ 1873.006437] airprime 5-2:1.1: GSM modem (1-port) converter detected
[ 1873.006615] usb 5-2: GSM modem (1-port) converter now attached to ttyUSB1
[ 1873.057365] scsi30 : SCSI emulation for USB Mass Storage devices
[ 1873.058803] usb-storage: device found at 11
[ 1873.058810] usb-storage: waiting for device to settle before scanning
[ 1876.078727] usb-storage: device scan complete
[ 1876.082294] scsi 30:0:0:0: CD-ROM HUAWEI Mass Storage 2.31 PQ: 0 ANSI: 2
[ 1876.117573] sr0: scsi-1 drive
[ 1876.117674] sr 30:0:0:0: Attached scsi CD-ROM sr0
[ 1876.117754] sr 30:0:0:0: Attached scsi generic sg1 type 5


As you can see, we get two serial ports and a CD-ROM drive. The second serial port and the CD-ROM drive can be ignored. PPP works straight away with the following config:


noauth
connect "/usr/sbin/chat -v -f /etc/chatscripts/e220"
debug
/dev/ttyUSB0
230400
crtscts
defaultroute
noipdefault
user ignored
remotename whatever
ipparam whatever
usepeerdns


Here's the e220 chatscript (put in into /etc/chatscripts, replace the "****" with your pin code, replace "omnitel" with your provider's APN):


# Chat file for Huawei E220 HSDPA USB modem
ABORT BUSY ABORT 'NO CARRIER' ABORT 'NO ANSWER' ABORT DELAYED
'' AT
OK AT+CPIN="****"
OK ATX3
OK 'AT+CGDCONT=1,"IP","omnitel"'
OK ATDT*99***1#
CONNECT ""

2008-06-08

New phone

Got a new phone

I got a new phone on Thursday, Nokia 6120 classic. It is my first Series 60 phone. I have been a loyal Nokia user for around four years now, mostly because of the ubiquity and universality of Nokia chargers. During the whole time they were producing GSM handsets, Nokia has changed the charger connector only two times. Each time the change was motivated by miniaturization.

Series 60 3rd edition is very nice. The UI metaphor is different from Series 40, but it's quite intuitive and comfortable. Surprisingly, there's no stopwatch app, but of course there already are too many Stopwatch apps for S60 on the web. Should I write another one? :-) There's a snag that this phone is not yet supported by Gnokii/Gammu/Wammu, so I had to install the Nokia PC suite on Windows in order to transfer my contacts from my old Nokia 6230i. Know what? It was not flawless. Getting the contacts from the 6230i was easy (if we ignore the constant Vista disk grinding), not so with restoring the backup on the 6120c. It took Nokia PC suite 3 attempts to create the Bluetooth pair, install the drivers on the PC and on the phone, and connect to the phone.

The phone has all the 3G technologies: UMTS, HSDPA. During my first Internet connection test on a late Thursday evening speedtest.net indicated 1.2 Mbps down and about 100 kbps up with a 3.5G (HSDPA) connection. On a Saturday night though the speed fluctuated between 300-600 kbps on average, and it took a couple of attempts to establish an HSDPA connection, I would get EDGE instead. I'm using the Bitė GMS network. We'll see how things will go with Omnitel.

Yesterday I installed Python on the phone. I set up and played with a Bluetooth console. The Hardy bluez-utils are broken (see Ubuntu bug 211525), so I had to install bluez-utils from Sid. The Bluetooth console is much more convenient than banging in Python code on the phone keyboard, but it does not have readline.

I got an impression that Nokia wants people to use Python on Series 60 very much. They try very hard to make it easy, provide all sorts of docs, even multimedia tutorials. Probably they see the ease and accessibility of Python as a path to widespread platform adoption. The Python API has easy access to most of the phone's functionality, including the GUI toolkit, camera, bluetooth, networking, messaging, contacts and so on. I have an impression that cooking a homebrew contacts backup/restore application in Python will be pretty trivial. I cannot start hacking away as Python looks for modules on the flash card, and I haven't bought a microSD card yet. On a positive note, it's nice that this time Nokia didn't include a cheap claustrophobic-sized card. They're useless after you buy a real card, but hard to throw away, so they contribute to cruft accumulation in life.

Unfortunately, Nokia only provides the platform SDK for Windows, but there are ways to use the GNU toolchain in combination with the SDK and some Wine.
The SDK is needed in order to package Python scripts as SIS installable files. Even then, I'm not sure it will work, as Series 60 3rd ed. only accepts packages signed by a registered developer. There should to be a way to play with your own software, no idea yet what's involved.