Android Wear and 3D Models (Pokemon Watch concept)

New post! I did a little experimenting with putting 3D models on Android Wear. I used the min3d library for Android and downloaded the egg model from TurboSquid. When comparing side-by-side versus the real Pokemon GO egg art you can appreciate all the visual quality and animation complexity that goes into a game like that. The min3d library ran on the watch without any problems. Check out the video and please note this is just a concept showing some basic animation rotating the object in the updateScreen RendererActivity override.

Posted in Uncategorized | Leave a comment

Android units – pixels, density, dpi, dip, dp, dps, sp, sip

The Android documentation for supporting multiple screen sizes says:

The density-independent pixel is equivalent to one physical pixel on a 160 dpi screen, the baseline density assumed by the platform (as described later in this document). At run time, the platform transparently handles any scaling of the dp units needed, based on the actual density of the screen in use. The conversion of dp units to screen pixels is simple: pixels = dps * (density / 160). For example, on 240 dpi screen, 1 dp would equal 1.5 physical pixels. Using dp units to define your application’s UI is highly recommended, as a way of ensuring proper display of your UI on different screens.

Confused? Try this. Take the example of two screens that are the same size but one has a resolution of 160 dpi (dots per inch, i.e. pixels per inch) and the other is 240 dpi.

Lower resolution screen Higher resolution, same size
Physical Width 1.5 inches 1.5 inches
Dots Per Inch (“dpi”) 160 240
Pixels (=width*dpi) 240 360
Density (factor of baseline 160) 1.0 1.5
Density-independent Pixels (“dip” or “dp” or “dps”) 240 240
Scale-independent pixels (“sip” or “sp”) Depends on user font size settings same

Notes: Density does not exactly follow the real screen size, pixels are not necessarily squares, there is no strict definition for what a “pixel” means. This may be a little confusing but not as much as CSS Units (em, ex, pt, etcetera).

Posted in Android, Mobile, Uncategorized | 23 Comments

Chinese Numbers Match

New app released on Android that lets you learn Chinese numbers. The video includes some gratuitous background music.

Let me know if you have any suggestions related to the app.

(BTW, I set up a WordPress plugin now so I don’t need to manually block spam anymore. This was killing my search rankings, not to mention annoying.)

Posted in Uncategorized | 1 Comment

Android Crash Reports are Awesome

In my last post, I said I like WP7 platform best for development, but one thing that blew me away about Android development is when Google came out with crash reports. Developers can see stack traces for all the crashes that users report that may direct you to exactly what the problem is.

I released a new version of Bubbles (and Bubbles Deluxe) yesterday. This morning I checked in the market console to see if there were any crashes and saw that there was a new error users were seeing:

I clicked through to see the stack reports (14 of them, all the same):

Wow, it pointed me to exactly where the problem was. Oops, I had forgotten to put a synchronize block around the code for popping all the bubbles when the user shakes the device so if a bubble popped of natural causes right during the time it was looping through popping all the bubbles due to shaking it would try to pop a bubble that no longer existed.

The crash reports can also include a user message. One kind user confirmed what I already knew:

This is a great feature which should improve app quality. I’m not happy that the bug existed but without the reports I wouldn’t have known about it — at least not for a long time. But don’t expect to see it anytime soon on Apple which uses native code where getting stack traces is very awkward. I wonder if Google uses this for ranking in the Market. It certainly would be interesting to see crash stats for other apps.

Posted in Android, Mobile, Uncategorized | 5 Comments

Developing on WP7 vs Android vs iPhone

Although iPhone is still by far the best platform to make money on or be able to have the highest quality experience for your apps, WP7 is my favorite platform to develop on with Android not far behind.

  • Microsoft has taken the best compromise for the submission process. Approval is fairly quick (about 2 days) but it can filter out the large quantities of junk you get on Android. I’m happy to have somebody check that my app works fine on whatever device they test it on too.
  • The development environment is seamless. You click on a .sln file to launch your project and then click Run. Voila. I admit that I’ve spent many more years developing in Visual Studio than Eclipse or Xcode but in the last couple years I’ve been using Eclipse/Xcode/vi, and Visual Studio just seems a quicker, smoother experience for jumping around, refactoring, debugging, etc. (It should be given its more limited scope.) When starting Mac development I remember reading this really long Get Started document about how Xcode/IB made so many things so easy. It must have said it was easy half a dozen times at least. So when you compare it to the case where you don’t have the concept of opaque resource bundles/File’s Owner/First Responder, it validates my initial impression that the architecture was a heck of a lot more obscure than it needed to be.
  • C# is a somewhat better language than Java (delegates/better annotation model) and Objective-C sucks compared to either of them (memory management, allowing dereferncing null pointers [edit: doesn't complain when sending a message to a nil object though this is probably not what you want], useless to learn for other development).
  • Android is better for being able to develop on your platform of choice (though I suspect developing on Mac is best supported) but WP7 isn’t that far behind since you can at least run Windows inside a virtual machine but that’s against the rules for Mac. [Edit: According to a comment, it isn't possible to run WP7 emulator in VM]
  • In terms of payments and reporting, WP7 still has some maturing to do but it looks like they are off to a good start and it looks to me like WP7 users are more willing to pay for apps vs Android (though of course the market is relatively small now). The key/unique thing to understand with Android payments is that you are legally acting as the seller, not Google. This means that you are the one the customer calls when something goes wrong related to payments or installation. Not so for Microsoft or Apple.

Flame away :)

Posted in Android, iPhone, Mobile, WP7 | 12 Comments

Bubbles Magic running on Windows Phone 7

Posted in Uncategorized | Leave a comment

Naked Mole Rat Gets Dressed (Toastmasters Project 6, Vocal Variety)

(Notes: Due to some issues with the projector that took a while to sort out, I didn’t end up getting the powerpoint showing up on my laptop and I ended looking back at the screen a lot. Also, the storage on my camera ran out before the end of the reading and I haven’t included the intro. Anyway, let me know if you have any other suggestions.)

Posted in Uncategorized | Leave a comment

Explaining Farmville’s Popularity using Robert Cialdini’s Principles of Persuasion (Toastmasters Speech Project 5)

Good afternoon. The title of my talk is “Explaining Farmville’s Popularity using Robert Cialdini’s Principles of Persuasion”. FarmVille is a game that runs within Facebook where you can pretend to be a farmer by planting and harvesting virtual crops. There are currently 60 million people playing FarmVille. That’s over 10 times as many people as there are actual farmers in the United States. FarmVille doesn’t have the best graphics, you can’t directly interact with other players, it doesn’t have any story, and there isn’t any way to win. So people wonder: why is FarmVille so popular?

A professor named Robert Cialdini in 1983 wrote a landmark book titled “Influence: The Psychology of Persuasion” which I think goes a long way to explaining it. He argued for 6 universal principles that influence human beings and we can see all these principles throughout Farmville.

1) Reciprocity – the pressure we feel to reciprocate; if somebody does something for us we feel compelled to do something for them. He studied Hare Krishnas at the airport. A Hara Krishna would interrupt a busy traveler trying to get to a flight and say “here, have this flower as a gift from us” and the traveler would say “no thank you” and then the Hare Krishna would say, “it’s a gift, there’s no charge” and then ask for a small donation and the poor, traveler wouldn’t be able to figure out how to get out of this situation and end up giving a donation. This is a very powerful influencer. It’s also a very important piece of Farmville. You advance by receiving gifts. Typically the way you get hooked into the game is one of your friends who is playing gives you some virtual gift such as an Olive Tree and asks for something back.

2) Liking – the principle that if you find somebody likeable you’re more likely to do what they request. This is why Tupperware parties took off. In Farmville, if you’ve seen the charming characters or heard the music, you know it scores high on this one.

3) Social Proof — the principle that people are influenced by what others around them believe and do. Facebook itself provides a lot of this for free by showing on the FarmVille page that are 60 million other people playing in my case it helpfully points out that 30 of my friends are playing it, along with showing pictures of them. This is very powerful social proof.

4) Authority – The authority described by Cialdini doesn’t really appear in FarmVille but the game flow is it tells you what to do instead of telling you the rules. When you first enter the game there is a giant bouncing arrow and text that essentially says “Click here!”, “now Click here!” It puts you in a position of having a very clear command that is actually takes some effort to disobey the bouncing arrows.

5) Scarcity – that people assign more value to opportunities when they are less available. This is seen all over the place in FarmVille, whether limited edition seeds, gifts that expire, I even got the opportunity to buy FarmVille cash at a discount for 24 hours only it displayed a large countdown timer on the top of the screen. […I’d be sure not to miss this wonderful opportunity]

And finally… 6) Consistency – We all fool ourselves sometimes in order to keep our thoughts and beliefs consistent with what we’ve already done. There was a study where people were asked to display a small sticker saying “BE A SAFE DRIVE”. Later they were asked to display a huge ugly billboard saying “DRIVE SAFELY” on their lawn and 76% of them agreed to do it whereas people who hadn’t received the small sticker general didn’t. In the FarmVille tutorial when you enter the first time, it pushes you through plowing some land, buying some strawberry seeds, and planting the seeds. You now see yourself as a farmer. At the end of that, it tells you can come back in a few hours to collect your strawberries and earn some virtual money… or you can let them all die. How inconsistent of a person would you have to be to — plow land, buy seeds, plant them — and then just walk away forever?

In conclusion, given what we’ve learned now about how human minds are influenced, it shouldn’t be so surprising how something like FarmVille could spread so quickly.

Posted in Toasmasters | 1 Comment

Learning Mindsets (Toastmasters Project 4, How to Say It)

5 – 7 minutes

Imagine if you will that you had the following day: [from Mindset]

It’s a rainy Monday morning. You have a History class to go to. History is your favorite subject and you’ll be getting your midterm essay back today. You’re pretty pleased with how you think you did and are expecting an A. The teacher hands you back your paper and you look at the top and instead see a C+. After class, you head back to your car and there’s a little yellow sticker on the windshield. It’s a parking ticket for $300. You head home and call your best friend to get some sympathy and she sort of blows you off.

Now, what would be going through your head?

Maybe you’d think: “I’m so stupid to park somewhere where I’d get a ticket. I’m going to go home and mope. Life stinks.”
Or maybe you’d think “At least it was only a midterm and a C+ is a long way from an F… so I need to work harder to pull up the grade, be more careful parking, and talk with my friend to see if anything’s going on.”

The reason I bring up this story isn’t just to say “hey, don’t sweat the small stuff”. The point is to ask the question “why doesn’t it seem like small stuff to begin with?”

I’m reading a book now called Mindset that I think provides a clue to the answer. It describes two different beliefs that somebody can have about the world – one she calls a fixed mindset and the other a growth mindset. If you have a fixed mindset, you believe it’s not possible to change basic qualities like intelligence and personality. If you have a growth mindset, that doesn’t necessarily mean that you believe anybody can become an Einstein or Beethoven, but that you believe you can’t really know until you try.

If I think “I parked somewhere where I’d get a ticket and that means I live in a universe where I’m a stupid person”, that’s pretty bad news. If I think “Note to self: check the parking signs” then at least the only thing I have to worry about is the $300.

One of the points she made that really resonated with me is the difference in how effort is viewed from each of the mindsets. From a fixed mindset, effort is a bad thing. If you get an A without effort that says you’re a really super smart person. If you spent a lot of effort, you’re not such a smart person. So ironically, people with a fixed mindset spend a lot of effort trying to appear as if they didn’t spend much effort.

People with fixed mindsets aren’t necessarily less confident but their confidence is more fragile. Researchers did a study where they took a group of employees learning computer skills. Half of the people were randomly put in a group that was told that computer skills were all a matter of how much natural ability they possessed and half of them were told that computer skills could be developed through practice. The people in the growth mindset group became more and more confident as they learned from mistakes and improved. The people in the fixed mindset group became less and less confident as they made mistakes. The more they learned the less confident they got. So it’s not just an innate quality of confidence, a different belief can lead you down one path or another.

There’s another mindset that can play an important role in learning too.
Raise your hand if you believe you learn better if you know you’re going to have to teach somebody else what you learned.

[I definitely feel I do too and... | For kids…]

Researchers have collected some evidence that kids learn better if they’re in a teaching mindset. The researchers created some software that they named Betty’s Brain. It allowed you to create maps of concepts. For example if the children are learning that the body can increase its temperature by shivering they could create a box for body temperature and a box for shivering and draw an arrow from shivering to temperature and mark it to say shivering increases body temperature. The children were divided into 2 groups with one of them was told that they were using the software to organize their own understanding and one of them was told that they were using it to teach Betty. The children that were put into the teaching mindset scored significantly higher. Not only that, they showed greater motivation. They spent more time revising the boxes and arrows. And they showed more interest according to instruments measuring skin conductance.

Every teacher in the world probably says something along the lines of “work hard and you can improve”, but giving children a visualization of how their brains improve can help them to really believe this truth and that we really don’t know how far they can go.

In concluding, I think it’s an exciting time for education. It’s not just about moving to e-Books and children carrying around less dead tree mass. It’s also about improving the psychological aspects of learning and putting children (and of course this can apply to us too) into mindsets that will lead to more growth.

Posted in Uncategorized | 2 Comments

Intro to Evolutionary Psychology (Toastmasters Speech Project 3)

This is a 6 minute presentation I gave at Toastmasters and may repeat. Be sure to click on show speaker notes (in Actions) to see the full text.

6 Minute Intro to Evolutionary Psychology

Any suggestions for improvements? Some people didn’t get it. Also, is it accurate enough? Also, I think the Wason Selection argument isn’t all that compelling and takes up about half of the time. Is there a better example I could use? (The speech was supposed to be for either informing or persuading and persuading required informing so I tried to focus just on informing.)

Also, check out You Are a Brain

Posted in Uncategorized | Leave a comment

Cute Bunny Cartoon

Idea by me, cute drawing by Elaine.

OK Honey, I'm off to another frick'n baby shower.

Copyright 2006 by Edwin Evans and Elaine Chien

Posted in Uncategorized | Leave a comment

Software Trade-off: Deeper versus Wider

When creating software, you’re often forced to choose between making existing functionality better or adding more functionality. A related dilemma is between making it what I call broader versus deeper, where breadth is the amount of user interface “stuff” (dialogs, controls, windows, etc) and depth is the value of each element. The most obvious way to add functionality is by adding UI stuff, but as Alan Cooper pointed out “No matter how beautiful, no matter how cool your interface, it would be better if there were less of it”.

Here are some characteristics of depth versus breadth:

Depth is often discovered by guessing, reading, or just using without thinking. It’s easy to look at the Microsoft Calculator and know what it can do but you need to stumble upon the Google calculator to know it even exists. Do you use the Google toolbar? If so, do you know that you can press Alt+Enter to do an “I Feel Lucky” search? I bet not since there doesn’t seem to be any UI stuff about this at all.

Making it faster is adding depth. If you make it fast enough that it appears instantaneous you can remove UI stuff such as progress bars or “please wait” messages. Speed has the typical characteristic of depth that it’s hard to do and requires a high threshold of brain power.

Depth is hard. In meetings, breadth is characterized by comments such as “it could do this too” or “some customer requested this option also”. Depth is characterized by someone saying “but is that possible?” It’s more straightforward to add breadth to an existing deep product than depth to an existing broad product since you’re always running out of room as the UI elements fill up the space available.

Adding subtle behavior is adding depth. Overlays, modeless feedback, or auto-completion algorithms are deep. They won’t show up on a feature comparison chart on the back of a box and will largely go unnoticed by the user. Depth is hard to describe and market since you can’t see it; you experience it, or more often the lack of it.

Insufficient depth causes many forms of frustration. Insufficient depth costs users time whereas adding depth costs developers time. Lack of depth causes many different forms of frustration: slow, buggy, intolerant of user errors, difficult to use. Lack of functionality causes only one form of frustration: “it doesn’t do what I need!”

Breadth is good when going after vertical markets. Specific markets have specific needs and care more about meeting those needs than meeting them in the most optimal (expensive) way possible. Depth is good for universal problems. Businesses lean towards breadth because it’s easier to calculate how it affects their potential market and requires less thinking. Depth leads to fandom. Breadth can lead to lock-in if you cover enough area at once.

Another Example

Here’s some of the UI for finding text in Microsoft Word 2007:

It’s wide and it also has some deep features such as “Find all word forms” and “Sounds like”. I don’t use any of these and you don’t either but it doesn’t bother me that they’re there. Microsoft obviously spent an enormous amount of money developing this and presumably some of their customers find these options useful.

But having this dialog doesn’t substitute for a quick way to jump to some text with minimal effort. Something like that would have the deep features of providing early-as-possible feedback, clear-as-possible results, and minimal user input. HandyFind is my attempt to do just that. It has virtually no UI stuff but it has deep features such as animation, interactivity, and multiple application support.


As a user and a sympathetic software developer I lean towards depth even if it means accepting that a particular version of software can’t do everything I want.

Posted in Uncategorized | Leave a comment