Friday, June 25, 2010

Using Android with Eclipse, creating AVDs on Mac

I found some helpful information on working with Android in the Eclipse environment, and added my own comment on creating an AVD, here.

Wednesday, June 23, 2010

taking a crack at things with 2.1

Verizon Wireless released an Android 2.1 ROM update for my HTC Eris Droid cell phone. I am hoping maybe that the Android Application Programming Interface docs and the Eclipse Integrated Development Environment plugins might be a more friendly environment for me with the updated software revision. I have been struggling to get traction with the Android 1.5 environment, as I am having trouble with the documentation not seeming to make sense with what is happening in Eclipse when I try to write some code.

I am taking a fresh run at things...

Wednesday, February 17, 2010

HTC Eris Droid

Yeah I bought a new phone, my wife and I have HTC Eris Droids now. I set up the IDE on my MacBook to handle Android 1.5 as a compiler target, and thrashed around trying to get the code to build for hours. My talkLock splash screen app runs on my phone now, even though I don't know why. I intuitively threw some hacky code in and it worked. It has something to do with R.drawable.image_name not resolving; Eclipse said it wanted an "int" so I figured out the resource id of my "image_name.jpg" image.

I get frustrated sometimes because the official tutorials have code in them that doesn't work, which means that this Android stuff is all very new and rough right now. I am fairly patient though, because I realize that I'm running Eclipse on platforms other than Windows, so I'm working in an environment that is shared by a very small percentage of Android hackers, which is a very small percentage of Java programmers overall. So it's really amazing that any of it works at all.

My only Windows box is very old and so I'm going to try to avoid doing development on it. It's a Pentium III Sony Vaio. I am not interested in seeing how Eclipse runs on it.

I am putting builds in the talkLock area on marmot.

Thursday, December 3, 2009

why not?

So every now and then I've thought about "porting" talkLock to a different platform/API. I bought a Motorola Q thinking that I could resume developing talkLock on it, only to find that I bought the Windows Mobile flavor, not the J2ME one. Bummer. I thought that maybe I would play with Windows Mobile a little. I ended up trying two of them, and they both had different problems (I bought them on eBay). So I had to fall back to my old BREW phone that I can't develop for.

My carrier, Verizon, who I was planning on ditching, has now come out with the Motorola Droid, and I believe at least one other Android based phone. Android is the platform I think I'd really like to try, since I have read some things about it that I liked. I am a Free Software guy, and Android seems like one of the most unrestricted mobile environments.

My wife ( I was married this past August!) bought an iPod Touch, but I never got bit by the bug of trying to develop for it. Partly because it's her iPod, and I'm not good at sharing electronic things :) I have learned that it's best if I have my own PC, laptop, phone, etcetera, whether it's with a roommate or significant other. That way everyone else will find their devices exactly the way they left them, while mine is always bootstrapping some wierd software or operating system, or running some bizarre user interface, or running some code that I wrote that is very brittle, or hogs all the cpu, or makes sound stop working sometimes, or runs up their data plan bill... Come to think of it I should probably have my own internet connection as well, since I'm always running my own server or doing some kind of test or analysis...

I digress.

The reason I posted today is that a couple of days ago I set up the Eclipse integrated development environment with the Android plugin and the rest of the development kit. I did it all on Linux on my MacBook, the same one I've been running Netbeans on and doing the talkLock J2ME development. By the end of the day I had a talkLock splash screen Android program running in the emulator :)

So I thought, why not just keep going? Android seems very J2ME, the concepts are there. So I figured out how to push out an Android .apk binary application, put it on my web server, and had a friend who bought a Motorola Droid install it. It installed and ran, and showed my talkLock logo 8-)

So I went from knowing pretty much nothing about Android to having a (very simple) application running on one in a day. Maybe a new namespace will be created on Sourceforge, "talklock_android". We'll see.

OH and guess what? Sound doesn't work in the Android emulator either! At least not on Mandriva on my MacBook at the moment...

Tuesday, October 13, 2009

hacking Sugar - building sugar on Ubuntu 7.10

So I find myself trying to build Sugar, the OLPC user interface for children. As always I don't really have any computers to dedicate to development for Sugar, but Sugar only supports being built on a handful of Linux distributions and versions. So I decided to hack a little and try to build it on my server, marmot runs Ubuntu 7.10. I found that if I pulled down the newest git source of Sugar, there is an area in config/sysdeps where there are files representing Linux distributions and versions. So I did this:
cp config/sysdeps/50ubuntu-allversions.xml config/sysdeps/50ubuntu-7.10.xml
That at least allowed me to run ./sugar-jhbuild depscheck :)
./sugar-jhbuild build is running now. This is quite complicated. Makes me start to wonder about the wisdom of code reuse. I guess it just moves the problems up the stack to a higher level. Instead of trying to make a device driver work, I'm trying to trick some code into compiling itself in an environment that it doesn't already understand.

talkLock is still rusting

Well I still haven't gotten a MIDP phone, or done any talkLock hacking. Now that my wedding and honeymoon are in the books, I'm going to take the next leap and buy a house.

I bought a Motorola Q on eBay, but it was the Windows Mobile one (doh!) not the MIDP one. It also didn't work well. The vendor is shipping me a replacement.

I spent a few minutes installing a MIDlet player on the old one, but it was faulty. I had heard that you can run MIDlets on Windows Mobile phones, but maybe not mine.

At the moment I'm hacking around and looking for my next project. I haven't really written any code other than shell scripts or Makefiles for quite a while.

Monday, July 6, 2009

not dead

No I'm not dead, but there is some rust on talkLock. I got engaged, family stuff has happened, I found an old motorcycle in a barn, my car got t-boned, I bought an old Jeep, I got the motorcycle running and cleaned up, the weather broke, I started mountain biking, I am enjoying Jeeping with no top and riding the old motorcycle. I went camping, shot up a bunch of ammo through my Russian guns, bought a cargo trailer, started fixing up the cargo trailer, friends came in from Norway, my laptop died, the AC adaptor for my other laptop died, I got a Eee PC to play with...
So lots of stuff. I think about talkLock, and I admit that I tried to abandon it for a new project, but nothing came of it. I thought it would be fun to hack gnash the open source flash engine, but it wasn't easy to set up the development environment on any of my machines. Maybe I will try that again, or maybe I will come back to talkLock. It doesn't help that my Blackberry died at the tender age of 13 months old, so I don't have a MIDP phone right now.