Tuesday, February 21, 2017

Android development tips

Problem: When you create a Google Maps demo and run it using an emulator of API level 24 (e.g. Nexus 5 API 24), the app opens on the emulator with the message "...won’t run unless you update Google Play services".

Solution:  In \app\build.gradle file, com.google.android.gms:play-services version might be 10.2.0. Change it to 9.8.0 and your app will run fine.

Sunday, February 19, 2017

Better WhatsApp Group Chat

Group chat is widely used in WhatsApp. As the size of the group gets bigger, communication is dominated by few people who usually generate a lot of noise. I had to leave groups because I was fed up with the endless nonesense of these few people. Arguing with them makes matters worse. Almost everyone I know has similar experiences.

I can silence a whole group in WhatsApp so that I do not get notifications. What I need is the ability to mark people in a group as important and unimportant. Messages from people that I mark important should be easy to spot when I scroll through the messages. They could have yellow background and bold font. Messages from people I mark as unimportant should be shown collapsed and become only visible in full when I click on the message. That would allow me to quickly see important messages.


Friday, January 20, 2017

My first Android app: Rescue Map

A friend of mine is a member of the search and rescue organization AKUT. He asked if there is an app that could draw the estimated victim region on a map according to victim category.

The category specifies at what speed the victim is expected to be moving. The app has to have offline map capability so that it can be used when there is no reliable internet connection.

I did a quick search on Google Play and could not find anything that did the job. So, I decided to write it myself as a first project in Android. The source code is on GitHub. I don't plan on publishing it to Google Play until my friend says that the app is really useful and others could benefit from it.

Racism test

Compared to older times, open racism is in decline. It takes on more light forms like "I love my culture/people". There is nothing wrong in loving certain things or having preferences. The critical point is how you view others: Do you just want to be left alone with your pure clan or do you think you also have a "natural" right to decide on others destinies because you are part of the master race/gender?

Likeable vs logical

In both professional and social interactions, being likeable is much more important than being right. I am amazed how much this fact is ignored by otherwise intelligent people. If people don't like you enough, they won't even listen to you which means that you are wasting your time constructing arguments. People will be meaner to you. Your name won't come up when there are opportunities or positions to fill. In short, your quality of life will suffer.

How can you be more likable (in order of difficulty):
  1. Smile and greet a lot.
  2. Don't talk if you have nothing nice or productive to say.
  3. Avoid ad hominem attacks and generalizations. Example: "You always do this because your are an emotionless prick!"
  4. Find mutually beneficial solutions to problems, even if it means to settle on a less-than-optimal solution.
  5. If you have to argue, keep calm and argue with unambiguous data. This implies that you have to collect data before the argument.
  6. Be sympathetic to others. People rarely mean exactly what they say. There are different dynamics at work that makes them behave as they do. If you take their words at face value, you might think that they are dumb or crazy. They are not. Their feelings might be hurt by something else, they might be tired etc. 
People have flaws, don't treat them like computers. The next time you are about to label others stupid because they are not convinced by your perfect arguments, ponder if they like you or not.

Book: Dark Sun: The Making Of The Hydrogen Bomb

Dark Sun: The Making Of The Hydrogen Bomb, Rhodes, Richard, documents the history and politics of hydrogen bomb development both in the USA and the Soviet Union. For the story of atomic bomb development see my previous post.

Book: Command and Control

Command and Control: Nuclear Weapons, the Damascus Accident, and the Illusion of Safety Schlosser, Eric, details how fragile nuclear weapons safety is.