… because I forget simple little things too soon …

23 Nov

Epson DS-40 scanner on Linux

In my recent continuous attempt in getting rid of things bulky and/or replacing them with compact and simpler/multipurpose tools (I collectively refer to all these efforts as “minimalism”), I came across my bulky, but trusty, scanner which is part of a multifunction that I purchased for 20 AUD back in 2009. It had outstanding quality and served me for 7 flipping years and 3500 scans. It still works fine but, you know, it’s big for what it does. So I went and did some research and found Epson DS-40 document scanner. It’s not a flatbed but given its size and capabilities as well as my use cases, I’m OK with the compromise. One little thing though — not easy to get it working on my Archlinux installation.

After few hours of headbanging, I gave up trying to make the seemingly well written official driver and scanner utility to work. While I was busy doing this, I read through some of the code and it turns out the protocol the scanner talks is very straightforward. So I decided to hack together a script to see if I could get an image out of it myself. Lo and behold, it was a piece of cake, in less than 150 lines of python code (this is early code, make sure you get the latest) with PyUSB as the only dependency written in less than half an hour, with the help of the official code and a dump of USB packets between the windows driver and the scanner.

It is true that this script doesn’t handle any but the simplest of errors and that’s OK for now because after a few dozen scans it seems to work fairly robustly. When and if it breaks, I’ll fix it.

I plan to add WiFi setup and scanning capabilities as well as Python 2 compatibility to the script to make it a truly one stop shop. Meanwhile, if someone else gets the official stuff working on Arch and it turns out to be better than what I have, I’ll abandon my script in a flash. Until then, how about some minimalistic scanner driver!

7 Nov

Mail Exchanger (MX) Providers Market Share

I recently read an article that showed Google was the email provider for the majority of the top startups in US (couldn’t find a link — anyone?). This inspired me to find out, on a larger scale, which companies are the top providers of email across the whole Internet. However, what I ended up doing was to gather some stats on Mail Exchanger (MX) providers market share. The difference is subtle but important: an “email provider” offers a complete package where a customer is given an email address, an inbox where incoming emails are stored and a facility to send out emails. On the other hand, an “MX provider” only provides servers to receive emails. For example, they don’t necessarily provide storage (e.g. forward only).

The rest of this post documents how I went about it, the results and some other notes.

17 Oct

difftr — Diff Pentaho KTR files

I’ve been using Pentaho Data Integration (PDI) as part of my various jobs over past few years. PDI is an Extraction+Transformation+Loading (ETL) tool that is often used for purpose of migrating data from one database to another. PDI runs scripts, in KTR format, which are directed graphs of “steps”, each of which manipulates the data rows that passes through them. For instance, an “Add constant” step adds new columns with constant values for all rows passing through it. PDI provides a visual development environment where these steps can be added and connected together as to make a “program” that takes a bunch of row+column data, manipulates them, and then outputs them.

Since KTR files are really just programs, they evolve and it is a good idea to keep track of their evolution using standard version control systems such as git. However, KTRs have an underlying XML format that is not persistent in terms of ordering of various elements, etc. Therefore, utilities such as diff are useless on KTRs. That’s why I decided to make a simple tool that would visually diff any two KTRs.

9 Oct

I see robots everyday

I see robots everyday. Not the ones with metallic arms and hydraulic joints. I see humanoid robots, with flesh, some that I’m even physically attracted to. My favorite amongst them is one that operates behind the counter at the pharmacy down the street of where I used to live.

It has the female form, long hair with very appealing smile and just generally friendly looking. Great design I must say, for interfacing with customers. It has a fairly fundamental software bug though. You see, I walk into the shop and it greets me with “Hi, how are you?”, to which I reply “long day, but ok otherwise, yourself?”. It responds with “Good, thanks”. I walk straight to the aisle where band aids are located. I pick one, and walk back to the counter to pay for it. The whole thing takes less than 10 seconds. As I re-enter the view of this robot, I’m again greeted with “Hi, how are you?”! Meanwhile, I’ve been the only customer in the shop since I entered.

14 Sep

I know

I know I’m a kid, throwing fits
I know I act tough, but at a gentle push, fall to bits

I know I’m fickle and stubborn
I know I still have a lot to learn

I know I’m no wall to lean against
I know I’ve failed, to date, at every test

I know you’ve half lost your faith in me
I know my words don’t match what you see

I know said and done stays done and said
I know shed tears cannot be unshed

I know I don’t stand by all that you do
I know you think along the same lines too

I know I don’t know about compromise
I know little I have done in way of sacrifice

I know it takes a pair of grounded feet
to afford the true taste of this treat

I know your plan and what you need
I’m watching carefully, following your lead

I know you have seen plenty of me
I assure you there is plenty more to see

I know in you, you’ve kept a space free
to soak in more of me, whenever that may be

12 Sep

You know

You know that song, that upbeat song
that hangs on the falling edge of your tongue
You know the word that you can’t reach to grab
The one that you think about all night long

You know that scent, the seeping scent
that to you, more than a thousand words it meant
You know the bitter aftertaste of that kiss
on the side of his neck before he went

You know the bang, the chilling bang a few
the wall that hit you when it all came to you
You know the bumps after bumps in your way
around every one of each you bravely flew

You know the ones, the tiny little ones
that one day will escort you around with big guns
You know the one that loses his way sometimes
the one that may not say it often, but loves you tons

You know you, the glowing vibrant soul
who for sake of others doesn’t mind to pay the toll
You know you, the rarity that’s hard to define
who makes the life of others around her, whole

You know all this well, I know you do
You won’t have to guess, you don’t need a clue
You know all this well, but choose to ignore
it’s you who gives gray, a sense of hue

12 Sep

The Flickering You

Oh I know it’s lingering in you
that tingling of a sensation you don’t verbalize
I can see the smoke of the gunpowder behind your lips
that fails to let that bullet mobilize

Your lips are an armor, that can only save me
not only in one but in two ways
But you flip the coin too early
before either takes shape and stays

Oh I know you hate to see my fall
at meeting the bullet that left its shell
Oh I know you want to purse your lips
and lock your hands around me as well

I was told it sucks to be me
seeing a garden behind the glass wall of circumstance
I agreed but then I walked into that wall again and again
each time closing my eyes and taking a chance

It’s not like a story
that gets old the more times it’s told
It’s the rising confidence from riding a bike
on a leaf covered sunny summer road

I never met anyone with whom
I painted such an art on the outside
that let us secretly make love
from across an attentive crowd

Part of me has found a hole in your heart
to fill, to wrap a rope around and keep
Part of me, sees a rose colored light
from the corner of my eye and hears a beep

Remember you lost control once
but never crossed that boundary
Was it because of another loop of a rope
or your belief that you weren’t free?

11 Sep


I’m hungry, haven’t had a thing to eat
I’m tired, can’t find a fucking seat
I’m fired, as soon as I get to work
I found food, but ain’t got a fucking fork

I’m here, but you’re not ready
I’m curious but steady
Why the chalk painted face
Why the calm and poisoned pace

Why the shame colored will
Why stepping off the thrill
Why a cutting edge that’s dull
Why a coming gift that’s null

Carpet couldn’t tell us apart
There is a little ink on your heart
Fairy does no justice at all
I’m forced again, to make the call

11 Sep

They know

Do you think it shows?
Do you think everybody knows?
Do you think they point at us
and call us one of those?

Do you think it’s obvious
that what we have is serious?
Don’t you think that after a while
it will become tedious?

Don’t you think that we’ve gone too far?
Left each other with a lasting scar?
Don’t you think that from afar
what we do looks mostly bizarre?

Of course it shows
For genuine ones like ours, that’s the way it goes
We could never hide it
The more we weigh it down, the higher it soars

To call it obvious is to put it lightly
To rhyme it with serious is certainly sightly
To make assumptions about what is to come
is naive and pointless if I put it politely

Break away from vagueness and cliche
Part with the need for others to shout hooray
Lock your steps with mine from now on
Let’s be a team, let’s kick and play

10 Sep

True Measure

Word has it
that the true measure of a pliar
given the breadths of the tools empire
is how it inspires a hammer
that’s trapped in barb wire

A tire in its entire
wisdom however
can only acquire
circular satire
while rolling on succulent cement
anxiously waiting to retire
so it can watch the dance of the pliar
It’s a scene to admire

besides ranting, you may also find me asking silly questions or writing code for the world. Make sure you read the privacy policy.