Saturday, October 3, 2009


買件無骨羊肩, 醃左佢

再加薯角... 咁又一餐!

同場加演, 肥死你牛油磨菇...

... 唔少得啤酒!


Sunday, September 13, 2009

Saturday, September 5, 2009

Star PSS-300

So I have caught the bug. Searched for replicas of air pistol used in competitions. The KSC GP100 is just too expensive for me. The solution? Go for the replica of replica! Here is the Star PSS-300 that I got.

The grip, front and rear sights, trigger etc are all adjustable. For around HKD1000, just can't beat the price.

BTW, the Maruzen APS-3 is very nice too. But again, the price is just out of reach for me... orz

Saturday, July 25, 2009

Olympus PEN E-P1


Sunday, June 21, 2009

Android bug #01

Calendar events entered via the phone won't show up on Google calendar.

Advice from Google doesn't help.

Update: Found the cause. By default, events created on phone are default to a local calendar "My Calendar" that can't be sync with any calendar in Google Calendar. And you can't change the calendar once the event is saved. A "workaround" is to select the Google Calendar for all events created on phone.

Wednesday, June 10, 2009

Signing symbian S60 applications

Note: This is NOT the official way to sign an application. This is just a quick hack to help my friend getting an application running on his phone. Go to Symbian Signed for more details on signing an application properly.

  1. First, go to here to get your certificate and key. If you are not a registered member, you will be forwarded to a registration page. Just create a dummy account. (Yes, the site is in simplified Chinese!)
  2. Once you are at the page for requesting the certificate, enter the data correctly. The "串号" is your IMEI number of your phone. If you don't know what it is, enter *#06# on your phone. The "手机号码" is your phone number. Just enter anything that starts with 13, 15, or 18. The length of the phone number MUST BE 11 digits long. e.g. 15000000000
  3. Once you submitted your request, go to "我的证书" and wait for your certificate and key files. It could take several hours or even a day for the files to be ready. Once it said "已完成", click on "普通下载" to download both the .cer and .key files. Keep them in a safe place. You will need them to sign your applications.
  4. Next, get hold of a Windows application called EasySignPlus. Please don't ask me where to get it. You can easily search for it on the Internet.
  5. In EasySignPlus, select the certificate and key file you got from The password for the key file is four zeros (i.e. 0000). Then drag your unsigned .sis file to the program window. By default, it will sign the application and generate the .sisx file under the same folder as your .sis file
  6. Install the .sisx file in your phone as usual and have fun~!

Saturday, May 23, 2009

my "sun jar"

Tried to make my own "sun jar" around a year ago. Left it on breadboard until today...

Find the schematic below. Added a switch to keep the LED off all the time... which effectively makes the whole thing a solar powered battery charger...

Notes to self:

  1. The solar panel is directly connected to the battery for charging. Without any control on voltage or current. May damage the battery in a long run. But then, the solar panel used is not that powerful... so....
  2. A normal LED requires more than 1 AA cell to power it up. To overcome this, the center-tapped-coil and one of the transistor formed a switching circuit. It generates voltage high enough to light up the LED with less than one volt.
  3. Unlike the commercially available Sun Jar, this circuit doesn't use photoresistor to control when to light up the LED. Instead, a transistor is used to detect the voltage output of the solar panel.

Sunday, May 17, 2009

Arduino test: voltmeter

First experiment with Arduino. Trying to implement a voltmeter.

Each analog input of Arduino has 1024 steps. From 0 to 5 volt. This experiment used a simple voltage divider to measure roughly 0 to 12 volt (using 50k as R1 and 4k3 as R2).

By varying the values of R1 and R2, the precision and range of the measurement can be changed.

Here is the Arduino code:

// variables for input pin and control LED
  int analogInput = 1;
  int LEDpin = 13;
  int prev = LOW;
  int refresh = 1000;
  float vout = 0.0;
  float vin = 0.0;
  float R1 = 50000.0;    // !! resistance of R1 !!
  float R2 = 4300.0;     // !! resistance of R2 !!

// variable to store the value
  int value = 0;

void setup(){

  // declaration of pin modes
  pinMode(analogInput, INPUT);
  pinMode(LEDpin, OUTPUT);

  // begin sending over serial port

void loop(){
  // read the value on analog input
  value = analogRead(analogInput);

  if (value >= 1023) {
  else if (value <= 0) {

  // blink the LED
  if (prev == LOW) {
    prev = HIGH;
  } else {
    prev = LOW;
  digitalWrite(LEDpin, prev);

  // print result over the serial port
  vout = (value * 5.0) / 1024.0;
  vin = vout / (R2/(R1+R2));


  Serial.println(" volt");

  // sleep...

Saturday, May 16, 2009

Arduino & LCD Smartie

Here is a test of Arduino with LCD Smartie. You can get the Arduino sketch here.

Tuesday, May 12, 2009


早兩日係淘寶 order 的新玩具…

Arduino 主板 + LCD and input shields



試 LCD panel

Tuesday, April 28, 2009



Thursday, April 16, 2009


Saturday, March 28, 2009

Windows Server 2008

Trying out Windows Server 2008. Tested it in VMWare 5.x (!) on Windows 2000 (OK, so I am still using Windows 2000 on my main machine). Hardware is AMD 4200+ with 2G RAM. And here are some tips on "converting" a Windows Server 2008 to a workstation.

BTW, if you are/were a high school or university student,go to DreamSpark to download Windows Server and Visual Studio etc for free.

Friday, February 27, 2009




Thursday, January 29, 2009

未來 & 後來

Wednesday, January 28, 2009

Converting MKV files for PSP

Here is the command I used to convert MKV files for PSP:
mencoder 5centimeter.mkv -font c:winntfontsmingliu.ttc -subfont-text-scale 3 -vf pullup,softskip,dsize=480:272,scale=0:0,harddup,unsharp=l3x3:0.5 -sid 1 -slang chi -ofps 24000/1001 -oac faac -faacopts br=128:mpeg=4:object=2:raw -channels 2 -srate 48000 -ovc x264 -x264encopts bitrate=500:global_header:partitions=all:trellis=1:level_idc=30:threads=2 -of lavf -lavfopts format=psp -o 5cm_psp.mp4

  • mencoder: the encoder that i used
  • 5centimeter.mkv: the source file. In this particular case, the MKV container has 1 video steam, 1 audio stream and 2 subtitles (Japanese and Chinese)
  • -font c:winntfontsmingliu.ttc: as I want to embed the Chinese subtitle into the output, I specified the MingLiu font here
  • -subfont-text-scale 3: scale down the font for PSP's relatively small screen
  • -vf pullup,softskip,dsize=480:272,scale=0:0,harddup,unsharp=l3x3:0.5: video filters. Pullup and softskip are not that useful here as the original source has frame rate of 23.976 already. Dsize and scale are to resize the video. Hardup ensure all frames are processed and finally apply an unsharpen mask.
  • -sid 1 -slang chi: embed the Chinese subtitle
  • -ofps 24000/1001: output fps is 23.976
  • -oac faac -faacopts br=128:mpeg=4:object=2:raw -channels 2 -srate 48000: audio part. Uses the AAC codec, 128kbps, mpeg 4 compatible, 2 channels, and sampling rate is 48kHz.
  • -ovc x264 -x264encopts bitrate=500:global_header:partitions=all:trellis=1:level_idc=30:threads=2 -of lavf -lavfopts format=psp video part. Uses X.264 codec. Trelllis, and level_idc are for fine tuning the quality. Threads=2 is used because my PC has 2 cores.

Monday, January 19, 2009



Sunday, January 11, 2009

梁文音 - 最幸福的事

剛買了梁文音【愛的詩篇】專輯。在網上找了《最幸福的事》 MV 來看…很特別的說…


  • 往事 The Past (海拔 2008公尺)

  • 孤獨山城站

  • 人間蒸發站

  • 失落 Lost (3公里)

  • 逝水年華站

  • 青春 Bloomy Youth (182 公里)

  • 沈默村

  • 珍惜公路 Blvd. Treasure

  • 思念點點站

  • 溫柔 Tender (27公里)

  • 遺憾草原

  • 滄海桑田 (1公里)

  • 寂寞招呼站

  • 偷心駅 (320公里)

  • 潰提海岸站

  • 遺憾出口 Sorrow Exit

  • 眼淚下水道 Tears' Drainage (8公里)

  • 幸福 Happiness (208公里)

  • 最幸福的海


最幸福的事 梁文音 (詞)馬嵩惟 (曲)劉宜


你撐著雨傘 借我那次 已經足夠我 記得一輩子
我懂後來你不是不堅持 愛情本來就 沒萬無一失

淚水離開了 你的手指
那不如讓它 流在這信紙

我想女孩子 最貼心的是

我最幸福的事 當過你的天使
趁鼻酸能掩飾 讓我們像當時擁抱最後一次

最幸福的事 吹蠟燭時你總為我許願的手勢
為摯愛的人 在左邊心口保留位置 是最幸福的事

    上行珍惜公路 直達滄海桑田

可惜愛不是 童話故事 不能夠永遠 依賴著王子
才慢慢認識只剩兩個字 我怎麼忍心 為難你解釋

我最幸福的事 當過你的天使
趁鼻酸能掩飾 讓我們像當時擁抱最後一次

最幸福的事 吹蠟燭時你總為我許願的手勢
為摯愛的人 在左邊心口保留位置 是最幸福的事

那一陣子有你 美的不像現實

我最幸福的事 牽著你的日子
一段愛從開始 直至分開我們都對彼此誠實

最幸福的事 對那片海用力大喊永遠的樣子
想得起的事 那天和你傻笑著認識



Thursday, January 8, 2009

The little one