Friday, November 15, 2013

Perlc usage | In an aim to make an object file of a perl script.
I was searching for something like a Perl executable to make an object file so that compilation is not necessary. Found that some tools do exist, such as perl2exe, perlapp and an outdated perllcc tool.

I just thought of writing this article to show the usage of the tool, as some beginners (like me) may end up confused.

So imagine you have a script to copy some stuff from one place to another, and you have named it as 'perlcp' and saved it with the extension of '.pl'.

So imagine you were searching online for a script that would help you make an executable of your perl script or try to make a '.c' file for whatever reasons you have. You copy this code and save it in a

And you have already installed perl before, and have already thought of leaving your job and becoming a monk.

Eventually to output a perlcp.c file, this is what you need to enter at the prompt:

perl -d

and to make an exe:

perl -exe pearl

This is the same approach used in this xkcd cominc

No wonder beginners get confused.

Wednesday, November 13, 2013

Getting the battery consumption in a COOJA simualtion

The end of the year is coming near, and the different project and researches are wrapping up. That also means unnoticed problems, occasional headaches, and tummy upsets for some staff. Luckily I am not so stressed, and I have nothing to wrap up (per se). Right now I am experimenting with XBee on an Arduino.

I made this small application. I kept an XBee Arduino setup with me, and gave another one to few of my colleagues (read as friends) who are working in another lab. They can press a button on their setup and metres away I will be notified that they are looking for me.

Apprantly they started calling me to close their door, to throw the trash, and the occasional itch.

Could they be punished each time they call me?

I installed a shrill speaker thing on theirs, which beeps a few times whenever they click the button, whereas I hear a nice square wave based music tone.

Nope! Didnt stop them.

Then I gave them the condition that they can only call me 3 times a day, and I will maintain a log of it. (Programming and debugging does mess up a mind)

They called me 3 times in a minutes. I went there. They said it was by mistake the first time, the thing fell down the second time, and third time they lifted it up and put it back.

Now, I have just unplugged my side of the thing.

In other news, COOJA gives me the same set of battery voltage values for some (undisclosed) code:

I don't really know why, and I haven't had the motivation to search for it online.

Now is the time to test it on real Z1 nodes. Now is the time to get the hands dirty (umm pants dusty)

Monday, November 11, 2013

Big Hiccup while renewing the domain

So its that time of the year when Google starts asking me for money.

Google has been a pretty good service provider ever since 2006 when I first started my adventures in the realm of domains.

This time it wasn't such a breeze.

My bank wasn't allowing Google to add my Credit Card details. I have to write them a letter too.

Finally, the domains are paid off. And I can enjoy the rest of this year without much worries.

The 'Kashmiri Songs Sections' has had a major facelift. The new look can be accessed at whereas the classic look is now archived at

In other news, my IIUM convocation is going to take place on the 18th of November.

Few things I observed about the robe.

1. It gets really hot when you put it on.
2. It really really gets really hot.
3. (Takes off robe)

I was planning to suit up in a nice tuxedo. Bad idea.



Hope the new look is better.