Recursive Complexity

Thoughts and musings of a programmer and wanna be entrepreneur

Archive for July 2010

What is BIOS ?

with one comment

What is a computer BIOS ? This was the question I had no answer to before I started working on it. All my earlier attempts to know what it is were fruitless as I had no understanding of the low-level features of a computer. Not the case now as I at least have a basic understanding of it and as I am working on optional-ROM, I have a hands on knowledge of what it is. I will talk about the system BIOS and give a little introduction to device optional-ROM (also called option-ROM).

BIOS stands for Basic Input Output System. Whenever you power on the system (or reboot), whatever output you see till the operating system starts executing (Windows 95, XP, Vista, 7 screen appears or Linux starts printing a lot of [ok]s) is by BIOS. This contains information about the system and the devices found on the system (size of RAM, USB devices found, CD-ROM drive type, Floppy-disk controller etc.). BIOS is a small program stored in flash memory on the motherboard (see image below). The computer vendor puts this small piece of code in the flash memory during device manufacture. When the system powers up, the processor doesn’t know what to do as the RAM is empty, but it does know where the BIOS is (This is hardwired into the motherboard logic) and starts executing it. The BIOS then starts initializing the system components one by one. This is what causes the output to be seen mentioned earlier. As it encounters devices and peripherals, it initializes them, gathers information about them and displays them on the screen.

BIOS flash memory

BIOS flash memory

You can configure the system hardware by going into the BIOS and configuring the devices present on the system. When the system is powered on, there is generally a message at the bottom of the screen or on the top right corner to press a key (F2 or DEL) to enter setup which is nothing but the system BIOS. When you press this key, the system BIOS displays various information about the devices and peripherals present which can be changed as required. Once this is done, there is generally a key to save the information and reboot, during which the necessary changes would have taken effect. See image below.

BIOS config utility

BIOS config utility

There are other advanced things that can happen during the execution of the BIOS. For this we need to know something about device option-ROM. An option-ROM is a piece of code that  resides in memory on the device and provides an interface to initialize, configure and manage the device.

The system BIOS while scanning for devices present on the system encounters a device which has option-ROM loaded on to it (This can be done in various ways and is widely known as flashing the code onto the device), it loads the option-ROM into main memory and gives control to it which can then be used to configure and setup the device as needed (The interface provided depends on the hardware vendor). The execution of the option-ROM depends on whether such an execution is allowed or required and is controlled by some parameters which can be configured in the BIOS. The option-ROM after doing the necessary tasks reboots the system if there is any change in the settings or hands back the control to the BIOS which continues it execution and finally the OS takes over.

An example use of this kind of setup is in storage area networks where ethernet adapters are flashed with a particular type of option-ROM (iSCSI, FCoE or PXE ) depending on the requirement. When the system starts up, the option-ROM is executed and the user can configure and initialize the adapter as required.

After the BIOS has finished initializing all the necessary components of the system, it loads another small program into main memory called the boot loader, common examples are GRUB, LILO etc. It hands over the control to the boot loader which then loads the OS into main memory and the OS takes control from then onwards.

The BIOS also provides low-level access to system hardware which is used by operating systems to configure and manage the device. Below are some useful links which explain BIOS in more detail.

Will try to follow this up with more about BIOS or option-ROMs. Keep reading.


Written by Vivek S

July 27, 2010 at 4:42 pm

Posted in Tech

Tagged with

Need to earn more money

with 4 comments

I want to earn more money than I am currently doing. I think most of us have gone through this feeling. Whats the solution to this problem ? I have come up with some answers.

They are…

  • Start freelancing by doing small projects in your free time.
  • Invest in the stock market.
  • Change your job.
  • Ask for a pay hike.

The above solutions look good, but don’t know why I havn’t been able to do execute them. The reasons for each option are..

1st option:

This requires some work to be done upfront like creating a profile, marketing yourself as a freelancer, knowing what you are good at and pitching yourself in that area to potential customers etc etc. I havn’t been able to do any of these till now. I want to do freelancing in creating websites for individuals and small organizations. As I am a C and C++ programmer, I have little knowledge about creating websites and the technologies used there. I have to get my hands dirty first by creating some websites and get a hang of it before taking up some projects. The biggest concern though is whether I will be able get the time to do these projects if i do get some ?? I am a geek and technology excites me…hence learning is not a problem…but its the second one….the question of time (and also dedication and commitment) for the projects that worries me. Hence I have not been able to do any progress in this area.

2nd option:

I have invested a good amount of money in the stock market and have got some good returns too. But stock market investment is a long term option and you won’t get that additional money every month or even after an year sometimes. Also you cannot utilize the money that you have invested as you don’t have it. You cannot get out of stocks that are in RED as you don’t want to incur any loss and your money is locked in that particular stock till it is making some profit. Therefore I can say that the extra money that you want (preferably) every month is not what stock market investment gives you (unless you are a stock broker yourself)

3rd option:

This option can really give you that extra money if you find the right job. But there are concerns here too. I really don’t know whether I will get the same kind of work that I am doing currently. I love what I am doing right now. If I don’t get the right work to do, then that extra money will be of no use as I won’t be motivated to do anything with that money as the primary thing that I am doing is not exciting. I am a geek as i said above and want something that acts as food for my brain, otherwise I am least interested in doing such things. Hence I have not been able to change my job.

4th option:

He hee… 🙂 This is a tricky area. I got a very good hike last year and theres another one scheduled this september. I can negotiate the percentage, but I don’t think much can be done about it as its the management which decides the percentage and whether I have been productive or not 😛 . I am optimistic though as the initial signs are that, I will be getting a good percentage this time too. But will this hike plug the hole that I am taking about ? What if I don’t get a good hike…I need something other than my work to fill this need and the hike is going to happen sometime in the future…what about till then ?

This is where I am right now (In limbo … watch Inception) wanting more money and doing nothing about it or in some cases things are not working out the way i expect them to be. Is there a fundamental flaw in my need ? Is my need flawed ? Can’t I have both money and good work together…do i need to do something else ? Am I being greedy here ? Will ponder on these things and write about it when i have a breakthrough.

Written by Vivek S

July 25, 2010 at 10:00 am

Posted in My different states

Tagged with

TED Blog

The TED Blog shares interesting news about TED, TED Talks video, the TED Prize and more.