How to recover a discarded draft in Gmail

June 2nd, 2013 by Ruwan Egoda Gamage

YOU CAN’T DO THAT!!! GMAIL DOESN”T PROVIDE THAT FEATURE! ONCE YOU DISCARD IT WON”T GO TO TRASH. IT’LL BE LOST!!

However, If you are lucky there are few options that would work.

1. Just hit the “UNDO” button :-) . You have few seconds for that.

2. If you’ve discarded the draft on a PC, you could use Android phone GMail app if available. You have to do that quickly :-) .

  • Disconnect the phone from Internet: If you are using 3G/4G data connectivity select Airplane mode quickly. If using wireless internet, disconnect that.
  • Select Drafts (top dropdown in the app).
  • If you are lucky, the Draft might be there. Copy the entire text.
  • Compose a new message and paste it.
  • Reconnect internet.

3. Re-type the lost message from memory :-(

#2 saved me!!

 

How to unlock T-Mobile Samsung Galaxy S3 (for SLT Mobitel) – No rooting or installing apps required.

June 2nd, 2013 by Ruwan Egoda Gamage

I’ve just unlocked my Samsung Galaxy S3 (SGH-T999).  Now it works with Sri Lanka Telecom : Mobitel.

Note: This method only works with phones having stock 4.1.1. 

Just dial the following keys *#197328640#

Main Menu
[1] UMTS
[1] Debug Screen
[8] Phone Control
[6] Network Lock
Options [3]Perso SHA256 OFF
(after choosing this option, wait about 30 seconds, then go back one step by pressing the Menu button then select Back, now you are in
[6] Network Lock then choose
[4] NW Lock NV Data INITIALLIZ ….. wait for a minute then reboot your phone

source: http://forum.xda-developers.com/showthread.php?t=2176721

Recovering ubuntu after a crash : a mount issue

February 22nd, 2012 by Ruwan Egoda Gamage

My ubuntu machine dumped following and went into initramfs prompt.

mount: mounting /dev/disk/by-uuid/xxxxxxxxxxxxxxxxxxxxxxxxx on
/root failed: Invalid argument
mount: mounting /dev on /root/dev failed: No such file or directory
mount: mounting / sys/ on root/sys failed: No such file or directory
mount: mounting /proc on /root/proc failed: No such file or dirctory
Target filesystem doesn't have /sbin/init.
No init found. Try passing init= boot arg
BusyBox vx.xx.x (Ubuntu 1:x.xx.xx.xubuntu7) built-in shell (ash)
(initramfs)

Several attempts to recover it using the LiveCD (10.04 LTS, same CD used during installation) failed.
ubuntu@ubuntu:~$ sudo umount /dev/sda1
umount: /dev/sda1: not mounted
ubuntu@ubuntu:~$ sudo e2fsck -f -v /dev/sda1
e2fsck 1.41.11 (XX-Mar-2010)
e2fsck: Device or resource busy while trying to open /dev/sda1
Filesystem mounted or opened exclusively by another program?

Then found out that this was a reported e2fsck bug!!

Comments suggested to use either 9.10 LiveCD or a nice boot-repair cd!

Since the latter downloaded earlier :-) , I gave it a try. It fixed the issue! I believe the former would fix it too.

TTFace – The Bus Time Table Display System for Southern Province of Sri Lanka

July 19th, 2011 by Ruwan Egoda Gamage

Have you been to a bus stand in Southern Province of Sri Lanka recently? Specially the new bus-stand in Galle? If you did, you might have noticed the new Bus Time Table Display System (TTFace).

I’m thankful to Southern Provincial Road Passenger and Transport Authority (SPRPTA), for the opportunity provided me to develop the above system.

We have come a long way since the first version I gave them for free in 2005. Now the system is in it’s version 3.

A sense of accomplishment : How people are using the system.

System Features

  • Displays information in 6 rows corresponding to 6 routes at a given time.
  • Each row displays multiple routes by rotating them over time.
  • In each row, Destination, Via and Route No information is displayed.
  • In each row, next two buses and their departure times are displayed of the route.
  • For each route, hop information is rotated. For each hop; destination, distance, and fare are displayed.
  • In each route, the bottom row displays the entire schedule of the day.
  • Displays a text marquee at the bottom. TTFace uses that to display important messages and text advertisements.
  • Displays video advertisements.
  • Supports, Sinhala, Tamil and English Languages.
  • Single computer supports multiple screens.

A courageous friend of mine

July 12th, 2011 by Ruwan Egoda Gamage

It was my first day in the University of Moratuwa. I remember, how much excited I was to make new friends. During the orientation I started a conversation with the gentlemen who was sitting next to me. As I remember, it was my first attempt to talk to a batch-mate I`ve never met before.

I couldn’t recall, how I started the conversation exactly. Most probably, I might have asked his home town. The conversation proceeded few more seconds.

I asked, “So, did you do any sports in your school?”

He smiled. And gently replied, “I couldn’t! I’m crippled”.

I felt really bad. I shouldn’t have asked that question. Unfortunately , I hadn’t noticed his condition. I certainly hoped that his thoughts were the same and most importantly I didn’t hurt his feelings.

Over the years I came to know about him a bit more. He was determined, courageous and most importantly very friendly. In the final exam, he ranked top in his field. After graduation, he joined a grad school in National University of Singapore with a scholarship.

A few days ago, he earned his PhD from National University of Singapore.

Dr. Jayathilake, CONGRATULATIONS machan. I wish you all the very best from the bottom of my heart. I’m honored to know you personally.

http://www.thesundayleader.lk/2011/07/10/pahalagedara-the-definition-of-courage/

Samsung Vibrant S (w/ Android 2.2 a.k.a Froyo) – Rooting, Unlocking and Configuring for Mobitel 3G Sri Lanka

May 27th, 2011 by Ruwan Egoda Gamage


1. ROOT using SuperOneClick application, works like a charm! http://shortfuse.org/?page_id=2

2. Follow these steps to Unlock http://forum.xda-developers.com/showthread.php?t=761045

3. User following configurations for Mobitel
Create a new APN
Name: mobitel3g
Server: www.mobitellanka.lk
APN: mobitel3g

Posted in Technology | 1 Comment »

Developing Web for Sri Lankans

April 4th, 2011 by Ruwan Egoda Gamage

It is always a pain to support all – at least widely used – browsers! Specially a lot of time is wasted in fixing issues in Internet Explorer (A.K.A. Internet Exploder!).

However, if the target audience is Sri Lankans, that worry is getting less and less. Sri Lankans, more than 69%, are using Firefox and Chrome!

Source: StatCounter Global Stats – Browser Market Share

Shooting Panoramas

October 26th, 2010 by Ruwan Egoda Gamage

I always wanted to write a comprehensive guide on shooting panoramas. But it doesn’t seem to happen. So I’m just dumping few thoughts on how to shoot panoramas :) .

In case you may wonder how I produced this: http://www.janapriya.net/gallery/sigiriya please read on.

Most of you know that, you can shoot panoramas (mostly cylindrical) using a normal point and shoot camera. Some cameras have the built in functionality for this. However, you don’t have the control over the entire process.

The “manual” work flow mainly has few steps. In brief, you take many photographs, stitch them to produce on single photo, upload it, and use a panorama viewer to display it.
1. Shooting photos
2. Stitching
3. Displaying

Shooting Photos
You might use a handheld camera (without using the built in panorama mode) to shoot a panorama. But sometimes it’ll be almost impossible to stitch accurately. This is mostly due to the parallax error: object closer to the camera may move w.r.t the objects seen far away. So two consecutive photos may see the scene differently. Initial years I used a handheld camera. I rotated the camera around a “virtual” point and shoot the photos. You might get satisfactory results after some practice. If you are shooting a landscape, where everything far away, with negligible parallax error. But later i bought few hardware to do the trick. It is called a Panohead (you can google it). Along with a tripod, you can accurately rotate the camera around a point, where there is almost no parallax error.

Number of images required for the stitching, is greatly reduced by using a wide angle lens (fish-eye lens if possible). In other words zoom out as much as possible :) . And take photos with at least 30% overlap.
I used a SLR camera, fish-eye lens, a panohead and a tripod for the sigiriya shots. Furthermore, I used different exposure levels for each photo, to make it a HDR.

Stitching
To stitch you can use Hugin. It is an open source software. Alternatively, you might use free software like Autopano, or commercial software like PTGui. All these software is easy to work with. So I won’t go in detail with them. All above software could be used to generate a stiched single image.

Displaying
There is a commonly used java based viewer called ptviewer. However, many now use flash based viewers. For example, FPP, Panosalado etc.. FPP is not for free, but Panosalado is. I bought FPP for Sigiriya panos :) .

Good Luck!

lolz, a letter for me from my niece (6yr old)

October 7th, 2010 by Ruwan Egoda Gamage

My 6yr old niece typed in a letter addressing me (Maama – in Sinhalese this means “Uncle”). She wanted me to behave well in-front of her friends :D .

No rain welcomed!

May 14th, 2010 by Ruwan Egoda Gamage

We are receiving heavy rain these days. Lets make our voice heard! No rain welcomed!
No rain welcomed!


From the rain’s point of view
From the rain's point of view


Source: Art. Lebedev Studio