Category Archives: Installation

Processing Countdown Timer

In case you need to implement timer in your project that have a specific countdown time and you can check if it has expired or not , this code snippet will help.  

Processing + SimpleOpenNi + Export exe

Seems like there’s an issue here where your code run find in IDE but not after exported to exe.
So the solution is found here:
So, you will need to download the simpleOpenNI fix and replace with the one in your exportedApp\lib. Good luck!

Kinect Pixel Mirror

This installation use Kinect to turn real human into pixel. A clever implementation as it avoided showing off kinect weakness but highlighted the strength. 1670870-inline-iris-interaction-04 1670870-slide-iris-interaction-02 More reading can be found here:
Perhaps a animated gif can present the idea better. Iris-by-Hybe-3 However, Hybe is not the only one doing thing like this. There are many other attempts: Here is my version of it, done using processing with screen base display. Havent have time to draw the grid yet, and i use icon from font-awesome for the representation. 20140913_200628 and here is a short video:  

AutoHotKey force app fullscreen automatically

For example, you have an exe that you need to force it fullscreen, on top and borderless and yet you have no access to the source code. AutoHotKey is here to rescue. Do you know that you can compile an AutoHotKey script into exe file? Then, you can pass parameter to it from CLI.

Step 1: grab this code

(assume your screen resolution is 1920×1080) and save as fullscreen.ahk

Step 2: convert it to fullscreen.exe

You can use the free Ahk2Exe.exe to convert the ahk into a exe file. Look for the compiler at path like: “C:\Program Files (x86)\AutoHotkey\Compiler”

Step 3: create a launcher.bat

Put the following line inside: make sure your fullscreen.exe and app.exe (program to launch in fullscreen) are in the same folder (in this case is in C:\MyApps). You will also need to change the window_title_name to the correct title name.

How to know my application title name

AutoHotKey come with another goodies called “Active Windows Info” or simple window spy. You can locate it at path like “C:\Program Files (x86)\AutoHotkey\AU3_Spy.exe” Launch it then focus on the application that you wanto find out the title. Look for the first line under >>>>>>>>>>( Window Title & Class )<<<<<<<<<<< section, that’s your application title name!

Capacitive Sensing

Capacitive sensing with arduino can easily amaze your friends as it can easily sense human touch through any conductive material such as metal, graphite (pencil drawing), or even fruits (juicy)! First of all, you will need to download and install the CapitiveSense Library from here. Restart your arduino and you should beable to see examples code likes below: capacitive example   Then, construct a circuit with arduino uno board. The resistor I using here is 10k ohm but the best would be 1M ohm. sketch_bb   You will need to upload the following sketches: Touch each end of the sensor and you should start seeing value changes in serial monitor. You may connect it with any conductive material, in this case, i choose vege and fruits. 20141201_220147 You may further enrich the output using processing + serial. The outcome:  

AutoHotKey force app to fullscreen

Sometime you need to full screen an application that you have no access to the source code. AutoHotKey come in handy:
  1. grab and install from here.
  2. Then, copy the code and save it as fullscreen.ahk, double click it.
  3. You can now press CTRL+Z to toggle the active application into full screen mode. (NOTE: the code assume your screen resolution is 1920×1080)

Checking arduino port on ubuntu

Sometime in processing, you will need to listen to the serial port that arduino attached to. Finding out the portIndex is easy on windows by simply checking in Control Panel -> Device Manager. However when you are in linux (ubuntu), you will need to use command to do it.
  1. First plugin your arduino to usb
  2. type lsusb to see list of attached usb devices
  3. type dmesg | tail and it show you which serial port your usb device bind to. In my case, it is something like: [3486.xxxxxx] usb 2-2: FTDI USB Serial Device Converter now attached to ttyUSB0
  4. or, you may also type dmesg | grep tty
  5. Then you need to figure out the index of this ttyUSB0. Ubuntu reserved ttyS0 to terminal and 1 until 31. normally ttyUSB0 means 32.

Arduino Clone vs FTDI

FTDI has been acting very unprofessional by pushed out a new driver with Windows Update that bricks counterfeit/clone/incompatible FTDI chips by setting the Product ID to “0000”. Here is the process that worked for me to return the FTDI chip back to its original VID:PID of 0403:6001 from a Linux (Ubuntu) computer.
  1. Plug in your bricked device.  If you run “lsusb” it should show a device at “0403:0000″.
  2. Download ft232r_prog from ft232r_prog (v1.24) and extract to a folder
  3. Install the build dependencies by running “sudo apt-get install make gcc libftdi-dev"
  4. Change directory into the folder cd /ft232r_prog
  5. Type “make” to build the program
  6. Now run “sudo ./ft232r_prog --old-pid 0x0000 --new-pid 0x6001
  7. You are done.  Unplug and re-insert your USB device and run “lsusb” again.  It should show an id of 0403:6001
However, if you just wanto use the chip on windows, you may follow this video tutorial: or
if somehow your USB Serial Port show a warning icon after you done all these, you may wanto follow this tutorial to set the PID from 0000 back to default 0001.
  1. Downlaod
  2. Install and run FT_Prog
  3. Click the magnificent glass and you see Product ID is 0x6000
  1. Click USB Device Descriptor
  2. On the right panel, select FTDI Default
  3. Click the lightning icon to Program Devices
  4. Click Program button and it will be alright.

Normal Map

We asked for normal map to use on 3d coin, but our freelance designer gave us this: 5Cent_LoNormalsMap   This is not normal map, not even quite a bump map. Here is a better explanation: normalMapMiniTut Malaysia colleagues trains many good 3D artist, but mostly for the pre-rendered video use. They should expose more to real-time rendering 3d modelling.