Archive for April, 2012

Flex UncaughtErrorEvent in non-debug flashplayer

// April 27th, 2012 // No Comments » // Hardware

Flashplayer 10.1 and AIR 2.0 come with very nice feature enabled – global error handling.
Here is the official Adobe announce about this:

Update 2010-01-12: Global error handling is now supported in Flash 10.1 and AIR 2.0 (both in beta), and is achieved by subscribing the UNCAUGHT_ERROR event of LoaderInfo.uncaughtErrorEvents.

Anyway, this is very useful especially when you run debug version of flash player.

But what is happening if you are using the regular non-debug flash player ?

Then simply the stack trace does not appear. Here Is example of demo code which globally handles errors in flex application:

In Application.mxml applicationComplete event handler:

loaderInfo.uncaughtErrorEvents.addEventListener(UncaughtErrorEvent.UNCAUGHT_ERROR, uncaughtErrorHandler);

And here is the handle method:

private function uncaughtErrorHandler(event:UncaughtErrorEvent):void {
var error:* = event.error;
if (error is Error) {

var errorObj:Error = error as Error;
LOG.error(“{0}. {1}\n {2}”, errorObj.errorID, errorObj.message, errorObj.getStackTrace());

} else if (error is ErrorEvent) {

var errorObj2:ErrorEvent = error as ErrorEvent;
LOG.error(“{0}”, errorObj2.text);


If you check out the result of this code ran in non-debug flashplayer version, you will notice that only “Error #1009″ is printed.
It would be nice if adobe store at least the target class in the ErrorEvent object, so we can see when regular users are having runtime errors and then can send the error to our support engineers.

RFID Destroyer

// April 20th, 2012 // No Comments » // Hardware

This is simple project that based on board of old camera.

The flash is removed and instead of it, there is a coil connected to the board, so the high voltage (~300V) is used to destroy the RFID chip, which is made to support low voltage. The schematics look something like this:

And here is the final result. Inside:


The usage is very simple. The RFID card must be placed directly under the soap-box and then the button must be pressed.

Then the card is completely destroyed :)

RFID EM4100 Emulator

// April 20th, 2012 // 2 Comments » // Hardware

This is simple hobby project that will show you easy, simple and fast way of emulating the popular RFID access cards EM4100.
My implementation uses manchester encoding for thansmitting the emulated card ID. The MCU I’m using is PIC18F2550.

The Antenna design:
Diameter D 43mm
NUmber of turns N 48
Wire Diameter W 0.18mm
Turn spacing S 0mm

So the target inductance is 160uH. This is the schematics:

You can download the code from here.  The final prototype is having 8 buttons which are used to switch between the currently emulated card.

The device supports 8 cards so far, which are programmed into the chip memory using standard Pic Kit 2 programmer.

This is how it looks:

The problem I’m having so far is that some readers are unable to read the card because they are expecing PSK coding.
Any help on modifying the code to support PSK coding will be aprischiated.