Archive for September, 2008

Bitx Progressing

September 28th, 2008 3 comments

The Bitx completed

My bitx project has been lying dormant for a couple of months now. I completed wiring about 2 months back. The transmitter was working properly. But the receiver was not receiving anything . When I tried to increase volume, it started howling. After initial testing, I became QRL with lot of other activities. This weekend I decided to look at bitx board again. I carefully rechecked all stages and found out that I had made 2 mistakes in wiring components , a 22 ohms resistor was in the place of 220 ohm and at another place I put a 1k instead of 100 ohm. After correcting the mistakes I fired up the receiver , I could hear some CW transmission around 14.01Mhz. When I increased the volume, the audio stage was howling. I decided to discard the audio stage and build a new one. I bought a small audio module form local market for Rs 25 and fixed it to the board. Now the audio is clean even when the volume is maximum. I am still not satisfied with the sensitivity of the receiver. I made the following measurements on various transistors today. The table of the voltages on transistors are given below. The transistors numbers are based on Bitx V3 diagram by OM vu2wmj Rahul.

BitX20 Voltage chart

Voltages on Receiver Chain  Supply voltage 12 V.  Transistor used 2N3904

Transistor Emitter Base Collector
Q1 1.64 2.38 8.22
Q2 1.8 2.5 8.14
Q3a 0 .6 4.46
Q3 4.04 4.76 10.6
Q4 0 .6 2.04

Voltages on Transmitter Chain, Supply Voltage 12V

Transistor Emitter Base Collector
Q10 1.72 2.33 7.7
Q11 1.5 2.1 7.3
Q12 1.31 1.95 6.2
Q13 1.41 1.96 6.4
Q14 2.2 2.9 9.5

I think I need to verify the voltages with some other builder.

Categories: Electronics, Ham Radio Tags:

Fork bomb

September 26th, 2008 3 comments

We run our college lab on LTSP built on Debian Etch. Today, one of our students inadvertently ran a fork bomb and the entire lab was stuck. We had to reboot the system. On examining the code , it was found that he put fork system call in an infinite loop.

A fork bomb is a process that ‘explodes’ by recursively spawning copies of itself. It will eventually eat up all your computing resources .

On Linux systems  you can set the maximum number of processes that a  user can run.

You can explore your current limits via the ulimit  command. This is what I got on my debian etch installation at home.

sunil@debian:~$ ulimit -a
core file size          (blocks, -c) 0
data seg size           (kbytes, -d) unlimited
max nice                        (-e) 0
file size               (blocks, -f) unlimited
pending signals                 (-i) 4031
max locked memory       (kbytes, -l) 32
max memory size         (kbytes, -m) unlimited
open files                      (-n) 1024
pipe size            (512 bytes, -p) 8
POSIX message queues     (bytes, -q) 819200
max rt priority                 (-r) 0
stack size              (kbytes, -s) 8192
cpu time               (seconds, -t) unlimited
max user processes              (-u)
virtual memory          (kbytes, -v) unlimited
file locks                      (-x) unlimited

On my ubuntu desktop I got this.

 sunil@Ubuntu-Hardy:~$ ulimit -a
core file size          (blocks, -c) 0
data seg size           (kbytes, -d) unlimited
scheduling priority             (-e) 0
file size               (blocks, -f) unlimited
pending signals                 (-i) 16312
max locked memory       (kbytes, -l) 32
max memory size         (kbytes, -m) unlimited
open files                      (-n) 1024
pipe size            (512 bytes, -p) 8
POSIX message queues     (bytes, -q) 819200
real-time priority              (-r) 0
stack size              (kbytes, -s) 8192
cpu time               (seconds, -t) unlimited
max user processes              (-u)
virtual memory          (kbytes, -v) unlimited
file locks                      (-x) unlimited

On debian the maximum user processes is 4031 and on ubuntu it is 16312.

ulimit settings can be controlled by /etc/security/limits.conf . The file is commented and self explanatory. Each line in the file is organized like this.

<domain> <type> <item> <value>


<domain> can be:
o a user name
o a group name, with @group syntax
o the wildcard *, for default entry
o the wildcard %, can be also used with %group syntax, for maxlogin limit

* <type> can have the two values:
o “soft” for enforcing the soft limits

o “hard” for enforcing hard limits
* <item > can be one of the following:
o core – limits the core file size (KB)
o data – max data size (KB)
o fsize – maximum filesize (KB)
o memlock – max locked-in-memory address space (KB)
o nofile – max number of open files
o rss – max resident set size (KB)
o stack – max stack size (KB)
o cpu – max CPU time (MIN)
o nproc – max number of processes
o as – address space limit
o maxlogins – max number of logins for this user
o maxsyslogins – max number of logins on the system
o priority – the priority to run user process with
o locks – max number of file locks the user can hold
o sigpending – max number of pending signals

o msgqueue – max memory used by POSIX message queues (bytes)

o nice – max nice priority allowed to raise to

o rtprio – max realtime priority
o chroot – change root to directory (Debian-specific)

Typical entries  in  /etc/security/limit.conf can be

*                      soft    core                  0
*                      hard    rss                   10000
@student        hard    nproc             20
@faculty         soft    nproc               20
#@faculty         hard    nproc           50

There are soft limits and hard limits. Soft limits are default values. However hard limits are  enforced via kernel. So a user can change his soft limit up to the hard limit   using the ulimit command. For details ,RTFM ulimit.

This wikipedia article is very informative and a must read for all sysadmins. There are lot of  example bombs you can try :D.

Categories: Gnu/Linux Tags:

Exploring Pardus Linux

September 12th, 2008 1 comment

Pardus Kurulan 2008 is a  cool Linux distribution from Turkey. It differs from conventional Linux distributions in several ways.  This was pointed out to me by Sarath. Last night I installed Pardus on a Virtual Box virtual machine to explore this distro. I will share some of the screen shots and observations that I made in the process.


The minimum hardware requirement  for installation  of pardus 2008

  • 256 MB memory (512 MB recommended)
  • 800 MHz Intel or AMD processor (1200 MHz recommended)
  • At least 4 GB of free hard disk space (10 GB recommended)

The opening screen for  installer is like any other distro. The default screen is is Turkish. Press F3 and select English.   Select boot from CD. The following screen will come up with a copyright notice.


Copyright Screen

Once you press  agree and then next, it proceeds to ask you the  time zone and default user name. I could not locate the Indian time zone  on the screen. See the screen shot below.


Time zone Selection

You can assign administrative privileges to user. To quote  the release notes, the privileges of all users may be arranged and the password inquiry behavior may easily be customized by using the advanced user authorization system of Pardus 2008. I am yet to try it out.


User name selection

Next, you can select the partition to which Pardus should be installed. The screen shot below shows the screen.


Partition Selection

The installation then proceeds smoothly. Finally you will be asked to install the boot loader. I selected master boot record ( I am on  a virtual machine). The default boot loader is grub. Then the machine rebooted . I  got the following screens .


Login Screen


Pardus running.

Exploring Pardus

The first thing I noticed about Pardus is the installer. The installer is named YALI ( Yet another Linux installer). YALI is smooth and intuitive. Secondly I was surprised to see how fast the Pardus booted up on my VirtualBox  virtual machine( Of course I have a Pentium 2 Quad  processor and plenty of memory). Upon  digging further , I found that all the startup scripts have been rewritten in python. All the conventional  startup code  have been removed and replaced with clean python code. No wonder the startup time is very low.  The startup script in Pardus is called mudur. If you are looking for further  info on this you can read this paper on mudur.    I am yet to learn the startup process fully.

Pardus uses a modified version of KDE 4 as the default desktop. It is called Kaptan . Another interesting feature is that the package management system is also re written. It is called pisi. Of course you can use pisi on command like like apt or via a graphical user interface.


PiSi (Packages installed Successfully)

The Pardus configuration utility is called TASMA.  It is very user friendly and I could configure all my devices quickly.



Pardus has several other features.Take a look at this page to find out .  This distro looks fresh and interesting. Hopefully we will  see some of these cool programs ported to other mainstream distros very soon.

Categories: Gnu/Linux Tags:

Learning with NPTEL

September 9th, 2008 2 comments

The national program of technology enhanced learning (NPTEL) is  an initiative of the Government of India to provide quality educational material to engineering students . The site has several video tutorials for various engineering subjects.  However, the site is not very popular among Indian students. I have been trying to promote it among my students and colleagues for quite some time as  a source of quality material. But, the response is not very encouraging.

The videos are hosted on youtube.   The complete playlist is here.  There are several course  suitable for electronics /computer science  students. Some of the so called “difficult” subjects are lucidly explained by senior professors.  I have recomended  the digital signal processing course by Prof. S C Dutta Roy as supplimentary  material to my students.

If you want to view the courses offline, you can download it form youtube using youtube-dl. The youtube  videos are in flash (.flv) format. Softwares such as ffpeg can be used to convert them to your favorite format.

Categories: Engineering Education, Finance Tags:

Storytelling Alice

September 8th, 2008 3 comments

My kids are having  holidays for next 10 days in connection with Onam.   During holidays,  I let them play Gcompris if i am not using the computer.  Today they wanted to play. I instead of letting them play Gcompris , I showed them  StoryTellng Alice They were hooked to it within half an hour. By  evening they showed me a small animation  they built. I am pretty amazed at the pace at which my  daughters ( aged 8 and 7) learn.

Story telling Alice is a spin of from Alice , a great programming environment for  teaching programming to kids. Alice is the brain child of Randy  Pausch.

Categories: Engineering Education Tags: