McEs, A Hacker Life
Did I tell that I've moved? Moved to a gorgeous flat on 7th floor of a very good building right in the middle of downtown, Toronto. There's something very very amusing that I cannot tell here :'-(. I may put photos later... Here
is a map of the flat in EPS format.
FAT32 hackings in 2004!
Of course not! Here is the story first: Behnam sent me back my tiny Minolta DimageX digital camera, but forgot to send the USB cable. So I had 128MB of space in my SD Card to fill with photos, and then wait for the cable to arrive by the next carrier from Tehran ;-). So, with Siamak, we made some 160 great photos, of meeting with Toronto Dylanists, in Toronto Wonderland, Niagara Falls region, and a few other places. I ran out of memory a few times, and each time I went back and removed a few redundant or bad photos, to make more space. After dropping Siamak at the airport, I was getting back home when in the subway, a bit bored, I was playing with the camera when I formatted the SD Card with all the photos inside!
I was sure that it just "quick format"ted it, can't empty 128MB in 2 seconds. My heart was in my mouth. I went straight to Future Shop and bought a USB SD Card reader, came home, copied the whole partition image. God, you mean I have to go back to 1995 and unformat/undelete the files, or worse, run Norton diskedit, or even worse, recover my photos by reading FAT32 chains manually?!?!?!
I made a guess that this dumb camera just writes the files sequentially all the time, no fill-in-the-gaps I mean. Well, thinking a bit more you see that you don't need to make any assumptions for that. The usage pattern has been all writes, with 5 batches of removes. So at most 10 images can be hurt. I proceeded and did that, I first copied an old photo taken by the same camera, and the typed these on command line:
# dd if=/dev/sdb of=sdcard
# head -c 100 pict0680.jpg > header
Python 2.3.3 (#1, May 7 2004, 10:31:40)
[GCC 3.3.3 20040412 (Red Hat Linux 3.3.3-7)] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> sdcard=file("sdcard", "rb").read()
>>> header=file("header", "rb").read()
>>> import string
>>> jpgs = string.split(sdcard, header)
>>> jpgs=[header+x for x in jpgs]
>>> for jpg in jpgs:
... c += 1
... f = open(str(c)+".jpg", "wb")
100.jpg 118.jpg 136.jpg 153.jpg 21.jpg 39.jpg 56.jpg 73.jpg 90.jpg
101.jpg 119.jpg 137.jpg 154.jpg 22.jpg 3.jpg 57.jpg 74.jpg 91.jpg
102.jpg 11.jpg 138.jpg 155.jpg 23.jpg 40.jpg 58.jpg 75.jpg 92.jpg
103.jpg 120.jpg 139.jpg 156.jpg 24.jpg 41.jpg 59.jpg 76.jpg 93.jpg
104.jpg 121.jpg 13.jpg 157.jpg 25.jpg 42.jpg 5.jpg 77.jpg 94.jpg
105.jpg 122.jpg 140.jpg 158.jpg 26.jpg 43.jpg 60.jpg 78.jpg 95.jpg
106.jpg 123.jpg 141.jpg 159.jpg 27.jpg 44.jpg 61.jpg 79.jpg 96.jpg
107.jpg 124.jpg 142.jpg 15.jpg 28.jpg 45.jpg 62.jpg 7.jpg 97.jpg
108.jpg 125.jpg 143.jpg 160.jpg 29.jpg 46.jpg 63.jpg 80.jpg 98.jpg
109.jpg 126.jpg 144.jpg 161.jpg 2.jpg 47.jpg 64.jpg 81.jpg 99.jpg
10.jpg 127.jpg 145.jpg 162.jpg 30.jpg 48.jpg 65.jpg 82.jpg 9.jpg
110.jpg 128.jpg 146.jpg 163.jpg 31.jpg 49.jpg 66.jpg 83.jpg header
111.jpg 129.jpg 147.jpg 164.jpg 32.jpg 4.jpg 67.jpg 84.jpg sdcard
112.jpg 12.jpg 148.jpg 165.jpg 33.jpg 50.jpg 68.jpg 85.jpg
113.jpg 130.jpg 149.jpg 16.jpg 34.jpg 51.jpg 69.jpg 86.jpg
114.jpg 131.jpg 14.jpg 17.jpg 35.jpg 52.jpg 6.jpg 87.jpg
115.jpg 132.jpg 150.jpg 18.jpg 36.jpg 53.jpg 70.jpg 88.jpg
116.jpg 133.jpg 151.jpg 19.jpg 37.jpg 54.jpg 71.jpg 89.jpg
117.jpg 134.jpg 152.jpg 20.jpg 38.jpg 55.jpg 72.jpg 8.jpg
Voila! And guess what? All photos are correct except for exactly 10! It really doesn't make sense to go about FAT32 hacking anymore. But I know where to find the missing bits...
Here is a proof of recovery:
A couple weeks ago, a dear friend was visiting me. He was good old Siamak Tazari (photo below), on his way from Germany to Vancouver for a year of exchange program in UBC, just stopped in Toronto for the week of August 9th to August 16th. Although I just now Siamak for five years now, he's been one of the most influential people on me who's shaped almost all my current interests, all in just two years, many of them none of us ever noticed before. Here is a short list for now:
- He brought me (among others) to Web Programming classes tought by his father. That was where I first heard about HTTP, Apache, etc, which is, well, among the top of my expertise for a few years now.
- Then I wrote my first CGI program with him. It was a silly simple Delphi program, doing the old trick. We were both nation team member candidates in Young Scholars Club for IOI'2000. We installed Apache on my machine in our lab, and wrote this little Delphi CGI program. When people visited our page (at that time people around us didn't really knew about internet addresses. So didn't note that it's not a page on internet, but a local machine at all), it showed them 5 playing cards, asking them to choose one and say it's name, then click next. After clicking next, the CGI application was fired listing the five cards, and I, sitting in the same lab hearing them, would select the chosen card. Here you go, we had quite a lot of fun with this silly program! It took other students a week or so to find out what the whole trick is...
- Siamak helped me to buy my Pentium III computer, which was awefully good, and after I installed Linux, he told me how to recompile kernel to enable sound. I never managed to make the sound working on that system, but the kernel compilation remained in my mind.
- After I got interested in Pink Floyd music by watching Pink Floyd The Wall movie, Siamak gave me a CD full of Pink Floyd MP3 albums. That made me a Pink Floydist.
- Later after he left Iran to Germany, he turned to Bob Dylan, and sent me a CD full of Bob Dylan MP3 albums. That made me a Dylanist that still I am. He's an awesome Dylanist himself. I learn a lot from him. Moreover, when I became interested in Joan Baez, he told me to find and listen Diamonds and Rust. He even found a Dylan concert ticket for my second concert in Toronto remotely from Germany!
Well, that's it! You read the rest...
So, in his trip to Toronto, we finally met after two years, had great fun together, and had some great Tequila. Siamak, I owe you so much. Thanks for your friendship.
Update: One more thing, people are typically amused by the fact that my hands have put marks on my laptop where they sit, two heart-shaped black parts on the gray body of the Vaio. No one else I knew seen with those on his laptop, until Siamak arrived, and he had the exactly same marks on his laptop too! Can you believe that?!
Bidi UI Project
After moving GNU FriBidi
and purchasing fribidi.org
domain for that, now I started a project called Bidi
, to document Bidirectional User Interfaces finally, on beloved freedesktop.org
again, and got bidi.info
In the early 2004 I started a debate on Persian Computing
list on how people are infringing copyright of Aryanpur Dictionary data by packaging it in dictionary applications for free download, or even maybe by providing online dictionary service based on this data which seems to be widely copied and assumed
to be in public domain
I couldn't stop any of them from doing so, and we even exchanged some bad words a couple times. But now things look a bit different: Yesterday Dr Manoochehr Aryanpur-Kashani, one of the authors of the dictionary and several other dictionaries, and was wondering how I got interested in the issue. To me it sounds like a great success, for at least we finally have an access to him. I'm going to ask him to:
- Give me permission to follow up the infringement issue. Then I will contact University of Columbia and ask them to remove the dictionary hosted there by Dr Pedram Safari,
- Ask him consider putting this widely pirated data in public-domain,
- Publish a GPLed Persian word list,
- Consider providing dictionary web service (of course I can arrange for all the technical part).
I will write down the whole story with links to the posts and everything later for the records.
If you still don't know what's new in the 1999 C standard, have a look at the link above. Some of these new additions are so tempting... But I can't make real use of them, otherwise I would start next library in C99.
I DID IT!
I finally inserted the Fedora Core 2 DVD and installed it! Nothing really broke. Hardly anything changed at all! Well, now at least I can do "yum update" again.
I found out that most of the brokenness in menus et al
comes from my dotfiles. So, in a first step, I removed all my GNOME CVS checkouts and cleaned up my ~/lib, ~/include, ..., set up a complete GNOME HEAD build in /opt using jhbuild
. Yum, jhbuild, and the crs tool that I wrote, all show that Python is the
tool for this kind of jobs. NO OTHER language is so charming to work with lists, graph, and config files! The build is just half way and I expect it to go for 10 or 15 more hours.
The build system is not ideal yet, but since I've got a small install of FC2, many build problems show up. Three of them so far.
So it remains to clean ~/.gconf, ~/.gnome-panel, ...
Also after cleaning up the old root partition, well, I will have a 10GB free partition! I will eventually move /opt to it since I expect to run out of space before the build finishes.
BUT I DID IT FINALLY!
[Yes, didn't start work on FriBidi
yet this week...]
26th Internationalization and Unicode Conference
The program for IUC'26
arrived today. I'm still waiting to be cleared for the visa I applied for to get to IUC'25
. By the way, the slides of my that I prepared for that talk are here
and the paper is here