The Android Tumblr client doesn’t rotate to landscape because portrait is the only way. #UI #fail

The Android Tumblr client doesn’t rotate to landscape because portrait is the only way. #UI #fail

Someone at Amazon needs to learn how to count and tell time. Today, I am at location 2356 of a book, yet my Kindle seems to think that location 19 from August 15th, 2012 is further along AND more current. #facePalm

1/30/2013 Update: I spent several hours with Amazon support over a few days tracking this problem down. The person I spoke with, Robert, was very helpful and Amazon finally tracked the problem to a software issue and it’s been resolved. That kind of support is what builds loyalty with me.

Someone at Amazon needs to learn how to count and tell time. Today, I am at location 2356 of a book, yet my Kindle seems to think that location 19 from August 15th, 2012 is further along AND more current. #facePalm

1/30/2013 Update: I spent several hours with Amazon support over a few days tracking this problem down. The person I spoke with, Robert, was very helpful and Amazon finally tracked the problem to a software issue and it’s been resolved. That kind of support is what builds loyalty with me.

How to get root on a locked Asus Transformer Prime TF201 with JellyBean 4.1.1

Like most of you, I too lost root on my Asus Transformer Prime when I updated to Jelly Bean. I just didn’t get around to doing anything about recovering it until now.  I tried installing TWRP and it failed. I had sent in my TF201 for repair and I think they locked the bootloader because I know I had unlocked it. That tells me either there is an error in the TWRP installer OR the bootloader was in fact locked. Thinking the latter was the more likely case, I decided to tried to unlock it. I had  read that the Asus unlocker no longer worked on a TF201 on JB 4.1.1 but I figured I would try anyway.

*** If you follow these steps, it’s your responsibility. Standard disclaimers apply. You know the drill. ***

I grabbed the unlocker here: http://forum.xda-developers.com/showthread.php?t=1510737 and downloaded the one from the Asus site. Copied it to my SD card and ran it. I agreed to the big scary EULA and proceeded. It took a while but I got a network error message. Undaunted, I tried again. Hey, repeated actions do sometimes have different results. This time, teh app noted I didn’t have a Google account installed and did I want to continue anyway. Damn straight I did … and it failed saying something like “too Busy, try again later.” I had reset my TF201 to factory, so I added my Google account to my TF201 and tried a third time. This time the app asked me to login to confirm my account. I did and it unlocked. w00t!

I wonder if those who are on JB but didn’t unlock while on the ICS bootloader are screwed now while those of us who had unlocked while on the ICS boot loader but for whatever reason have a locked bootloader (I sent mine in for repair) are fine. Seems to be the case.

At this point, If I just boot up, I see the “The Device is Unlocked” message. If I boot into recovery (press VOL down + Power), I don’t see it.

Next, I followed the steps here (http://forum.xda-developers.com/showpost.php?p=26595675&postcount=2) to install TWRP. Success!

Then I grabbed the Superuser binary http://androidsu.com/superuser/ and dropped it onto the SD card. Booted into recovery (TWRP) this time and installed SU. Sweetness.

Android Fragmentation is a Pernicious Myth

One of the oldest and most common myths that chaps my ass is that Android is fragmented. The first instance I found was in 2007, there may be earlier instances. It’s not fragmented and saying so doesn’t make it so. Android, like all software, has a version problem which is exacerbated by handset makers’ and carriers reluctance to update the OS, but that’s isn’t fragmentation. It’s a versioning and, that is not a semantic difference but a real difference in how it affects the end-user experience on all devices and OS’s.

Calling Android fragmentation is hyperbolic rhetoric. The word “fragmentation” is used to imply fracture, broken, a shattering of the OS so that nothing runs. Don’t deny it. The word elicits a fiction that is out of line with reality. Calling Android fragmented is meant as FUD. If you want to call Android fragmented, have a ball, but at least have the courage of your convictions and be honest about why you are saying it—furthering FUD.

Fragmentation occurs when developers have to recompile their application for specific platforms of the same OS. Linux, specifically Linux distributions, is fragmented. There is fragmentation in the distributions, the window managers, libraries, lots of things. What this means is that Linux developers often have to compile applications for each platform (Ubuntu, Debian, Fedora, etc) and possibly window manager. You can’t take a program compiled for Fedora and expect it to work on Debian in many cases. The result is extra work for developers to code, compile, distribute, and support multiple versions of the same application at the same time. It also means that I can’t take an application and simply copy it from one Linux install to another using a different distribution and have any guarantee that it will work. The current version of any application could vary across distributions. Some features may or may not be available across distributions. That, my friends, is fragmentation.

Android has a version problem which appears to complicate matters. The OS and SDK has undergone 10 major revisions since 2008. Having that many versions that quickly is bound to cause growing pains as developers have to decide which baseline version to support. Add to the number of Android versions, the explosion of handsets with varying types, displays, and hardware and yes, developing for the platform can be difficult. (A developer wrote an analysis of this matrix, which was impressive, but I can’t find it)

However, in the SDK are plenty of tools that allow developers to add backwards compatibility into the same source tree so that they don’t have to write multiple versions of code (and the libraries are getting better). There is extensive documentation on how to write an app for multiple display types. I’ve done it. It’s not that hard (none of my apps are available, they aren’t ready for public consumption). Some applications like games require special graphics processing so won’t work on phones without them or applications that require telephony won’t work on a tablet.

Since most users equate the the UI with Android, Google finally required handset makers using Android (well, supporting the Google Services Framework) to at least support the Holo theme bringing some consistency to the use experience. Some people look at the SenseUI and scream “OMG! It’s a new OS! Will my apps run!?!?!”

The fact is, you can take an application compiled for Android 2.x and it will work on any future version. You can write an application that supports both the new features in 4.X as well as running on older phones using the support library (obviously without the new features in the older OS). You can take that APK, the Android app package, and copy it to other device and Android versions (providing they are at or above the apps minimum version) they they run fine. That is not fragmentation.

Fragmentation isn’t likely to happen, either. At least not in a meaningful or impactful way. If some handset maker decided to fork Android to the point where new and existing apps required special support and compilation, then that would be a fragment and frankly would likely die in the market unless said vendor could quickly build up apps that users want. They would lose access to the hundreds of 1000’s of existing Android apps as well as new ones and they would have to convince app developers to support their fork. Good luck with that.

The Hidden Cost of Not Buying Apple

While I like my Galaxy Nexus, the battery life sucks. The battery on my OG Droid sucked too, but I bought an extended battery that left an unsightly bulge but gave me a day and a half of battery with full use. I don’t expect battery life to get better with newer phones, either. I get maybe 6 hours with light use. 2 - 2 1/2 hours if I am actually using it. Since I work at home, it’s not that big a deal. When I travel, I bring a spare battery. However, when I’m driving, the battery on my Nexus drains slowly even when plugged in.

Apparently, a USB 2.0 device can only pull 500 mA. This was likely for safety reasons. However, in 2007, a USB charging specification was created that allows for up to 1500 mA to a dedicated charging port (doesn’t carry data). That’s great since my Galaxy need more than 500 mA to operate and charge (my OG Droid was fine, at 500 mA). Can I find an adapter for will fit? Not really.

See, long before the specification was ratified, Apple used a different method to detect and pull more than 500 mA using signals on two of the USB pins (see the link above for gory details). So nearly all of the USB car chargers out there support Apple’s negotiation and don’t support now standardized ones.

So here’s what happens. I go look for some on Amazon and there a bazillion for Apple’s iPhone and iPod. But few can actually support anything other an Apple products without taking them apart and completing a relatively simple hack. If the data pins are shorted out, that signals the phone that it is connected to a dedicated charging port and it can draw more than 500 mA, per the USB standard. Try to find an adapter that works like that. Very rare.

What makes this search that much more frustrating is that the manufacturers claims on these chargers is that they will work with anything that has a micro-USB port—and they are right. They will deliver 500 mA to non Apple devices but for everything else, they won’t actually be useful for charging the phone. I’ve had my Samsung Nexus near exhaustion and plugged in to a 500 mA adapter in my car and it barely charged. Have a B&N Nook? Guess what, you need 1.9 mA to charge and nothing else. Any different amperage and it won’t charge at all.

Sure, I could pay the ridiculous price of $29.95 for Verizon’s car charger accessory, but at that price, it’s thievery. I guess I’ll have to hack something together, but that’s alloying.

What If Microsoft Copied Android’s API?

While reading this really long but well thought out comment on Reddit, it occurred to me that Microsoft will struggle to attract developers to Windows 8 RT. But wouldn’t it be funny and forward thinking of Redmond simply copied Android or iOS’s API’s so that Windows 8 could run those applications natively?

Microsoft would have instant access to 100’s of 1,000’s of applications. I know it would be pretty hard to accomplish, but what an accomplishment it would be.

Hey, if Google can copy the Java API, then surely Microsoft could copy both Android and iOS’s.

Asus Tech Support Saga Begins

A few months after picking up my Asus Transformer Prime, I noticed an issue where for no reason, there were touches on the display and I wasn’t actually touching it. Ghost touches, I guess. I searched the net trying to find something similar and finding nothing, I started to remove applications I had installed starting with the most recent. Eventually the Ghost Touching stopped. A few days later, they returned. Sometimes just a few touches, at other times the Ghost Touches were so frequent and long lived that the tablet was unusable.

Cycling the screen sometimes helped. Power cycling sometimes helped, but they’d eventually return. The ghost touches always showed up in the same place, along the right most half of the upper right edge of the screen in landscape or the lower most half of the lower right edge in portrait. That looks like a hardware issue.

So I performed a hard reset and Ghost touches disappeared for a month or two and then returned. So I went through the process again. I didn’t call tech support since I was traveling and I figured it was likely that they would want me to send in the tablet. So I struggled with it and thankfully I got through my travel schedule mostly unscathed. Asus also updated to 4.1.1 and the ghost touches returned. Yep, definitely looking like a hardware problem.

Knowing that this is an intermittent problem, knew that I was going to have trouble with tech support, but I didn’t think I’d have this much trouble. As in Asus is actively trying to not provide support. I called and did a hard reset on the phone with the tech (even though I just did one). He asked if the problem returned and I said No. The he launched into his closing script. “Wait, the problem wasn’t happening right before the hard reset either. I told you it was intermittent. It just isn’t happening right now. It may start back up tonight, or tomorrow, or next week, but it will happen again. I need to get this fixed, permanently.”

Well call us when it happens again, he asked. Oh boy.

Look, I want to talk to someone else, like your supervisor. If you can’t help me, perhaps someone else can. This is an intermittent issue so there is no guarantee it will happen in the next 30 seconds, but it will happen again. “You can turn it off and on when it occurs,” he suggested. Um, NO, that is not satisfactory.

Please hold while I get my supervisor. After being on hold for several minutes, my Internet connection crapped out and the call was dropped. I can not make this stuff up. Of course, after taking all of my information at the start of the call, I never got a call back.

Nice.

I will be calling back and hopefully get this problem settled. Meanwhile, my Transformer Prime is sitting on my desk, powered on, no ghost touches. It’s mocking me.

EA Makes The Best Android Racing Games

Here’s my pick of the top racing games. My criteria are simple. A good game has to be visually stunning, have interesting tracks, have challenging AI, contain realistic physics and be fun. My Galaxy Nexus is a good gaming device and there are three racing games that I’ve found so far that fit the bill. My favorite is Real Racing 2 from EA.

Real Racing 2

It’s got it all. The graphics are great and notice the lens flare. When a helo or bird flies over head, the shadows move across the pavement. Going under elevated bridges, you get the picket fence affect. It looks great in full motion. The AI is smart, with three levels and challenging to race against. They try to avoid collisions and stick to the track, but they will wipe out, too. The physics are good.

I know, I know, it’s a game, how realistic can it be? Quite. When you go around a curve too fast, you don’t just spin out. EA has modeled understeer and oversteer quite well so that you first see the problem (under and over steer look different in the game) and you have time to correct. Not much, it’s less than a second, but if you have ever been in car that goes into a spin, you know what the scene outside the windshield looks like, that how it looks in the game. Also, you lose velocity quickly in a slide.

You progress through a ladder earning money to unlock cars and buy some upgrades. There aren’t any in-app purchases, either. EA tried to keep the game pretty realistic. You get penalized with speed for going off track or having a collision (though the damage doesn’t last). It’s also not enough to have the fastest car. I can win more races with a slower car that I can control better than a faster car. I have to think about each race and select the car I think will work best.

The controls are good and the camera is moveable with 4-5 positions from bumper to high and in the rear. I prefer the bumper or cockpit view. The game is $4.99. Yes, there is on-line licensing, but I think you get 6 runs before you need to connect to the servers. You can also set brake and steering assists on or off.

Plays great on my Galaxy Nexus and if I recall correctly, the same price gets you the HD version for tablets.

Need for Speed Shift

NFS Shift is also from EA and is similar in game play. The tracks, however, are street tracks for the most part. Again, you progress up a ladder collecting money (again, no in-app purchases) to buy cars. Each stage has you unlocking new tracks.

NFS Shift isn’t as stunning as RR2 but it has some nice features like manual transmission (flicking your thumb up or down for shifting) and track guidance for corners (which you can turn off). It also has difficulty settings as well but not as detailed as RR2. It’s a capable racing game that runs well on both my Galaxy Nexus and Asus Transformer Prime. I just noticed that Play says NFS Shift is not compatible with either of my devices but it works fine. I suspect a manifest issue.

NFS Shift is a street racer and unlike RR2, you can drift and there are a few drift challenges. Drifting fills up the nitro faster but at the cost of speed. I find holding the drift line difficult, so I don’t do it much.

Need for Speed Most Wanted

NFS Most Wanted just came out and I have only been playing for a day. It’s fun, but I don’t think it will surpass RR2 as my favorite. NFS Most Wanted is a racing game, but there are police to avoid (or ram as you see fit) and most of the races so far are one way.If you played NFS Hot Pursuit on Android or computer, you’ll feel at home in this game. It’s similar but not as feature rich.

I don’t think the graphics are as crisp and the track’s can be very low contrast, but like the other two EA games, the physics while racing are good but not as good as RR2 or NFS Shift. It’s hard to kick into a slide so I can be sloppier with the controls and the affect of collisions (which are part of the game) are really fake. I know, part of the game is to ram the police, but it’s goofy non-the-less when you do and if you do spin, the physics aren’t as smooth as in RR2 and Shift. These may be small points, but I find it jarring.

Drifting in this game is a blast. However it’s fun to drive and dodge slow moving cars and trucks. You can modify your cars, but only before a race and the modifications are only good for that race. When the 1st prize is $15,000 and a modification is $3,000, for a one time use, it hardly seems worth it. Save your simoleans and buy a better car.

***

I’ve tried a bunch of other Android racing games. I like Polarbit’s Reckless Racing and Reckless Racing 2 which are top down racers and are just fun to play. The others I have tried are not a lot of fun. Both of Gameloft’s Asphalt 6 and 7 are relatively crude arcade style racers. Your car is on a rail and you just point it. Control is based on twitching. The goal is to collect money and power-ups and knock opponents off the track. Same with Polarbit’s Raging Thunder series. Neither is very immersive and are quite repetitive. With RR2, similarly powered cars drive differently. The cars in Asphalt and Raging Thunder just go faster. Not my thing I guess.

If you know of any Android racing games that you like, tell me about them in the comments.

*** Disclosure ***

Nothing to disclose. I am not affiliated with any vendor mentioned and I paid for all of these games.

Learning To Write Android Apps

The process is pretty straight forward. Here’s the short version. Learn Java. Get familiar with the Android API. Walk through the tutorials. Learn to use search to answer questions on how to do something. Get an account on Stack Overflow and participate (ask and answer questions). Think up an app you want/need and get coding.

The longer answer

Whether or not you already know a programming language, you have to learn Java. If you already know a language—any language will do—picking up Java probably won’t be that hard. If you have never programmed at all, decide if you really want to write programs. It’s tedious, exacting work and not everyone has the focus to write code.

Your program will do exactly what you tell it to do, even if you don’t fully understand the methods you are using. You have to learn to interpret often obtuse documentation. You will have to experiment with new methods to see what they actually do. You will have to troubleshoot obscure errors. You will have to think about what happens if there is an error and how you will handle it. You will have to have to communicate clearly and succinctly with others when you ask questions or propose answers.

Your reward, or at least the reward I get, is having a program that works which you can share, improve, and use. You will also get a better insight into how computers work and communicate. It’s fun.

Learn Java

I can recommend Big Java by Cay Horstmann. It’s a text book but the explanations are fairly clear and there are a lot of examples and exercises. Sadly, you can’t get access to exercise answers if you are not a professor, but don’t let that deter you!

You can buy the book or you can join the Association for Computing Machinery (ACM) and get it as part of your membership. The ACM library has other Java books as well, so it’s useful to join. There are other books but I’d suggest avoiding Head First Java. It’s an OK book if you use it with something else or you have Java basics under your belt, but by itself, it’s not going to teach you what you need to know to write Java programs.

While you are learning Java, also learn how to write Javadoc and get in the habit of documenting your code using it. Once you build the habit, you will be able to generate documentation for your code easily. As you build your own libraries, your Integrated Development Environment (IDE) like Eclipse or NetBeans will be able to use your Javadocs to show context sensitive help.

Also learn how to write unit tests using Junit and write them even for the silly little setter and getter methods. Again, it’s a good practice to start early and you can easily test your code using unit tests. Your first set of programs as you are learning are going to be easy and your unit tests will be easy to write. As you progress, your methods will get more complex as will your unit tests. Seriously, take the time to learn Junit. It’s not the only testing you will need to perform, but unit tests will cover basic issues.

I’d also suggest using what ever IDE the book you are using recommends or uses in their examples to make your life simpler. There is no value to write Java in a text editor and compiling on the command line. You won’t spend any of your time doing that once you start coding so why learn now? If you ever get to the point where you need direct control over compilation, you will be skilled enough to handle it. You will be using an IDE most of the time while developing, so you might as well use one from the start. Frankly, IDE’s are very similar, but if you use the one your book uses, the learning will be much quicker.

If your book doesn’t use an IDE in the examples, I’d suggest using Eclipse at first simply because the Android tutorials use Eclipse and Android Developer has detailed set-up instructions for Eclipse. You can develop Android in any IDE that supports Java, but if you don’t have a preference, start with Eclipse. Big Java uses NetBeans (an earlier version than is available today) in the book, so I used it first, then migrated to Eclipse later. Many people like IntelliJ as well.

Learning Android

Android apps are written in Java but Android is an environment with an extensive set of API’s that define the objects and methods you will use to create apps. The quickest way to learn is to go through the tutorials and rather than downloading the examples, write your own and see how they work. There are also videos on The New Boston which some like very much. I haven’t seen them, but I will be watching a few. Personally, I learn better by reading and doing than by watching and doing, but that’s just me.

Seriously, write as much code as you can. It’s the only way to learn Android. You can compare your code with the examples to see how it fares (the example code may not always be best). Developer.android.com is going to be your friend and you need to get to know it very well.

Start out with a simple idea and learn how to create an app that you designed. Create the layouts, the images, everything. Keep it simple so that you can focus on getting it working and then either come up wit more complex apps or keep improving the same one by adding more features.

As you progress, create mini apps to learn more complex things. For example, I wrote a number of apps so that I can learn how to use a database, launch an intent, launch an intent with extras, etc. These are focused little apps that do nothing but help me learn aspects of Android that I can apply later.

Get Involved

Join Stack Overflow and learn to use the search function to find answers to questions. Answer questions when you can. Get involved. SO is not chat system or a forum for general chat. You ask a specific question to wait for answers. Learn to use the SO editor to properly format code examples so that others can help you. Frankly, if you don’t conform to the formal and informal rules, you are not likely to get answers to questions.

Good questions are along the lines of “here is what I want to accomplish”, “here is where I am stuck (and why)”, and “here is my code that I have written.” A bad question is one like “I need to open a new window, how do I do that?”

How long will it take?

How long will it take? Who knows? It depends on how much time you have to spend learning. How quickly you pick up Java and Android. How quickly you can assimilate the Android Way into your programs. Whether or not you have an affinity for programming (not everyone does and that’s OK) and a numerous other reasons.

I don’t call myself a programmer (I don’t think I am good enough for that title), but I can write code. I am self-taught in Pascal, Object Pascal, C, perl, php, TCL, shell (Bash and c-shell), Dos batch files, and a few dead scripting languages.

My experience was that it took me a few months spending 5-7 hours a week on Java working through the Big Java book before I could start learning Android. I was basically to the point of learning objects and just starting to get into interfaces and so on. I am still learning Java and Android. Your mileage may vary.