r1 - 20 Sep 2007 - 07:38:47 - RajMathurYou are here: TWiki >  Main Web > MotorolaA1200

Using the Motorola MotoMing? A1200 with KDE and Linux

This article describes my experiences with using the Motorola A1200 with Debian GNU/Linux. Feedback welcome at mailto:raju(at)linux-delhi(dot)org.

This document is not a newbie guide -- it assumes a fair amount of familiarity with Linux.

Author and copyright

Copyright 2007 by Raj Mathur. This document may be reproduced under the terms of the Creative Commons Share Alike License.

What it is

The A1200 is a GSM mobile phone with a number of features. Since I'm not too keen on carrying multiple electronic gizmos around, I've been using PDA-cum-phones since the past few years. As I'm not too keen on a Winduhs or Symbian based phone, the A1200 is the latest in the series.

The phone includes a Linux-based PDA. Features (stolen shamelessly from some Motorola site) include:

  • Tri-band GSM (900, 1800 and 1900). [Some models have quad-band]
  • Weight: 122 grams
  • TFT 240x320 touchscreen, 18-bit colour
  • Internal antenna
  • Clamshell design with transparent clam cover
  • MonteVista? Linux OS
  • Bluetooth
  • 2 megapixel camera
  • Music player (Real)
  • MicroSD? Memory slot
  • Speakerphone
  • MS and PDF document viewer
  • MMS
  • Internal modem
  • USB
  • Display themes
  • Web browser
  • E-mail
  • FM radio
  • Streaming video/audio
  • Video capture
  • Alarm
  • Calculator
  • Calendar
  • SyncML?
  • To-Do list
  • Voice memos

Availability and pricing

The A1200 is easily available in India from most mobile phone shops. Though the price on the package is Rs 18,370, most of the shops I talked to were willing to give it for Rs. 12,050 (about USD 300) on a cash transaction, add 1.5 to 2% if you want to pay by credit card.

Prices valid as of July 2007.

Package

The phone came with the following items in the package:

  • The phone itself
  • Primary and backup stylus
  • Battery
  • Faux-leather cover with magnetic closing band
  • Clip for cover
  • 512MB memory card
  • Adaptor for memory card
  • Stereo cable headphone
  • Manual
  • Charging cable with Indian mains plug adaptor
  • USB cable

Features I liked

The A1200 charges off USB if you plug it into a computer, which is a great feature. In fact, if you use it regularly with your computer you could probably afford to lose the battery charging cable altogether, since the phone starts charging as soon as you plug it into the computer. Having had bad experiences with phone chargers earlier (I end up stepping on their most delicate parts for some reason), this is a boon for me.

While the phone itself doesn't have much memory (some 11MB or so in all), the ability to add a MicroSD? is useful. I'm working with the included 512MB card right now, will eventually get up enough energy to go and get a 2GB card from the market. 2GB is the largest SD card that the A1200 supports. While not in real MP3 player class, 2GB should give me enough play time to handle those rare cases when I'm in desperate need of music and there's no other player handy.

A nice touch -- under the camera you can find a tiny mirror that lets you see what the camera is seeing, so you can take mug shots of yourself to frighten little children with.

The Business Card Reader (OCR) is sort of decent. It makes stupid mistakes on names, and sometimes recognises the company name as the name of the person. I wouldn't use it on any except the most cleanly formatted cards. However, it's a great toy to impress people with.

Before we start

Some of the packages discussed under come in a special packaging format called MPKG. In order to install those packages you will have to install the MPKG. I found it in a file called yan0.rar, or just look for MPKG_A1200.rar. Instructions for installation are available on the web.

*Installing MPKG could seriously break your phone, so follow the instructions very carefully! Be sure to mount your MicroSD? and make a backup copy of the .system directory before you install MPKG!*

PC setup

I'm running Debian Testing (lenny) with a very few packages from Unstable with the following versions on my PC:

  • Kernel 2.6.18
  • Bluez 3.7
  • Opensync 0.19
  • Multisync0.90 0.91
  • KDE 3.5.7
  • Kdebluetooth 0.99

What's working and what's not

So far I've tested the following connectivity features of the phone, and they're all working fine:

  • Mounting the MicroSD? as a USB drive
  • Telnet'ing into the phone
  • Using the phone as a modem (just tested that AT commands work)
  • Send files to the phone over Bluetooth
  • Receive files from the phone using Bluetooth
  • Synchronisation of Phone Book (one way) over Bluetooth

Connectivity

Right, enough sales talk, let's get down to the Real Stuff. There's 4 types (I'm ignoring the modem mode) of connectivity we're talking about here, so let's look at each one in turn. We'll start with the easiest, mounting the MicroSD? .

I'm not going into details of what kernel modules, etc. are needed since I assume that most modern distributions will ship with kernels with the modules already compiled and set up to auto load. If you have problems on a specific distribution or kernel, go ahead and mail me; if I'm busy I'll redirect you to a list where you could get help.

Accessing the Phone's MicroSD? through Linux

Quick overview:

  • Set the phone into USB mass storage mode.
  • Mount the phone on the PC.
  • Copy files to/from the phone.
  • Disconnect the phone properly.

On the Phone

  • Select Setup
  • Select USB Mode
  • Select Mass Storage
  • Press Save

On the PC

I use the command line for mounting and accessing the USB disk; there's also stuff you can do to auto mount it and have an icon show up automagically on your desktop, you GUI weenie you!

In a terminal, use dmesg(8) to view the last few kernel messages after plugging the phone in. If everything has gone well you would see these type of messages when you plug the phone into the PC's USB slot:

Jul  8 00:48:42 mail vmunix: usb 2-4: new full speed USB device using ohci_hcd and address 57
...
Jul  8 00:48:42 mail vmunix: usb 2-4: Product: Phone
Jul  8 00:48:42 mail vmunix: usb 2-4: Manufacturer: Motorola Inc.
Jul  8 00:48:42 mail vmunix: usb 2-4: SerialNumber: 000000000000
Jul  8 00:48:42 mail vmunix: usb 2-4: uevent
Jul  8 00:48:42 mail vmunix: usb 2-4: device is self-powered
Jul  8 00:48:42 mail vmunix: usb 2-4: configuration #1 chosen from 1 choice
Jul  8 00:48:42 mail vmunix: usb 2-4: adding 2-4:1.0 (config #1, interface 0)
...
Jul  8 00:48:42 mail vmunix: scsi21 : SCSI emulation for USB Mass Storage devices
Jul  8 00:48:42 mail vmunix: usb-storage: waiting for device to settle before scanning
Jul  8 00:48:47 mail vmunix:   Vendor: Motorola  Model: Phone             Rev:
Jul  8 00:48:47 mail vmunix:   Type:   Direct-Access                      ANSI SCSI revision: 04
Jul  8 00:48:47 mail vmunix: SCSI device sdd: 990976 512-byte hdwr sectors (507 MB)
...
Jul  8 00:48:47 mail vmunix: SCSI device sdd: 990976 512-byte hdwr sectors (507 MB)
Jul  8 00:48:47 mail vmunix: sdd: Write Protect is off
...
Jul  8 00:48:47 mail vmunix:  sdd: sdd1
Jul  8 00:48:47 mail vmunix: sd 21:0:0:0: Attached scsi disk sdd
Jul  8 00:48:47 mail vmunix: sd 21:0:0:0: Attached scsi generic sg3 type 0
Jul  8 00:48:47 mail vmunix: usb-storage: device scan complete

In this case, the MicroSD? is being recognised as /dev/sdd; yours may show up as /dev/sda or some other letter. The partition is /dev/sdd1. Now mounting it is simple:

mkdir -p /media/sdd1
mount /dev/sdd1 /media/sdd1

After you have mounted the MicroSD? you can access it as /media/sdd1. Use your favourite Linux commands to copy files back and forth between your PC and the phone.

When you are done don't forget to unmount and eject the MicroSD? properly, otherwise buffered data may remain unwritten:

eject /dev/sdd1

Telnet'ing into the phone

Quick overview:

  • Install and run the USBNet application on the phone.
  • Configure the USB network device on your PC.
  • Ping and telnet to the phone.

Install USBNet

To telnet into the phone you need the usbnet_a1200.zip or USBNet_A1200.pkg files. Copy the .pkg file to the MicroSD? , use the phone's file manager to find it and click on it to install it. If clicking doesn't work, keep the pointer down on the file icon, select Open with from the pop-up menu, and select MPKG. You could also check the Always use the program to open files of this type button to have MPKG automatically handle files of type .pkg in future. (You did install MPKG as requested earlier, didn't you?)

Now the phone will switch from Modem to USBNet mode whenever you click on the USBNet application in the phone. The only feedback you get when this happens is a chime from the phone, so don't worry if you don't see anything happen when you execute the application.

Configuring USB on the PC

The phone gets an automatic address when it's in USBNet mode; on mine it is 192.168.1.2, other people have reported other addresses. If your phone's address is 192.168.1.2, you need to configure your usb0 interface accordingly on the Linux end:

ifconfig usb0 192.168.1.6 [or any other address in the 192.168.1.x range]

Now you should be able to ping the phone and telnet to it:

ping 192.168.1.2
telnet 192.168.1.2

Use root as the login, it doesn't have a password. Most of the basic Unix/Linux commands work, but don't try anything fancy, it probably won't work.

If you don't get a usb0 interface on plugging the phone in, make sure that you have the cdc_ether and zaurus modules available for your kernel. They are both needed for USBNet in Linux.

Bluetooth file transfers

Quick overview:

  • Install the Bluetooth dongle and bluez-utils.
  • Configure bluez-utils if desired.
  • Install kdebluetooth and start kbluetoothd.
  • Configure kdebluetooth if desired.
  • Use kbtobexclient to send files to the phone.

Connecting the A1200 to the PC using Bluetooth

You need the bluez-utils (in Debian) package to enable Bluetooth. Of course, you also need a Bluetooth dongle smile The dongle I'm using is:

Integrated System Solution Corp. KY-BT100 Bluetooth Adapter

It's recognised automatically if bluez-utils is installed. I had to make minor changes to /etc/bluetooth/hcid.conf and /etc/bluetooth/pin to get the phone to bind to the computer:

  • in hcid.conf, change the security user to security auto
  • in pin, put in a 4-digit number (e.g. 1234). This will be the default PIN for bonding with all bluetooth devices.

Restart the bluetooth service (/etc/init.d/bluetooth restart in Debian), turn on the Bluetooth in the phone and search. You should find your computer and be able to bond with it using the pin that you entered in the pin file.

Transferring files over Bluetooth

I used the KDE Bluetooth tools for file transfers. The Debian package is called kdebluetooth and a simple aptitude install gets and installs it for you. After installation you can run the kbluetoothd app manually once to start it.

You can configure notifications and permissions for various Bluetooth services through the KDE Control Centre -- select Internet & Network and Bluetooth Services in that. I prefer to automatically receive files from my own devices, so in the Confirmation tab I've added a rule for kbtobexsrv (the file transfer server) and my phone and set allow as the policy.

Once this is done you should be able to send a file from your phone (hold down the stylus on a file name in the file manager, select Share, Bluetooth and your computer and send). KDE will popup a window with the file name (and preview, if it can) and ask you to save it. If you haven't enable accepting files automatically from your phone, you may need to confirm the transfer first.

To send in the reverse direction, use the kbtobexclient application, which is available under Internet in the K menu. The first time you send a file to your phone you may need to make the phone discoverable so the app can find it. Once it's found, select your phone in the Device Selector window on the bottom left and drag and drop files from the file system panel on top to the File to send (bottom right) panel. Click Send when you're ready to transfer files.

Backing up the phone book

My biggest worry is losing or damaging my phone and losing the nearly 300 contacts I've fed into the phone's memory. Using the Motorola Winduhs-based tools wasn't an option (since I don't have Winduhs), so the choices I was left with for synchronising my contact database were:

  • Installing a SyncML? server on my PC and somehow getting the phone to sync with that over USBNet.
  • Somehow doing a sync over Bluetooth.

As it is shipped, the A1200 doesn't support syncing over Bluetooth, as far as I can tell. However, there's a III-party Java midlet available for it, and with some tweaking I managed to get it to work.

Quick overview:

  • Install the j2mesync application on the phone.
  • Give the application permissions to read/write files.
  • Install multisync0.90, Opensync and the j2mesync plugin.
  • Configure multisync0.90.
  • Perform the sync.

Installing the software on the phone

The instructions and software for performing the sync over Bluetooth are available at http://www.ohl.name/?J2MESync. Download the Midlet from there and install it on the phone. Once that is done, you need to give the Midlet permissions to access the PIM API on the phone. This will require editing the Midlet's registry manually.

You will first need to locate the directory into which the Midlet meta-data has got installed. This will be one of the directories under /mmc/mmca1/.system/java/DownloadApps (if you telnet-ed to the phone) or /.system/java/DownloadApps (if you access the file directly from the MicroSD? ). Within this directory you will see one or more directories named MIDletXXXXXX? , where XXXXXX is a 5-digit number. Each of these directories contains a file named registry.

Look for the registry file that contains j2mesync.jar in the Jar-Path entry. This is the one you have to change. In this file, change the Domain from Untrusted to Manufacturer. Now when you start the j2mesync application on your phone it will be able to read (and hopefully write -- not tested) the Address Book.

Installing software on the PC

On the Debian end I used the multisync0.90 package (aptitude install multisync0.90) for performing the sync. You need the j2mesync plugin for this, also available on the same page as above. I used the Debian package from there, but the Opensync plugin source tarball is also available if you prefer to compile or package it yourself.

You may also need to install Opensync and its plugins on your PC. They are available as standard Debian packages.

Once multisync0.90 and the plugin are installed, you can start multisync0.90 and configure it for syncing with the phone:

  • Add a new group, called (say) A1200
  • Edit the group and add file-sync and j2mesync-plugin as members.
  • Click on file-sync, and add the directory where you wish your contacts to be saved between the <path> and </path> markups. Create the directory if it doesn't exist.
  • Click on the j2mesync-plugin and add your phone's MAC address between the <btmac> and </btmac> markups. Insert 7 between the <btchannel> and </btchannel> markups.

[If you don't know your phone's MAC address you can get it from the Properties menu option in the phone's Bluetooth application.]

Backing up the phone's address book to the PC

OK, you're ready to backup your contact database to your PC. On the phone, start the j2mesync application. The phone will ask you to confirm write permissions a number of times, just accept it each time. Now go to the application menu and select the backup contacts entry.

On your PC, click on the Refresh button for the A1200 group. The phone should now start sending the contact list (and other items like calendar, TODO, etc.) to the PC. While the sync is going on the PC will display how many entries it has received, and the phone will display the number of the entry that is sending. At the end, you should see a sync successful message, and your backup directory should contain a number of files that each contain a phone number or calendar item, etc.

Miscellaneous

The motorolafans site has pointers to a huge number of games that work on the A1200, exactly the sort of stuff you need to keep you occupied while waiting for the judge to pronounce the sentence.

There's also tons of other applications for all sorts of stuff available. Since the phone runs J2ME? , most J2ME? applications will also work out of the box. The ones that usually give problems are those that extensively use the number keys; since the phone doesn't have a keypad, it becomes difficult or impossible to use those.

The camera sucks.

The headphones have no bass at all. OK if you're listening to old Hindi songs (I mean, when was the last time you really sat and listened to the left-hand tabla, huh?), but makes trance and rock a tad vapid to listen to.

Resources

I found the Motorola Fans web site to be the best resource for information related to doing just about anything on the A1200. The site is http://www.motorolafans.com/.

Web searches for MIDP or J2ME? throw up tons of applications that can be used with the A1200.

Conclusion

So far I'm quite happy with the phone -- it plays music, it plays games, it runs Linux and most important for me, it allows me to save my address book on my PC. It even makes phone calls! I'd recommend the phone to anyone looking for a reasonably priced GSM PDA-cum-phone.

-- RajMathur - 20 Sep 2007

Edit | WYSIWYG | Attach | Printable | Raw View | Backlinks: Web, All Webs | History: r1 | More topic actions

tip TWiki Tip of the Day
RSS news feed of topic changes
You can use an RSS news reader to find out what is new in a TWiki web. This complements WebChanges that ... Read on Read more

 
Kandalaya
This site is powered by the TWiki collaboration platformCopyright © by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding TWiki? Send feedback