05.01.11

Barcoding

Posted in Development at 10:20 pm by cphoton

Just sharing a few lessons learnt for adding barcodes to your application (had to do this for a personal one):

1) Select the barcode type you want to use. For common stuff, Code 39 or Code 128 are good options. Make sure the barcode scanners available support the selected barcode type.

2) Create an algorithm for encoding the information you want to embed on the barcode.

2a) It’s a good idea to use Base36 encoding to shorten the data and therefore make the barcode shorter.

2b) It’s also a good idea to use a checksum algorithm if you use Code39 (Code 128 already has a checksum algorithm), for example Luhn’s algorithm.

3) Bind the data to the barcode control. Barcode controls are usually expensive, so if you want a cheaper solution go for a barcode font, there are free ones out there.

Share and Enjoy:
  • Digg
  • del.icio.us
  • Facebook
  • Google Bookmarks
  • DZone
  • email
  • Print
  • Reddit
  • Technorati
  • Add to favorites
  • HackerNews
  • Twitter

02.10.11

Connecting your Wii Classic Controller to your PC

Posted in Hacks at 11:05 pm by cphoton

Long time no see!

This time I am sharing how to connect your Wii Classic Controller to the PC and having it detected as a Virtual Joystick (so that you can use it in games). You need to have a Bluetooth adapter in your computer for this to work. The way that this works is that you connect the Wii Controller to the computer via Bluetooth, and then use a program called GlovePIE to emulate another device, like a mouse, keyboard or a joystick. Joystick emulation is achieved by using PPJoy, which is a program that can be used to emulate Virtual Joysticks and connect other joysticks by using serial or parallel ports. I think that some electronic guys use this way to connect PS2, SNES and other controllers by building a special adapter, but we just require this program so that it can provide Windows with a virtual joystick, and then GlovePIE send the commands from the Wii Classic Controller to the virtual joystick. Keep in mind that this post assumes power user skills, so I won’t go into many details (and the links are comprehensive in that regard). Anyways, here are the steps that need to be followed:

1) Connect the Wii Remote to the computer via Bluetooth.

2) Download GlovePIE (with or without Emotiv support, I used the one without).

Now, from here you can use GlovePIE to map the Wii Classic Controller to the keyboard or mouse, but if you want to map it to a virtual joystick, you need to follow this extra step:

3) Install PPJoy. This one is tricky because its drivers are signed with test signatures. This means that in order for the driver to work, you need to tell windows to accept running drivers in test mode. This is accomplished by running the following commands from a command prompt with administrative rights:

bcdedit -set testsigning on

And to disable:

bcdedit -set testsigning off

You need to reboot the computer after running any of these commands in order to take effect.

Once Windows is in test mode, you can open this script I made in GlovePIE and then you can use your wii classic controller in any games that require a joystick!

One thing I haven’t mentioned yet is that GlovePIE supports a lot of devices, not only the Wii Classic Controller, you can use it for the Nunchuk, the Wii Fit, non-Wii devices, etc (refer to GlovePIE for the complete list).

Share and Enjoy:
  • Digg
  • del.icio.us
  • Facebook
  • Google Bookmarks
  • DZone
  • email
  • Print
  • Reddit
  • Technorati
  • Add to favorites
  • HackerNews
  • Twitter

05.07.10

System Restore Explorer

Posted in Tools at 1:20 pm by cphoton

While organizing my downloads, sometimes I directly delete files directly in order to free up some space, skipping the recycle step. Now, in Windows 7 it happened to me that sometimes it screws up in determining which folder to delete when you have no file selected, and it deletes the entire folder instead!

After venting for a bit, I decided to search for a better way to recover files than using an unerase tool. Fortunately, if you have System Restore enabled, Windows stores a copy of the files you deleted, and by using a tool called System Restore Explorer, you may be able to recover the recently unerased files (I recovered them all)!

Share and Enjoy:
  • Digg
  • del.icio.us
  • Facebook
  • Google Bookmarks
  • DZone
  • email
  • Print
  • Reddit
  • Technorati
  • Add to favorites
  • HackerNews
  • Twitter

« Previous entries Next Page » Next Page »