Saturday, October 08, 2011

printf ("Goodbye Dennis Ritchie");

Rest in peace Dennis Ritchie


Wednesday, October 05, 2011

Rest in Peace Steve Jobs

Steve Jobs, Apple co-founder and former CEO, has died at the age of 56. So sad :(

Rest in peace Steve ....
http://www.apple.com/stevejobs




Thursday, September 29, 2011

Android HttpURLConnection improvements

This is awesome news , the Android team is finally fixing and improving the HttpURLConnection.


"Apache HTTP client has fewer bugs on Eclair and Froyo. It is the best choice for these releases.
For Gingerbread and better, HttpURLConnection is the best choice. Its simple API and small size makes it great fit for Android. Transparent compression and response caching reduce network use, improve speed and save battery. New applications should use HttpURLConnection; it is where we will be spending our energy going forward."
http://android-developers.blogspot.com/2011/09/androids-http-clients.html?m=1

Wednesday, September 28, 2011

MacBook, the battery status check

Pick up this useful bit today. If you need to check the battery status on the MacBook you can use the command:
ioreg -w0 -l | grep -i capacity

On my MacBook I got:
    | |           "MaxCapacity" = 5936
    | |           "CurrentCapacity" = 1106
    | |           "LegacyBatteryInfo" = {"Amperage"=18446744073709549771,"Flags"=4,"Capacity"=5936,"Current"=1106,"Voltage"=10837,"Cycle Count"=356}
    | |           "DesignCapacity" = 6900

The 6900 is the designed capacity of the battery and 5936 is the max I can get at this point. This kind of gives some info how much the battery degraded over time.




Wednesday, September 14, 2011

Chrome on Mac OS X with Android User Agent

open /Applications/Google\ Chrome.app --args -user-agent="Mozilla/5.0 (Linux; U; Android 2.1-update1; de-de; HTC Desire 1.19.161.5 Build/ERE27) AppleWebKit/530.17 (KHTML, like Gecko) Version/4.0 Mobile Safari/530.17"

Wednesday, September 07, 2011

Michael Arrington interview with Arianna Huffington

I found this interview quite entertaining.


Saturday, July 02, 2011

Thursday, June 30, 2011

Ref: Android UI: Tips, Tricks, and Techniques

Just saving the pointer to this post here:
Android UI: Tips, Tricks, and Techniques

This presentation video is worth watching if you are looking for the few tips on the Android code optimization and UI optimization in particular from the couple of the "founding fathers" so to speak :)
The guys do not go deeper on the subject but give a pretty good overview on things to be aware of. The more detailed articles are available on android developers web site.

Android - libs-for-android

Couple of days ago I started to list few quite useful Android open source projects to learn from.

Here is another one I forgot to mention:

libs-for-android

Slightly different approach to ImageLoader implementation, with the public API that binds image view the the url. Also it uses http API from java.net instead of org.apache, that I would probably change, cause I remember having few issues with java.net connections before.

Enjoy!

Wednesday, June 29, 2011

Odd Day

Today one colleague of mine and just a very good guy, that I really enjoyed working with, had his last day at the company after 12.5 years of service.
It's kind of sad to go back to work tomorrow and not to see him again, but I'm glad to see him happy about the new opportunities for him.
12 years at the same company is a long time.....

....And the things get "better" when you find out that there is another great guy that I learned a lot from is most likely to leave in 3 months from now.

Certainly today was not the most productive day.
So, the plan for tomorrow: regroup and try to get my mojo back.

Monday, June 27, 2011

Chromebook - first impression

Just got Chromebook today that was sent to every Google IO attendee this year and wanted to share my first impression.

Pros:

1. The start up and shutdown time is pretty fast.

2. The battery time is very good so far

3. It doesn't get as hot as MacBook Pro


Cons:

1. The Chromebook device feels flimsy. It's all plastic and it gets kind of annoying when the screen vibrates when I type on the keyboard. Might need to get used to the keyboard, missing some keys when I type fast and navigation keys layout is a bit strange.

2. The Wifi is the "corner stone" of this device is very mediocre. In the house where I have full strengh Wifi reception on my MacBook laptop the Chromebook shows just a half (two bars). It shows 3 bars out of 4 when I sit in just 4 meters from the wifi router. It said on the box that the device comes with 100MB/month 3G data allowance, and this is very limiting for the device where network presence is everything.

3. Touchpad does not feel like too responsive, probably I just might need to get used to it.

4. I do't know if it's a quality of the screen or the fonts, but the text doesn't look that pleasant for reading , especially the small fonts. Some fonts seem to be off from the fonts I got used to see in the browser on Mac or Windows.

5. Gtalk feels more limited since I can not resize the chat window or I can't pop it out, cause there is nowhere to pop it out to.

6. I still kind doubt that the browser-only OS will be sufficient for me and that I would like to keep everything I do in the cloud.

It feels like Android OS at this point has some advantages, cause one can still run web applications on it as well as the native apps.

Finally, I understand that I got the Chromebook for free and really should thank Google for this instead, but I kind of hope that my feedback would help to make the next devices and Crome OS better.

I will keep playing with Chromebook some more and maybe, who knows, will change my opinion or even find some positive aspects of this device.

So far I'm not impressed.

Update: One thing the full screen browser experience kind of lack is ability to see both browser windows side by side, it pretty much invaluable in situation when our small kid wants to watch some cartoons on youtube and I would like to read emails or news at the same time.

Android - some best practices with source code

Android applications development although seems to be quite simple, has few things that can be described as a best application design practices. I personally learned many things from my own trials and mistakes, but nowadays you can make few shortcuts and learn from experts.

There are some good code samples that show some good practices shipped with Android SDK. You can always get the Android source code (expect the latest Honeycomb 3.0) and explore how everything is done there.

Also I'm going to list few projects that one can use as a reference for some good practices or inspiration:

1. The Google IO schedule application: http://code.google.com/p/iosched/
2. The Romain Guy's application that he created for Google IO 2011, that has some tips on animation and images handling (LruCache): http://code.google.com/p/xlarge-demos/
3. The application created by Reto Meier that shows some best practices for location aware applications: http://code.google.com/p/android-protips-location/. The post about this can be found here: http://android-developers.blogspot.com/2011/06/deep-dive-into-location.html
4. The Droid-fu library that contains some useful ideas and patterns: https://github.com/kaeppler/droid-fu . I found ImageLoader to be pretty useful.

These are just few recent ones (except droid-fu) .... more is coming.

Thursday, June 23, 2011

Android devices stats

One of the projects I'm working here on is the framework of collecting applications metrics for Android, IOS and RIM applications. There is a bit of client code involved as well as the "big data" processing (Hadoop, Vertica) on the server side.

Recently I was asked if it's possible to get the applications usage report on Phone vs Tablet devices for the different platforms.
Don't ask me why, I don't know the answer to it, it's just needs to be done, period :)

The situation with IOS devices is pretty simple, cause you are pretty much limited to 3 devices:
iPod touch
iPhone
iPad


For android the situation is more complicated, especially since many early tablets are still running Android 2.1 and 2.2 and virtually indistinguishable from the phone with slightly bigger screen.

Currently we use Build.PRODUCT as the main device identifier, that, for example, has "htc_supersonic" value for HTC EVO phones. Now the problem is that we have more than 2000 different android "products" values reported, and every day the new devices are getting announced. So somebody would have to maintain manually the mapping between the device product name and some commercial product name and the type in order to get the kind of report we are being asked for, something like htc_supersonic <=> HTC EVO, Phone.

I wonder if there is such mapping is readily available and also it might be convenient if Google could open the API for that, since the kind of do the final certification for Android devices as far as understand.

Anyways, if you stumbled upon similar problem and have a solution to it, please share.

How to leave the running process on Linux after SSH session is disconnected

.... I had to use this pretty often recently, to kick off the script on the remote machine and exit SSH session while leaving the process running.

Here is how to start the process:
nohup ./myscript.sh > /dev/null 2>&1 &


This post is mostly for myself so I don't forget ....

Sunday, June 05, 2011

Richard Feynman: "Fun to Imagine"

Stumbled upon quite interesting and entertaining videos by Richard Feynman:
http://www.youtube.com/playlist?p=PLC351CC566C21C884

Friday, May 06, 2011

Google IO 2011, here I come!

Having early flight tomorrow morning to San Francisco, will stay in Palo Alto for the weekend, meet friends, drive around, visit few places (Napa Valley? ;) ).
Then off to the city for Google IO conference, can't wait. Should be very interesting :)

Tuesday, April 12, 2011

50 years of space exploration

It's been 50 years since the first human journey to outer space.

I can't say that I'm completely happy with the pace of the space exploration.
There is no doubt that a lot was done there, but it feels like there is more that could have been accomplished during these years.

It's amazing to remember how much enthusiasm towards the space we had when we were young. I pictured future to be a bit different back then after all the sci-fi books I've read after all the sci-fi movies I watched.

It's amazing that after 1972 we never visited the moon anymore or any other planet.

Nowadays it looks like the next generation of young people is more interested in all kind of gadgets/gizmos (iPods/iPads). They either want to be some kind of celebrity and/or own bunch of "stuff" or/and be rich.

I hope that I'm all wrong about this, we will see.

One more day till vacation ...

... looking forward to enjoy this weekend and the next week in Playa del Carmen, Mexico.
Just went through all my scuba gear, packed it all up and ready to go.
...one more day, yeah! :)

Friday, February 11, 2011

Running Man

About 5 month ago I started running.

Our company built one mile trail around the campus at that time and I had to try it. Also my daughter signed up for "Girls on the Run" 5K (km) marathon for December, so I really needed to get in shape in about three months.

I'm quite fit person, but never was a good runner. The most I even run before was when I was at school and we did 3km (a bit less than 2 miles) timed runs in the physical education classes. My work days are full of sitting behind the desk, working on the computer type of "activities", and this doesn't really promote healthy well-being.

My first run I barely made 1 mile, the pace was very moderate, but my heart was racing fast (165bpm+) and I felt really out of breath at the end of the run. This was quite motivating experience. After this, I was even more determined to run 5k marathon by December and I knew that I would have to push harder to reach that goal.

So I kept running about 3-4 times a week and slowly increase the distance. I started to notice that it becomes easier and easier to run once I find the rhythm. By December I reached 5 km (3.2 miles) distance. The first time I run 5K I was like, WOW(!!!), I did it, I never run more than 3K in my whole life and now I did it. There were few other positive changes that I noticed: my running heart rate dropped from (160bpm+) to 130bpm range, the stairs do not cause such a spike in the blood pressure anymore, I forgot when I had a headache last time and I started to feel better overall.

I've read many discussions online where people are complaining on all kinds of running injures they start getting once they start running more. Initially my knees started to bother me sometimes as well. Don't make it stop you from running. You have to listen to your body of course, and if your body starts to "complain" you are maybe pushing it a bit too hard, especially in the beginning, give it more time to heal and recover, but do not stop running, just push a bit less. Instead of increasing distance or time by a mile a week/month, try half a mile or quarter of a mile or maybe even less than that. Try to change the technique how you run to avoid unnecessary injures, try to land softer on the balls of your feet, right under your body center, open up your posture, relax more.

I've heard many people who run actually say how much they enjoy running. For me running is continuous struggle with myself and my laziness. But I found one interesting thing for myself: I really like the feeling after the good run (has something to do with natural biochemistry and metabolism), and the feeling of "victory" over myself (no matter how much I want to stop and rest on the last mile I just have to keep going).

This week I run four days so far, two of them were 4 miles (6.4km) run, the best time was around 32 minutes, maybe it's not that fast, but I'm pretty happy about this accomplishments. If I keep up the pace I hope to be able to run 10K marathon (10km ~ 6.2 miles) in around 50 minutes.

Hope this short post will spread some motivation around.

Keep running, keep pushing! :)

Saturday, December 11, 2010

Android "Gingerbread" SDK - first issues

I downloaded Android "Gingerbread" 2.3 SDK with the new tools the same day it came out, and started to get nuch of errors with the string resources that were using formatting flags: SDK 2.3: Get "Multiple substitutions specified in non-positional format" error.

So the issue was that with the latest SDK tools the absence of positional identifiers in the resource string ends up flagged as errors. Here is a little bit more discussion on this problem:
http://groups.google.com

The solution is to change the resource strings to look like this:
Hello, %1$s! You have %2$d new messages.