Posts

Showing posts from April, 2013

Dependency walker

Dependency walker is a great program that tells you what dlls your windows program is using. So you can ship your program with only those dlls and not need to carry a number of unnecessary files.

SDM - SATA disk module

For last few days I have been working on a SDM based system. The goal was to setup a lightweight system with a SDM instead of a SATA hdd as main storage. The concern was that the SDM is supposed to have write failure protection. This will prevent data corruption in case of power failure. The SDM was an apacer module and was of 4GB capacity. As I had worked on such small scale systems the task of installation and configuration was handed to me. The installation was straight forward. We were going to start with a minimal CentOS Desktop and add extra packages as per need. So to safely test it I started with a 4GB virtual machine in VirtualBox. I installed CentOS in it and that took about 1.6GB of available space. Next I put a minimal QT and QWT library package plus our Client software on top of that. This consumed about 300 MB of more space. Finally I installed PostgreSQL v9.1 as required. This took another 180MB after creating the empty databases etc. Later I installed telnet, vsft...

Fixing Turbo C in windows 7

There's a FIXED version of tc floating around in the net and for general programs it works well. But one of my friends being an adventurous soul wanted to try some graphics functions and the program wouldn't run. The error was related to the path to the BGI files. The problem came to me and I remembered this being caused by the c:\Program Files location of turbo c folder. So I had him copy it to C drive and modify the path accordingly. With updated path the program stared working and a circle appeared on the screen. Made me recall my own college days.

GPS run/cycling trackers

I have wanted to track my exercise for a long of time. But I don't exercise that much - couple of long walks a week plus some aerobics. So I really was being lazy at it. But I've decided to up my efforts and so I was looking for an app that would help me keep track of my efforts and the amount of distance I passed on and the speeds etc. After going through the measly no of such apps on my WP Omnia, I stumbled across "run the map". And after using it for a few times I think it's a great app for tracking your exercise. The main interface is divided into 3 pages - first page shows Recorder i.e. speed, distance and elapsed time. This page also has start-stop button as well as exercise selector. Below these, we get current values for speed and altitude. Next page is maps which shows your real time path updated at regular intervals. The last page is mixed mode where you get to see both the map and recorder values. Also available are features to export GPX or KML fil...

Batchgeo.com

A nice website to let you put people on map.

Very interesting discussion

I was searching for a decent way to kill hung jobs and stumbled onto following discussion: Orig URL: http://superuser.com/questions/49024/kill-9-programs-but-they-still-hang-on It's very informative! --------------------------- A: I tried to kill all my background jobs submit earlier under KUbuntu by kill -9 $(jobs -p) Although this command immediately gave the message like [1] Killed myjob1 [2] Killed myjob2 I can still see their processes hanging in the output of top and the CPU and memory usages are not changed in the output of uptime and free. So I guess I must have not killed them properly. Can someone please explain what's happening to me and what shall I do? I found that in top, if type k and input the PID I can kill the processes one by one. SO is this different from the command kill? I also found somewhere online http://www.ruhr.de/home/smallo/award.html about not recommending kill -9 Useless Use of Kill -9 form letter (Quote abomina...
Image
One line of code made so much change! this->setPalette(QPalette(QColor(rand()%255,rand()%255,rand()%255)));

Image Processing

Image
If you are familiar with image processing textbooks and articles, you must have seen the following picture: Following is an extract from the comp.compression FAQ : For the curious: 'lena' or 'lenna' is a digitized Playboy centerfold, from November 1972. (Lenna is the spelling in Playboy, Lena is the Swedish spelling of the name.) Lena Soderberg (ne Sjooblom) was last reported living in her native Sweden, happily married with three kids and a job with the state liquor monopoly. In 1988, she was interviewed by some Swedish computer related publication, and she was pleasantly amused by what had happened to her picture. That was the first she knew of the use of that picture in the computer business.  A scan of the original Lenna from Playboy is available from: http://www.lenna.org The editorial in the January 1992 issue of Optical Engineering (v. 31 no. 1) details how Playboy has finally caught on to the fact that their copyright on Lena Sjooblom...

Practical C++ Error Handling in Hybrid Environments

Orig Article Link:   http://www.drdobbs.com/cpp/practical-c-error-handling-in-hybrid-env/197003350 Exception-safe code is notoriously difficult to get right in C++. Still, it is the recommended way to go, at least according to C++ gurus. And for a reason. If you write nontrivial programs or libraries in C++, you should probably study exception handling and use it where appropriate. In the real world, however, exception handling is not always possible, viable, or used by anyone. So what do you do if you need to integrate or interoperate with software that doesn't use exception handling? In this article, I discuss situations where exception handling is not used and why. I then demonstrate how to interface your exception-handling code to other software components that practice a different error-handling method. Error-Handling Strategies in C++ There are different ways to report and handle errors in C/C++. (You have to consider C because C++ is—more or less—a supe...