Random Musings of Brian A. Thomas. Love for Ari and Sidd.
Java
Revisiting Android Development
May 21st
That is a screenshot of a basic Hello World application I did for Android… Well, I followed the lesson to make it so it isn’t an original… Anyhow, this is what it would look like on a G1, or other Android based phone.
I thought I would see if I could get into Android development again, and the Hello World application is where you typically start all programming lessons.
A MySpace, Facebook Application for the Google Android Phone
Jun 12th
I talked how I was wanting to learn Java, so I could start making programs for the Android mobile phone platform.
A project that I thought of, but is perhaps beyond my ability for any time soon, is an application that will tie in with MySpace, Facebook and expendable to other social network websites.
Basically, it searches your friends lists, and if they have an Android phone as well and the location tracking feature turned on, you can see which of your MySpace/Facebook friends are nearby by using the Android’s built in GPS. There are variants I saw of this out there, but none I know tie in directly with the current social network, rather they setup their own networks.
Bes I can figure it, each user who has an Android device, sets up an application on their MySpace/Facebook page that detects when they enable the location feature on their Android. For privacy reasons, all it shows on the webpage itself is that location tracking is on. The back end of the application that the Friends can’t see, but the user can, allows them to block certain friends, or allow only certain friends to see their location.
If two friends have their location tacking enabled, then when they look at the application on their Android, it shows where they are via Google Maps. You can see in an instant if your friends are running late to meet you at the movie theater, or see when a friend arrives in town and a host of other cool features.
At the same time, there are the normal security concerns if some pervert is using a fake MySpace account to find young girls or something like that. I haven’t figured a way around that, but in all honesty I don’t know as if one does need to, since if they already got friended, they are already in, and as I said, the back end allows you to add only select friends to the location tracking, so hopefully that added level of security will be enough. Still the end user license would need to be written in a way so that the developer would assume no responsibility for abuse of the system. Personally, I would add a warning when they add friends to the location tracking that reminds them to be extra careful of whom they allow to track their location (this would be a dialog box that pops up each time, but would probably have a check mark so you could avoid the message next time). By default, it wouldn’t have any friends listed in the allow column.
Anyhow, that is the basics of it. I have more details floating around in my head.
Some of the variations out there currently (well, currently may not be the right word since Android itself isn’t out yet, but these are the ones that I know of in active development) that I know of:
More >
Learning Java
Jun 10th
There is a phone platform coming out called Android, which is a project of the Open Handset Alliance. A number phone manufacturers are going to be making mobile phones based on the Open Handset Alliance specification, all of which use Android. To program for Android, you need to know Java, and so I am starting on a path of learning Java. I chose C# over Java eons ago as I was mostly interested in Windows programming, so Java’s ability to compile on one machine and run on many others, even if they weren’t Windows machines, be they Linux, Mac or whatever, wasn’t a concern. Most mobile phones use Java for their games and applications. Apple’s iPhone is cool, but to program for it, you have to have a Mac, so no programming for the iPhone. Plus the iPhone’s market is limited right now do to the exclusive AT&T deal (you can unlock the phone and run it on T-Mobile for example, but most people won’t go through that much trouble). nVidia has a chipset coming out, but for the moment, none of the Tegra based phones are for Android, but Windows Mobile based phones (and other handheld devices). nVidia is a member of the Open Handset Alliance, so they may support somebody making a Tegra based phone that conforms to the Open Handset Alliance and Android. This will be cool since they seem to have the best graphics of the phones.
There are a couple of caveats however as I embark on learning Java. First, while most Java programs can be ran on many platforms, this doesn’t seem to be the case with Android’s implementation. While the language itself is the same, you can’t compile a program that will run on both Android and say a Windows machine, another cell phone, or something like that, and vica-versa. The problem is they apparently use a different virtual machine to run on than all other implementations. They did this so it would run better on a mobile platform as I understand it. It isn’t clear to me, but it looks like since the language is the same, you could do two compiles, one for Android and one for everything else, but I may be wrong on that part… of course if you use Android specific APIs, then it won’t work on anything else.
Anyhow, I am presently staring on reading Head First Java, 2nd Edition (I am just borrowing that copy, so I don’t have a good hardcopy of my own yet…). Early into the first chapter we do an exercise where we do the “99 Bottle of Beer on the Wall”. The program compiles and runs fine, but, as they note, the output isn’t 100% correct. It took me a while, but I found it.
More >






Recent Comments