Nov 29, 2011

Messing around with AppleScript

Ever since I made the decision to buy a Mac I've wanted to mess around with apples excellent application scripting system (i.e AppleScript). I finally got around to it today and now am throughly impressed by the number things you can accomplish with it.

Anyway as my sort of "hello world" task, I've written up this little script down here which will "speak" or "Read Aloud" the number of unread messages in your "Mail" (assuming you're using - which you should) and the sender and subject of each unread message. This combined with the impressive new text-to-speech voices in OSX Lion makes it rather useful. I will now have all my emails read to me by a sexy indian lady on my computer (aka sangeetha!)

I did some googling around but didn't find anybody else doing this so I figured I'd share it here.

the script!
tell application "Mail"
 set unreadCount to unread count of inbox
 set theMessages to (messages of inbox whose read status is false)
 if unreadCount > 0 then
  say ("you have," & unreadCount & ",new messages")
  repeat with msg in theMessages
   say ("message, from" & (sender of msg) & ". Saying" & (subject of msg))
   delay 1
  end repeat
  say "you have no, new messages."
 end if
end tell
I've also compiled it into an alfred extension which you can download from here cheers

Oct 10, 2011

Donate button is up again.

Hey there,

A few months ago I encountered some problems with the PayPal Donate button. It is now fixed, and donations are working again.

If you like any of my work, have profited from it in any way, or just want to help me out, please consider donating. Even small amounts are appreciated. Donations help keep me motivated, and pay for my education.

Thank you.

Oct 7, 2011

touch! SMS app now on Cydia @MMi repo

I just released a small project that has been sitting on my computer for quite some time. Dhiraagu touchSMS is a small client for Dhiraagu's websms. Search for "Dhiraagu toucSMS" on cydia and install.

It is pretty barebones for now (as it was primarily designed for personal use), but I hope to update it soon and include more error checking routines.. If you encounter any major problems, drop me a line here, or holla @kudanai on twitter.

Thanks @a_rishwan for the support, and the artwork.

Some Known Bugs:

The implementation is pretty rudimentary and you MAY encounter some problems. Firstly, the backend API is far from  complete, and will sometimes act inconsistently. Messages MAY have gotten through even if "request timeouts" occur. Secondly, the "connection checking" doesn't work too reliably so you yourself may need to verify that the internet connection IS in fact, working.

in honor of SJobs. May he rest in peace and his legacy live on for generations to come.


touch! SMS v0.1 screenshot



Sep 18, 2011

Guitar Chords: Heeviyey (TAS)

I've had quite a few requests to do this song, and now finally here it is. I think it's fairly accurate. Note, some of those F#m are better played as F#m7 (where exactly I can't tell you, as shuiz too seems to do it by feel)... just uh..go with it.



#chords: kudanai []

{c: Intro F#m7 C#m Bm E F#m}

Heeviy[F#m]ey, Fenif[C#m]aa e' vaa gothun
Hurev[Bm]eynehen, Bal[E]an mihen dhurug[F#m]aa
Belevun[F#m]ey, engidh[C#m]aaneyey kalaa
ekug[Bm]aa mithaa thih[E]en viyas dhurug[F#m]aa

nuhurev[E]eyney, heeviy[F#m]ey

    hiy ava[E]s kuru vee thiya fathur[C#m]aa vas jehum[F#m]un
    thoonu dh[E]elolaa[Bm], thunfath[F#m]aa
    huvafene[E]i hen mulhi rey dh[C#m]iyumey beynunv[F#m]ee

{c: Interlude F#m C#m Bm E}

m[F#m]aathaku ther[E]ey lui hingumakun dh[Bm]aathee ma dhusheemey
m[F#m]aathakey h[E]eevee raki vaah[F#m]en
ey[F#m] saahib[E]aa thiya ali vi m[Bm]ooney fenuneema
m[F#m]ulhi javvu heev[E]ey alhi vaa[F#m]hen

[Bm]Hinithun vel[F#m]aafaa heevey
[Bm]Udhuhen fash[F#m]aafaaney hen
[Bm]gathugaa hurum[F#m]ey edhenee
[Bm]athugaa hif[E]aashey aadhey dh[Bm]aan
…aadhey dh[F#m]aan.

    hiy ava[E]s kuru vee thiya fathur[C#m]aa vas jehum[F#m]un
    thoonu dh[E]elolaa[Bm], thunfath[F#m]aa
    huvafene[E]i hen mulhi rey dh[C#m]iyumey beynunv[F#m]ee

hiy avas[E] kuru vee thiya fathur[C#m]aa vas jehum[F#m]un
huvafenei h[E]en mulhi rey dh[C#m]iyumey beynunv[F#m]ee

Aug 27, 2011

Guitar Chords: Kalhusoru (Intoxicated By You)

In keeping with the ZeroDegree theme going on at the moment, here's another "simple" song for you.

Basic chord progression is Cm,A#,G#,G in the verse and chorus (with the exception of A#,G#,A#,G on the second bar of the chorus).


{title: Intoxicated By You (KalhuSoru)}
{subtitle: ZeroDegree Atoll}

[Cm]Kalhufoe rey rey [A#]thundi mathi fenifaa  
[G#]Handhuvaru dhekilaa [G]hivvefaa  
[Cm]Magu kolhu hoadhaa [A#]dhekolhah balamun  
[G#]Harukoh helifaa [G]ulhe dhanee  

    [Cm]Dhandumathi gomaya [A#]hama hama kurumah
    [G#]Kalhusoru ovegen [G]farivanee
    [A#]Undumathi nubalaa [G#]nama nama thakuraa
    [A#]Damu higumah nudha[G]maa bahee

[Cm]Iru ossey dhalha[A#]ya balamunthaa 
[G#]dhigumagu medhugaa [G]ithivefaa
[C]Hithuthere raavaa [A#]dhe athah kiremun
[G#]Hithuga hifaa fura[G]gas belee

[Cm]Migothah hutta [A#]ekkala golayah 
[G#]fiyokeh buni adu [G]ivilanee
[Cm]Bala dhon thakuraa [A#]kamaku nudhaaney 
[G#]Hama thigothah hu[G]ttas mirey

{a: Chorus}

[Cm]Hey bo naaraa [A#]kamakutherah Bo-
[G#]beytho beliyas [G]hamahilaa
[Cm]Vidhuvaru fenifaa [A#]dhalhayah helley
[G#]Hindhukolhu dhiyumun [G]foohivey

{a: Chorus x 4}

Jun 18, 2011

Guitar Chords : Thakurah Bahei (Zero Degree Atoll)

I don't think that this song will require much introduction. I spent some time tonight filling in the gaps of how I used to play it (which as it turned out was a few semitones off-key).

Anyway Enjoy, and check out my other music related posts here.

lyrics from here

{title: Thakurah Bahei}
{subtitle: Zero Degree Atoll}

# -------------------------------------------------------------
# tabbed by KudaNai - 2011
# this might be a little confusing. I used to play this in 2,1,1
# dropping the note on the second count which should sound fine.
# I dropped a few fast changing (slide) chords. If you listen 
# carefully you should be able to hear them.
# --------------------------------------------------------------

[C]Othakas maa [Em]kandu, [F]hithakah libi[G]faa
[C]Atha viha nora [Am]dhosha nakathun [A#]nubalaa
Thariyaa [C]burujaa ranga[Em]lhah nufi[F]laa....[G]
[C]Aruvaa jaha[Am]mun dhathurah [A#]nufuraa  
{a: chorus}  
    [C]Riyaleh maa [Am]bodu othakas libi[G]faa....[A#]
    [F]Dhiyagandu nuhi[G7]key nama ee [C]ekugaa
    [Am]Vayashaa [F]oivaru [C]rangalhah nuba[F]laa
    [C]Hiyalehgaa [F]thibe dhathurah [C]nufuraa

[Em]Samugaa molhu[F]kannn, hithu[G]gaame a[A#]lhaaa
[F]Emuney fathi[G]varu farugadhi [C]eh gaaa
[Em]Kamudhaa varu[G]gaa, [F]dhas nuve hithu[C]gaa
[F]Amudhun [G]thakuraa dhathurah [A]nufuraa

[C]Kulhadhaana vi[Am]yas [F]falhuveri e ku[Em]dhin
[F]Hulhangaa dheku[G7]naa vakinuvi na[C]ma ee
[Am]Molhukan [F]dhakkan [C]ovegen [F]hithugaa
[C]Olhigen nama [F]nama dhathurah [C]nufuraa

{a: chorus}  
{a: repeat from samuga, then chorus again}

May 21, 2011

Guitar Chords: Reethi handhuvar (Zero Degree Atoll)

I can honestly say this was one of the hardest songs to figure out. in the end, I think I got most of it  right. If you spot mistakes, let me know in the comments. chords are in "chordpro" format. (you can use GuitarTeX2 or something similar to convert them into a nicely formatted songbook).


{title: Reethi Handhuvaru }
{subtitle: Zero Degree Atoll}
# Tabbed by KudaNai -

# Note- 
# Tabbed here are the major chords used
# in the song. I think I can hear some
# Cm's in the verse but only in transition.
# I tabbed this by ear, and I'm not entirely sure
# if I got everything right.
# Also note, the F's might actually be Fmaj7's

Intro Picking Fmaj7 with high E open

{a: Chorus}
[Cmaj7]Reethi handhuvaru [F]rey dhekifaa
[Cmaj7]Beehi dhe athun [F]fan vathugaa
[A#]Roalhi vee hindhu
[F]Fun assarakun
[D#]Loabi raki hini[F]thun vevilaa x 2

{a: verse 1}
[Cmaj7]Saafu dhonveli fi[F]yavalhugaa
[Cmaj7]Moodhu kairee ha[F]ma jehilaa
[A#]Raalhu raalhaa
[F]Kulhela kulhelaa
[D#]Loabi fari fari [F]thun fathugaa

{a: verse 2}
[Dm]Haa govaa kolve[A#]leege aduthah
[Gm]Dhooni udhuhey [F]hiyanithah
[A#]Mas mahaa vela[F]yaa eh bolithah
[Gm]Russenee hini[Am7]thun vamun

{a: Chorus}
[Cmaj7]Reethi handhuvaru [F]rey dhekifaa
[Cmaj7]Beehi dhe athun [F]fan vathugaa
[A#]Roalhi vee hindhu
[F]Fun assarakun
[D#]Loabi raki hini[F]thun vevilaa x 2

Hmmmm hmmm mmm

May 19, 2011

Guitar Chords: Mulhizindhagee (hithaamain)

This is track on the album "Eyzamaanaa" by "The out of Doors Maldives" (now available on iTunes). Incidentally the same chords apply to Ali Rameez's version titled "Thiya Loabivaage Loibah". Enjoy.


{t: Mulhizindhagee}
{st: Artist: Out of Doors Maldives}
{st: Album: Eyzamaana}

{c: Intro Chords - G C Am D}

[G]Mulhizindhagee hithaamain, huri haalakee miee [C]tho
Edhi hiyaa[Am]lugaa mi[D]loabin aadheyskuree ruhey[G]tho
[G]Mulhizindhagee hithaamain.....

[G]Dhehvaanu hey, [C]rahmaai ekee va[G]faa X2

[G]Eh ummathah thakaaves, ekuverivelaanu tho [C]ey
Edhi hiyaa[Am]lugaa mi[D]loabin, aadheys kuree ruhey[G]tho
[G]Mulhizindhagee hithaamain...

{c: interlude riff  G C Am D}

[G]Gendhaanuhey udu[C]gaa hin’gaa va[G]yaa X2

[G]Hah’gahtakaa miloabin, haaluge dhulun bunee[C]mey
Edhi hiyaa[Am]lugaa miloabin aadheyskuree ruhey[G]tho
[G]Mulhizindhagee hithaamain

{c: Interlude Riff G C Am D}

[G]Annaanuhey ufa[C]lun nikan ka[G]laa X2

[G]Mithurah Takaa in’geythoa gurubaan vumun hagee[C]gee
Edhi hiyaa[Am]lugaa mi[D]loabin aadheyskuree ruhey[G]tho

[G]Mulhizindhagee hithaamain, huri haalakee miee [C]tho
Edhi hiyaa[Am]lugaa mi[D]loabin aadheyskuree ruhey[G]tho
[G]Mulhizindhagee hithaamain.....

May 1, 2011

iThaana for iPhone 4.3.x

Firstly, allow me to apologize for the delay in packaging the keyboard/font package for iPhone for firmwares 4.3 upwards...I have been really rather busy with a lot of things of late, and I have been taking some..personal time. I'm sorry to have kept a lot of you guys waiting. I am touched by the amount of emails that you've sent.

afxal and I are working to release the update soon enough, and will hopefully make it available within the week.

There is an important side-note here though; I had originally planned to improve and release the keyboard as a commercial package. However, after a long battle with me conscience I decided to keep the package free for now. I do not however, guarantee that future versions will be free.

There are a few reasons for this:

  1. I am a college student trying to earn an education - and this costs money.
  2. I am starting to get sick of commercial entities ( grossly misappropriating and continuing to exploit our work for monetary gain...
  3. I have no monetary goals, but a little retribution is always welcome. (Please contact me on twitter or facebook if you would like to make a donation.)

So keep a lookout. Updated packages will be made available on m0bi repo. <>
As with the previous releases, I am releasing it under the terms lf GNULesser/LGPL, so if you are not familiar with the terms, please read up on them.

Mar 17, 2011

"Eyzamaanaa" album now available on iTunes.

Eyzamaanaa has been in the making for a long time now, and it's wonderful to see the album finally out and selling. It features some timeless classics brought to you in the unique and relaxing style that is the signature of Abcy. If you are a fan of this truly Maldivian and unique style of music, then this is an album you cannot afford to miss.

The album is available in various outlets (Shellbeans, some resorts etc) in and around Maldives , and also on iTunes.

Visit the iTunes store here Out of Doors Maldives

also visit Abcy's fan page on Facebook to hear some sample tracks. Don't miss Luba's version of Ey Hithaa

Feb 26, 2011

Quran Translation needs Your Help.

I understand that the text here might seem a little long and boring, but please bear with me. This is important. If you must skim, please read the last few paragraphs.

About an year ago, I grew frustrated with the lack of a readily usable version of the Quran translation in Dhivehi. Back then, I wanted to be able to use the Dhivehi translation with Zekr; a free (as in freedom) versatile open source Quranic study tool that came standard with a multitude of translations, recitations, localizations and so forth. I wished that the Dhivehi translation was also included among these for everyone to benefit from. For this, I needed a standards compliant plaintext UNICODE version of the translation which, needless to say was not available.

I searched high and low to find such a text. The PDF's available on Presidency Maldives where just that. PDF's from which - despited many hours spent trying - nothing "useful" could be extracted. All the while, interest in the efforts grew, and a few of my friends (Bunyameen, his brothers, Nisham, Nadheem and so on to name a few) volunteered to help.

We approached the Islamic Ministry, the Presidents Office, and all our friends in nooks and crannies of the government trying to obtain in the very least, an MS Word document that we could work with. None of these people were willing to part with anything useful - officially stating the reason that the subject of the Quran Translation was too "volatile" for them to release it. That there were people looking for commercial/political/religious/social/etc gain from the text.

Feb 5, 2011

Dhiraagu webSMS Conduit

I posted a simple bash script a long time ago to try and ease the process of sending webSMS's. While the age when everybody around here was messing around with the service is long gone, I have personally found the service to be quite useful (it's free after all!), and still occasionally mess around with it. The script works through and through and has served it's purpose well over the ages. The problem however, was that it still required the exchange of a (relatively) large amount of data between the client (me) and the server(Dhiraagu). While this is inconsequential on a regular broadband connection, it is a problem on my rather expensive mobile data connection.

Thus, out of this particular need, and after a brief spurt of late night coding (4:00 am - 4:15am?) the following PHP script was born. It is to live on my hosted server, and there act as a "Conduit" between myself and Dhiraagu. As you can see, it is, more or less, a "port" of the original Bash script to PHP...and I hope the PHP gods won't rain thunder and rocks on my head for the horrible job I did of it.

I do wish however that the people at Dhiraagu would update this site, and maybe provide a simple API or something to developers. They also need to reconsider the security..for instance an unexpected upshot of all this, is that THIS script allows me to use SSL between myself and my conduit. Dhiraagu itself doesn't provide this functionality. Not that I think it's of particular relevance, but SSL is always a good thing.

FUN FACT: No matter how long your webSMS password is, only the first 8 characters matter (I'll admit 8 isn't so bad..) be the thing.


PHP script to act as a go-between for Dhiraagu websms
to minimize data-exchange. Ideally for use over a
mobile network.
just upload the php file to some place that supports
php_curl and make a standard GET request to the file
with the follwing parameters:
where cookie is optional, and is the session string of
an existing session.
The Script returns a JSON encoded status message.
$old_error_handler = set_error_handler("myErrorHandler");
'status' => 'OK',
'count' => NULL,
'cookie' => NULL,
'retries' => 0,
function terminate_now() {
    global $SessionData;
    echo json_encode($SessionData)."\n";
function myErrorHandler($errno, $errstr, $errfile, $errline)
    global $SessionData;
    if (!(error_reporting() & $errno)) {
    switch ($errno) {
        case E_USER_ERROR:
        $SessionData['status']="ERR: ".$errstr;
        case E_USER_WARNING:
        $SessionData['status']="WARN: ".$errstr;
        $SessionData['status']="ERRUNKWN: ".$errstr;
    return true;
function make_curl_request($url,$post_params,$useCookie) {
    global $SessionData;
    $ch = curl_init($url);
    curl_setopt($ch, CURLOPT_HEADER, 0);
    curl_setopt($ch, CURLOPT_POST, 2);
    curl_setopt($ch, CURLOPT_POSTFIELDS,$post_params);
    if($useCookie) {
    curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
    $output = curl_exec($ch);
    return $output;
function login()
    global $SessionData;
    if(preg_match('/^Set-Cookie: Dhi=(.*?);/m', $return, $cookie_out)) {
        if(preg_match('/send (.*?) more/',$return,$msg_count)) {
                trigger_error('You have Reached your Daily Quota',E_USER_ERROR);
                } else {
        return true;
        } else {
        trigger_error('Invalid Username andor Password',E_USER_ERROR);
        return false;
function sendsms() {
    global $SessionData;
    if(strlen($message) > 140) {
        trigger_error('Message Truncated',E_USER_WARNING);
    if(preg_match('/send (.*?) more/',$return,$msg_count)) {
        } else {
            trigger_error('maximum number of retries exceeded',E_USER_ERROR);
if (isset($_GET['user']) && isset($_GET['pass']) && isset($_GET['msg']) && isset($_GET['num'])) {
        } else {
        trigger_error('Invalid Number Format',E_USER_ERROR);
    } else {
    trigger_error('Insufficiant Arguments',E_USER_ERROR);
    } else {

and then we have this modified version of the bash script to help make calls to the conduit

#!/usr/bin/env bash

# Bash helper script for Dhiraagu webSMS
# using the webSMS Conduit script from
# 2010 - kudanai

user= #defaultuser
pass= #defaultpass

function printhelp {
cat << EOT
Dhiraague WebSMS Conduit helper- KudaNai (
USAGE: $0 [OPTIONS...] -n number 'message'

 -h  Print this help and exit
 -N  New Session. Do not reuse old cookies.
 -d  Override default directory file. The Directory file
     is a comma seperated file containing name,number pairs
 -u  USERNAME Override default username.
 -p  PASSWORD Override default password.

  Please note that the -n argument is MANDATORY


function sendsms {
 if [ -e ${dirlist} ];then dcheck=`cat ${dirlist} | grep -w ${number} | cut -f2 -d","`;fi 
 if [ -n "${dcheck}" ];then number=${dcheck};fi

 if [ $purge -lt 1 ]
  if [ -e /tmp/$user.wsmscookie ]
   cookie=$(cat /tmp/$user.wsmscookie)
 return=$(curl --silent -G \
  -d "user=${user}" \
  -d "pass=${pass}" \
  -d "num=${number}" \
  --data-urlencode "msg=${message}" \
  -d "cookie=${cookie}" \
 echo $return

 if [[ "${return}" =~ \"cookie\":\"(.*)?\", ]]
  echo ${BASH_REMATCH[1]} > /tmp/$user.wsmscookie

while getopts 'hNn:u:p:d:' Option
 case $Option in
  u) user="${OPTARG}" ;;
  p) pass="${OPTARG}" ;;
  N) purge=1;;
  d) dirlist="${OPTARG}" ;;
  n) number="${OPTARG}" ;;
  h) printhelp ;;
  ?) printhelp ;;

shift $(( $OPTIND - 1 ))

Jan 11, 2011

about updates: iPhone Thaana Keyboard.

This post is long over-due and I apologize for not having written it sooner.

as you probably might have noticed, the thaana keyboard currently only works on 4.0x and 4.1x firmware. However since then, apple has released a major firmware update in the form of 4.2.1. This update include a tonne of changes, including changes to the default fonts, font-handling and keyboard configurations. This inadvertently has broken both our thaana fonts package as well as thaana keyboard package. So right now, the keyboard does not work for 4.2+.

The good news is that it IS possible to get it back up and running without too much effort.

however the bad news is that I am currently using an non-factory unlocked iPhone 4 (as is afxal). As of now, there is no unlock for the iPhone 4 on 4.2.1 firmware. Hence I am unable to update my phone to the newest firmware.

The bottom line is that until I can run 4.2+ firmware on my device, I cannot update the packages. I sincerely apologize for this. Hopefully, the dev-team will come out with some good news soon.

P.S - Some of you have asked if I stopped working on these projects because of what happened with eLL Mobile. This is not the case.

P.P.S - yes eLL, I know you have been  emailing people looking for updates.