IT full

Document Sample
IT full Powered By Docstoc
					                                                   BCA I – Fundamentals Of I.T & O.S


                                        Unit-1

                               Computer Basics

1.1 Computer:
Computer is an electronic device, which is used for manipulating data according to a list
of instructions. A list of computer instructions designed to perform some task is known as
a program. It is a complete collection of hardware, software and peripherals designed to
work together. Computers take numerous physical forms. Early electronic computers
were the size of a large room, consuming as much power as several hundred modern
personal computers. Today, computers can be made small enough to fit into a wrist watch
and powered from a watch battery. the most common form of computer in use today is by
far the embedded computer. Embedded computers are mostly small and simple and they
are often used to control other devices. They are used to control machines from fighter
aircraft to industrial robots, digital cameras, and even children’s toys.
The defining feature of modern computers which distinguishes them from all other
machines is that they can be programmed. That is to say that a list of instructions can be
given to the computer and it will store them and carry them out at some time in the
future. Instruction is a command given to a computer to perform specified task. Some
computer instructions are simple: add one number to another, move some data from one
location to another, send a message to some external device, etc. These instructions are
read from the computer's memory and are generally executed in the order they were
given.

Computer works mostly on data and information. Data is a collection of raw facts. Data
may be valuable or non-valuable. When these data has been converted and processed, so
that it gets definite form and shape which becomes useful and act as a base for making
any decision. Then it becomes an information, in simple we can say that information is
the processed data. The two principal characteristics of a computer are:

      It responds to a specific set of instructions in a well-defined manner.
      It can execute a prerecorded list of instructions.

Modern computers are electronic and digital. The actual machinery i.e. wires,
transistors, and circuit is called hardware. The instructions and data are called
software. All general-purpose computers require the following hardware
components as shown in the diag:




                                             1      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S




        memory: Enables a computer to store, at least temporarily, data and
       programs.
        mass storage device : Allows a computer to permanently retain large
       amounts of data. Common mass storage devices include disk drives and
       tape drives.
        input device : Usually a keyboard and mouse, the input device is the
       way through which data and instructions enter a computer.
        output device : A display screen, printer, or other device that lets you
       see what the computer has accomplished.
        central processing unit (CPU): The heart of the computer, this is the
       component that actually executes instructions.

Computer System mainly consists of two things:

Hardware: The term hardware covers all of those parts of a computer that are tangible
objects. Circuits, displays, power supplies, cables, keyboards, printers and mice are all
hardware.

Software:     Software refers to parts of the computer that have no material form;
programs, data, protocols, etc are all software. When software is stored in hardware that
cannot easily be modified (such as BIOS ROM in an IBM PC compatible), it is
sometimes termed firmware to indicate that it falls into an area of uncertainty between
hardware and software.




                                           2      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S


1.2     Characteristics Of Computer
Speed: The smallest unit of time that we know is second, But the measurement of
operations in computers are in microsecond, nanosecond and pico second. The speed of
computer is closely related to the amount of data it process. The term volume and
frequency are often used to describe the amount of data. Volume represent the overall
quantity of the data to be processed. Frequency specifies how often a specific data item is
used in processing.

Accuracy:    Human Beings make certain mistakes while doing certain computation.
But the computer system computes the data accurately and quickly.

Reliability: Computer systems are widely accepted because of their exceptional
reliability. Unlike, most humans, they are capable of doing the work under the most
adverse condition without showing any sign of fatique. Computer provides the accurate
result under all the operating conditions.

Storage Capability: Computer system has a storage area which is known as memory to
hold a large amount of data. The installation of computer has meant economic survival
for many companies.

Versatility: Computers are versatile. They can do a variety of jobs depending on the
instruction fed to them and their hardware characteristics. Modern computers are capable
of handling not only complex arithmetic problems but also a lots of job unrelated to
numbers, like railways and airline ticket reservation. Computers can be attached with
several kinds of peripheral devices to accomplish variety of jobs.

Even computer system has got thousand of advantages but there are some disadvantages
also that it does not take any decision o their own because it is working on the basis of
what are feed in it. It’s Iq is completely zero.

Beside many advantages the computer has also some of the disadvantages they are:

      Computer does no work by itself. It works on the basis of the list of instruction
       given to it.
      Computer does not have any I.Q it works on the basis of what has been instructed.
      Computer does not take decision of its own.
      Computer does not learn by experience.

1.3     History Of Computer:
The history of computers dates back to 500 BC, when the Chinese invented a calculating
machine called Abacus. Some of these types of inventions discussed below are:
   • Abacus
   • Jacquard Loom


                                            3      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

    •   Charles Babbage’s Difference Engine
    •   Hollerith Census Tabulator
    •   Aiken & Mark1
    •   Von Neumann

A. Abacus
An abacus is a calculation tool, often constructed as a wooden frame with beads sliding
on wires. It was in use centuries before the adoption of the written Hindu-Arabic numeral
system and is still widely used by merchants and clerks in the People's Republic of
China, Japan, Africa, and elsewhere.

The Chinese abacus is typically around 20 cm (8 inches) tall and it comes in various
widths depending on the application. It usually has more than seven rods. There are two
beads on each rod in the upper deck and five beads each in the bottom for both decimal
and hexadecimal computation. The beads are usually rounded and made of a hard wood.
The beads are counted by moving them up or down towards the beam. The abacus can be
reset to the starting position instantly by a quick jerk along the horizontal axis to spin all
the beads away from the horizontal beam at the center.

Chinese abaci can be used for functions other than counting. Unlike the simple counting
board used in elementary schools, very efficient suanpan techniques have been
developed to do multiplication, division, addition, subtraction, square root and cube root
operations at high speed.

Bead arithmetic is the calculating technique used with various types of abaci, in
particular the Chinese abacus. The similarity of the Roman abacus to the Chinese one
suggests that one could have inspired the other, as there is some evidence of a trade
relationship between the Roman Empire and China. However, no direct connection can
be demonstrated, and the similarity of the abaci may be coincidental, both ultimately
arising from counting with five fingers per hand. Where the Roman model (like most
modern Japanese) has 4 plus 1 bead per decimal place, the standard Chinese abacus has 5
plus 2, allowing less challenging arithmetic algorithms, and also allowing use with a
hexadecimal numeral system. Instead of running on wires as in the Chinese and Japanese
models, the beads of Roman model runs in groves, presumably making arithmetic
calculations much slower. Possibly the Roman abacus was used primarily for simple
counting. In a contest between the Chinese abacus and the electric calculator on
November 12, 1946, the abacus won 4 to 1.

.




                                              4      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S




2. Jacquard’s Loom

The Jacquard loom is a mechanical loom, invented by Joseph Marie Jacquard in 1801,
which utilized holes punched in pasteboard, each row of which corresponded to one row
of the design. Multiple rows of holes were punched on each card and the many cards that
comprised the entire design of the textile were strung together in order.


Each hole in the card corresponds to a "Bolus" hook, which can either be up or down.
The hook raises or lowers the harness which carries and guides the warp thread so that
the weft will either lie above or below it. The sequence of raised and lowered threads is
what creates the pattern. Each hook can be connected via the harness to a number of
threads, allowing more than one repeat of a pattern. A loom with a 400 hook head might
have four threads connected to each hook, resulting in a fabric that is 1600 warp ends
wide with four repeats of the weave going across.




                                           5      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S



Charles Babbage Difference Engine
The first device that might be considered to be a computer in the modern sense of the
word was conceived in 1822 by the eccentric British mathematician and inventor Charles
Babbage.

Babbage's engines were among the first mechanical computers. His engines were not
actually completed, largely because of funding problems and personality issues. Babbage
realized that a machine could do the work better and more reliably than a human being.
Babbage directed the building of some steam-powered machines that more or less did
their job, suggesting calculations could be mechanized to an extent.

The data and program memory were separated, operation was instruction based, the
control unit could make conditional jumps and the machine had a separate I/O unit.


In Babbage’s time numerical tables were calculated by humans called ‘computers’. At
Cambridge he saw the high error rate of the people computing the tables and thus started
his life’s work in trying to calculate the tables mechanically, removing all human error.
He began in 1822 with what he called the difference engine, made to compute values of
polynomial functions.

Soon after the attempt at making the difference engine crumbled, Babbage started
designing a different, more complex machine called the Analytical Engine. The engine is
not a single physical machine but a succession of designs that he tinkered with until his
death in 1871. The main difference between the two engines is that the Analytical Engine
could be programmed using punch cards, an idea unheard of in his time.


Hollerith Census Tabulator

The US government began to encounter certain problem in data processing. It took seven
years to compile the statistics from the 1880 census and it became apparent that it would
be time to begin a new census before the analysis one was completed. Hollerith designed
a device called the tabulating machine, which used machine readable punched cards. This
card has round holes and forty five columns. His machine reduces the tabulating time to
one-eighth the time required by the old methods.

Aiken & Mark1
The IBM Automatic Sequence Controlled Calculator (ASCC), called the Mark I by
Harvard University[1], was the first large-scale automatic digital computer in the USA. It
is considered by some to be the first universal calculator.




                                            6      Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S

The electromechanical ASCC was devised by Howard H. Aiken, created at IBM, shipped
to Harvard in February 1944, and formally delivered there on August 7, 1944. The main
advantage of the Mark I was that it was fully automatic—it didn't need any human
intervention once it started. It was the first fully automatic computer to be completed. It
was also very reliable, much more so than early electronic computers. It is considered to
be "the beginning of the era of the modern computer"

The building elements of the ASCC were switches, relays, rotating shafts, and clutches. It
was built using 765,000 components and hundreds of miles of wire, amounting to a size
of 51 feet (16 m) in length, eight feet (2.4 m) in height, and two feet deep. It had a weight
of about 10,000 pounds (4500 kg). The basic calculating units had to be synchronized
mechanically, so they were run by a 50 foot (15 m) shaft driven by a five-horsepower (4
kW) electric motor.

The Mark I could store 72 numbers, each 23 decimal digits long. It could do three
additions or subtractions in a second. A multiplication took six seconds, a division took
15.3 seconds, and a logarithm or a trigonometric function took over one minute.

The Mark I read its instructions from a 24 channel punched paper tape and executed the
current instruction and then read in the next one. It had no conditional branch instruction.
This meant that complex programs had to be physically long. A loop was accomplished
by joining the end of the paper tape containing the program back to the beginning of the
tape.

1.4 Von Neuumann

The von Neumann architecture is a computer design model that uses a processing unit
and a single separate storage structure to hold both instructions and data.

The separation between the CPU and memory leads to the von Neumann bottleneck, the
limited throughput (data transfer rate) between the CPU and memory compared to the
amount of memory. In modern machines, throughput is much smaller than the rate at
which the CPU can work. This seriously limits the effective processing speed when the
CPU is required to perform minimal processing on large amounts of data. The CPU is
continuously forced to wait for vital data to be transferred to or from memory. As CPU
speed and memory size have increased much faster than the throughput between them,
the bottleneck has become more of a problem.




                                             7       Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S




1.5 Technical Evolution Of Computer:
The term generation is used to characterise the major developments in the computer
industry. There are five generations of computers and the term generation means we are
able to distinguish between different hardware technologies.

      First Generation        1946-1956
      Second Generation       1956-1964
      Third Generation        1964-1971
      Fourth Generation       1971-Present
      Fifth Generation        Present-Future

1.5.1 First Genration Computers
The era of the first generation computers began in 1946 because that was the year when
people consciously set out to build stored program computers. In 1946 there was no 'best'
way of storing instructions and data in a computer memory. There were four competing
technologies for providing computer memory: electrostatic storage tubes, acoustic delay
lines (mercury or nickel), magnetic drums (and disks), and magnetic core storage.

Electrostatic Storage tubes: A high-speed electrostatic store was the heart of several
early computers. The great advantage of this type of "memory" is that, by suitably
controlling the deflector plates of the cathode ray tube, it is possible to redirect the beam
almost instantaneously to any part of the screen

Acoustic delay lines: It is based on the principle that electricity travels at the speed of
light while mechanical vibrations travel at about the speed of sound. So data can be
stored as a string of mechanical pulses circulating in a loop, through a delay line with its


                                             8       Rajesh Deshmukh – Disha College
                                                      BCA I – Fundamentals Of I.T & O.S

output connected electrically back to its input. The sequence of bits flowing through the
delay line is just a continuously repeating stream of pulses and spaces, so a separate
source of regular clock pulses is needed to determine the boundaries between words in
the stream and to regulate the use of the stream. Delay lines have some obvious
drawbacks. One is that the match between their length and the speed of the pulses is
critical, yet both are dependent on temperature. Another is a programming consideration.
The data is available only at the instant it leaves the delay line. If it is not used then, it is
not available again until all the other pulses have made their way through the line.

       A mercury delay line is a tube filled with mercury, with a piezo-electric crystal
        at each end. Piezo-electric crystals, such as quartz, have the special property that
        they expand or contract when the electrical voltage across the crystal faces is
        changed. Conversley, they generate a change in electrical voltage when they are
        deformed. So when a series of electrical pulses representing binary data is applied
        to the transmitting crystal at one end of the mercury tube, it is transformed into
        corresponding mechanical pressure waves. The waves travel through the mercury
        until they hit the receiving crystal at the far end of the tube, where the crystal
        transforms the mechanical vibrations back into the original electrical pulses.
        Mercury delay lines had been developed for data storage in radar applications.
       Nickel delay lines take the form of a nickel wire. Pulses of current representing
        bits of data are passed through a coil surrounding one end of the wire. A receiving
        coil at the other end of the wire is used to convert these pressure waves back into
        electrical pulses.

Magnetic Drum: The magnetic drum is a more familiar technology, comparable with
modern magnetic discs. It consisted of a non-magnetic cylinder coated with a magnetic
material, and an array of read/write heads to provide a set of parallel tracks of data round
the circumference of the cylinder as it rotated. Drums had the same program optimization
problem as delay lines.

Magnetic Core Memory: The most important contribution made by the
MIT(Massachusetts Institute of Technology) group was the development of the magnetic
core memory, which they later installed in Whirlwind. The MIT group made their core
memory designs available to the computer industry .




                                               9       Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S




Some computers of these generations are given below:

ENIAC: The first generation of computers is said by some to have started in 1946 with
ENIAC, the first 'computer' to use electronic valves i.e. vacuum tubes. It is developed at
the university of Pennsylvania in U.S.A by the team of Eckert and Mauchly. The full
form of ENIAC is Electronic Numerical Integrator and Calculator. It has a very small
memory and mostly used for calculating the trajectory of missiles.

EDVAC: The full form of EDVAC is Electronic discrete variable Automatic Computer.
In this machine instruction of the program are stored with the data internally. By the help
of this the accessing of computer becomes faster.

EDSAC:       In May 1949 there is a introduction of EDSAC, the first stored program
computer. EDSAC stands for Electronic Delay Storage Automatic Computer. It makes
use of mercury delay lines for storage of data.

UNIVAC:       The first commercial production of stored electronic computer was
UNIVAC. UNIVAC stands for Universal Automatic Computer. Univac division of
Remington Rand develops it.



                                            10     Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S

Characteristics of First Generation Computers

       Used vaccum tubes
       Not reliable
       Big and clumsy computers
       Electric consumption is very high
       This type of computers generate too much heat, therefore air conditioners are
        required.
       Batch processing
       Slow Input/Output operations.

1.5.2    Second Generation Computers

The invention of Transistors marked the start of the second generation. These transistors
took place of the vacuum tubes used in the first generation computers. First large-scale
machines were made using these technologies to meet the requirements of atomic energy
laboratories. One of the other benefits to the programming group was that the second
generation replaced Machine language with the assembly language. Even though
complex in itself Assembly language was much easier than the binary code.

Second generation computers also started showing the characteristics of modern day
computers with utilities such as printers, disk storage and operating systems. Much
financial information was processed using these computers.

In Second Generation computers, the instructions could be stored inside the computer's
memory. High-level languages such as COBOL (Common Business-Oriented Language)
and FORTRAN (Formula Translator) were used.

Characteristics of Second Generation Computers

       Transistor takes place of vaccum tubes.
       Faster than first generation.
       Assembly language is used instead of machine language.
       Generate less heat
       Smaller in size
       Magnetic tapes and disks are used.

1.5.3 Third Generation Computers
Although transistors were great deal of improvement over the vacuum tubes, they
generated heat and damaged the sensitive areas of the computer. In third generation of
computers, Integrated Circuit replaces the transistors. The Integrated Circuit(IC) was
invented in 1958 by Jack Kilby. It combined electronic components onto a small silicon
disc, made from quartz. More advancement made possible the fitings of even more
components on a small chip or a semi conductor. Also in third generation computers, the


                                           11     Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S

operating systems allowed the machines to run many different applications. These
applications were monitored and coordinated by the computer's memory.

From small-scale integrated circuits (SSI) , which had about 10 transistors per chip,
technology developed to medium scale integrated circuit with 100 transistors per chip.
Magnetic disk technology also improved and it become feasible to have drive having
capacity up to 100 MBs.

Characteristics of Third Generation Computers

       Transistors is replaced integrated circuits
       Increases speed as well as reliability.
       Uses multiprogramming operating system .
       Lower power consumption
       Magnetic disk can be used as a secondary storage.

1.5.4 Fourth Generation Computers
Fourth Generation computers are the modern day computers. The Size started to go down
with the improvement in the integrated circuits. Very Large Scale (VLSI) and Ultra Large
scale (ULSI) ensured that millions of components could be fit into a small chip. It
reduced the size and price of the computers at the same time increasing power, efficiency
and reliability. "The Intel 4004 chip, developed in 1971, took the integrated circuit one
step further by locating all the components of a computer i.e. central processing unit,
memory, and input and output controls on a minuscule chip."

Due to the reduction of cost and the availability of the computers power at a small place
allowed everyday user to benefit. In 1981, IBM introduced personal computers for home
and office use. Computer size kept getting reduced during the years. It went down from
Desktop to laptops to Palmtops. Machintosh introduced Graphic User Interface in which
the users didn’t' have to type instructions but could use Mouse for the purpose. The
continued improvement allowed the networking of computers for the sharing of data.
Local Area Networks (LAN) and Wide Area Network (WAN), were potential benefits.

Characteristics of Fourth Generation Computers

       Very large scale and ultra large scale integrated circuits has been developed.
       Computers now becomes portable.
       Semiconductor can be used as primary storage.
       Database Management system can be used
       Distributed data processing.

1.5.5     Fifth Generation Computers




                                             12     Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

Fifth generations computers are only in the minds of advance research scientists and
being tested out in the laboratories. These computers will be under Artificial Intelligence
(AI), They will be able to take commands in a audio visual way and carry out
instructions. These computers will perform many of the operations, which require low
human intelligence.

Parallel Processing is coming and showing the possibility that the power of many CPU's
can be used side by side, and computers will be more powerful than those under central
processing. Advances in Super Conductor technology will greatly improve the speed of
information traffic. Future looks bright for the computers.

1.6 Types Of Computers
The computers can be broadly classified into three types

   1. Analog Computers.
   2. Digital Computers.
   3. Hybrid Computers.

1.6.1 Analog Computers
An analog computer is a form of computer that uses electrical or mechanical phenomena
to model the problem being solved. Modeling a real physical system in a computer is
called simulation. In this computations are carried out with physical quantities such as
voltage, length , temperature etc. The devices that measure such quantities are voltmeter
and ammeter.

Computations are often performed, in analog computers, by using properties of electrical
resistance, voltages and so on. For example, a simple two variable adder can be created
by two current sources in parallel. The first value is set by adjusting the first current
source (to say x milliamperes), and the second value is set by adjusting the second current
source (say y milliamperes). The use of electrical properties in analog computers means
that calculations are normally performed in real time. The core mathematical operations
used in an electric analog computer are:

      summation
      inversion
      exponentiation
      logarithm
      integration with respect to time
      differentiation with respect to time
      multiplication and division

Analog computers are limited by real, non-ideal effects. An analog signal is composed of
four basic components: DC and AC magnitudes, frequency, and phase. The real limits of
range on these characteristics limit analog computers.


                                              13   Rajesh Deshmukh – Disha College
                                                 BCA I – Fundamentals Of I.T & O.S


1.6.2 Digital Computers

Computers which are used today is digital computers. They work on binary digits, incase
of some alphabetic information, the information must be coded in the form of by binary
digit. Digital computers can be classified into two types:

   1. Purpose wise: Purpose wise digital computers can be classified into two
      categories.First is, special purpose computer which is designed to perform some
      specific task.Second is, General purpose computer, whichis used to develop for
      work on different types of program.
   2. Size And Performance wise: These digital computers can be classified as follow:

           Personal Computer : A small, single-user computer based on a
           microprocessor. In addition to the microprocessor, a personal
           computer has a keyboard for entering data, a monitor for displaying
           information, and a storage device for saving data. The most common
           personal computers are desktop machines. The machines made by
           IBM are called IBM PCs. Other manufacturers use IBM’s
           specification and design their own PC are known as IBM compatible
           PC.
          Workstation : A powerful, single-user computer. A workstation is like
           a personal computer, but it has a more powerful microprocessor and a
           higher-quality monitor. They are single user computers having a lot of
           features of personal computer. Their processing speed is like mini
           computers. This powerful machine is greatly used by the scientist,
           engineers and other professionals. They are very expensive.
          Mini Computer : These are medium sized computers. They possess
           more work efficiency in comparison with micro computers. Mini
           computers are more expensive than a micro computers and one cannot
           think of purchasing a mini computer for personal use. These
           computers are generally useful for small & medium sized company.
           More than one person can use this computer at a time. Mini computer
           possess multiple CPUs. They have bigger memory and higher speed
           than micro computer but less than that of main frame. They are
           cheaper than mainframe. A multi-user computer capable of supporting
           from 10 to hundreds of users simultaneously. Medium sized company
           can be used for following purpose:

             1.   Employees Payroll
             2.   Maintenance of books of accounts.
             3.   Cost Analysis.
             4.   Sales Supervision.



                                          14     Rajesh Deshmukh – Disha College
                                          BCA I – Fundamentals Of I.T & O.S


  Mainframe : A powerful multi-user computer capable of supporting
   many hundreds or thousands of users simultaneously. These are large
   computer with bigger storage capacity. These can store huge data
   bases and can also process the data wit more speed. Due to there speed
   in processing huge data bases, they are being used by big companies,
   banks etc as a centralized computer system. It can continuously work
   round the clock and hundreds of users can work on them
   simultaneously. Mainframe can easily attached to any network and
   even to microcomputer. These computers are used for following
   purpose.

 To maintain customer details
    1. To maintain payment details
    2. To process bills
    3. To process notices.

  Super Computer : An extremely fast computer that can perform
 hundreds of millions of instructions per second. These computers with
 biggest capacity and higher working speed among all the catgories of
 computers. It has multiple CPU arranged and working parallel to each
 other. In a super computer, a CPU consist of many ALU and each ALU is
 assigned for specific process, working parallel. These computers are used
 in the following fields:

     1. In modeling nuclear fission
     2. In weather forecasting
     3. In space research and space exploration.

      Laptop: A laptop computer or simply laptop is a small mobile personal
computer, which usually weights 4-12 pounds (2-6 kilograms), depending on size,
materials and other factors.

Laptops usually run on a single battery or from an external AC/DC adapter which
can charge the battery while also supplying power to the computer itself.

Distributed Computer System: A configuration in which several computers are
interconnected by a communication network is called distributed computer
system. A common use of distributed computer system is called client server
computing. The PC which is requesting for the srevices is called client and the
computer providing the services is called server.

                                    Sometime there are problems requirng either
large storage or high speed processing which cannot be solved using a single
computer in a network. In such cases it may be possible to get a set of computers


                                   15      Rajesh Deshmukh – Disha College
                                               BCA I – Fundamentals Of I.T & O.S

     connected to the network to cooperate and solve the problem. In distributed
     computer system it often happens that many computers are not fully utilized. In
     such cases a user requiring more CPU resources than what he as in his computer
     can steal CPU cycles from idle processor to do his job. The communication
     network connecting te computers in a distributed system is normally slow and
     allows only one message to be communicated between two computers at a time.
     This type of network is called LAN(Local Area Network).

     Parallel Computers:      A set of computers connected together by a high speed
     communication network and programmed in sucha way that they can cooperate to
     solve a single large problem is called a parallel computer. There are two major
     types of parallel computers. One of them is called a shared parallel computer. In
     this case a number of processing elements are connected to a common main
     memory by a communication network. A program for this computer is written in
     such a way that multiple processsor can work independently and cooperate to
     solve problem. The processes are allocated to different processors and they read
     and modify the data accessible to all of them in memory.



                          Shared Memory




                     Communication Network


    CPU                 CPU                                         CPU



     The other type of parallel computer is called a distributed memory computer. In
     this type a number of processors, each with its own memory are interconnected by
     a communication network. A program is divided into many parts and each
     computer work independently. Whenever processo need to exchange data to
     continue with computation they do so by sending messages across the
     network.Such computers are called message passing multicomputers. A popular
     interconnection network is called a hypercube.

1.6.3 Hybrid Computers


                                        16      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

Hybrid computers are made by combining features of analog computers and digital
computers. In general, analog computers are extraordinarily fast, since they can solve
most complex equations at the rate at which a signal traverses the circuit, which is
generally an appreciable fraction of the speed of light. Digital computers can be built to
take the solution of equations to almost unlimited precision, but quite slowly compared to
analog computers. Hybrid computers can be used to obtain a very good but relatively
imprecise 'seed' value, using an analog computer front-end, which is then fed into a
digital computer iterative process to achieve the final desired degree of precision. Hybrid
computers utilizes the best qualities of digital and analog computer.



1.7 Block diagram of Computers looks like the one below /
computer Organisation
                                          CPU

                                    Memory Unit



                                                                        Output Unit
Input Unit                           Control Unit



                                          ALU



A. Central Processing Unit
A central processing unit (CPU), or sometimes simply called processor, is the component
in a digital computer that interprets instructions and processes data contained in computer
programs. CPUs provide the fundamental digital computer trait of programmability, and
are one of the necessary components found in computers of any era, along with primary
storage and input/output facilities. A CPU that is manufactured using integrated circuits
is known as a microprocessor. A typical central processor unit (CPU) consists of the
following interconnected functional units:

      Registers
      Arithmetic/Logic Unit (ALU)
      Control Unit


                                            17     Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S


B. Registers:
Register consist of flip flops. These flip flops are connected in parallel. A CPU contains a
number of registers to store data temporarily during the execution of a program. The no
of register is differ from processor to processor. The advantages of storing the data in
register are that it can be retrieved faster than memory because the number of register in
the memory is very less. The drawback of using the register is that it is very expensive.
Register are classified as follows:

   1. Accumulator: It is a register, which holds one of the operand prior to the
      execution of instruction and receives the result of most of the arithmetic and logic
      operations. It is one of the frequently used registers.
   2. General Purpose Register: These register stores data and intermediate
      result during the execution of a program. These are accessible to the user if the
      user is working in assembly language.
   3. Special Purpose Register: A CPU contains a number of special purpose
      registers. It is used for different purpose. These are:
           Program counter
           Stack pointer
           Status register
           Instruction register
           Memory address register
           Memory buffer register

         Program Counter: It holds the address of the memory location, which contains
         the next instruction, which is to be fetched from the memory. It content is
         automatically incremented after the execution of an instruction.

         Stack Pointer: It is used to save the contents of the register if it is required
         during the execution of a program.

         Status Register: It is a 1-bit flag, which is used to indicate certain condition
         that arises during the arithmetic and logic operation.

         Instruction Register: It holds the instruction until it is decoded.

         Memory Address Register: It holds the address of the instruction or data to be
         fetched from the memory.

         Memory Buffer Register: It holds the instruction code or data received from or
         sent to the memory. The data which are written into the memory are held in this
         register until write operation is completed.




                                            18      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S


      Arithmetic/Logic Unit: All processors contain an arithmetic/logic unit,
       which is often referred to simply as the ALU. The ALU, as its name implies, is
       that portion of the CPU hardware which performs the arithmetic and logical
       operations on the binary data .The ALU must contain an Adder which is capable
       of combining the contents of two registers in accordance with the logic of binary
       arithmetic. This provision permits the processor to perform arithmetic
       manipulations on the data it obtains from memory and from its other inputs. The
       ALU contains Flag Bits, which specify certain conditions that arise in the course
       of arithmetic and logical manipulations. Flags typically include Carry, Zero, Sign,
       and Parity.

      Control Unit: The control unit is the primary functional unit within a CPU.
       Using clock inputs, the control circuitry maintains the proper sequence of events
       required for any processing task. After an instruction is fetched and decoded, the
       control circuitry issues the appropriate signals for initiating the proper processing
       action. Often the control circuitry will be capable of responding to external
       signals, such as an interrupt or wait request An Interrupt request will cause the
       control circuitry to temporarily interrupt main program execution.

1.8 Problem Solving Using Computers

To solve a problem using a computer following steps are carried out.

   1. The given problem is analyzed.
   2. The method used to solve the problem is broken down into a sequence of
      elementary tasks.
   3. Based on the analysis an algorithm to solve the problem is formulated. The
      algorithm should be precise, concise & unambiguous (not repeated).
   4. The algorithm is expressed in a precise notation. An algorithm expressed using a
      precise notation is called a computer program.
   5. The computer program is fed to the computer.
   6. The computer’s processing unit interprets the instructions in the program,
      executes them and sends the result to the output unit.


1.9 Computer Hardware:
The data are processed by a collection of electronic circuits and other devices that make
up the computer system. The physical component that you can see, touch and feel in the
computer system is called hardware. Computer hardware is the physical part of a
computer, including the digital circuitry, as distinguished from the computer software
that executes within the hardware. The hardware of a computer is infrequently changed,
in comparison with software and data, which are "soft" in the sense that they are readily
created, modified or erased on the computer. Most computer hardware is not seen by
normal users. It is in embedded systems in automobiles, microwave ovens,
electrocardiograph machines, compact disc players, and other devices.


                                            19      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

The term hardware covers all of those parts of a computer that are tangible objects.
Circuits, displays, power supplies, cables, keyboards, printers and mice are all hardware.
These Components are:

  CPU: CPU stands for Central processing unit. It is the brain of the computer. The part
 of the computer that performs the bulk of data processing operations is called central
 processing unit. The CPU fetches the instruction of the program from the memory at
 time, decodes it and then executes it. CPU takes the data from the input unit , process it
 and passes the output to the output unit. The CPU consist of the following units:
             Memory Unit
             Control Unit
             ALU

    Memory Unit: Memory is one of the most wonderful features on computer. It is
   one of the most important parts of this system. In this unit the data and result are
   stored. This unit consists of cells. Each cell has a numbered "address" and can store a
   single number. The function of the memory is to store information, it stores data
   result, or any other kind of information. There are two types of memory:

           Primary Memory: It is also called primary storage devices and it is directly
   connected to the CPU. . It stores program along with the data which is to be exected.
   It is a volatile memory.

    Secondary Memory: It is an additional part of storing the data which is not
   directly attached to the computer system. . It has much larger capacity than main
   memory. Secondary memory is also known as auxiliary memory. The magnetic
   memory is used as secondary memory. It is a non volatile memory.

               Control Unit: This is that unit of the CPU, which coordinates all the
       activities of each and every element of computer. It control the entire operation of
       the computer system. It fteches the instruction from the memory decodes the
       instruction, interprets the instruction to know what task are to be performedand
       sends suitable control signal to other component to perform necessary step to
       execute the instruction. It gives order to ALU what operation is to be performed .
       It generates timing and control signal and provide them for all operation. It
       control the data flow between CPU and peripherals.

              ALU: ALU stand for arithmetic and logic unit. It is used to perform
       certain arithmetic and logical operation like Addition, Multiplication, Logical
       And , Logical Or etc. If, an addition operation was requested, an arithmetic logic
       unit (ALU) will be connected to a set of inputs and a set of outputs. The inputs
       provide the numbers to be added, and the outputs will contain the final sum.




                                           20      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S


1.10 Computer Software
The term "software" was first used in this sense by John W. Tukey in 1957. In computer
science,computer software is nothing but all computer programs.To perform any task on
computer, the programmer has to write a set of instruction. This sequence of instruction
given to the computer is called a program. A set of program written for the computer is
called software. Software is a program that enables a computer to perform a specific task,
as opposed to the physical components of the system. This includes application software
such as a word processor, which enables a user to perform a task, and system software
such as an operating system, which enables other software to run properly, by interfacing
with hardware and with other software. In computers, software is loaded into RAM and
executed in the central processing unit. At the lowest level, software consists of a
machine language specific to an individual processor. A machine language consists of
groups of binary values signifying processor instructions i.e. object code. Software is an
ordered sequence of instructions for changing the state of the computer hardware in a
particular sequence. It is usually written in high-level programming languages that are
easier and more efficient for humans to use than machine language. High-level languages
are compiled or interpreted into machine language object code. Software may also be
written in an assembly language, essentially, a mnemonic representation of a machine
language using a natural language alphabet. Assembly language must be assembled into
object code by the help of assembler. Software is categorized on the basis of application
it performs. Software can be classified on the basis of three categories.

                      System Software
                      Application Software
                      Utility Software


1.10.1         System Software
As you know that, a set of programs written for the computer is called software. The
software required to execute user program is called system software. This software
controls all processing activities and make sure that resources and the power of the
computer are used in most efficient manner. The major purpose of system software is it
controls the execution of program and helps in the development of software.

System software helps in running the computer hardware and computer system. It
includes operating systems, device drivers, diagnostic tools, servers, windowing systems,
utilities and more. The purpose of systems software is to insulate the applications
programmer as much as possible from the details of the particular computer complex
being used, especially memory and other hardware features, and such accessory devices
as communications, printers, readers, displays, keyboards, etc. System software can be
classfied into two categories.

      Operating System
      Language Processor


                                           21      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S


A.      Operating system

An operating system is a program that acts as an intermediate between the user and
computer hardware. It is a computer program that manages the hardware and software
resources of a computer. At the foundation of all system software, the OS performs basic
tasks such as controlling and allocating memory, prioritizing system requests, controlling
input and output devices, facilitating networking, and managing files. It also may provide
a graphical user interface for higher level functions. The purpose of an operating system
is to provide an environment. In which user can execute the program.

Modern general-purpose computers, including personal computers and mainframes, have
an operating system to run other programs, such as application software. Examples of
operating systems for personal computers include Microsoft Windows, and Linux. The
primary goal of an operating system is thus to make the computer system convenient to
use. A secondary goal is to use the computer hardware in an efficient manner.

                                          User

             Compiler       Assembler    Text editor     Database system



                                 Application Program
                                 Operating system


                                    Computer
                                    Hardware



When the hardware provides the basic computing resources, then the application program
defines the way in which these resources are used to solve certain problem. Operating
system controls and coordinates the use of hardware among the application program.
Efficiency of operating system can be measured on the basis of following 3 factors.

     1. Turn around time : It is the time delay between the submission and completion of
        any job.
     2. Response time: It is the time taken by the system to give first response.
     3. Throughput: It is the no of job executed in an unit time.

Computer Software:




                                           22      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S


B. Language Processor

When a program written in a language other than the machine language of computer, the
computer will not understand it. Hence, the program written in other language must be
translated into the machine language of the computer. Such translation is done with the
aid of software. This type of software is known as language processor.

A Compiler
A compiler is a computer program or set of programs that translates text written in a
computer language i.e. in the source language into another computer language i.e. the
target language. The original sequence is usually called the source code and the output
called object code. The most common reason for wanting to translate source code is to
create an executable code. The name "compiler" is primarily used for programs that
translate source code from a high level language to a lower level language or machine
language. A program that translates from a low level language to a higher level one is a
decompiler. A compiler is likely to perform many or all of the following operations:
lexing, preprocessing, parsing.

Early computers did not use compilers. Compilers had not yet been invented because
early computers had very little memory and programs were necessarily quite short. Users
often entered the decimal or binary machine code for a program. With the evolution of
programming languages and the increasing power of computers, compilers are becoming
more and more complex to bridge the gap between problem-solving modern
programming languages and the various computer.

A compiler is itself a computer written in some implementation language. Early
compilers were written in assembly language. The first self-hosting compiler which is
capable of compiling its own source code in a high-level language — was created for
Lisp.

      A program that translates from a low level language to a higher level one is a
       decompiler.
      A program that translates between high-level languages is usually called a
       language translator.

Most compilers are classified as either self-compilers or cross compilers. If a compiler
run on a computer for which it produces the object code, then it is known as self-
compiler. If a compiler run on a computer other than that for which it produces the object
code, then it is known as cross compiler.


B Assembler




                                           23      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

A program that converts an assembly language program into machine language so that
computer can run the program. As you know that assembly language program can be
written by making use of mnemonic code (symbolic code). The use of symbolic
references is a key feature of assemblers, saving tedious calculations and manual address
updates after program modifications. Assemblers are available since the 1950s. An
assembler, which runs on the computer for which it produces the object code, is called
self-assembler. The assembler runs on the computer other than that for which it produces
the object code is called cross assembler. There is two types of assembler, first is one
pass assembler, it is an assembler which read the program once and assign addresses to
the labels used in assembly language program. Second is Two pass assembler, which
goes to the program twice, in first pass it will assign address to the labels and in the
second pass it will convert each assembly language instruction into machine language
instruction.

More sophisticated High-level assemblers provide language abstractions such as:

      Advanced control structures.
      High-level procedure/function declarations and invocations.
      High-level abstract data types, including structures/records, unions, classes, and
       sets.
      Sophisticated macro processing.

C Interpreter
An interpreter is a program which translates a high level language rogram into machine
level language. It translates one instruction of a program at a time. If it is correct then
only it proceeds towards the next instruction. It reads the instruction, translate it,and after
that it executes the instruction. An interpreter is a smaller program as compared to the
compiler. It occupy less memory space. Interpreting code is slower than running the
compiled code because the interpreter must analyse each statement in the program each
time it is executed and then perform the desired action whereas the compiled code just
performs the action. Access to variables is also slower in an interpreter because the
mapping of identifiers to storage locations must be done repeatedly at run-time rather
than at compile time. The IBM 550 Numeric Interpreter and IBM 557 Alphabetic
Interpreter are typical examples of the interpreter.

1.10.2 Application Software

Application software allows humans to accomplish one or more specific tasks.It is a set
of program that is necessary to carry out operation for a specified application. Typical
applications include industrial automation, business software, educational software,
medical software, databases. Almost every field of human activity now uses some form
of application software. It is used to automate all sorts of functions.

Application software or Applications are what most people think of when they think of
software. Application software is often purchased separately from computer hardware.


                                              24      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S

Sometimes applications are bundled with the computer, but that does not change the fact
that they run as independent applications. Applications are almost always independent
programs from the operating system

Customized Application software: The software which is developed to meet all the
requirement specified by the user.

General Application software: The software which is developed by keeping all the
general requirements in mind for carrying out a specific task.These are those software
which are developed by the group of people or an individual to be use by the other.For
e.g. word processing software, Electronic spread sheet etc.

1.10.2.1        Application software consist of Packages and Business
software.

A Packages
Software package, in computing, a type of file format where software installation
material is grouped together. A software package is a bundle of one or several files that
either are necessary for the execution of a computer program, or add features for a
program already installed on the computer or network of computers. Software packages
can either be in a standardised package format to be installed by a program that is
integrated with the operating system, or be a self-sufficient installer.

The term software package is also used in object-oriented programming to name a group
of related classes of a program. In this, meaning of packages are especially useful to
measure and control the inherent coupling of a program. Some most common packages
that are mostly used are:

      Word Processor
      Electronic Spreadsheet
      Database Management System
      Desktop publishing

Word Processor

It is an application program designed to replace a typewriter. A word processor manages
text-based documents. It allows the user to enter, edit, view, store and retrieve the text
material. These text material may be letter, reports, or book etc. It is very easy to make
corrections in the data which is written there. Editing in the documents like to insert or
delete a word or sentences from the document can be done very easily.

In word processing, there is automatic flowing of text on to the next line as new text is
inserted. It means, when an operator enters the character to the document and as soon
they reached at the end of the line the word processor program automatically moves the



                                           25      Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S

text to the next line. This feature of the word processing is known as word wrap. Word
wrap ensures that the text stays inside the designated document boundaries or margins.
Word processing program also provides us certain features like boldface, italic,
superscript, sub script etc. It also provide certain alignment like left, right, center.

Word processor vary from simple to the complex. An advanced word processor must
contain all the features needed for entering, editing and formatting the text as well as
support macros to simplify complex or routine task. It also include facility for spell
checking (speling check), dictionary etc.WordPerfect from Word Perfect Corporation and
Microsoft word are examples of fully featured word processor.

Electronic Spreadsheet

A spreadsheet is a rectangular table (or grid) of information, which is often used for
giving financial information. The word came from "spread" in its sense of a newspaper
or magazine item (text and/or graphics) that covers two facing pages, extending across
the center fold and treating the two pages as one large one. The compound word "spread-
sheet" came to mean the format used to present bookkeeping, ledgers.

One of the first commercial uses of computers was in processing payroll and other
financial records, so the programs were designed to generate reports in the standard
"spreadsheet" format, bookkeepers and accountants used it. The generally recognized
inventor of the spreadsheet as a commercial product for the personal computer is Dan
Bricklin. The spreadsheet or work sheet consists of rows and columns of cells. The rows
are usually identified by numbers, and columns by letters. Each cell can hold a numeric
value, text label or a formula that produces values contained in other cells.

Many people find it easier to perform calculations in spreadsheets than by writing the
equivalent sequential program. This is due to two traits of spreadsheets.

      They use spatial relationships to define program relationships. Like all animals,
       humans have highly developed intuitions about spaces, and of dependencies
       between items.
      They are forgiving, allowing partial results and functions to work. One or more
       parts of a program can work correctly, even if other parts are unfinished or
       broken. This makes writing and debugging programs much easier, and faster.
       Sequential programming usually needs every line and character to be correct for a
       program to run. One error usually stops the whole program.

In a spreadsheet, however, a set of cells is defined, with a spatial relation to one another.
In the earliest spreadsheets, these arrangements were a simple two-dimensional grid.
Over time, the model has been expanded to include a third dimension also which is
known as 3-D spreadsheet. Lotus 1-2-3 from Lotus Development Corp, Quattro Pro
developed by Borland International and Microsoft Excel are examples of spreadsheet
programs. Some of the problems associated with spreadsheets are:



                                             26      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S


      Lack of auditing. This makes it difficult to determine who changed what and
       when.
      Lack of security. Generally, if one has permission to open a spreadsheet, one has
       permission to modify any part of it. This, combined with the lack of auditing
       above, can make easy for someone to commit fraud.
      Lack of concurrency. Unlike databases, spreadsheets typically allow only one user
       to be making changes at any given time.

Database Management System

It is an application software that controls the data in the database, including overall
organization, storage, security, data integrity.A database management system (DBMS) is
a system or software designed to manage a database, and run operations on the data
requested by numerous clients. Typical examples of DBMS use include accounting,
human resources and customer support systems. A DBMS is a complex set of software
programs that controls the organization, storage and retrieval of data in a database. The
DBMS accepts requests for data from the application program and instructs the operating
system to transfer the appropriate data.

When a DBMS is used, information systems can be changed much more easily as the
organization's information requirements change. New categories of data can be added to
the database without disruption to the existing system. Database servers are specially
designed computers that hold the actual databases and run only the DBMS and related
software.

Features Of DBMS

      Persistence - Attributes are permanently stored on a hard-drive or other fast,
       reliable medium until explicitly removed or changed.
      Concurrency - Many people may want to change and read the same attributes at
       the same time. For example, if you change the color attribute of car 7 to be "blue"
       at the very same time somebody is changing it to "red", then you may not see
       your change when you go to view the attributes of the car you thought you just
       changed. DBMS provide various tools and techniques to deal with such issues.
       "Transactions" and "locking" are two common techniques for concurrency
       management.
      Security - Often it is desirable to limit who can see or change which attributes or
       groups of attributes.
      Computation - There are common computations requested on attributes such as
       counting, summing, averaging, sorting, grouping, cross-referencing, etc can be
       done.
      Meta-data Repository - Meta-data is information about information. For
       example, a listing that describes what attributes are allowed to be in data sets is
       called "meta-information".




                                           27      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

A DBMS can also format reports for printed output , and import and export data from
other application programs by making use of standard file format. A data manipulation
language is also provided to support queries against the database.

Desktop publishing Software
The use of computer with specialized page layout software to combine text and graphics
into a single document that can be printed on a aser printer. The original document text is
usually wrtten by using a word processor and the line art are prepared with a paint
program, photographs can be incorporated as scanned images. All of these separate
elements are then brought together in the page layout or desktop publishing program,
where they can usually be imported directly as separate files. The software that handles
page layout by combining the functions of a traditional typesetter and a layout artist is
known as desktop publishing software.Hardware for desktop publishing may include a
high speed personal computer with a large capacity hard dik and a full-pabe display, a
scanner and a laser printer.

B Business Software

Business software is generally any software program that helps a business increase
productivity or measure their productivity. The term covers a large variation of uses
within the business environment, and can be categorized by using a small, medium and
large matrix.The software that is developed by keeping all the requirement of business in
mind is known as business software. There are many types of business softwrae are
available in market like inventory management system, payroll system, Hotel
management system. Some of them are explained below:

Inventory Management System
An inventory management system is an integrated package of software and hardware
used in warehouse operations, and elsewhere, to monitor the quantity, location and status
of inventory as well as the information related to the shipping, receiving, picking and
putaway processes. Modern inventory control systems rely upon barcodes to provide
automatic identification of inventory objects. An inventory control system may be used to
automate a sales order fulfillment process. Such a system contains a list of order to be
filled, and then prompts workers to pick the necessary items, and provides them with
packaging and shipping information. Real time inventory control systems use wireless,
mobile terminals to record inventory transactions at the moment they occur. Some
Widely used inventory control systems are:

      Inventory Control Software - Soft-Aid
      IntelliTrack
      ACCPAC, published by The Sage Group
      HighJump Software, a division of 3M
      S3CO
      Inventory Control Software – AMICS


                                            28     Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S


Payroll System
In a company, payroll is the sum of all financial records of salaries, wages, bonuses, and
deductions. A paycheck is traditionally a paper document issued by an employer to pay
an employee for services rendered. A payroll savings program is a method of
automatically deducting money from one's paycheck and depositing it into a savings
account. Since these funds are made less available there is a reduced chance that they will
be spent. A payroll card is a card that allows an employee to access their paycheck by
using a card that looks like a bank debit card. A payroll card can be more convenient than
using a check casher, because it can be used at participating automatic teller machines to
withdraw cash. Some payroll cards also are cheaper than Payday loans available from
retail check cashing stores. The payroll card account usually is held as a single account in
the employer's name. That account holds the payroll funds for all employees using the
payroll card system. Some payroll card programs establish a separate account for each
employee, but others do not.

Financial Accounting

Financial Accounting software is computer software that records and processes
accounting transactions within functional modules such as accounts payable, accounts
receivable, payroll and trial balance. It functions as an accounting information system. It
may be developed in-house by the company or organization using it, may be purchased
from a third party, or may be a combination of a third-party application software package
with local modifications. It varies greatly in its complexity and cost.

Accounting software is typically composed of various modules. Among the most
common are:

          Accounts receivable—where the company enters money received.
          Accounts payable—where the company enters its bills and pays money it
           owes.
          General ledger—the company's "books".
          Billing—where the company produces invoices to clients/customers.
          Stock/Inventory—where the company keeps control of its inventory.
          Purchase Orders—where the company orders inventory.
          Sales Orders—where the company records customer order for the supply of
           inventory.

The most complex and expensive business accounting software is frequently part of an
extensive suite of software often known as Enterprise resource planning or ERP software.

These applications typically have a very long implementation period, often greater than
six months. In many cases, these applications are simply a set of functions which require
significant integration, configuration and customisation to even being to resemble an
accounting system.



                                            29      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S


1.10.3          Utility Software

It is a set of program, that supports the operating system by providing the additional
services that the operating system does not provide. There are many task which are
performed by utility programs are hard disk backup, disk optimization, file recovery, safe
formatting and resource editing.

Utility software is also known as service program, or utility routine. It is specifically
designed to help in managing and tune the computer hardware, operating system or
application software, and perform a single task or a small range of tasks.Some important
utilities are bein discussed below:

        Disk defragmenters/Disk management tools Disk defragmenter can detect
         computer files whose contents have been stored on the hard disk in disjointed
         fragments, and move the fragments together to increase efficiency. There is a
         Disk checker which can scan the contents of a hard disk to find files or areas that
         are corrupted in some way, or were not correctly saved, and eliminate them for a
         more efficiently operating hard drive. A Disk cleaner can find files that
         unnecessary to computer operation, or take up considerable amounts of space.
         Disk cleaner helps the user to decide what to delete when his hard disk is full. To
         start disk defragmentation we have to click start>Programs>Accessories>System
         tools>Disk Defragmentation. It will show like this




        Virus scanners/Antivirus. Virus Scanners scan for computer viruses among files
         and folders. Virus is a program intended to damage your computer sytem without
         your knowledge and belief. A virus may itself attach to another programon your
         hard disk and when the date passes, or a certain event occurs, the virus is trigerred
         into action. The most famous virusis jerusalem virus, which is also known as


                                              30      Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S

        Friday the 13th, first seenat the university of jerusalem in july 1987. The virus
        slow down the system. There are several precautions that you can take to protect
        yoursef from infection, including backing up your system on the regular basis ,
        and you can also buy and run the commercially available virus detecting program.

                                    Antivirus is an application program that can detect and
       eliminate the computer virus. Some antivirus program can detect suspicious activity
       on your computer as it happens. While, the other must be run periodically. The
       antivirus program locates and identifies a virusby looking some of the
       characteristics, like unexpected disk access. It recognizes the virusby comparing the
       information from the system against the database of known virus that is kept n the
       disk. There are several simple precautions that you can take to minimize your
       chances of contracting a virus:

            1. Back up your hard disk regularly.
            2. Do not install software if you don’t know where it’s been or where it came
                 from.
            3. Write protect disks as soon as you get them.
       Compression utilities output a shorter stream or a smaller file when provided
        with a stream or file. A file that has been processed by a special utility programso
        that it occupies a little hard disk space. When the file is needed, the same program
        decompresses the file back into its original form so that it can be read by the
        computer. Two kind of file file compression program are available those program
        that cancompress more than one file at a time such as winzip. Those program that
        can compress al the files on a specific disk.Any method of encding data so that it
        occupies less space than its original form.

       File Management tools A file manager or file browser is a computer program
        that provides a user interface to work with file systems. They are very useful for
        speeding up interaction with files. The most common operations on files are
        create, open, edit, view, print, play, rename, move, copy, delete, attributes,
        properties, search/find, and permissions.
       Encryption utilities use a specific algorithm to produce an encrypted stream or
        encrypted file when provided with a key and a plaintext.

1.11 Central Processing Unit
CPU is an acronym for central processing unit. It is a brain of the computer. The primary
function is to execute the program. The program, which is to be executed, is stored in the
main memory. The CPU fetches one instruction from the memory at a time, decodes it
and after decoding the instruction it under stands what operation is to be performed. After
knowing the operations, it will execute the instruction as specified. After decoding it also
came to know that the data, which is used in the program, is stored either in the main
memory or in register. If the data is stored in the memory, then CPU reads the data from
memory. Then it executes the instruction. After executing one instruction it fetches the
next instruction for execution. This process is continued unless and until all the


                                             31      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

instruction of a program is fetched and executed. Besides executing the program, the
CPU also control input devices, output devices and other components of computer.




After the fetch and decode steps, the execute step is performed. During this step, various
portions of the CPU are connected so they can perform the desired operation. If, for
instance, an addition operation was requested, an arithmetic logic unit (ALU) will be
connected to a set of inputs and a set of outputs. The final step, writeback, simply "writes
back" the results of the execute step to some form of memory. Very often the results are
written to some internal CPU register for quick access by subsequent instructions. In
other cases results may be written to slower, but cheaper and larger, main memory. Some
types of instructions manipulate the program counter rather than directly produce result
data. There are many steps which may be performed concurrently or in a different order
by the CPU depending on its type:

   1. Read the code for the next instruction from the cell indicated by the program
      counter.
   2. Decode the numerical code for the instruction into a set of commands or signals
      for each of the other systems.
   3. Increment the program counter so it points to the next instruction.
   4. Read whatever data the instruction requires from cells in memory (or perhaps
      from an input device). The location of this required data is typically stored within
      the instruction code.
   5. Provide the necessary data to an ALU or register.
   6. If the instruction requires an ALU or specialized hardware to complete, instruct
      the hardware to perform the requested operation.
   7. Write the result from the ALU back to a memory location or to a register or
      perhaps an output device.
   8. Jump back to step (1).

1.11.1 CPU consist of


    ALU (Arithmetic Logic Unit)
    Control Unit
    General And Special Purpose Register

A. ALU (Arithmetic Logic Unit)


The abbreviation stands for Arithmetic Logic Unit. The function of this unit is to perform
arithmetic and logical operations like Addition, Subtraction, Multiplication, Division,
Logical AND, Complement etc. If, an addition operation was requested, an arithmetic


                                            32      Rajesh Deshmukh – Disha College
                                                      BCA I – Fundamentals Of I.T & O.S

logic unit (ALU) will be connected to a set of inputs and a set of outputs. The inputs
provide the numbers to be added, and the outputs will contain the final sum. The ALU
contains the circuitry to perform simple arithmetic and logical operations on the inputs .If
the addition operation produces a result too large for the CPU to handle, an arithmetic
overflow flag in a flags register may also be set.

Other mathematical operationsuch as exponentia, logarithmic and floating point operation
are performed by special purpose math processor called floating point unit.


B. Control Unit
A control unit is the part of a CPU device that directs its operation. The outputs of the
unit control the activity of the rest of the device. A control unit can be thought of as a
finite state machine. It control the entire operation of the computer system. It fteches the
instruction from the memory decodes the instruction, interprets the instruction to know
what task are to be performedand sends suitable control signal to other component to
perform necessary step to execute the instruction. It gives order to ALU what operation is
to be performed . It generates timing and control signal and provide them for all
operation. It control the data flow between CPU and peripherals. It performs the
following functions

   1.   It can get the instruction out of the memory unit.
   2.   It can decode the instruction.
   3.   It sets up the routing through internal wiring.
   4.   It can determine the storage from where it is to get the next instruction.




           CPU
                                                     ALU


               Control Unit
                                                Register Set



Control units are usually one of these types:




                                             33       Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

   1. Microcoded control units. In a microcoded control unit, a program reads signals,
      and generates control signals. The program itself is executed by a very simple
      computer, a relatively simple digital circuit called a microsequencer.
   2. Hardware control units. In a hardware control unit, a digital circuit generates the
      control signals directly.

The control system's function is as follows

      The address of the memory location where the instruction lies, is placed on the
       address bus.
      Instruction is read from memory.
      The instruction is sent to the decoding circuitry for decoding.
      Address and data required for the execution is read from the memory.
      These data and addresses are sent to the other section for processing.
      The result is sent to the memory or in some register.
      Necessary steps are taken to fetch the instruction. For this content of the program
       counter is get incremented.

C. Registers

Register consist of flip flops. These flip flops are connected in parallel. A CPU contains a
number of registers to store data temporarily during the execution of a program. The no
of register is differ from processor to processor. The advantages of storing the data in
register are that it can be retrieved faster than memory because the number of register in
the memory is very less. The drawback of using the register is that it is very expensive.
Register are classified as follows:

   4. Accumulator: It is a register, which holds one of the operand prior to the
      execution of instruction and receives the result of most of the arithmetic and logic
      operations. It is one of the frequently used registers.
   5. General Purpose Register: These register stores data and intermediate
      result during the execution of a program. These are accessible to the user if the
      user is working in assembly language.
   6. Special Purpose Register: A CPU contains a number of special purpose
      registers. It is used for different purpose. These are:
           Program counter
           Stack pointer
           Status register
           Instruction register
           Memory address register
           Memory buffer register

Program Counter: It holds the address of the memory location, which contains the next
instruction, which is to be fetched from the memory. It content is automatically
incremented after the execution of an instruction.


                                              34    Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S



Stack Pointer: It is used to save the contents of the register if it is required during the
execution of a program.

Status Register: It is a 1-bit flag, which is used to indicate certain condition that arises
during the arithmetic and logic operation.

Instruction Register: It holds the instruction until it is decoded.

Memory Address Register: It holds the address of the instruction or data to be fetched
from the memory.

Memory Buffer Register: It holds the instruction code or data received from or sent to
the memory. The data which are written into the memory are held in this register until
write operation is completed.

1.12 Memory
Computer storage, computer memory, and often casually memory refer to computer
components, devices and recording media that retain data for some interval of time. It is
one of the fundamental components of all modern computers, and coupled with a central
processing unit (CPU). A computer's memory may be viewed as a list of cells into which
numbers may be placed or read. Each cell has a numbered "address" and can store a
single number. The function of the memory is to store information, it stores data result,
or any other kind of information. Data that are being processed are held in primary
memory which is capable of sending and receiving the data at a very high speed.
Secondary memory stores data not currently being used and operate morwe slowly but it
is capable of storing large volume of data.


                                          Memory



              Primary Memory                                Secondary Memory

1.12.1 Characteristics Of Memory
      Volatile memory:        Memory requires constant power to maintain the stored
       information. Volatile memory is typically used only for primary storage. When
       the power supply is off data present in the volatile memory disappears.
      Non-volatile memory:           This type of memory will retain the stored
       information even if it is not constantly supplied with electric power. It is suitable
       for long-term storage of information, and therefore used for secondary, tertiary,
       and off-line storage.



                                             35      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

      Dynamic memory: It is volatile memory which also requires that stored
       information is periodically refreshed, or read and rewritten without modifications.
      Random access:          It means that any location in storage can be accessed at any
       moment of time. This makes random access memory well suited for primary
       storage.
      Sequential access: It means that the accessing a piece of information will take
       a varying amount of time, depending on which piece of information was accessed
       last. The device may need to seek (e.g. to position the read/write head correctly),
       or cycle (e.g. to wait for the correct location in a constantly revolving medium to
       appear below the read/write head).
      Storage capacity:       It is the total amount of stored information that a storage
       device or medium can hold. It is expressed as a quantity of bits or bytes

1.12.2 Primary Memory/ Storage
Primary storage is directly connected to the central processing unit of the computer. It
must be present for the CPU to function correctly, just as in a biological analogy the
lungs must be present (for oxygen storage) for the heart to function (to pump and
oygenate the blood). It is a faster memory. It stores program along with the data which is
to be exected. It also store necessary program of a system software which are required to
execute user program. It is a volatile memory. Primary storage typically consists of three
kinds of storage:

      Processor registers are internal to the central processing unit. Registers contain
       information that the arithmetic and logic unit needs to carry out the current
       instruction. They are technically the fastest of all forms of computer storage,
       being switching transistors integrated on the CPU's silicon chip, and functioning
       as electronic "flip-flops".
      Cache memory is a special type of internal memory used by many central
       processing units to increase their performance or "throughput".It is a
       semiconductor memory. Some of the information in the main memory is
       duplicated in the cache memory, which is slightly slower but of much greater
       capacity than the processor registers, and faster but much smaller than main
       memory. In this the active portion of program and data are placed in a fast small
       memory , the average acess time can be reduced. The cache memory access time
       is less than the access time of main memory by a factor of 5 to 210. Multi-level
       cache memory is also commonly used - "primary cache" being smallest, fastest
       and closest to the processing device; "secondary cache" being larger and slower,
       but still faster and much smaller than main memory.

                            The basic operation can be done like this: When CPU needs
       to access the memory, the cache is examined first, if the word is found then it is
       read from there only. If, not then main memory is accessed to read the word. A
       bock of words containing that word which is just accessed is then transferred from
       main memory to cache memory.The block size may vary from 1 word to 16 word.




                                            36      Rajesh Deshmukh – Disha College
                                                BCA I – Fundamentals Of I.T & O.S

   Main memory contains the programs that are currently being run and the data the
    programs are operating on. The arithmetic and logic unit can very quickly transfer
    information between a processor register and locations in main storage, also
    known as a "memory addresses". In modern computers, electronic solid-state
    random access memory is used for main storage, and is directly connected to the
    CPU via a "memory bus"and a "data bus". The memory bus is also called an
    address bus or front side bus and both busses are high-speed digital
    "superhighways". Access methods and speed are two of the fundamental technical
    differences between memory and mass storage devices. It is broadly categorised
    in two:

       1. RAM : Random-access memory usually known by its acronym, RAM
          refers to data storage formats and equipment that allow the storing data to
          be accessed in any order — that is, at random, not just in sequence.
          Computers use RAM to hold the program code and data during
          computation. A defining characteristic of RAM is that all memory
          locations can be accessed at almost the same speed. Most other
          technologies have inherent delays for reading a particular bit or byte. The
          user can write the information into the RAM and also able to read the
          information from it. It posses random access property. It is a volatile
          memory.

           The read and write memory of a computer is called RAM. The user
           can write information into RAM and read information from it. It is
           accessible to user.The user enters his program into the RAM. It posses
           random access property. In a random access memory any memory
           location can be accessed in a random manner without going through the
           any other memory location. RAM is a volatile memory. The information
           written into it is retained init as long as the power supply is on, as soon as
           the power supply goes off its stored information is lost.The two most
           important type of RAM are

          Static RAM: SRAM retains its contents as long as power is supplied. It is
           made up of a flip flop. Static RAM are costlier and consume more power.
           Si transistor are needed per memory cell in a ststic RAM. It does not need
           constant refreshment like dynamic RAM chips .Static RAM hold
           information in a flip flop circuit connsiting of two cross coupeled inverter.
           In a Ram the memory cell must be associated withread and write facility.
           Six transistor are neededper memory cell in a static RAM. A static RAM
           can only store one forth of the information that a dynamic RAM of same
           complexity hold. Static RAM , with access time 15 to 30 nanoseconds, is
           much faster than the dynamic RAM.
          Dynamic RAM:           A common type of computer memory that uses
           capacitor and transistor storing electrical charges to represents memory
           states. These capacitors lose their eectrical charge, and so need to be
           refreshed every millisecond, during that time they cannot be read by the


                                        37      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

               processor. DRAM chips are small, cheap, easy to make, and hold
               approximately four times as much information than static RAM. DRAM
               requires less no of transistors per memory cell because information is
               stored Iin capacitors. Only one transistor is needed to form the memory cel
               of the dynamic RAM.

    1. ROM (Read Only Memory)

    Read-only memory (ROM) is a class of storage media used in computers and other
    electronic devices. It is a non volatile memory i.e information is not lost eevn if the
    power supply goes off. It is used for permanent storge of information. It provides
    random access property. The stored information in ROM can ony be read at the time
    of operation. It has random acess property means, data can be eassily retrieved from
    anywhere without any difficulty or in simple words, data retrieval is faster. ROM is
    not accessible by user, means information cannot be written into a ROM by user.

       Types of ROMs

              PROMs : Programmable Read-Only Memory can be written to
               (programmed) via a special device, a PROM programmer. The writing
               often takes the form of permanently destroying or creating internal links
               with the result that a PROM can only be programmed once.
              EPROMs: Erasable Programmable Read-Only Memory can be erased by
               exposure to ultraviolet light then rewritten via an EPROM programmer.
               Repeated exposure to ultraviolet light will eventually destroy the EPROM
               but it generally takes many (greater than 1000) exposures before the
               EPROM becomes unusable. Once programmed, this window is typically
               covered by a label to prevent accidental erasure.
              EAROMs: Electrically Alterable Read-Only Memory can be modified a
               bit at a time, but writing is intended to be an infrequent operation; most of
               the time the memory is used as a ROM. EAROM may be used to store
               critical system setup information in a non-volatile way.
              EEPROM: Electrically Erasable Programmable Read-Only Memory
               allow the entire ROM to be electrically erased then written to without
               taking them out of the computer .

N
u
m
e
r
i
c




                                            38      Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S


                                          Unit-2

                    Input, Hard/Soft Copy Devices, Storage Devices


Input Devices

These are those devices, which facilitate a user to give input. Information is entered in to
a computer through input devices. An input device converts input information in to
suitable binary format, which can be accepted by the computer system. Some examples
of input devices are keyboard, mouse, Light pen etc. Some of theses devices permit the
user to select some thing on the CRT screen by pointing to it. Therefore, these devices are
also known as pointing devices.
                       The computer system has to process details of each command,
therefore the command will have to be converted in to machine readable format and this
work can be done through input unit. This unit will transmit the data as a series of electric
pulses in to the computer memory unit, where it will be available for processing. These
devices translate the data into a code that can be read by the computer’s system electronic
circuitry.


Keyboard

Keyboard is one of the most widely used peripheral devices. Data is entered in to the
computer system through keyboard. Keyboards are designed for the input of text and
characters and also to control the operation of a computer. A keyboard is similar to the
keyboard of a type-writer.




Physically, computer keyboards are an arrangement of rectangular or near-rectangular
buttons, or "keys". Keyboards typically have characters engraved or printed on the keys;
in most cases, each press of a key corresponds to a single written symbol. Keyboard
come in a variety of sizes and shapes, But most of the keyboard have a common number
of features like:

   1.   Standard type writer keys
   2.   Function keys
   3.   Special purpose keys
   4.   Cursor Movement Keys
   5.   Numeric keys


                                             39      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S


Working Of A Keyboard

   1. When a key is pressed, it pushes down on a rubber dome sitting beneath the key.
      A conductive contact on the underside of the dome touches a pair of conductive
      lines on the circuit below.
   2. This bridges the gap between them and allows current to flow.
   3. A scanning signal is emitted by the chip along the pairs of lines to all the keys.
      When the signal in one pair becomes different, the chip generates a "make code"
      corresponding to the key connected to that pair of lines.
   4. The code generated is sent to the computer through a keyboard cable.
   5. A chip inside the computer receives the signal bits and decodes them into the
      appropriate keypress. The computer then decides what to do on the basis of the
      key pressed. Eg: Either display a character on the screen, or perform some action.

2.1.2 Mouse

This input deice is used especially for Graphica User Interface. Mouse is a device which
is used to move the cursor on the screen and to select options. When the mouse is moved
on the surface the cursor is also moved in the same direction on the monitor. By moving
the mouse the user can point to menu on the screen i..e. Mouse is also known as pointing
device. Pressing the button of a mouse is known as clicking. Technicians often describe
mouse speed in DPI(dots per inch). One DPI is intended to be the number of pixels the
mouse cursor will move when the mouse is moved one inch.




Some common types of mouse are


Mechanical Mouse
This type of mouse are used on personal computer.It has a rubber ball inside it , which
can roll in any direction. There is a mechanical sensor which is present inside the mouse
and which is able to detect the direction of rolling the ball and moves the pointer
according to that.

1 Moving the mouse turns the ball.
2 X and Y rollers grip the ball and transfer movement.
3 Optical encoding disks include light holes.


                                           40     Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

4 Infrared LED shine through the disks.
5 Sensors gather light pulses to convert to X and Y velocities.


Optical Mouse

This mouse works on the basis of light source and the base where optical mouse kept
should be clean. The statement does not mean that any special base is needed: we should
required the base where 50% of the light should be reflected. An optical mouse uses a
light-emitting diode and photodiodes to detect movement relative to the underlying
surface, rather than moving some of its parts — as in a mechanical mouse.

2.1.3 Light Pen

A light pen is a pointing device.It is an input device in the form of a light-sensitive wand
used in conjunction with the computer's CRT monitor. It allows the user to to select a
displayed menu option on the CRT. A light pen can work with any CRT-based monitor,
but not with LCD screens, projectors or other display devices. It is capable of sensing a
position on the screen when its tip touches it ,its photocell sensing element detects the
light coming on the screen and sends the corresponding signal to the processor.

2.1.4 Touch Screens

It is a type of display screen in which one can use finger to point the command displayed
on the screen. In this user touches the icon that represent their choices and the computer
display information about their choices.




There are some types of touch screen technology:

   1. A resistive touch screen panel is coated with a thin metallic electrically
      conductive and resistive layer that causes a change in the electrical current which
      is registered as a touch event and sent to the controller for processing.
   2. Surface wave technology uses ultrasonic waves that pass over the touch screen
      panel. When the panel is touched, a portion of the wave is absorbed. This change
      in the ultrasonic waves registers the position of the touch event and sends this
      information to the controller for processing.


                                            41      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S


2.1.5 Joystick

A joystick is a personal computer peripheral devices. It is also used to move the cursor
position on the CRT screen. Most joysticks are two-dimensional, having two axes of
movement, but three-dimensional joysticks do exist. A joystick is generally configured so
that moving the stick left or right signals movement along the X axis, and moving it
forward (up) or back (down) signals movement along the Y axis. Joysticks are often
usedto control games.




2.1.6 MICR

Magnetic Ink Character Recognition, or MICR, is a special kind of character recognition
technology that was adopted mainly by the banking industry to facilitate the processing
of cheques. A special ink called magnetic ink is used to write the character of the cheques
and deposit forms which are to be processed by an MICR. The magnetic ink is
magnetized during the input process. The MICR reads these pattern and compared with
the special pattern stored in the memory. This method is fast, accurate and automatic.
Moreover, the the chances of errors are negligible.

2.1.7 OCR

It is an abbreviated form of Optical Character Reader. It detects the alphanumeric
character printed on paper. It is a computer software designed to translate images of
handwritten or typewritten text into machine-editable text, or to translate pictures of
characters into a standard encoding scheme representing them (e.g. ASCII or Unicode).
It works on the basis of light scanning techniques in which each character is illuminated
by the light source and the reflected images of the character is received by the photocells
which provides binary data corresponding to the lighted and dark areas.OCR is quite
costly because the memory requirement is very high.

2.1.8 Bar Code Reader

Bar code is a machine readable numerical code, printed as a set of varying width vertical
bars.Bar codes are used in many applications where strict control of inventory is needed.
A barcode reader is a computer peripheral for reading barcodes printed on various
surfaces.As you know bar codes are present on most of the grocery item, it consist of a


                                            42     Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

number of thick lines with a varying distance between them.A barcode reader scans the
bar code, and converts it into a number that the computer that the computer can then
process and display on the screen. Bar code reader, generally consists of a light source, a
lens and a photo conductor translating optical impulses into electrical ones. Therefore, it
read such bars and convert thm in to electrical pulses which is processed by the computer.

Benefits of using barcodes

      Barcodes can provide very detailed up-to-date information , enabling decisions to
       be made much quicker and with more confidence.
      Bar code scanners are also relatively low costing and extremely accurate – only
       about 1/100000 entries will be wrong.

Types of barcodes:

      Linear barcodes

      Stacked barcodes

      2D barcodes: A matrix code, also known as a 2D barcode, is a two-dimensional
       way of representing information. It is similar to a linear (1-dimensional) barcode,
       but has more data representation capability.



2.1.9 Digital Camera

A digital camera is an electronic device used to capture and store photographs
electronically instead of using photographic film like conventional cameras. Digital
cameras are those cameras whose primary purpose is to capture photography in a digital
format. In this once the picture is taken then it can be transferred or downloaded it in to
the computer.




Many modern digital photography cameras have a video function, and a growing number
of camcorders have a still photography function. The resolution of a digital camera is


                                            43     Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S

determined by the camera sensor which is usually a Charged Coupled Device or CCD
chip that turns light into digital information, replacing the job of film in traditional
photography. It represents this light value in pixels, which are little squares that make up
the image. Each pixel can store one digital value, which can then be recalled and put with
other pixel values to generate a digital photograph. The more pixels the camera can
recall, the better the resolution it can offer. Many digital cameras can connect directly to
a computer to transfer data. Early cameras used the PC serial port. Digital cameras need
memory to store data. Common formats for digital camera images are the Joint
Photography Experts Group standard (JPEG).

2.1.10   Web Camera

A web camera (or webcam) is a real-time camera whose images can be accessed using
the World Wide Web. Web-accessible cameras typically involve a digital camera which
uploads images to a web server, either continuously or at regular intervals. Web camera
focuses on an object at one end and reflect it on the screen at the other end. You can be
able to see the person while chatting by the help of this web camera. Videoconferencing
cameras typically take the form of a small camera connected directly to a PC. Webcams
typically include a lens, an image sensor, and some support electronics.




2.1.11   Graphic Tablet

A graphics tablet is a computer input device that allows one to hand-draw images and
graphics, similar to the way one draws images with a pencil and paper.Graphics tablets
consist of a flat surface upon which the user may "draw" an image using an attached
stylus,it is just a pen-like drawing apparatus. The image generally does not appear on the
tablet itself but, it is displayed on the computer monitor. The stylus is a technology, that
was originally designed as a part of the electronics, but later it simply took on the role of
providing a smooth, but accurate "point" that would not damage the tablet surface while
"drawing".




                                             44      Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S




Graphics tablets, because of their stylus-based interface has the ability to detect pressure,
tilt, and other attributes of the stylus and its interaction with the tablet, are widely
considered to offer a very natural way to create computer graphics, especially two-
dimensional computer graphics. The first home computer graphics tablet was the
KoalaPad. ACE CAD Enterprise Co. Ltd, Aiptek, Wacom are some of the manufacturer
f the graphic tablet. Some examples are:

        the Crosfield imaging system

        the Quantel Paintbox

2.1.12    Microphone (Mic)

A microphone, sometimes referred to as a mike or mic.It is an electric transducer that
converts sound into an electrical signal. The first commercially practical microphone was
the carbon microphone conceived in October, 1876 by Thomas Edison. A microphone is
a device which is able to capture waves in air, water or hard material and translate it to
an electrical signal.

Microphones are used in many applications such as telephones, tape recorders, hearing
aids, in radio and television broadcasting and in computers for recording voice, and
numerous other computer applications.

2.1.13 Scanner

Scanner is that kind of input device which are capable of entering the information directly
in to the computer system. A scanner is a device that analyzes an image such as a
photograph, printed text, or handwriting and converts it to a digital image.

Scanners typically read red-green-blue color (RGB) data from the array. This data is then
processed with some proprietary algorithm to correct for different exposure conditions
and sent to the computer. The other qualifying parameter for a scanner is its resolution,
measured in pixels per inch (ppi). The third important parameter for a scanner is its
density range. A high density range means that the scanner is able to reproduce shadow
details and brightness details in one scan.


                                             45      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

Scanner works on the basis of light source. In this light source emit the light to the object.
Some amount of light is absorbed by the object, wherease some amount of light is
reflected by it to the sensor. The work of the sensor is to convert that amount of light into
the digital data and the that digital data is transmitted to the computer.




                                                         object



                                                                           Light source



                                                     Sensor

                                Side View Of The Scanner

Types Of Scanner

Drum scanners: Drum scanners capture image information with photomultiplier tubes
(PMT). It is of medium size. In this drum roles over the image for scanning. The scanner
drum, which rotates at high speed while it passes in front of the precision optics that
deliver image information to the PMTs. The Most modern color drum scanners use 3
matched PMTs, which read red, blue and green light respectively. Drum scanners are
rarely used to scan prints of high quality because inexpensive flatbed scanners are readily
available.




                                             46      Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S




Flatbed scanner: A flatbed scanner is usually composed of a glass pane, under which
there is a bright light which is often of cold cathode fluorescent which illuminates the
pane. Images to be scanned are placed face down on the glass and the sensor array and
light source move across the pane reading the entire area.

Hand scanner: Hand scanners are manual devices which are dragged across the surface
of the image to be scanned. They typically have a "start" button which is held by the user
for the duration of the scan, some switches to set the optical resolution, and a roller which
generates a clock pulse for synchronisation with the computer. Most hand scanners were
monochrome, and produced light from an array of green LEDs to illuminate the image.

Scanner quality

Scanners typically read red-green-blue color (RGB) data from the array. This data is then
processed with some proprietary algorithm to correct for different exposure conditions
and sent to the computer, via the device's input/output interface (usually SCSI or USB, or
LPT in machines pre-dating the USB standard). Color depth varies depending on the
scanning array characteristics, but is usually at least 24 bits. High quality models have 48
bits or more color depth. The other qualifying parameter for a scanner is its resolution,
measured in pixels per inch (ppi), sometimes more accurately referred to as samples per
inch (spi). Instead of using the scanner's true optical resolution, the only meaningful
parameter, manufacturers like to refer to the interpolated resolution, which is much
higher thanks to software interpolation., a good flatbed scanner has an optical resolution
of 1600–3200 ppi, high-end flatbed scanners can scan up to 5400 ppi, and a good drum
scanner has an optical resolution of 8000–14,000 ppi.

The third important parameter for a scanner is its density range. A high density range
means that the scanner is able to reproduce shadow details and brightness details in one
scan.



2.1.14 Smart Card Reader



                                             47      Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S

Smart cards were invented and patented in the 1970s. The first mass use of the cards was
used for payment in French pay phones, starting in 1983. A smart card, is also known as
chip card, or integrated circuit(s) card (ICC), is defined as any pocket-sized card with
embedded integrated circuits. Although there is a diverse range of applications, there are
two broad categories of ICCs. Memory cards contain only non-volatile memory storage
components, and perhaps some specific security logic. Microprocessor cards contain
memory and microprocessor components.

Smart cards stores data in the magnetic stripes which is present at the back side of the
card. These data cannot be read visually, and therefore, to read this data, special card
reader machine is required, which can decode data present on these magnetic strips.The
smart card can hold many information and it is impossible to duplicate it because data is
stored in magnetic strips. They can serve as multipurpose card such as credit card,
electronic cash card etc.

There is a , Contact Smart Cards which has a small gold chip about ½ inch in diameter on
the front. When inserted into a reader, the chip makes contact with electrical connectors
that can read information from the chip and write information back. The cards do not
contain any batteries, energy is supplied by the card reader. Contact smart card readers
are used as a communications medium between the smart card and a host, e.g. a
computer.

2.1.15   Biometric Sensor

Biometric sensor is a type of input device which is used for identifyind a person. This
technology includes signature verification, voice recognition, finger prints identification.
Automated Fingerprint Identification System (AFIS) or Automated Fingerprint
Verification System refers to a computer system capable of establishing the identity of an
individual through fingerprints. Automated Fingerprint Verification is used to refer to
more civilan applications such as attendance and access control systems. On a technical
level, verification systems verify a claimed identity (a user might claim to be John by
presenting his PIN or ID card and verify his identity using his fingerprint) where as an
identification system determines the identity based solely on fingerprints. The US
government maintains an extensive database system containing fingerprint and criminal
history system that is maintained by the Federal Bureau of Investigation (FBI).

Pointing Devices

The pointer is a graphical representation of the movements made by a pointing device. A
pointing device is "An input device that is used to move the pointer on the computer
screen."The most common pointing device is the mouse, other kinds include a tracker
ball, touchpad, pointing stick, lightpen, and various other kinds of digitising tablets.

A mouse moves the graphical pointer by being slid across a smooth surface. The
conventional roller-ball mouse uses a ball to create this action. The ball is in contact with
two small shafts that are set at right angles to each other. As the ball moves these shafts



                                             48      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

rotate, and the rotation is then measured by sensors within the mouse. The distance and
direction information from the sensors is then transmitted to the computer. The computer
then moves the graphical pointer on your screen by following the movements of the
mouse. Another common mouse is the optical mouse. This device is very similar to the
conventional mouse but it does not use a roller-ball. An optical mouse uses visible or
infrared light to detect the changes in position.

A trackball is a pointing device consisting of a ball housed in a socket containing
sensors to detect rotation of the ball about two axes. It is similar to an upside-down
mouse. As the user rolls the ball with their thumb, fingers, or palm the mouse cursor on
the screen will also move. Tracker balls are commonly used on CAD workstations for
ease of use, where there may be no desk space on which to use a mouse. Some are able to
clip onto the side of the keyboard and have buttons with the same functionality as mouse
buttons.

A touchpad is a stationary pointing device. It is commonly used on laptop computers. It
is flat surface that you slide your finger over to make the graphical pointer move. You
use the same movements as you would with a mouse. It uses a two-layer grid of
electrodes to measure finger movement. The upper layer has vertical electrode strips that
handle vertical movement, and the lower layer has horizontal electrode strips to handle
horizontal movements.

A pointing stick is a pointing device that is comparible to a touchpad. It is found on
laptops embedded between the 'G', 'H', and 'B' keys. The mouse buttons are commonly
placed just below the Spacebar. It operates by sensing the force applied by the user. It has
also been observed on computer mice and on some desktop keyboards.

Digitizing tablet is "An input device that enables you to enter drawings and sketches into
a computer. A digitizing tablet consists of an electronic tablet and a cursor or pen. A
cursor (also called a puck) is similar to a mouse, except that it has a window with cross
hairs for pinpoint placement, and it can have as many as 16 buttons. A pen (also called a
stylus) looks like a simple ballpoint pen but uses an electronic head instead of ink. The
tablet contains electronics that enable it to detect movement of the cursor or pen and
translate the movements into digital signals that it sends to the computer." [5] This is
different from a mouse because each point on the tablet represents a point on the screen.

OMR:

Optical mark recognition is the process of capturing data by contrasting reflectivity at
predetermined positions on a page. By shining a beam of light onto the document the
scanner is able to detect a marked area because it is more reflective than an unmarked
surface. Some OMR devices use forms which are preprinted onto 'Transoptic' paper and
measure the amount of light which passes through the paper, thus a mark on either side of
the paper will reduce the amount of light passing through the paper.




                                            49      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

It is generally distinguished from optical character recognition by the fact that a
recognition engine is not required. That is, the marks are constructed in such a way that
there is little chance of not reading the marks correctly. This requires the image to have
high contrast and an easily-recognizable or irrelevant shape.

One of the most familiar applications of optical mark recognition is the use of #2 (HB in
Europe) pencil bubble optical answer sheets in multiple choice question examinations.
Students mark their answers, or other information, by darkening circles marked on a pre-
printed sheet. Afterwards the sheet is automatically graded by a scanning machine.

Other examples of OMR are the MICR recognition of the numbers on the bottom of
checks, scannable bar codes.

Disadvantages

There are also some disadvantages, limitations to OMR. If the user wants to gather large
amounts of text then OMR complicates the data collection , there is also the possibility of
missing data in the scanning process, incorrectly or unnumbered pages can lead to them
being scanned in the wrong order. Also, unless safeguards are in place, a page could be
rescanned providing duplicate data and skewing the data.For the most part OMR provides
a fast, accurate way to collect and input data.

Digitizing:

Digitization, is the process of turning an analog signal into a digital representation of that
signal. The term is often used for the scanning of analog sources, such as printed photos
and taped video into computers for editing, but it also can refer to audio (where sampling
rate is often measured in kilohertz) and textures map transformation.

In this last case, like in normal photos, sampling rate refers to the resolution of the image
(often measured in dots per inch). Digitizing is the primary way of storing images in a
form suitable for transmission and computer processing.

Voice Input Devices

In an effort to increase worker productivity, a substantial amount of research is being
done in voice recognition-programming the computer has to recognizspoken commands.
Voice Input devices or voice recognition system converts the spoken words into electrical
signal by comparing the electrical patterns produced by the speakers voice with a set of
pre recorded patterns. If matching pattern is found, the computer accept this pattern as a
part of its standard vocabulary. This technology is also used by the people who are not
able to use traditional devices.

The biggest problems with this technology involve limitation on the size of the computers
vocabulary. Pronunciation differences among the individuals and the computers inability
to accept continous speech.


                                             50      Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S


Output Devices

The output devices receive information from the computer and provide them to user in a
readable format. The computer sends information to the output devices in binary coded
forms. Then, output devices convert them in to a form, which can be used by user. Some
output devices are

                      Printer
                      Monitor
                      Plotter
                      Speaker

2.2.1 Printer
A computer printer, or more commonly just a printer, is a device that produces a hard
copy which is permanent human-readable text of documents stored in electronic form,
usually on physical print media such as paper or transparencies. Many printers are
primarily used as computer peripherals, and are permanently attached to a computer
which serves as a document source. Other printers, commonly known as network printer,
have built-in network interfaces, and can serve as a hardcopy device for any user on the
network. Some printers are combined with a scanners. A printer which is combined with
a scanner can essentially function as a photocopier. Printers are designed for low-volume,
short-turnaround print jobs; requiring virtually no setup time to achieve a hard copy of a
given document. However, printers are generally slow devices, and the cost-per-page is
relatively high. The choice of print engine has a substantial effect on what jobs a printer
is suitable for, as different technologies are capable of different levels of image/text
quality, print speed, low cost, noise; in addition, some technologies are inappropriate for
certain types of physical media such as carbon paper or transparencies. Printers vary
considerably in price, speed, resolution, noise level, paper-handling abilities, printing
mechanism and quality and all of these points should be considered when making a
selection. The data received by a printer may be:

   1. a string of characters
   2. a bitmapped image
   3. a vector image

Some printers can process all three types of data, others not.

      Daisy wheel printers can handle only plain text data or rather simple point plots.
      Plotters typically process vector images.
      Modern printing technology, such as laser printers and inkjet printers, can
       adequately reproduce all three.

Printers which are used with computer can be classified in two ways. One way of
classification of printer is how they print:



                                             51      Rajesh Deshmukh – Disha College
                                                       BCA I – Fundamentals Of I.T & O.S

Character Printer: Character printer print one character at a time. Their speed lies in the
range of 30-600 characters per second. It depends upon the type of printer.

Line Printer: Line printers, as the name implies, print an entire line of text at a time. It
make use of a thermal technology. Three principle designs existed.
                               Drum Printer
                               Chain Printer
                               Comb Printer
In drum printers, a drum carries the entire character set of the printer repeated in each
column that is to be printed. The printer recieves all characters to be printed in one line of
the text from the processor. The hammer hit the paper and ribbioon against the desired
character on the drum when it comes in the printing position.


Ribbon                 Synchronied Hammer

                                                                 Paper

                         A B C D E F G H I J--
                         B C D E F G H I J K-
                         ---------------------------
                         Print Cylinder
                         ---------------------------
                         ---------------------------
                         ---------------------------


In chain printers which is also known as train printers, the character set is arranged
multiple times around a chain that travels horizontally past the print line. In either case, to
print a line, precisely timed hammers strike against the back of the paper at the exact
moment that the correct character to be printed is passing in front of the paper. The paper
presses forward against a ribbon which then presses against the character form and the
impression of the character form is printed onto the paper.

Comb printers represent the third major design. These printers were a hybrid of dot
matrix printing and line printing. In these printers, a comb of hammers printed a portion
of a row of pixels at one time. By shifting the comb back and forth slightly, the entire
pixel row could be printed.

Another way of classifying the printer is on the basis of manufacture:

Impact Printer: Impact printer use electromechanical mechanism that causes hammer
or pin to strike against a ribbon and a paper to print the text. A printer that forms an
image on paper by forcing a character image against an inked ribbon. Dot-matrix, Daisy-
wheel etc are impact printer.




                                                52     Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

Non Impact Printer: A printer that creates an image without striking a ribbon against
the paper.It does not use electromechanical printing head to strike against ribbon and
paper.These type of printer use thermal, chemical, electrostatic, laser beam or inkjet
technology for printing the text. A nonimpact printer is faster than impact printer. Non
impact printer include thermal printer, inkjet printer and laser printer. These printer are
all much quieter in operation than impact printer.


2.2.1.1 Dot Matrix Printer
It is a type of impact printer. The term dot matrix printer is specifically used for impact
printers that use a matrix of small pins to create precise dots. The advantage of dot-matrix
over other impact printers is that they can produce graphical images in addition to text;
however the text is generally of poorer quality than impact printers that use letter forms.

In this character is printed by printing the selected no of dots from a matrix of dot. The
formation of a character has been shown 5 dot rows and 7 dot columns. This pattern is
called 5*7 dot matrix. Such printers would have either 9 or 24 pins on the print head.
Print head is that part of the printer that creates the printed image. 24 pin print heads were
able to print at a higher quality. Dot matrix printers were one of the more common types
of printers used for general use - such as for home and small office use. These print
hammer strikes the ribbion individually as the print mechanism that move across the
entire printline in both the directions i.e. from left to right and viceversa. The speed of a
dot matrix printer is about 240 to 4800 words per minutes.

Some dot matrix printers, such as the NEC P6300, can be upgraded to print in color. This
is achieved through the use of a four-color ribbon mounted on a mechanism that raises
and lowers the ribbons as needed. Color graphics are generally printed in four passes at
standard resolution, thus slowing down printing considerably. As a result, color graphics
can take up to four times longer to print than standard monochrome graphics, or up to 8-
16 times as long at high resolution mode.

Dot matrix printers are still commonly used in low-cost, low-quality applications like
cash registers, or in demanding, very high volume applications like invoice printing.

2.2.1.2 Inkjet Printer

It is a type of non impact printer. It is a printer that creates an image by spraying tiny
droplets of ink from the printhead. While many dot matrix printers have 9 to 24 pins,
most ink-jets have printheads with some where between 30 and 60 nozzles, and this
allows them to create high resolution images in a single pass over the paper. Both color
and black-and-white ink jet printers are avaiable.

In ink-jet printer, whenever we want to print the image the nozzel spread the ink, so there
is a permanent remark on the paper. Suppose there is a 5 pin then it spread the ink up to 5
pixels. But it can approximately print up to 16 to 32 pixel at a time.


                                             53      Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S

As you know inkjet printers consist of nozzles that produce very small ink bubbles that
turn into tiny droplets of ink. The dots formed are the size of tiny pixels. Ink-jet printers
can print high quality text and graphics. They are also almost silent in operation. Inkjet
printers have a much lower initial cost than do laser printers, but have a much higher
cost-per-copy, as the ink needs to be frequently replaced.

In inkjet printer the ink is stored in a cartridge.A colour inkjet printer cosist of four
cartridge one each for blue, green, cyan, magenta and black. This system of colour is
called CYMK(K stands for black). Inkjet printers are also far slower than laser printers.

2.2.1.3 Laser Printer

A high-resolution non impact printer that uses a variation of electrophotographic process
which is used in photocopying machines to print the text and graphics on to the paper.
Laser printer are page printer. They make use of laser beam to produce an image of the
page containing text /graphics on a photo sensitive drum. The most common type of
toner-based printer is the laser printer. Laser printers are known for high quality prints,
good print speed, and a low cost-per-copy; they are the most common printer for many
general-purpose office applications. Laser printers are available in both color and
monochrome varieties.

A laser printer uses a rotating disc to reflect laser beam onto a photosensitive drum,
where the image of the page is converted in to an electrostatic charge that attracts and
hod the toner. A piece of charged paper is then rolled against the drum to transfer the
image , and heat is applied to fuse the tonnerand paper together to create the final image.
In simple we can say that, the laser printer consist of a drum coated with photoconductive
material and there is a laser beam, and the control of the laser beam is on to the computer
to turn it either on or off. When the aser beam falls on the drum, then it produces a –ve
potential on it. And the graphite powder has +ve potential, therefore both paper and
powder attracts each other. The powder is attached only where the electric potential is
present, but the powder is also spread on an unwanted area and it is removed by the heat.
The graphite powder is stored in the tonner. The ink is spread through the tonner and it is
spread in an unsaturated form. These type of printer are quite, fast, clean and well
suitedto the home or office environment.

2.2.2 Plotter

A plotter is a vector graphics printing device that connects to a computer. It is an output
device. It is used to produce precise and good quality grphics and drawings under
computer control. Plotters print their output by moving a pen across the surface of a piece
of paper. This means that plotters are restricted to line art, rather than raster graphics as
with other printers. They can draw complex line art, including text, but do so very slowly
because of the mechanical movement of the pens. It is just like dot matrix printer but the
difference is that , in printer the paper has the movement wherease in plotter the pen will
move arround the pape. In this the pen will move in horizontal as well as in vertical



                                             54      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

direction. In plotter only one pin is availale.The pen moves up on the page where we
want to draw the image.

Another difference between plotters and printers is that a printer is aimed primarily at
printing text. This makes it fairly easy to control, simply sending the text to the printer is
usually enough to generate a page of output. This is not the case of the line art on a
plotter, where a number of printer control languages were created to send the more
detailed information like "draw a line from here to here".

Early plotters for e.g. the Calcomp 565 of 1959 worked by placing the paper over a roller
which moved the paper back and forth for X motion, while the pen moved back and forth
on a single arm for Y motion. Plotter draw the graphic faster. Plotters uses inkpen to draw
graphics or drawing. Either single colour or multicolour pen is used. The pen are driven
by motors.The pen potter may be classified in to the following types

Drum plotter: It contain along cylinder and a pen carriage. The paper is placed over the
drum. The drum rotates back and forth. The pen moves horizontally along the surfacei.e
either left to right or right to left.

Flat-Bed Plotter: It uses horizontal flat surface on which paper is fixed and the pen
moves along both the axes i.e. x axis and y axis.

Inkjet Plotter: These plotter uses inkjet in place of ink pens.

2.2.3 VDU

VDU stands for visual display unit. A computer display (also known as a computer
monitor, computer screen, or computer video display) is a device that can display signals
generated by a computer as images on a screen. A visual display terminal contain a key
board for input and visua display unit for output. Quality factors used in monitor are:

      Pixels: It is the smallest unit of monitor which is displayed without disturbing the
       other point .While designning the pixels, some distance between the pixels must
       be there in the horizontal as well as in vertical directin also.
      Aspect Ratio: It is the ratio of the pixels in the horizontal as well as in vertical
       direction also.
      Resolution: No of pixels in a per unit area.
      Refreshing Rate: The rate by which the pixels glow again

                           Refreshing Rate = 1/Refreshing Time

 The visual display unit is known as monitor. Visual display unit is broadly divided into
                                     two categories:

2.2.3.1 CRT Monitors


                                             55      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

CRT stands for the cathode ray tube.To see an image on the screen we have to glow that
part. Energy of the photon goes to the fluroscent material,it produces the light and a point
is introduced on the monitor.CRT makes use of the directing devices to give direction to
the photon otherwise, it will goes towards the center. Some amount of magnetic field is
applied to run photons in correct directions. Magnetic field is nothing but electrical
signls.

                               Coincidentor



                                                                                 Flurosent



Photon gun     Accelerator

                               Horizontal Deflection

                               Vertical Deflection Plates

In thae above diag, there is a photon gun which is used to produce photonsbut the speed
of the generated photon is very slow, therefore to increase its speed,there is an
accelerator. It will give velocity to the photon. Before shifting the photons to different
directions we have to coincident all the photonsat a point and this point is known as
coincidentor. Two horizontal and vertical defection plates is usedto give direction to the
photon in the upward and the downward direction. For colour monitor, 3 electron gun is
used.

Monochrome & Colour Monitors:

Monochrome monitor is a monitor which is capable of displaying only a single colour
image and an RGB monitor is a colour monitor. Both monitors differ in two ways, first,
they have no of electron guns. A monochrome monitor has one electron gun whereas
RGB monitor has 3 electron gun. Secod tscreen in an RGB colour monitor is coated with
3 types of phosphors: red, green, blue. In this each ixel is made up of 3 dots one of each
colour. The 3 electron gun direct their beam togeter. Each gun is aimed precisely so that
it can hit a specific colour dot in each pixel. A wide variety of colour is made by the
combination of gun fire. For eg: if all the three guns are fired at full intensity , aspecific
coour is made, if only two guns are fired with full intensiy and the third gun is fired at
half intensity, an entire different colour is made,. By varying the intensity of the gun,
RGB monitors are capable of displaying a large no of different colour.

2.2.3.2 Non CRT Display




                                              56     Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

   1. LCD: LCD stands for liquid crystal display. In LCD a liquid crystaline material
   is sandwiched between two plate that is made of plastic the front plate is transparent
   and the back plate is reflective.At the back end there is one more field and the
   function of this field is to generate the electric field. Through back panel the light is
   emitted which falls on the crystal then the crystal induces the colour on the screen.
   When the amunt of light source falls then some amount of light source also get
   wasted also. The area around a particular crystal is known as segment.Each and every
   liquid crystal has separate segment area.

   In LCD for colour monitor there is 3 layers which is made up of transparent
   materialand all they are made up of RGB colour. These 3 layers are overlapped with
   one another. Suppose, if we want to emit the light of different colour which is made
   by th mixture of any two colour then it is predecided that what is the proportion of
   each colour to be mixed so that particular colour is made.




       Back panel                                    Front end




                      Side view Of LCD

The Principle advantage of LCD are:

        Lower power consumption.
        Low cost.
        Small size.

The biggest disadvantage of LCD are:

             LCD do not emit light; as a result, the image has very little contrast.
             The screen is very suspectible to glare, so the optimum viewing angle is
              very narrow.
           The resolution is not as good as that of a CRT.
   2. Plasma Display: In this ionized gas is sandwiched between two glass plates. A no
      of parallel wires run horizontally as well as vertically. A small amount of current
      is passed through one horizontal and one vertical wire to cause the gas to glow at
      a spot at the intersection of wires.



                                            57      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

The Principle advantage of gas plasma display are:

       The images are much brighter than on a standard CRT.
       The resolution is excellent.
       The screen does not flicker like some CRTs.

The biggest disadvantage of gas plasma display are:

       Only single colour is available.
       The technology is expensive.
       It uses a lot of power.
       It does not show sharp contra




2.2.4      Speaker
Speaker is one of the output devices which is mainly used for entertainment, video
conferencing etc.Computer speakers, or multimedia speakers, are external speakers and
are usually equipped with a male-end stereo jack plug .The sound capability of the
computer system does not work unless and unti there is a sound card. Speaker recieves
the data from the sound card in the form of electric signal and then convert it in to the
sound format.There are also USB speakers which gain their power from the 5 volts of a
USB port. Computer speakers are usually a simplified stereo system without a radio or
other media sources built in.

Computer speakers range widely in quality and in price. Typically, the simplest computer
speakers come with computers. There are also advanced forms of computer speakers that
have graphic equalization features such as bass, treble, etc for dynamic audio flexibility.
Speaker must have the following features

       An LED, typically green, that acts as a power indicator.


                                            58       Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S

      A 1/8" or even 1/4" headphone jack.
      Dials or buttons for volume, bass, and treble.
      A wired or wireless remote control for volume and power control.

Types Of Cards:


Storage Devices

Storage hardware provides the capability to store the data either temporarily or
permanently. It has much larger capacity than main memory. Secondary memory is also
known as auxiliary memory. The magnetic memory is used as secondary memory. Some
important features of secondary storage devices are:

   1. Permanent: The data, which is stored in these devices, is not lost even when the
      power is switched off.
   2. Voluminous Storage: We can store volume of data and instructions in these
      devices.
   3. Cheaper: These storage devices are cheaper than main memory.
   4. Computing Capability: It is only a storage devices, It does not have any
      capability of executing a program.
   5. Portable: All these devices act as a portable media for transferring the data from
      one system to another.

2.3.1 Some Of The Storage Devices Are:
2.3.1.1 Floppy Disk
Floppy disks, also known as floppies or diskettes. It is small, flexible, faster and cheap
alternative to store data by using magnetic tape. It is made up of a very thin plastic plate
coated with magnetic material like iron-oxide. It is an inexpensive storage devices and
used as a backup memory. In floppy disk, data is recorded in the form of minute invisible
magnetic spot. The thin platic plate i.e. floppy disk is packed in a protective paper or in a
plastic envelope.

The first diskettes were single sided, but when the need to store more data became then
technology has to produce the double sided disk, which is capable of storing the data
twice as that of single sided disk. Double sided disk drives are equipped with read/write
heads for both the top and bottom surface of a disk, so that the data can be read from or
written to both the surface simultaneously.Disk capacity depends on recording density.
Recording density means the no of bits written per inch. The floppy disk has to be
divided in to tracks and sectors.

Tracks:- These are logical concentric circles which start from the edge of floppy disk and
move inwards toward the center of the disk. The traks are numbered.




                                             59      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

Sector:- In these tracks are subdivided in to sectors where data is physically stored and
the amount of data which is to be stored depends on the type of floppy disk. Typically a
disk is divided up into eight or nine sectors, or equal,wedge shaped areas that is used for
storage reference area.

Access Time:- The access time of a disk drive is determined by measuring the time it
takes to performthe following activities like positioning the read write heads over the
proper track which is known as seek time,waiting for the disk to revolve until the correct
sector is reached which is known as latency time,the time taken in placing the read/write
heads, called setting time,and the time taking in transfer the data from disk to computer
main memory.


                                                                          Track


                                                                           Sector




Some of the floppy disk that are commonly used:
   1. 3.5 inches floppy disk
   2. 5.25 inches floppy disk

3.5 inches Floppy Disk

It is introduced in the year 1987 and has the storage capacity of 1.44 MB. In this floppy
disk the read/write head is covered with a sliding metal shield. When the disk is inserted
into the drive, the disk drive pushes the cover aside. There is a write protect notch to store
the information and it can make use of the sliding button, which can slide either of the
two position. One position allows reading, writing and erasing and the other position only
allow reading.




                                             60      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S




The basic internal component of 3.5 inches floppy disk are
1.Write-protect tab
2. Hub
3. Shutter
4. Plastic housing
5. Paper ring
6. Magnetic disk
7. Disk sector

5.25 inches Floppy Disk

It has a storing capacity of 1.2 MB. The protective cover of 5.25 inches is a soft plastic.
Inside the cover there is a white felt liner and these liner helps in rotating the disk
smoothly. In the center there is a drive spindle hole, which is fitted with a plastic hub ring
so that it must be able to protect the edge of the disk. The write protect notch protects the
stored information.




                               Head Slot      Plastic Hub Ring        Write protect notch
Drive Spindle Hole




                                             61      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S


2.3.1.2 Hard Disk

A hard disk drive is also known as hard disk, hard drive, or the now-near-obsolete terms
fixed disk, fixed drive, fixed disk drive, hard file.It is a non-volatile, digitally encoded
data storage device that stores data on the magnetic surfaces of hard disk platters. It
contain more than one disk or platters that is packed together. Unlike floppy disk, it is
fixed,mostly it cannot be inserted or removed from the system.All the platter is packed in
an air tight dust free container. The average access time of hard disk is about 20ms. A
hard disk is also divided into tracks and sector. A low capacity hard disk drive has: 12
recording surface, 256 sectors per track, 5350 tracks per surface and 512 bytes per sector.
It means it has a storing capacity of 8 GB approximately.

 The hard disk uses the rotating platters to store data. Each platter is coated with a smooth
magnetic film structure on each side onto which digital data is stored. Information is
written to the disk at high speed as it rotates past read-write heads that fly very close over
the magnetic surface. The magnetic medium (film) on the disk surface changes its
magnetization in microscopic spots due to the head's write field, which is a strong and
highly localised magnetic field. The information can be read back by a magnetic sensor.
The read sensor detects the magnetic flux emanating from the transitions passing
underneath it through a small change of the MR(magnetoresistive) sensor's electric
resistance and this is converted by electronics into a stream of 1's and 0's. There is one
head for each magnetic platter surface on the spindle, mounted on a common arm. The
actuator arm moves the heads on an arc (roughly radially) across the platters. The
associated electronics control the movement of the actuator and the rotation of the disk,
and perform reads and writes on demand from the disk controller.




 The inside of a hard disk drive with the platter. To the left there is a read-write arm. In
the middle the electromagnets of the platter's motor can be seen. In a hard disk , the disk
 is addressed by the drive no, cylinder no, surface no, and sector no. There is a separate
      read/write head is available for each of the platters as shown in the diagram:




                                             62      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S




                               2.3.1.3 Compact Disk
A Compact Disc (CD) is an optical disc used to store digital data, originally developed
for storing digital audio. An audio compact disc consists of one or more stereo tracks
stored using 16-bit PCM coding at a sampling rate of 44.1 kHz. Standard compact discs
have a diameter of 120 mm or 80 mm. The 120 mm discs can hold approximately 80
minutes of audio. The 80 mm discs, sometimes used for CD singles, hold approximately
20 minutes of audio. Compact disc technology was later adapted for use as a data storage
device, known as a CD-ROM, and to include record-once and re-writable media (CD-R
and CD-RW). CD-ROMs and CD-Rs remain widely used technologies in the personal-
computer industry as of 2006.




Compact discs are made from a 1.2 mm thick disc of very pure polycarbonate plastic. A
thin layer of Super Purity Aluminium is applied to the surface to make it reflective, which
is protected by a film of lacquer. The lacquer can be printed with a label. Common
printing methods for compact discs are silk screening and offset printing. CD data is
stored as a series of tiny indentations (pits), encoded in a tightly packed spiral track of
pits moulded into the top of the polycarbonate layer. The areas between pits are known as
'lands'. Each pit is approximately 100 nm deep by 500 nm wide, and varies from 850 nm
to 3.5 μm of length. The spacing between the tracks, the pitch, is 1.6 μm. A CD is read by
focusing a 780 nm wavelength semiconductor laser through the bottom of the
polycarbonate layer. The difference in height between pits and lands leads to a phase
difference between the light reflected from a pit and from its surrounding land. By
measuring the intensity with a photodiode, one is able to read the data from the disc. The
pits and lands themselves do not directly represent the zeroes and ones of binary data. A



                                            63     Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S

change from pit to land or land to pit indicates a one, while no change indicates a zero.
The main parameters of the CD are

      Scanning velocity: 1.2–1.4 m/s which is equivalent to approximately 500 rpm at
       the inside of the disc, and approximately 200 rpm at the outside edge.
      Track pitch: 1.6 μm.
      Disc diameter 120 mm.
      Disc thickness: 1.2 mm.
      Inner radius program area: 25 mm.
      Outer radius program area: 58 mm.

Capacity

A standard 120 mm CD-ROM holds 650 or 700 MiB of data. To put this storage capacity
into context, the average novel contains 60,000 words. Assume that average word length
is 10 letters and that each letter occupies one byte. A novel therefore might occupy
600,000 bytes (600 kB, without layout information). One CD can therefore contain over
1,000 novels. If each novel occupies at least one centimetre of bookshelf space, then one
CD can contain the equivalent of over ten metres of bookshelf. However textual data can
be compressed by more than a factor of ten, using compression algorithms, so a CD-
ROM can accommodate at least 100 metres of bookshelf space.



CD ROM Operation:

CD-ROM is a reflective light system, where laser light is shone against turns of track
which are encoded with digital data using pits and areas of lands. Pits scatter the laser
light, while areas of land produces reflected light. Reflected light is diverted to a
photodetector that produces a series of electric pulses corresponding to encoded data.

A CD_ROM disc rotats at a speed to provide a constant avearge read rate of around 75
blocks/second. Because data is embedded in the track of a CD-ROM at a uniform density,
the disc must spin faster when the read head converges on its center. The required
constant linear velocity is achieved by coordinating the position of the read head with
speed of rotation using a simple feedback system.

CD-ROM Standards:

Origins Of CD-ROM:

2.3.1.4 Magnetic Tape
Magnetic tape is a non-volatile storage medium consisting of a magnetic coating on a thin
plastic strip. Nearly all recording tape is of this type, whether used for video, audio
storage or general purpose digital data storage using a computer. Magnetic tape was first


                                           64     Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S

invented for recording sound by Fritz Pfleumer in 1928 in Germany, based on the
invention of magnetic wire recording by Valdemar Poulsen in 1898. The use of magnetic
tape for data storage has been one of the constants of the computer industry. The tape is
nothing but a stripof plastic coated with a magnetic recording medium.Data are
recordedas magnetic spots on the tape. In magnetic tape the information is recorded in
blocks reffered to as a record. A tape unit is addressed by specifying the record no and
the no of characters in the record. Record may be fixed or variable length.




Advantages

      Large amount of data can be stored.
      The tape is very easy and convenient to handle
      The tape is reusable, fast and saves time
      The tape is very economical.

Disadvantages

    Humans cannot read the data directly because it is stored as magnetic spots.
    Access of data from magnetic tape is sequential.Therefore, it takes much time in
     retrieving the data in saome cases, or searhing becomes difficult.
    Magnetic tape is sensitive to certain environmental factor like dust, temperature
     and moisture.

2.3.1.5 DVD

DVD is also known as "Digital Versatile Disc" or "Digital Video Disc". It is an optical
disc storage media format that can be used for data storage, including movies with high
video and sound quality. DVDs resemble compact discs as their physical dimensions are
the same (120 mm (4.72 inches) or occasionally 80 mm (3.15 inches) in diameter) but
they are encoded in a different format and at a much higher density. It is able to hold
about 15 times more information and transfer it to the computer about 20 times faster
from CD-ROM.DVD comes in some format:

DVD-Video : DVD-Video discs require a DVD-drive and an MPEG-2 decoder e.g. a
DVD-player, or a DVD computer drive with a software DVD player. It is mostly used for



                                           65     Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S

entertainment like seeing movies etc. The specifications for video files on a DVD can be
any of the following:

      Up to 9.8 Mbit/s (9800 kbit/s) MPEG-2 video
      Up to 1.856 Mbit/s (1856 kbit/s) MPEG-1 video

DVD-ROM: The abbreviation stands for DVD-Read only memory format. It is mostly
used in computer to store data. Through this we are able to play games as well as able to
see certain movies.

DVD-R: It is a recordable DVD. The user can write data once and abe to read the da the
data as many times as desired.

2.3.1.6 Zip Drive

The Zip drive is a medium-capacity removable disk storage system, introduced by
Iomega in late 1994. Originally it had a capacity of 100 MB, but later versions increased
this to first 250 MB and then 750 MB. The original Zip drive had a data transfer rate of
about 1 megabyte/second and a seek time of 28 milliseconds on average, compared to a
standard 1.44 MB floppy's 500 kbit/s (62.5 kB/s) transfer rate and several-hundred
millisecond average seek time. Zip media is thicker, but otherwise similar in size to 3.5"
(9 cm) floppy disks, which means the drive slot is large enough to accept such a floppy.
To prevent drive and disk damage, the underside of Zip media cases include a
retroreflective spot in one corner.

Higher capacity Zip disks must be used in a drive with at least the same capacity ability.
Generally, higher capacity drives also handle all lower capacity media, although the
250 MB drive is much slower than the 100 MB one to write data on a 100 MB disk. The
750 MB drive, however, cannot write to the 100 MB media, which is the cheapest and
most common.

The Zip system also introduced media access protection via a password. Like write
protection, this is also implemented on the software level. When a disk is inserted, the
Zip drive reads the metadata; if the data indicates the disk should be read-locked, the
drive awaits a password from the computer. Until it receives such a password, the drive
pretends to still be empty. Once the password has been sent and verified, the drive
"activates" the disk in the drive and allows access. One side effect of this implementation
is that, on some drive models, it is possible to trick the software into allowing access to a
different disk than it believes to be in the drive, thereby bypassing the password
protection.

Graphical Display Devices: Under this we have to discuss about CRT.

Graphical Input Devices: Under this we have to discuss the below specified input
devices which we have discussed earlier.




                                             66      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S

Keyboard
Mouse
Joystick
Trackball
Digitizer

Three Dimensional Input Devices
   •   Accoustic devices: It consist of accoustic tablet. To measure the styulus position
       in 3 dimension.we can use 3 microphones aligned with the axes.
   •   The perpendicular distances of the stylus from these microphones can be
       determined from 3 arrival times and from these 3 distances the stylus coordinate
       can be computed.
   •   Mechanical Devices: Three dimensional coordinate input can also be achieved
       with the aid of mechanical linkage of various kinds.
   •   The simplest of these uses wires strectching from spring loaded reels mounted at
       fixed position.


UNIT 2 OPERATING SYSTEM
As a scheduler/allocator:

      The operating system has resources for which it is in charge. Responsible for
       handing them out (and later recovering them).
      Resources include CPU, memory, I/O devices, and disk space.

As a virtual machine:

      Operating system provides a "new" machine.

       This machine could be the same as the underlying machine. Allows many users to
       believe they have an entire piece of hardware to themselves.

       This could implement a different, perhaps more powerful, machine. Or just a
       different machine entirely. It may be useful to be able to completely simulate
       another machine with your current hardware. Example of upgrading to a new
       piece of hardware. This can get out of hand. E.g., 1401 -> 360 -> 370 -> 3081.

As a multiplexor:

      Allows sharing of resources, and provides protection from interference.
      Provides for a level of cooperation between users.
      Economic reasons: we have to take turns.




                                           67     Rajesh Deshmukh – Disha College
                                                       BCA I – Fundamentals Of I.T & O.S




According to these three views, if:

      we had enough hardware to give everyone too much;
      the hardware was well designed;
      the communications problem -- how to share knowledge -- is solved;

then we would not need operating systems. My view of operating systems says that they
will still be needed:

As a servant and provider of services:

      Need to provide things like in the above views, but deal with environments that
       are less than perfect. Help the users use the computer by:

       providing commonly used subroutines;

       providing access to hardware facilities;

       providing higher-level "abstract" facilities;

       providing an environment which is easy, pleasant, and productive to use.

This view as a provider of services fits well with our modern network view of computing,
where most resources are services.



What are the desirable qualities of an operating system? We can discuss them in terms of:
Usability, Facilities, Cost, and Adaptability.

      Usability:
          o Robustness
              accept all valid input without error, and gracefully handle all invalid
              inputs
          o Consistency
              E.g., if "-" means options flags in one place, it means it in another. Key
              idea: conventions. Concept: The Principle of Least Astonishment.
          o Proportionality
              Simple, cheap and frequent things are easy. Also, expensive and
              disastrous things (rm *) are hard.
          o Forgiving
              Errors can be recovered from. Reasonable error messages. Example from
              "rm"; UNIX vs. TOPS.




                                             68        Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S

           o   Convenient
               Not necessary to repeat things, or do awkward procedures to accomplish
               things. Example copying a file took a batch job.
          o Powerful
               Has high level facilities.
      Facilities
          o Sufficient for intended use.
          o Complete.
               Dont leave out part of a facility. E.g., protection with
          o Appropriate.
               Do not use fixed-width field input from terminal.
      Costs
          o Want low cost and efficient services.
          o Good algorithms.
               Make use of space/time tradeoffs, special hardware.
          o Low overhead.
               Cost of doing nothing should be low. E.g., idle time at a terminal.
          o Low maintenance cost.
               System should not require constant attention.
      Adaptability
          o Tailored to the environment.
               Support necessary activities. Do not impose unnecessary restrictions.
               What are the things people do most -- make them easy.
          o Changeable over time.
               Adapt as needs and resources change. E.g., expanding memory and new
               devices, or new user population.
          o Extendible-Extensible
               Adding new facilities and features - which look like the old ones.



Two main perspectives of an operating system:

      Outside - depends on your level of sophistication.

       A system to compile and run Java programs

       Your average introductory Computer Sciences student.

       A system with many facilities - compilers, databases, file systems, system calls.

      Inside - internals, code, data structures.

       This is the system programmers view of an operating system. At this level you
       understand not only what is provided, but how it is provided.




                                             69     Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S


System Software
As you know that, a set of programs written for the computer is called software. The
software required to execute user program is called system software. This software
controls all processing activities and make sure that resources and the power of the
computer are used in most efficient manner. The major purpose of system software is it
controls the execution of program and helps in the development of software.

System software helps in running the computer hardware and computer system. It
includes operating systems, device drivers, diagnostic tools, servers, windowing systems,
utilities and more. The purpose of systems software is to insulate the applications
programmer as much as possible from the details of the particular computer complex
being used, especially memory and other hardware features, and such accessory devices
as communications, printers, readers, displays, keyboards, etc. System software can be
classfied into two categories.

        Operating System
        Language Processor

A.       Operating system
An operating system is a program that acts as an intermediate between the user and
computer hardware. It is a computer program that manages the hardware and software
resources of a computer. At the foundation of all system software, the OS performs basic
tasks such as controlling and allocating memory, prioritizing system requests, controlling
input and output devices, facilitating networking, and managing files. It also may provide
a graphical user interface for higher level functions. The purpose of an operating system
is to provide an environment. In which user can execute the program.

Modern general-purpose computers, including personal computers and mainframes, have
an operating system to run other programs, such as application software. Examples of
operating systems for personal computers include Microsoft Windows, and Linux. The
primary goal of an operating system is thus to make the computer system convenient to
use. A secondary goal is to use the computer hardware in an efficient manner.

                                          User

             Compiler         Assembler   Text editor    Database system



                                  Application Program
                                  Operating system




                                            70     Rajesh Deshmukh – Disha College
                                                 BCA I – Fundamentals Of I.T & O.S



                                   Computer
                                   Hardware



When the hardware provides the basic computing resources, then the application program
defines the way in which these resources are used to solve certain problem. Operating
system controls and coordinates the use of hardware among the application program.
Efficiency of operating system can be measured on the basis of following 3 factors.

   4. Turn around time : It is the time delay between the submission and completion of
      any job.
   5. Response time: It is the time taken by the system to give first response.
   6. Throughput: It is the no of job executed in an unit time.

Computer Software:

B. Language Processor

When a program written in a language other than the machine language of computer, the
computer will not understand it. Hence, the program written in other language must be
translated into the machine language of the computer. Such translation is done with the
aid of software. This type of software is known as language processor.

A Compiler
A compiler is a computer program or set of programs that translates text written in a
computer language i.e. in the source language into another computer language i.e. the
target language. The original sequence is usually called the source code and the output
called object code. The most common reason for wanting to translate source code is to
create an executable code. The name "compiler" is primarily used for programs that
translate source code from a high level language to a lower level language or machine
language. A program that translates from a low level language to a higher level one is a
decompiler. A compiler is likely to perform many or all of the following operations:
lexing, preprocessing, parsing.

Early computers did not use compilers. Compilers had not yet been invented because
early computers had very little memory and programs were necessarily quite short. Users
often entered the decimal or binary machine code for a program. With the evolution of
programming languages and the increasing power of computers, compilers are becoming
more and more complex to bridge the gap between problem-solving modern
programming languages and the various computer.

A compiler is itself a computer written in some implementation language. Early
compilers were written in assembly language. The first self-hosting compiler which is


                                          71      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

capable of compiling its own source code in a high-level language — was created for
Lisp.

      A program that translates from a low level language to a higher level one is a
       decompiler.
      A program that translates between high-level languages is usually called a
       language translator.

Most compilers are classified as either self-compilers or cross compilers. If a compiler
run on a computer for which it produces the object code, then it is known as self-
compiler. If a compiler run on a computer other than that for which it produces the object
code, then it is known as cross compiler.


B Assembler

A program that converts an assembly language program into machine language so that
computer can run the program. As you know that assembly language program can be
written by making use of mnemonic code (symbolic code). The use of symbolic
references is a key feature of assemblers, saving tedious calculations and manual address
updates after program modifications. Assemblers are available since the 1950s. An
assembler, which runs on the computer for which it produces the object code, is called
self-assembler. The assembler runs on the computer other than that for which it produces
the object code is called cross assembler. There is two types of assembler, first is one
pass assembler, it is an assembler which read the program once and assign addresses to
the labels used in assembly language program. Second is Two pass assembler, which
goes to the program twice, in first pass it will assign address to the labels and in the
second pass it will convert each assembly language instruction into machine language
instruction.

More sophisticated High-level assemblers provide language abstractions such as:

      Advanced control structures.
      High-level procedure/function declarations and invocations.
      High-level abstract data types, including structures/records, unions, classes, and
       sets.
      Sophisticated macro processing.

C Interpreter
An interpreter is a program which translates a high level language rogram into machine
level language. It translates one instruction of a program at a time. If it is correct then
only it proceeds towards the next instruction. It reads the instruction, translate it,and after
that it executes the instruction. An interpreter is a smaller program as compared to the
compiler. It occupy less memory space. Interpreting code is slower than running the


                                              72      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S

compiled code because the interpreter must analyse each statement in the program each
time it is executed and then perform the desired action whereas the compiled code just
performs the action. Access to variables is also slower in an interpreter because the
mapping of identifiers to storage locations must be done repeatedly at run-time rather
than at compile time. The IBM 550 Numeric Interpreter and IBM 557 Alphabetic
Interpreter are typical examples of the interpreter.

1.10.2 Application Software
Application software allows humans to accomplish one or more specific tasks.It is a set
of program that is necessary to carry out operation for a specified application. Typical
applications include industrial automation, business software, educational software,
medical software, databases. Almost every field of human activity now uses some form
of application software. It is used to automate all sorts of functions.

Application software or Applications are what most people think of when they think of
software. Application software is often purchased separately from computer hardware.
Sometimes applications are bundled with the computer, but that does not change the fact
that they run as independent applications. Applications are almost always independent
programs from the operating system

Customized Application software: The software which is developed to meet all the
requirement specified by the user.

General Application software: The software which is developed by keeping all the
general requirements in mind for carrying out a specific task.These are those software
which are developed by the group of people or an individual to be use by the other.For
e.g. word processing software, Electronic spread sheet etc.

1.10.2.1        Application software consist of Packages and Business
software.

A Packages

Software package, in computing, a type of file format where software installation
material is grouped together. A software package is a bundle of one or several files that
either are necessary for the execution of a computer program, or add features for a
program already installed on the computer or network of computers. Software packages
can either be in a standardised package format to be installed by a program that is
integrated with the operating system, or be a self-sufficient installer.

The term software package is also used in object-oriented programming to name a group
of related classes of a program. In this, meaning of packages are especially useful to
measure and control the inherent coupling of a program. Some most common packages
that are mostly used are:



                                           73     Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S


      Word Processor
      Electronic Spreadsheet
      Database Management System
      Desktop publishing

Word Processor

It is an application program designed to replace a typewriter. A word processor manages
text-based documents. It allows the user to enter, edit, view, store and retrieve the text
material. These text material may be letter, reports, or book etc. It is very easy to make
corrections in the data which is written there. Editing in the documents like to insert or
delete a word or sentences from the document can be done very easily.

In word processing, there is automatic flowing of text on to the next line as new text is
inserted. It means, when an operator enters the character to the document and as soon
they reached at the end of the line the word processor program automatically moves the
text to the next line. This feature of the word processing is known as word wrap. Word
wrap ensures that the text stays inside the designated document boundaries or margins.
Word processing program also provides us certain features like boldface, italic,
superscript, sub script etc. It also provide certain alignment like left, right, center.

Word processor vary from simple to the complex. An advanced word processor must
contain all the features needed for entering, editing and formatting the text as well as
support macros to simplify complex or routine task. It also include facility for spell
checking (speling check), dictionary etc.WordPerfect from Word Perfect Corporation and
Microsoft word are examples of fully featured word processor.

Electronic Spreadsheet
A spreadsheet is a rectangular table (or grid) of information, which is often used for
giving financial information. The word came from "spread" in its sense of a newspaper
or magazine item (text and/or graphics) that covers two facing pages, extending across
the center fold and treating the two pages as one large one. The compound word "spread-
sheet" came to mean the format used to present bookkeeping, ledgers.

One of the first commercial uses of computers was in processing payroll and other
financial records, so the programs were designed to generate reports in the standard
"spreadsheet" format, bookkeepers and accountants used it. The generally recognized
inventor of the spreadsheet as a commercial product for the personal computer is Dan
Bricklin. The spreadsheet or work sheet consists of rows and columns of cells. The rows
are usually identified by numbers, and columns by letters. Each cell can hold a numeric
value, text label or a formula that produces values contained in other cells.

Many people find it easier to perform calculations in spreadsheets than by writing the
equivalent sequential program. This is due to two traits of spreadsheets.



                                           74      Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S


      They use spatial relationships to define program relationships. Like all animals,
       humans have highly developed intuitions about spaces, and of dependencies
       between items.
      They are forgiving, allowing partial results and functions to work. One or more
       parts of a program can work correctly, even if other parts are unfinished or
       broken. This makes writing and debugging programs much easier, and faster.
       Sequential programming usually needs every line and character to be correct for a
       program to run. One error usually stops the whole program.

In a spreadsheet, however, a set of cells is defined, with a spatial relation to one another.
In the earliest spreadsheets, these arrangements were a simple two-dimensional grid.
Over time, the model has been expanded to include a third dimension also which is
known as 3-D spreadsheet. Lotus 1-2-3 from Lotus Development Corp, Quattro Pro
developed by Borland International and Microsoft Excel are examples of spreadsheet
programs. Some of the problems associated with spreadsheets are:

      Lack of auditing. This makes it difficult to determine who changed what and
       when.
      Lack of security. Generally, if one has permission to open a spreadsheet, one has
       permission to modify any part of it. This, combined with the lack of auditing
       above, can make easy for someone to commit fraud.
      Lack of concurrency. Unlike databases, spreadsheets typically allow only one user
       to be making changes at any given time.

Database Management System

It is an application software that controls the data in the database, including overall
organization, storage, security, data integrity.A database management system (DBMS) is
a system or software designed to manage a database, and run operations on the data
requested by numerous clients. Typical examples of DBMS use include accounting,
human resources and customer support systems. A DBMS is a complex set of software
programs that controls the organization, storage and retrieval of data in a database. The
DBMS accepts requests for data from the application program and instructs the operating
system to transfer the appropriate data.

When a DBMS is used, information systems can be changed much more easily as the
organization's information requirements change. New categories of data can be added to
the database without disruption to the existing system. Database servers are specially
designed computers that hold the actual databases and run only the DBMS and related
software.

Features Of DBMS

      Persistence - Attributes are permanently stored on a hard-drive or other fast,
       reliable medium until explicitly removed or changed.



                                             75      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S


      Concurrency - Many people may want to change and read the same attributes at
       the same time. For example, if you change the color attribute of car 7 to be "blue"
       at the very same time somebody is changing it to "red", then you may not see
       your change when you go to view the attributes of the car you thought you just
       changed. DBMS provide various tools and techniques to deal with such issues.
       "Transactions" and "locking" are two common techniques for concurrency
       management.
      Security - Often it is desirable to limit who can see or change which attributes or
       groups of attributes.
      Computation - There are common computations requested on attributes such as
       counting, summing, averaging, sorting, grouping, cross-referencing, etc can be
       done.
      Meta-data Repository - Meta-data is information about information. For
       example, a listing that describes what attributes are allowed to be in data sets is
       called "meta-information".

A DBMS can also format reports for printed output , and import and export data from
other application programs by making use of standard file format. A data manipulation
language is also provided to support queries against the database.

Utility Software
It is a set of program, that supports the operating system by providing the additional
services that the operating system does not provide. There are many task which are
performed by utility programs are hard disk backup, disk optimization, file recovery, safe
formatting and resource editing.

Utility software is also known as service program, or utility routine. It is specifically
designed to help in managing and tune the computer hardware, operating system or
application software, and perform a single task or a small range of tasks.Some important
utilities are bein discussed below:

      Disk defragmenters/Disk management tools Disk defragmenter can detect
       computer files whose contents have been stored on the hard disk in disjointed
       fragments, and move the fragments together to increase efficiency. There is a
       Disk checker which can scan the contents of a hard disk to find files or areas that
       are corrupted in some way, or were not correctly saved, and eliminate them for a
       more efficiently operating hard drive. A Disk cleaner can find files that
       unnecessary to computer operation, or take up considerable amounts of space.
       Disk cleaner helps the user to decide what to delete when his hard disk is full. To
       start disk defragmentation we have to click start>Programs>Accessories>System
       tools>Disk Defragmentation. It will show like this




                                           76      Rajesh Deshmukh – Disha College
                                                 BCA I – Fundamentals Of I.T & O.S




    Virus scanners/Antivirus. Virus Scanners scan for computer viruses among files
     and folders. Virus is a program intended to damage your computer sytem without
     your knowledge and belief. A virus may itself attach to another programon your
     hard disk and when the date passes, or a certain event occurs, the virus is trigerred
     into action. The most famous virusis jerusalem virus, which is also known as
     Friday the 13th, first seenat the university of jerusalem in july 1987. The virus
     slow down the system. There are several precautions that you can take to protect
     yoursef from infection, including backing up your system on the regular basis ,
     and you can also buy and run the commercially available virus detecting program.

                                 Antivirus is an application program that can detect and
    eliminate the computer virus. Some antivirus program can detect suspicious activity
    on your computer as it happens. While, the other must be run periodically. The
    antivirus program locates and identifies a virusby looking some of the
    characteristics, like unexpected disk access. It recognizes the virusby comparing the
    information from the system against the database of known virus that is kept n the
    disk. There are several simple precautions that you can take to minimize your
    chances of contracting a virus:

         1. Back up your hard disk regularly.
         2. Do not install software if you don’t know where it’s been or where it came
              from.
         3. Write protect disks as soon as you get them.
    Compression utilities output a shorter stream or a smaller file when provided
     with a stream or file. A file that has been processed by a special utility programso
     that it occupies a little hard disk space. When the file is needed, the same program
     decompresses the file back into its original form so that it can be read by the
     computer. Two kind of file file compression program are available those program


                                          77      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S

       that cancompress more than one file at a time such as winzip. Those program that
       can compress al the files on a specific disk.Any method of encding data so that it
       occupies less space than its original form.

      File Management tools A file manager or file browser is a computer program
       that provides a user interface to work with file systems. They are very useful for
       speeding up interaction with files. The most common operations on files are
       create, open, edit, view, print, play, rename, move, copy, delete, attributes,
       properties, search/find, and permissions.

Encryption utilities use a specific algorithm to produce an encrypted stream or encrypted
file when provided with a key and a plaintext


A Compiler

A compiler is a computer program or set of programs that translates text written in a
computer language i.e. in the source language into another computer language i.e. the
target language. The original sequence is usually called the source code and the output
called object code. The most common reason for wanting to translate source code is to
create an executable code. The name "compiler" is primarily used for programs that
translate source code from a high level language to a lower level language or machine
language. A program that translates from a low level language to a higher level one is a
decompiler. A compiler is likely to perform many or all of the following operations:
lexing, preprocessing, parsing.

Early computers did not use compilers. Compilers had not yet been invented because
early computers had very little memory and programs were necessarily quite short. Users
often entered the decimal or binary machine code for a program. With the evolution of
programming languages and the increasing power of computers, compilers are becoming
more and more complex to bridge the gap between problem-solving modern
programming languages and the various computer.

A compiler is itself a computer written in some implementation language. Early
compilers were written in assembly language. The first self-hosting compiler which is
capable of compiling its own source code in a high-level language — was created for
Lisp.

      A program that translates from a low level language to a higher level one is a
       decompiler.
      A program that translates between high-level languages is usually called a
       language translator.

Most compilers are classified as either self-compilers or cross compilers. If a compiler
run on a computer for which it produces the object code, then it is known as self-


                                           78     Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

compiler. If a compiler run on a computer other than that for which it produces the object
code, then it is known as cross compiler.


Compiled versus interpreted languages
Many people divide higher-level programming languages into compiled languages and
interpreted languages. However, there is rarely anything about a language that requires it
to be compiled or interpreted. Compilers and interpreters are implementations of
languages, not languages themselves. The categorization usually reflects the most popular
or widespread implementations of a language -- for instance, BASIC is thought of as an
interpreted language, and C a compiled one, despite the existence of BASIC compilers
and C interpreters.

There are exceptions; some language specifications spell out that implementations must
include a compilation facility (eg, Common Lisp), while other languages have features
that are very easy to implement in an interpreter, but make writing a compiler much
harder; for example, SNOBOL4, and many scripting languages are capable of
constructing arbitrary source code at runtime with regular string operations, and then
executing that code by passing it to a special evaluation function. To implement these
features in a compiled language, programs must usually be shipped with a runtime
environment that includes the compiler itself.

B Assembler
A program that converts an assembly language program into machine language so that
computer can run the program. As you know that assembly language program can be
written by making use of mnemonic code (symbolic code). The use of symbolic
references is a key feature of assemblers, saving tedious calculations and manual address
updates after program modifications. Assemblers are available since the 1950s. An
assembler, which runs on the computer for which it produces the object code, is called
self-assembler. The assembler runs on the computer other than that for which it produces
the object code is called cross assembler. There is two types of assembler, first is one
pass assembler, it is an assembler which read the program once and assign addresses to
the labels used in assembly language program. Second is Two pass assembler, which
goes to the program twice, in first pass it will assign address to the labels and in the
second pass it will convert each assembly language instruction into machine language
instruction.

More sophisticated High-level assemblers provide language abstractions such as:

      Advanced control structures.
      High-level procedure/function declarations and invocations.
      High-level abstract data types, including structures/records, unions, classes, and
       sets.
      Sophisticated macro processing.


                                            79      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S


C Interpreter

An interpreter is a program which translates a high level language rogram into machine
level language. It translates one instruction of a program at a time. If it is correct then
only it proceeds towards the next instruction. It reads the instruction, translate it,and after
that it executes the instruction. An interpreter is a smaller program as compared to the
compiler. It occupy less memory space. Interpreting code is slower than running the
compiled code because the interpreter must analyse each statement in the program each
time it is executed and then perform the desired action whereas the compiled code just
performs the action. Access to variables is also slower in an interpreter because the
mapping of identifiers to storage locations must be done repeatedly at run-time rather
than at compile time. The IBM 550 Numeric Interpreter and IBM 557 Alphabetic
Interpreter are typical examples of the interpreter.

Difference Between Compiler & Interpreter

                Compiler                                        Interpreter


Scans the entire program first and translate Translates the program line by line.
it in to machine code.
Compiler produces object code.               During conversion, the interpreter does not
                                             produce its object code.
Converts the entire program to machine Each time the program is executed, every
code; when all the syntax errors are line is checked for syntax error and then
removed, execution takes place.              converted to equivalent machine code.
Slow for debugging (removal of mistakes Good for fast debugging
from the program).
Execution time is less                       Execution time is more.




Introduction To DOS
DOS commonly refers to the family of closely related operating systems which
dominated the IBM PC compatible market between 1981 and 1995. This is a single user,
single task systems. MS-DOS from Microsoft was the most widely used. The first
version, PC-DOS 1.0, was released in August, 1981. It supported up to 256 kB of RAM
and two 160 kB 5.25" single sided floppy disks.

In May 1982, PC-DOS 1.1 added support for 320 kB double-sided floppy disks. PC-DOS
2.0 and MS-DOS 2.0, released in March 1983, were the first versions to support the
PC/XT and fixed disk drives. Floppy disk capacity was increased to 180 kB (single sided)
and 360 kB (double sided) by using nine sectors per track instead of eight.


                                              80      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S



Important Terms That You Are Using wioth DOS
Program: It is a set of instruction written in computer languages. These instructions are
stopred in filers ad tells your computer to perform a task.

File: A file is a collection of related information. File on disk can also contaion letters,
memos, data, program etc. there are three types of files:

Text Files
Command Files
Application Program Files

      Text files are data files that contain characters, numbers and symbols.
      A set of DOS commands put together to perform a specific task which can laterbe
       stored in a text file called command files.
      An Application program files such as word processor, it stores our work, such as
       documents in data files,

Directory: A directory contain an entry for each file that gives the file name,
extension,size, date & time it was created or last modified.

File Name: A file name consist of two parts i.e. the name of the file & its extension. A
file name can be up to eight characters long and can be typed into upper case or lower
case letter. DOS automatically converts the lower case letter into upper case letter.

                                   Filename.Extension

3.6.1 Types Of Command
In MS-DOS all the command are categorized into two main category. They are:

Internal Command
External Command

Internal Command
These are the commands which resides in a portion of the computer memoryand are
loaded along with the operating system into the memory. These files are always available
for execution.

The internal commands are part of DOS' COMMAND.COM file. If you delete
COMMAND.COM, you can no longer command DOS to do anything at the command
line. Internal command is a command that has the capability to run within DOS at all
times, such as Dir, Copy, Del, Ren, Type and Cls. The other kind of commands DOS can
execute are external commands. Each external command, such as Format, Xcopy and


                                            81      Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S

Backup, resides in its own file in the DOS directory. If any of those files are deleted
accidentally or purposefully, you can still execute all of DOS' internal commands and any
external commands that are still left on disk.

External Command
These are the commands which have to be loaded from the disk into the memory of the
computer before we want to execute them. A separate utility program that comes with
DOS, such as Format, Diskcopy, XCopy, Tree, Backup and Restore, but is not resident
within DOS, such as Copy and Dir. The directory that contains these programs should be
on the path so that you can run them no matter which directory you're in.

Internal DOS Command
   1. MD and MKDIR

   This command is used to Make a Directory. You type MD followed by a file name.
   You can nest the directory i.e. Make a directory within a directory up to 16 directories
   on most DOS only systems. Some will let you nest up to 32. Syntax for this is:

                                  C:\> md directory-name

   For Eg:

   C:\> md windows

   2. CD and CHDIR

   This command lets you change directories. The syntax for this is:

                                      C:\> cd directory-name

   For Eg:

   Lets say you are at root (Just a "C:\>" prompt) and you want to get into a directory
   named WINDOWS. Type the following:

   C:\>cd windows
   You will get a prompt like this:
   C:\WINDOWS>

   You need to get back to your root directory, and quick! Type "CD.." and you will be
   magically transported back to root.

   3. COPY


                                              82     Rajesh Deshmukh – Disha College
                                                BCA I – Fundamentals Of I.T & O.S

This command is used to copy a file from one place to another. The syntax for this
command is:

                     Copy Source-filename Destination-filename

For Eg:

C:\copy mystuff.doc A:

This example will copy "mystuff.doc" to your A: drive.

C:\copy mystuff.doc A:\stuff.doc

This copies "mystuff.doc" to the A: drive and renames it to "stuff.doc".

You want to combine two plain text files into one big happy file. This will
accomplish that:

C:\copy mystuff.doc+herstuff.txt C:\house\ourstuff.yea

Certain options that are used in the copy command are:

/A: The switch /A treats a file like an ASCII text file. This means that if the file has
an End-Of-File character in the middle of it everything up until the [E-O-F] character
will be copied. Anything after that will be chopped off.

/B: The switch /B treats the file like a binary file and will copy EVERY THING up
the specified file length to the destination. Using the /B switch will ignore all control
characters including End Of File markers.

/V: Switch /V makes COPY VERIFY if it correctly made a copy to the destination.

4. TYPE
This command will dump the contents of a text file to your screen. When you use the
TYPE command, the file is displayed with limited on-screen formatting. Tabs are
expanded and generally displayed as eight spaces wide. If you display files that
contain special (non-text) characters, these characters may have unpredictable effects
on your display. Wild card characters (? and *) cannot be used with this command in
either the filename or the extension. Syntax for this is:

                               TYPE [d:][path]filename

For Eg:




                                         83      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S

C:\>type bill.txt
Bills stuff document.
Bill has 2 things:
1 basket ball
1 used sock
C:\>

This should mostly be used on plain ASCII text files. While you can use TYPE to
print out an executable program to the screen, it will be a bunch of junk and you'll get
a lot of annoying beeps. TYPE will stop printing a file to your screen when it
encounters an End-Of-File character.

5. DEL/ERASE

DEL and ERASE do the exact same thing. This command is used to delete a file. We
can also erase one or more files at a time using the wild cards. But one has to be very
careful while using wild cards because it will erase all the files mentioned in the
specification.

Syntax:

                              DEL[d:][path]filename.ext

For Eg:

C:\> abc.txt
DOS immediately replies with
ARE YOU SURE (Y/N)

6. CLS

This command clears the screen. It also places your cursor at the top left-hand corner
of your screen.

Syntax:

                                         CLS

7. VOL
VOL will tell you the volume label of your hard drive or floppy disk. On DOS 5 and
up it will also give you a serial number too.

Syntax:

                                        Vol[d:]


                                        84        Rajesh Deshmukh – Disha College
                                               BCA I – Fundamentals Of I.T & O.S



Eg:

Vol E:

8. Ver
VER will tell you what version of DOS you are using. VER/R will tell you some
more information like the revision letter and if DOS is in HIGH memory or not.

Syntax:

                                         VER

9. REN

This command is used to rename a file.

Syntax:

                     REN[d:][path] oldfile-name newfile-name

For Eg:

REN ABC XYZ

10.RD

RD will Remove a Directory. Use RD followed by the name of the directory you wish
to delete. You must empty the directory first or you will just get an error message
from DOS. Instead of RD we can also use RMDIR.

Syntax:

                                RD[path] filename

For Eg:

C:\> RD Windows

11.Date

This command lets you set your systems date.




                                         85    Rajesh Deshmukh – Disha College
                                                 BCA I – Fundamentals Of I.T & O.S

C:\>date
Current date is Wed 03-11-98
Enter new date (mm-dd-yy):
C:\>

12.Time
This lets you set your systems time.

C:\time
Current time is 1:46:11.30p
Enter new time:
C:\>

Notice that at the end of the second line. That means it's P.M. You MUST put at the
end of your new time or else your computer will be set to A.M. You can put an a
there if you want an A.M. time, or you can just leave it blank.

13.Prompt
This is used to set your command prompt. If you use it by itself your prompt will
change to C>. Your prompt looks like this most of the time:

C:\>

You can change it by typing PROMPT followed by any text that you want as your
new prompt. There are also some switches you can add to spice up your boring old
prompt.

$$ adds a $ to your prompt
$t states the time
$d states the date
$p lists your current directory and drive letter
$v adds your DOS version (Or Windoze 95 version)
$n lists just your current drive
$g the > character
$l the < character
$b the | character
$q the = character
$h a backspace, it deletes the last letter of your prompt
$e the escape character, can be A LOT of fun
$_ does a carriage return after listing your prompt

14.DIR



                                         86      Rajesh Deshmukh – Disha College
                                                BCA I – Fundamentals Of I.T & O.S

This command gives a listing of most of the files and directories on a disk. DIR also
displays both the volume name and amount of free storage space on the disk (if there
are files stored in the current directory).

Syntax:

DIR [d:][path][filename] [/A:(attributes)] [/O:(order)] [/B][/C][/CH][/L][/S][/P] [/W]


/W - gives the directory listing wide across your screen without times, dates, and sizes
listed

/P - pauses the output of the DIR command if there are more files than can be listed
on your screen at once.

/B - (Bare format) Displays only file names.

/C - Displays the compression ratio of files compressed using DBLSPACE. This
option is available with DOS Version 6.

CH - Displays the compression ratios of files on a DoubleSpace volume.

/L- Information is displayed in lowercase letters.

/S- Displays file entries in the specified directory and all subdirectories located below
it hierarchically.

For Eg:

Dir D:

15.Path

This command is used to set the path for search. When you type the name of a
program, like FORMAT, DOS will look through it's list of INTERNAL
COMMANDs. Since FORMAT isn't an internal command DOS will then look
through your current directory for that programs name. If it doesn't find FORMAT in
your current directory it will look through all of the directories listed in your PATH
environment variable. You can see what your current PATH is by just typing PATH.

C:\>path
PATH=C:\DOS;C:\WINDOWS;C:\UTIL;D:\GAMES;

C:\>




                                         87      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

     To change your path just use PATH followed by the new PATH directories. Notice
     the semi-colon between directories, this separates entries. The equal sign is optional
     when you are setting the PATH statement. Be careful, when you set the PATH you
     will replace the previous one.

     16. Copy Con
     This command is used to create files and saving them to the disk . once you give the
     command then you can type the contents of the file, once finished press CTRL+Z and
     then press enter.

     Syntax:

                               COPYCON [d:] [path] filename

     For Eg:

     COPYCON D1.TXT

     HELLO! HOW ARE YOU.

     17.MOVE
     This command is used to move the files from one directory to another. It is also used
     to rename a directory. This is done by specifying the old directory named as source
     and target would be new directory name.

     Syntax:

                      MOVE [d:] [path] DIRECTORY1 DIRECTORY2.

     For Eg:

     MOVE c:\abc c:\xyz

External Dos Command

 o      BACKUP

     It is used for backing up one or more files from a hard disk on to a floppy disk. To
     backup the files in all sub directories under the path specified ‘/s’ has to be used.

     Syntax:

                              BACKUP d: [path] filename] d: [/s]



                                            88      Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S


For Eg:

BACKUP C:\abc a:

o CHKDSK

This command is used for checking the disk and reporting back to the status of the
system. It checks the memory and gives the detailed information about the memory. It
has following switches:

/F automatically fixes any errors found.

/V shows every file on your disk.

Syntax:

                              CHKDSK [d:] [filename.txt]

For Eg:

CHKDSK

CHKDSK D:

o DISKCOPY
This is used to diskette into another.this make an exact copy of the diskette in the first
drive on the diskette into the another drive.

Syntax:

                                  DISKCOPY [d:] [d:]

For Example

DISKCOPY d: e:

o DISKCOMP
This command is used to compare the contents of two diskettes. And here are the two
switches you can use with it:

/1 only compares the first side of the disks.

/8 only checks the first 8 sectors of each track.



                                           89       Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S

 It compares two diskettes to see if they are identical. It can't be used on hard drives.
 DISKCOMP will ask you to insert the first diskette into drive A:, then it will scan this
 disk. It will then ask for the second disk and scan it. If they are identical it will tell
 you, if they are not it will also tell you.

 Syntax

                                  DISKCOMP [d:] [d:]

 For Eg:

 DISKCOMP d: e:

o Tree
 This is used to display all the directories and also the files if specified. If we want
 display all the files use ‘/f’.

 Syntax:

                                       TREE [d:] [/f]

 For Eg:

 TREE b:/F

o FORMAT

 FORMAT is used for- you guessed it- formatting disks. This is necessary so that DOS
 knows where to put data on a disk. FORMAT writes over every available sector on
 the disk, putting "place holders" where every bit can go. It also sets up the boot
 sector, root directory, and FAT. FORMAT also detects bad sectors on your disk and
 marks them out so DOS wont try to use them. FORMAT gives you a list of all it did
 after completion.

 /S this copies system files to you disk after it's formatted

 /Q does a quick format- basically it just overwrites the FAT and root directory, does
 not check for bad sectors or overwrite the data section of the disk For Eg:

 Format c:




                                           90      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S



Introduction To Windows
Microsoft Windows is a family of operating systems by Microsoft. They can run on
several types of platforms such as servers, embedded devices and, most typically, on
personal computers. Microsoft first introduced an operating environment named Windows
in November 1985. This operating system has graphical user interface. Windows 32-bit
operating systems is the family of Windows systems which was designed and marketed
for higher-reliability business use.


Windows 95 is a 32 bit, multitaking, multithreaded operating system which is capable of
running DOS, Windows 3.1, and Windows 95 application. It supports plug and play, and
adds an enhanced FAT(File Allocation Table) file system in the Virtual FAT which
allows long file name of upto 255 characters

Features Of Windows Operating system

        The start button and task bar are your primary jumps between the programs and
         documents.

        Plug and play is one of the most important features of windows.It is an automatic
         technique designed to make PC configuration simple and straight forward. It frees
         you from normally manual setting of hardware devices.

        It will customize and use resources effectively and efficiently.

        A 32 bit version of Windows deliever better performance and reliability in certain
         areas such as networking, Printing and in multimedia.

        It is preemptive multiprogramming operating system.

ADVANTAGES
   (i)      Easiest operating system yet
             Navigate your system quickly with powerful new tools:
             Plug and play frees you from manually setting up hardware devices.
               Windows 95 detects and configures plug and play-compatible devices
               automatically.
             Customize and use resources efficiently- just click the right mouse button
               wherever you are working and a context menu appears in order to help
               you manipulate objects directly.
             Microsoft Exchange is your one-step in box for viewing and working with
               such things as: electronic mail from multiple sources, faxes, documents
               and bullet in boards.


                                              91      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

   (ii)        A faster, more powerful windows
                Increase your productivity. A 32-bit architecture delivers better
                   performance and reliability in areas such as networking, printing
                   communicating and multimedia.
                Work on several tasks at once. With fast, new 32-bit programs that support
                   preemptive multitasking and multithreading and run in their own memory
                   space, so errant programs can’t affect one another.
                Focus on your documents instead of the programs that created them.
                   Programs that use OLE, Microsoft’s strategic object technology, let you
                   create and edit documents easily, allowing you to work not only within a
                   single documents, but within multiple programs.
                Built in networking. Windows 95 is network ready, providing easy 32-bit
                   access to network resources, even simultaneously.
                Play today’s hottest games on Windows 95, thanks to faster graphics
                   support for Windows based action games.
   (iii)       compatibility is built-in
              works with all your current software
              Run on today’s PC platform. Use Windows 95 on a PPC with as little as 4 MB
               of memory and a 386DX processor.
              Reduce support burden. A more intuitive interface guides users through tasks
               and greater system reliability, through protected-mode networking, reduces
               downtime-both of which previously required helpdesk intervention.
              Increase control of the desktop. Centralized security, remote administration
               and a registry that stores each user’s environment.
              Improve end-user productivity with the intuitiveness, speed and power of
               Windows 95. for example , Windows 95 reduces the complexity of remote
               computing with built-in dial-up networking and support for plug and play
               hardware.
              Smooth migration to Windows 95. Testing shows users of Windows 3.1
               becoming more productive after just one hour with Windows 95 and end-users
               transition is eased with reference aids such as a computer-based tutorial and
               powerful new help system.

2. Logging On To The Windows:
When you start Windows, you may be prompted to log on to Windows or, if you are on a
network, to log on to your network. You don’t want to log on with a password, don’t type
anything in the password box and click OK. You won’t see this prompt in the future.
To log on to Windows, do the following:
    In the User name box, type your name.
    In the password box, type a password. The first time, Windows prompts you to
       confirm your password.
    Choose OK push button.




                                              92      Rajesh Deshmukh – Disha College
                                                 BCA I – Fundamentals Of I.T & O.S




3. Shutting Down The Windows:
  The term shut down can be used to mean "turning off" something, but most
  commonly used for computers. To quit windows and shut down your computer, the
  following steps have to be performed:

     Click the start button and then click the Shut down.




     A window appears that contain certain option like log off, sutdown or restart the
      computer, the user can select the option according to its convenience.




                                          93      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S




      Choose the option and then, click O.K.

4. Start Button:
The Start Menu and Start Button are user interface elements in the Microsoft Windows
product line, which serve as the central launching point for applications. By default, the
Start Button is visible at all times in the lower left-hand corner of the screen. Clicking the
Start Button, it activates the Start Menu. The Start Menu provided a customizable nested
list of programs for the user to launch, as well as a list of most recently opened
documents, a way to find files and get help, and access to the system settings. The Start
Menu provides a much easier way to open programs, even for experienced users.


Command                                         Description
Programs        Display a list of programs you can start.
Documents       Display a list of documents that you have opened previosly.
Settings        Display a list of system components for which you can change the
                setting.
Find            Enable you to find files, folder etc.
Help            Start Help
Run             Starts a program or opens a folder when you write command sin it.
Shutdown        Shutdown or restart your computer.




                                             94      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S




                                                                              Start Menu




   Start Button


Users may add entries by creating various folders and shortcuts in the Start Menu folder,
located in the hard drive. These appear in a separated section at the top of the Start Menu,
or, if placed in the Programs sub-folder, in the Programs menu. In the Windows 95,
Windows 98 and Windows Me, it is located in C:\Windows\Start Menu, or, if there are
multiple users, C:\Windows\Profiles\username\Start Menu.

5. TaskBar:
In computing, the taskbar is a term for the application desktop bar which is used to
launch and monitor applications in Microsoft Windows 95 and later operating systems. In
Windows, the default location for the taskbar is at the bottom of the screen, following
Fitts' law, and from left to right it contains by default the Start menu, Quick Launch bar.

      The Start menu contains commands that can access programs, documents, and
       settings.
      The Quick Launch bar, introduced with Internet Explorer 4, contains shortcuts to
       applications.

When ever you start a program, a button representing that window appears on the
taskbar. To switch between the windows , just click the button for the window you want
from the task bar. When you close the window, its button disappear from the task bar.


                                            95      Rajesh Deshmukh – Disha College
                                                BCA I – Fundamentals Of I.T & O.S




6. Starting A Program:
  1. Click the start button and then point to programs.
  2. Point to the folder, such as Accessories which contains the program and then click
     the program.




                                         96     Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S




Introduction
This document is only a brief introduction to UNIX and does not include information on
how to use all of its capabilities.

Since this introduction to UNIX is brief, we encourage you to seek out more detailed
introductory information. Information Systems offers free Short Courses on UNIX that
you can sign up for. The Computing Resource Area, located in B40 in the basement of
Fondren Library, has a number of very good introductory books on UNIX available for
checkout. These books go into more detail and cover more of the operating system than
will be covered in this document. You can also purchase some introductory UNIX books
at the Rice Campus Store or almost any local bookstore with a computing section.

This document introduces you to the basics of UNIX, including:

      How to get started
      Shell and Commands
      File structures
      Directories

There are several variants of UNIX on the Rice campus; the type used most on
Information Systems supported networks is from Sun Microsystems. Therefore, although
the information concerning the UNIX operating system presented here is not limited to
Sun workstations, it will focus on them.

Information Systems maintains groups of machines for different groups of users; these
groups of machines are known as domains. The major Information Systems domains are
Owlnet, the Rice UNIX Facility (RUF), and Information Systems administration. Other
departments or divisions may have their own domains, such as Computer Science or
Electrical and Computer Engineering. Accounts in one domain are not valid on machines
of other domains. Every workstation is labeled with its name and domain. If you have an
Owlnet account, use the workstations or terminals in A121 or B223 Abercrombie, 241
Mechanical Engineering, 102 Ryon Lab, 105 Mudd, 221 Physics, or the workstations at
your residential college..

What is UNIX?
UNIX is a powerful computer operating system originally developed at AT&T Bell
Laboratories. It is very popular among the scientific, engineering, and academic
communities due to its multi-user and multi-tasking environment, flexibility and
portability, electronic mail and networking capabilities, and the numerous programming,
text processing and scientific utilities available. It has also gained widespread acceptance
in government and business. Over the years, two major forms (with several vendor's
variants of each) of UNIX have evolved: AT&T UNIX System V and the University of
California at Berkeley's Berkeley Software Distribution (BSD). This document will be



                                             97      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

based on the SunOS 4.1.3_U1, Sun's combination of BSD UNIX (BSD versions 4.2 and
4.3) and System V because it is the primary version of UNIX available at Rice. Also
available are Solaris, a System V-based version, and IRIX, used by Silicon Graphics
machines.

UNIX Layers
When you use UNIX, several layers of interaction are occurring between the computer
hardware and you. The first layer is the kernel, which runs on the actual machine
hardware and manages all interaction with the hardware. All applications and commands
in UNIX interact with the kernel, rather than the hardware directly, and they make up the
second layer. On top of the applications and commands is the command-interpreter
program, the shell, which manages the interaction between you, your applications, and
the available UNIX commands. Most UNIX commands are separate programs, distinct
from the kernel. A final layer, which may or may not be present on your system, is a
windowing system such as X. The windowing system usually interacts with the shell, but
it can also interact directly with applications. The final "layer" is you, the user. You will
interact with the entire operating system through just the shell, or through a combination
of the shell and the window system. The figure below gives a visual representation of the
layers of UNIX.




FIGURE 1. UNIX Layers

Basic UNIX Elements
You need to be familiar with six basic elements of UNIX. They are: commands, files,
directories, your environment, processes, and jobs. Commands are the instructions you
give the system to tell it what to do. Files are collections of data that have been given
filenames. A file is analogous to a container in which you can store documents, raw data,
or programs (it can contain only one kind of data at a time). A single file might contain
the text of a research project, statistical data, or an equation processing formula. Files are
stored in directories. A directory is similar to a file cabinet drawer that contains many
files. A directory can also contain other directories. Every directory has a name, like files.
Your environment is a collection of items that describe or modify how your computing
session will be carried out. It contains things such as where the commands are located
and which printer to send your output to. A command or application running on the
computer is called a process. The sequence of instructions given to the computer from the
time you initiate a particular task until it ends it is called a job. A job may have one or
more processes in it. We will explore each of these elements in a little greater detail later
on, but first you need to learn how to get on to your system.


                                             98      Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S


Logging In and Out
Getting the Login Prompt
Before you can start using the system you must login to it. The method that you use to
login varies depending on the type of device that you are using to login. Read the section
below that is appropriate for you and then read the section, Entering Your Userid and
Password.

TTY Terminal
If you are using a TTY terminal (a TTY is line-at-a-time oriented as opposed to page
oriented) and the screen is blank, you only need to press RETURN and a login prompt
should appear on the screen.

Workstation
If you are using a workstation, you may see a dark screen with a brief message similar to
this:
chub, 4:20 pm, idle 2h 53m (Press ^C)
Press ^C (control-C) and you will see the prompt
chub login:
Almost every login prompt includes the workstation name before the word "login."

X Terminals

If the display features a box in the center of the screen with text similar to that in the
figure below, then you are using a workstation that is configured to run a windowing
system called the X Window system. These machines are called X terminals. (For more
information on the X Window system, see the Information Systems document, UNIX 2,
Introduction to the X Window System.).




FIGURE 2. X Terminal Login Window




                                            99      Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S

If the screen is entirely black, then a screen-saving program is running automatically to
protect the monitor from damage. Moving the mouse or pressing the RETURN key
should "wake up" the display. (If you see the words "This screen has been locked..." then
someone else is using the workstation, but they are temporarily away from their seat.
Look for an unoccupied machine.) Move the mouse until the cursor (a black `X') is on top
of the white box.

Entering Your Userid and Password
When you picked up your account information, you were given a userid and a password.
This combination of information allows you to access your account. Type your userid
using lower-case letters, then press the RETURN key. It is very important that you use
lower-case letters for your userid. If you make a typing mistake, you can correct it by
pressing the DELETE key once for each character you wish to erase. You must make
your corrections before you press the RETURN key. If the text you are typing appears in
upper-case, see the section, Troubleshooting.

After you have entered your userid, the system will prompt you for your password (by
displaying the word "Password:" if it is not already on the screen, or by moving the
cursor behind the word "Password:" already on your screen). Enter your password and
press the RETURN key. Notice that the system does not show or "echo" your password
as you type it. This prevents other people from learning your password by looking at your
screen.

If you receive a message similar to "Login failed, please try again," you may have typed
your userid or password incorrectly. Try again, making sure to type in your userid and
password correctly. If you are still having problems, go to the Consulting Center in 103
Mudd Lab and ask for help.

When you have successfully logged on, the system will pause for a moment, and then
display a few lines telling you when and from which machine you last logged on, and any
messages from the system administrator.

On X terminals, you will get a window containing system information. After reading it,
use the left mouse button click on either the "Help" or "Go Away" button, depending on
what you want. Help puts you into a help system; Go Away allows you to begin your
work.

Your new account is provided with a set of command procedures which are executed
each time you log in. You can change part of your UNIX environment by changing these
setup files (accounts on Information Systems supported systems are set up to produce a
default environment). For further information, check the Sun manual SunOS User's
Guide: Customizing Your Environment, available for building use only in the Operations
Center, 109 Mudd Lab.

The system will then display the command prompt. The prompt signals that the system is
ready for you to enter your next command. The name of the workstation followed by a


                                           100     Rajesh Deshmukh – Disha College
                                                  BCA I – Fundamentals Of I.T & O.S

percent sign (%) forms the command prompt (e.g. chub%). Once you finish typing a
command, you must always press RETURN to execute it.

Logging Out

Workstations and TTY Terminals
To end a work session, you must explicitly log out of a UNIX session. To do this, type
logout at the command prompt. Once you have logged out, the system will either display
the login prompt again or begin executing a screen saver program.

You should never turn a workstation off. Turning off a terminal does not necessarily log
you out. If you are having trouble logging out, see the section, Troubleshooting.

X Terminals
To log out of the X Window system from an X terminal, move the cursor into the console
window (it is labeled "console"), type the command exit, and press RETURN. If you try
to use the logout command in the console window, you will receive the message, "Not in
login shell."

If you used the startx command to start the X session (if you are working on a Sun
workstation, for example), after you end the X session you will have the option to remain
logged on by pressing CTRL-C within three seconds after exiting. If you do so, the X
windows and background vanish, returning you to a text-only display. At the prompt,
type exit to log out.

Changing Your Password
You can change your password at any time. You should change it the first time that you
log in, and we recommend that you change it on a regular basis. At the command prompt,
type passwd.You will be prompted to enter your old password and be asked twice to
enter your new password. Neither your old nor new password will appear on the screen as
you type. In order to be accepted, your password must meet the following conditions:

   1. It must be at least seven characters long.
   2. It must not match anything in your UNIX account information, such as your login
      name, or an item from your account information data entry.
   3. It must not be found in the system's spelling dictionary unless a character other
      than the first is capitalized. It must not have three or more consecutively repeated
      characters or words in the dictionary contained within it.

For example, changing your password from Kat899 to B00z00e will look similar to the
following example, except that the keystrokes for you old and new password will not be
echoed on the screen.




                                           101     Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

       passwd
       current password: Kat899
       New password (? for help): B00z00e
       New password (again): B00z00e
       Password changed for userid
On many systems, the password change does not take effect immediately, even though
you have finished with the passwd command. It can take upwards of an hour for the
system to install the new password, due to the scheduling of the password changing
process. Thus you should be prepared to use your old password to login again shortly
after changing it.

If you should ever forget your password, you can go to the Information Desk in 103
Mudd Lab and request that a new password be generated for you. You will need to bring
your Rice ID card with you to pick up your new password.

UNIX Commands

The UNIX Shell
Once you are logged in, you are ready to start using UNIX. As mentioned earlier, you
interact with the system through a command interpreter program called the shell. Most
UNIX systems have two different shells, although you will only use one or the other
almost all of the time. The shell you will find on Information Systems supported
networks is the C shell. It is called the C shell because it has syntax and constructs similar
to those in the C programming language. The C shell command prompt often includes the
name of the computer that you are using and usually ends with a special character, most
often the percent sign (%). Another common shell is the Bourne shell, named for its
author. The default prompt for the Bourne shell is the dollar sign ($). (If the prompt is
neither one of these, a quick way to check which shell you are using is to type the C shell
command alias; if a list appears, then you are using the C shell; if the message,
"Command not found" appears, then you are using the Bourne shell). Modified versions
of these shells are also available. TC shell (tcsh) is C shell with file name completion and
command line editing (default prompt: >). The GNU Bourne-Again shell (bash) is
basically the Bourne shell with the same features added (default prompt: bash$).

In addition to processing your command requests, UNIX shells have their own syntax and
control constructs. You can use these shell commands to make your processing more
efficient, or to automate repetitive tasks. You can even store a sequence of shell
commands in a file, called a shell script, and run it just like an ordinary program. Writing
shell scripts is a topic discussed in the class notes for the UNIX III-Scripts Short Course.

About UNIX Commands
UNIX has a wide range of commands that allow you to manipulate not only your files
and data, but also your environment. This section explains the general syntax of UNIX
commands to get you started.


                                             102     Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

A UNIX command line consists of the name of the UNIX command followed by its
arguments (options, filenames and/or other expressions) and ends with a RETURN. In
function, UNIX commands are similar to verbs in English. The option flags act like
adverbs by modifying the action of the command, and filenames and expressions act like
objects of the verb. The general syntax for a UNIX command is:

command [-flag options] file/expression
The brackets around the flags and options are a shorthand way to indicate that they are
often optional, and only need to be invoked when you want to use that option. Also, flags
need not always be specified separately, each with their own preceding dash. Many times,
the flags can be listed one after the other after a single dash. Some examples later on will
illustrate this concept.

You should follow several rules with UNIX commands:

   1.   UNIX commands are case-sensitive, but most are lowercase.
   2.   UNIX commands can only be entered at the shell prompt.
   3.   UNIX command lines must end with a RETURN.
   4.   UNIX options often begin with a "-" (minus sign).
   5.   More than one option can be included with many commands.

Redirecting Input and Output
UNIX maintains a couple of conventions regarding where input to a program or
command comes from and output from that program or command goes. In UNIX, the
standard input is normally the keyboard, and the standard output is normally the screen.
UNIX is very flexible, and it allows you to change or redirect where the input comes
from and where the output goes. First, any command that would normally give results on
the screen can be directed instead to send the output to a file with the ">" (output
redirection) symbol. Thus,
        date > file
directs the system to put the output from the date command, which merely reports the
time and date as the system knows it, into the file named file rather than printing it to
your screen. One thing to keep in mind about ">" is that each successive redirection to a
particular file may overwrite all of the previously existing data in that file, though this is
unlikely.

Another redirection is "<," which tells the command to take its input from a file rather
than from the keyboard. For example, if you have a program that requires data input from
the keyboard, you may find that you have to type the same data a large number of times
in the debugging stage of program development. If you put that data in a file and direct
the command to read it from there you will only have to type the data once, when you
make the data file.

        program < datafile



                                             103      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

If you do this, you would see the same response from program as if you had typed the
data in from the keyboard when requested.

You can also combine both kinds of redirection as in,

        program < datafile > outputfile
The data in the file datafile will then be used as input for program and all output will be
stored in outputfile.

If you want to accumulate output from different sources in a single file, the symbol ">>"
directs output to be appended to the end of a file rather than replacing the previous (if
any) contents, which the single ">" redirection will do.

A final I/O redirection is the pipe symbol, "|." The "|" tells the computer to take the output
created by the command to the left of it and use that as the input for the command on the
right. For example, we could type:

      date | program
This would use the output of the date command as input to another program.

Getting On-Line Help with Commands
The standard on-line help facility available with UNIX is electronic reference manuals,
known as the man pages, and you access them with the man command.
        man command-name
The man pages provide an in-depth description of command-name, with an explanation
of its options, examples, and further references. The information is an electronic
duplicate of the paper reference manual pages. Use the man command for explicit
information about how to use a particular command. Use the -k option to search for a
keyword among the one line descriptions in the help files.
        man -k keyword

The command apropos serves exactly the same function as man -k and is used in the
same way.

You can read about the man command itself using man. Type man man at the prompt.
The UNIX reference manual is divided into eight numbered sections:

   1.   General User Commands
   2.   System Calls
   3.   User-level Library Functions
   4.   Device Drivers, Protocols
   5.   File Formats
   6.   Games (rarely available)
   7.   Document Preparation
   8.   System Administration



                                             104     Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

You can see the command summary for each section by typing:
       man # intro
where # is one of the eight section numbers.

In addition, other applications that reside on your system may have man pages. These
pages can often be called up in the same manner as the operating system man pages.

Case Sensitivity
UNIX is a case sensitive operating system. It treats lower-case characters differently than
upper-case characters. For example, the files readme, Readme, and README would be
treated as three different files. Most command names and files are entirely in lower-case.
Therefore, you should generally plan to type in lower-case for most commands,
command line arguments, and option letters.

Special Keys and Control Characters
UNIX recognizes special keys and control-character key strokes and assigns them special
functions. A special key such as the DELETE key is usually mapped to the ERASE
function, which erases the most recent character that you typed on the current line. A
control-keystroke such as CTRL-C is invoked by holding down the key labeled
CONTROL and pressing the "c" key (in the same manner that you hold down the SHIFT
key and press the "c" key to generate a capital C). The notation for control characters is
usually ^C or CTRL-C. Some standard special keys and control characters are
summarized below.

TABLE 1. Special Keys and Control Characters


SPECIAL KEY                  FUNCTION/DESCRIPTION


DELETE             Acts as a rubout or erase key. Pressing DELETE once will
backup             and erase one character, allowing you to correct and
retype
                   mistakes.

BACKSPACE      This key is sometimes used as the rubout key instead of
the                    DELETE key. Otherwise, it is mapped as a
backspace key,                         which generates a ^H on the
display.
CTRL-U         ^U erases the entire command line. It is also called the
line
                kill character.
CTRL-W         ^W erases the last word on the command line.
CTRL-S         ^S stops the flow of output on the display.
CTRL-Q         ^Q resumes the flow of output stopped by CTRL-S.
CTRL-C         ^C interrupts a command or process in progress and
returns to                     the command line. This will usually work;
if it doesn't, try typ                 ing several ^C's in a row. If it
still doesn't work, try typing                 ^\, q (for quit), exit,
^D, or ^Z.



                                           105      Rajesh Deshmukh – Disha College
                                                 BCA I – Fundamentals Of I.T & O.S

CTRL-Z            ^Z suspends a command or process in progress.
CTRL-D            ^D generates an end-of-file character. It can be used to
                  terminate input to a program, or to end a session with a
shell.
CTRL-\            ^\ quits a program and saves an image of the program in
a file                    called core for later debugging.




A Selected Command List
The next few pages summarize many of the basic UNIX commands you need to get
started. For further details on UNIX commands not discussed (or that are beyond the
scope of this introductory document), consult the system manuals available in the
Operations Center, 109 Mudd Lab, and in the labs, or get some practice using the man
command.

Setup and Status Commands

COMMAND           PURPOSE

logout            end your UNIX session
passwd            change password by prompting for old and new passwords
stty              set terminal options
date              display or set the date
finger             display information about users
ps                display information about processes
env               display or change current environment
set               C shell command to set shell variables
alias             C shell command to define command abbreviations
history           C shell command to display recent commands




File and Directory Commands

COMMAND           PURPOSE

cat               concatenate and display file(s)
more              paginator - allows you to browse through a text file
most              more versatile paginator than more
mv                move or rename files
cp                copy files
rm                remove files
ls                list contents of directory
mkdir             make a directory
rmdir             remove a directory
cd                change working directory
pwd               print working directory name
du                summarize disk usage


                                         106     Rajesh Deshmukh – Disha College
                                         BCA I – Fundamentals Of I.T & O.S

chmod           change mode (access permissions) of a file or directory
file            determine the type of file




Editing Tools

COMMAND         PURPOSE

vi              screen oriented (visual) display editor
diff            show differences between the contents of files
grep            search a file for a pattern
sort            sort and collate lines of a file (only works on one file
at a time)
wc              count lines, words, and characters in a file
look            look up specified words in the system dictionary
awk             pattern scanning and processing language




Formatting and Printing Commands

COMMAND         PURPOSE

lpq             view printer queue
lpr             send file to printer queue to be printed
lprm            remove job from printer spooling queue
enscript        converts text files to POSTSCRIPT format for printing




Program Controls, Pipes, and Filters

COMMAND         PURPOSE

CTRL-C          interrupt current process or command
CTRL-D          generate end-of-file character
CTRL-S          stop flow of output to screen
CTRL-Q          resume flow of output to screen
CTRL-Z          suspend current process or command
jobs            lists background jobs
sleep           suspend execution for an interval
kill            terminate a process
nice            run a command at low priority
renice          alter priority of running process
&               run process in background when placed at end of command
line
>               redirect the output of a command into a file




                                   107   Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

>>             redirect and append the output of a command to the end
of a file
<              redirect a file to the input of a command
>&             redirect standard output and standard error of a command
into a file (C shell only)
|              pipe the output of one command into another

THE FOLLOWING COMMANDS ARE NOT AVAILABLE WITH THE BOURNE SHELL

bg                 run a current or specified job in the background
fg                 bring the current or specified job to the foreground
!!                 repeat entire last command line
!$                 repeat last word of last command line




Other Tools and Applications

COMMAND            PURPOSE

mail               electronic mail
bc                 desk calculator
man                print UNIX manual page to screen




Files

About UNIX Files
Now that you understand UNIX commands, let's discuss the objects manipulated by most
commands: files. As we said before, all files have a filename, and UNIX imposes few
restrictions on filenames. This makes it easy for you to name your files so that you can
easily recognize their contents. You will find it useful to adopt names and classes of
names that indicate how important each file is and what connection it has with other files.
For example, temporary files used to test commands and options could all begin with a
"t." A filename can be up to 256 characters long, consisting of any alphanumeric
character on the keyboard except the "/". In general, you should keep your filenames
relatively short (to reduce typing effort) and use normal lower-case characters such as
letters, numbers, periods and underscores. For instance, if your program calculates
employee paychecks, you might call it payroll, or if your file is a research paper on
Frank Lloyd Wright, you might call it wright. Do not include blanks in your filenames as
they will make it very difficult for you to work with the file. If you do wish to separate
letters in a filename, use the underscore ("_") character (as in wright_paper) or the
hyphen ("-") character. Remember that UNIX is case sensitive, which means it
recognizes the difference between upper-case and lower-case letters. For instance,
Wright and wright would refer to two different files.



                                           108      Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S

When you place a single period in the middle of a filename, the part after the period is
commonly referred to as an extension or suffix and usually indicates what type of
information is stored in the file. You may use any extension desired; a text file might
have the extension .txt or .text; a note may have the extension .note, and so forth. UNIX
does not require extensions; they are intended to help identify similar types of files. Since
some UNIX programs (especially compilers) look for certain standard extensions, it is
common practice to use the following conventions: .h for header files, .c for C source
files, .f for FORTRAN, .p for Pascal, and .s for assembler source files. So the file
wright.txt indicates a text file whereas the file payroll.c indicates a C program called
payroll. For more information on programming conventions, see the section, Additional
Resources.

Some UNIX files begin with a period, for example, .cshrc or .login. Files that begin with
a period will not appear in a normal directory listing and are usually UNIX environment
and application setup files.

A large grouping of files and directories is referred to as a file system. File systems are
related to the disk size and structure, and to the internal structure of UNIX. What you
should remember is that users' files and directories are usually on a different file system
than the system's files and directories. If the number of users is large, as on Owlnet, the
user files and directories may be on more than one file system.

Creating Files
Many files are created using a text editor. A text editor is a program that allows you to
enter and save text. You can also use a text editor to manipulate saved text through
corrections, deletions, or insertions. The main text editors on Information Systems
managed networks are vi, GNU Emacs, Pico, and aXe. (Note: vi is included with every
UNIX system, but GNU Emacs is commonly installed separately by system managers.
aXe is only available if you are using the X Window system.) You should learn how to
use at least one of these tools. Information Systems has tutorial documents on each of
these editors. Please see the section, Additional Resources, for information on the
tutorials.

You can create a file without a text editor by using the cat command (short for
concatenate) and the ">" (redirect output) symbol. To create a file using the cat
command, type:

        cat > new-filename
where new-filename is the name you wish to give the file. The command cat generally
reads in a file and displays it to standard output. When there is no filename directly
following the command, cat treats standard input as a file. The ">" symbol will redirect
the output from cat into the new filename you specify. cat will keep reading and writing
each line you type until it encounters an end-of-file character. By typing CTRL-D on a
line by itself, you generate an end-of-file character. It will stop when it sees this
character. Try it, using this example as a guide:
        cat > practice


                                            109      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

When you reach the end of each line, press the RETURN key. You can only correct
mistakes on the line you are currently typing. Use the DELETE key to move the cursor
back to the mistake and then retype the rest of the line correctly. When you have
completed the last line, press RETURN and type CTRL-D.

Displaying Files
Now that you have created a file, you can display it one of several ways. You could use
the cat command. Just type cat followed by the name of the file that you want to see.
        cat practice
Sometimes the files you want to view are very long. When using the cat command, the
text will scroll by very quickly. You can control the flow of text by using CTRL-S and
CTRL-Q. CTRL-S stops the flow of text and CTRL-Q restarts it. If you use CTRL-S,
stopping the flow of text, and so on, you must remember to type CTRL-Q or the
computer will not respond.

more is a program that displays only one screen of information at a time; it waits for you
to tell it to continue. Type more followed by a filename.

        more practice
The computer will display one screen of text and then wait for you to press the space bar
before it displays the next page of text, until you reach the end of the file. Pressing the "?"
character will show help for more. A utility of greater power called most is available on
many systems; it allows reverse scrolling of files and other enhancements. It is invoked
the same way as more.

Listing Files
The ls command will list the files in the current directory that do not begin with a period.

Below is a list of options you can tack on to ls:


ls -a           lists all the contents of the current directory,
including files                with initial periods, which are not
usually listed.

ls -l               lists the contents of the current directory in long
format,
                    including file permissions, size, and date information.

ls -s               lists contents and file sizes in kilobytes of the
current
                    directory.



If you have many files, your directory list might be longer than one screen. You can use
the programs more or most with the "|" (vertical bar or pipe) symbol to pipe the directory
list generated as output by the ls command into the more program. more or most will
display the output from ls one page at a time.


                                             110      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

       ls | more

Copying Files
To make a copy of a file, use the cp (copy) command.
       cp filename newfilename
where filename is the file you wish to copy and newfilename is the file you are creating.
       cp practice sample (make a copy of "practice" called "sample")
       ls
       practice sample
The example created a new file called sample that has the same contents as practice. If
sample already exists, the cp command will overwrite the previous contents. New
accounts are often set up so that cp will prompt for confirmation before it overwrites an
existing file. If your account is not set up in this manner, use the -i option (cp -i) to get
the confirmation prompt.

Renaming Files
To rename one of your files, use the mv (move) command.
       mv oldfilename newfilename
where oldfilename is the original filename and newfilename is the new filename. For
instance, to rename sample as workfile type:
       mv sample workfile
       ls
       practice workfile
This moves the contents of sample into the new file workfile. (Note: Moving a file into
an existing file overwrites the data in the existing file.) New accounts are often set up so
that mv will prompt for confirmation before doing this. If your account is not set up in
this manner, use the -i option (mv -i) to get the confirmation prompt.

Deleting Files
To delete files, use the rm (remove) command. For instance, to delete workfile, type:
       rm workfile
       ls
       practice
Important: rm can be very dangerous. Once a file has been removed you cannot get it
back, except, possibly, from system backups (which may or may not contain the file). It
may take the system administrators several days to to recover your deleted file, so use a
great deal of caution when deleting files. New accounts are often set up so that rm will
prompt for confirmation. If your account is not set up in this manner, use the -i option to
get the confirmation prompt.

Creating Links Between Files
You can refer to one particular file by different names in different directories. The ln
command creates a link, which "points" to the file. Note that links are simply alternative
names for a single file; ln does not rename the file (as does mv) nor does it make a copy
of the file (as does cp). It allows you to access the file from multiple directories. Since
only one copy of the file actually exists, any changes that you make through one of its


                                             111      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

links will be reflected when you access it through another of its links, yet if you delete the
link, you do not delete what it points to.

Links are useful for cross-referencing files. If you know that you will need to access a file
from different directories, creating links is a better alternative to making a copy of the file
for each directory (and then having to alter each one every time a change is made to the
original). It is also more convenient than having to use the file's full pathname every time
you need to access it. Another use for linking a file is to allow another user access to that
particular file without also allowing entry into the directory that actually contains the file.
The kind of link you will want to create is called a symbolic link. A symbolic link
contains the pathname of the file you wish to create a link to. Symbolic links can tie into
any file in the file structure; they are not limited to files within a file system. Symbolic
links may also refer to directories as well as individual files. To create a symbolic link to
a file within the same directory, type:

        ln -s originalFile linkName
where originalFile is the file that you want to link to and linkName is the link to that file.
To create a link in a directory other than that of the original file, type:
        ln -s originalFile differentDirectoryName/linkName
If you create a link within the same directory as the original file, you cannot give it the
same name as the original file. There is no restriction on a file's additional names outside
of its own directory. Links do not change anything about a file, no matter what the link is
named. If someone makes a link to one of your files, and you then delete that file, that
link will no longer point to anything and may cause problems for the other user.

Printing Files
To print a file, use the lpr command:
        lpr filename
or
        lpr [-Pprintername] filename (for laser printers only)
To get a list of the printers available to your machine, type:
        lprloc
lprloc lists all of the printers that your system knows about, by name, along with their
type and location. To get some status information on the printers, use the command lpstat
-p.

NOTE: Line printers are used for text-only files. Laser printers are needed to handle
graphics or PostScript files. PostScript is a page-description language developed by
Adobe Systems, Inc. and was specially designed for creating graphics and typography on
a printed page. The option flag -P printername specifies which laser printer to use and is
optional (as indicated by the brackets). When no printer is given, the print command uses
the system default printer. However, on some systems such as Owlnet, you must always
specify a laser printer with the -P flag. For more information on printing commands, use
the man command to consult the manual pages on lpq, lpr, and lprm.




                                             112      Rajesh Deshmukh – Disha College
                                                    BCA I – Fundamentals Of I.T & O.S


Directories

About UNIX Directories
UNIX directories are similar to regular files; they both have names and both contain
information. Directories, however, contain other files and directories. Many of the same
rules and commands that apply to files also apply to directories.

All files and directories in the UNIX system are stored in a hierarchical tree structure.
Envision it as an upside-down tree, as in the figure below.




FIGURE 3. UNIX Directory Structure

At the top of the tree is the root directory. Its directory name is simply / (a slash
character). Below the root directory is a set of major subdirectories that usually include
bin, dev, etc, lib, pub, tmp, and usr. For example, the /bin directory is a subdirectory, or
"child," of / (the root directory). The root directory, in this case, is also the parent
directory of the bin directory. Each path leading down, away from the root, ends in a file
or directory. Other paths can branch out from directories, but not from files.

Many directories on a UNIX system have traditional names and traditional contents. For
example, directories named bin contain binary files, which are the executable command
and application files. A lib directory contains library files, which are often collections of
routines that can be included in programs by a compiler. dev contains device files, which
are the software components of terminals, printers, disks, etc. tmp directories are for
temporary storage, such as when a program creates a file for something and then deletes
it when it is done. The etc directory is used for miscellaneous administrative files and
commands. pub is for public files that anyone can use, and usr has traditionally been
reserved for user directories, but on large systems it usually contains other bin, tmp, and
lib directories.




                                            113      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

Your home directory is the directory that you start out from when you first login. It is the
top level directory of your account. Your home directory name is almost always the same
as your userid.

Every directory and file on the system has a path by which it is accessed, starting from
the root directory. The path to the directory is called its pathname. You can refer to any
point in the directory hierarchy in two different ways: using its full (or absolute)
pathname or its relative pathname. The full pathname traces the absolute position of a file
or directory back to the root directory, using slashes (/) to connect every point in the path.
For example, in the figure above, the full pathname of file2 would be /usr/bin/file2.
Relative pathnames begin with the current directory (also called the working directory,
the one you are in). If /usr were your current directory, then the relative pathname for
file2 would be bin/file2.

If you are using C shell, TC shell, or the Bourne-Again shell, UNIX provides some
abbreviations for a few special directories. The character "~" (tilde) refers to your home
directory. The home directory of any user (including you, if you want) can be abbreviated
from /parent-directories/userid to ~userid. Likewise, you can abbreviate /parent-
directories/youruserid/file to ~/file. The current directory has the abbreviation . (period).
The parent of the current working directory uses .. (two consecutive periods) as its
abbreviation.

Displaying Directories
When you initially log in, the UNIX system places you in your home directory. The pwd
command will display the full pathname of the current directory you are in.
         pwd
         /home/userid
By typing the ls -a command, you can see every file and directory in the current
directory, regardless of whether it is your home directory. To display the contents of your
home directory when it is not your current directory, enter the ls command followed by
the full pathname of your home directory.
         ls /home/userid
If you are using a shell other than the Bourne shell, instead of typing the full pathname
for your directory, you can also use the tilde symbol with the ls command to display the
contents of your home directory.
         ls ~
To help you distinguish between files and directories in a listing, the ls command has a
-F option, which appends a distinguishing mark to the entry name showing the kind of
data it contains: no mark for regular files; "/" for directories; "@" for links; "*" for
executable programs.

Changing Directories
To change your current directory to another directory in the directory tree, use the cd
command. For example, to move from your home directory to your projects directory,
type:
       cd projects (relative pathname from home directory)


                                             114     Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S

or,
       cd ~/projects (full pathname using ~)
or,
       cd /home/userid/projects (full pathname)
Using pwd will show you your new current directory.
       pwd
       home/userid/projects
To get back to the parent directory of projects, you can use the special ".." directory
abbreviation.
        cd ..
        pwd
        /home/userid
If you get lost, issuing the cd command without any arguments will place you in your
home directory. It is equivalent to cd ~.

Moving Files Between Directories
You can move a file into another directory using the following syntax for the mv
command:
        mv source-filename destination-directory
For example,
        mv sample.txt ~/projects
moves the file sample.txt into the projects directory. Since the mv command is capable
of overwriting files, it would be prudent to use the -i option (confirmation prompt). You
can also move a file into a another directory and rename it at the same time by merely
specifying the new name after the directory path, as follows:
        mv sample.txt ~/projects/newsample.txt

Copying Files to Other Directories
As with the mv command, you can copy files to other directories:
       cp sample.txt ~/projects
As with mv, the new file will have the same name as the old one unless you change it
while copying it.
       cp sample.txt ~/projects/newsample.txt

Renaming Directories
You can rename an existing directory with the mv command:
       mv oldDirectory newDirectory
The new directory name must not exist before you use the command. The new directory
need not be in the current directory. You can move a directory anywhere within a file
system.

Removing Directories
To remove a directory, first be sure that you are in the parent of that directory. Then use
the command rmdir along with the directory's name. You cannot remove a directory with
rmdir unless all the files and subdirectories contained in it have been erased. This
prevents you from accidentally erasing important subdirectories. You could erase all the


                                            115     Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

files in a directory by first going to that directory (use cd) and then using rm to remove all
the files in that directory. The quickest way to remove a directory and all of its files and
subdirectories (and their contents) is to use the rm -r command along with the directory's
name. For example, to empty and remove your projects directory (assuming that you are
in that directory), type:
         cd .. (move to that directory's parent)
         rm -r projects (remove the directory and its contents)


File and Directory Permissions
It is important to protect your UNIX files against accidental (or intentional) removal or
alteration by yourself or other users. The UNIX operating system maintains information,
known as permissions, for every file and directory on the system. This section describes
how to inspect and change these permissions.

UNIX was designed and implemented by computer scientists working on operating
system research. Many of the fundamentals of UNIX reflect this origin in academia. A
low concern for security is one of the hallmarks of UNIX operating systems. Therefore,
unless you act to restrict access to your files, chances are high that other users can read
them.

Every file or directory in a UNIX file system has three types of permissions (or
protections) that define whether certain actions can be carried out. The permissions are:

       read ( r ) A user who has read permission for a file may look at its contents or
       make a copy of it. For a directory, read permission enables a user to find out what
       files are in that directory.

       write ( w ) A user who has write permission for a file can alter or remove the
       contents of that file. For a directory, the user can create and delete files in that
       directory.

       execute ( x ) A user who has execute permission for a file can cause the contents
       of that file to be executed (provided that it is executable). For a directory, execute
       permission allows a user to change to that directory.


For each file and directory, the read, write, and execute permissions may be set separately
for each of the following classes of users:
        User ( u ) The user who owns the file or directory.

       Group ( g ) Several users purposely lumped together so that they can share access
       to each other's files.

       Others ( o ) The remainder of the authorized users of the system.


                                             116      Rajesh Deshmukh – Disha College
                                                        BCA I – Fundamentals Of I.T & O.S



The primary command that displays information about files and directories is ls. The -l
option will display the information in a long format. You can get information about a
single UNIX file by using ls -l filename.

Each file or subdirectory entry in a directory listing obtained with the -l option consists of
seven fields: permission mode, link count, owner name, group name, file size in bytes,
time of last modification, and the filename (the group name appears only if the "g" flag is
also specified, as in ls -lg).

The first 10 characters make up the mode field. If the first character is a "d" then the item
listed is a directory; if it is a "-" then the item is a file; if it is an "l" then it is a link to
another file. Characters 2 through 4 refer to the owner's permissions, characters 5 through
7 to the group's permissions (groups are defined by the system administrator), and the last
three to the general public's permissions. (You can type id to verify your userid and
group membership.) If a particular permission is set, the appropriate letter appears in the
corresponding position; otherwise, a dash indicates that the permission is not given.

The second field in the output from ls -l is the number of links to the file. In most cases it
is one, but other users may make links to your files, thus increasing the link count. A
special warning to people using links to other people's files: your "copies" of their files
can be counted against them by the file quota system available on certain UNIX variants.
The third field gives the userid of the owner of the file. The group name follows in the
fourth field (if the -g option is used in conjunction with -l). The next two fields give the
size of the file (in bytes) and the date and time at which the file was last modified. The
last field gives the name of the file.

        ls -l myfile
        -rw-r--r-- 1 owner 588 Jul 15 14:39 myfile
A file's owner can change any or all of the permissions with the chmod (change mode)
command. The chmod command allows you to dictate the type of access permission that
you want each file to have. In the previous example the current permissions for myfile
are read for everybody, write for the owner, and execute by no one.

The arguments supplied to chmod are a symbolic specification of the changes required,
followed by one or more filenames. The specification consists of whose permissions are
to be changed: u for user (owner), g for group, o for others, or some combination thereof
(a (all) has the same effect as ugo), how they are to be changed (+ adds a permission, -
removes a permission, and = sets the specified permissions, removing the other ones) and
which permission to add or remove (r for read, w for write, and x for execute). For
example, to remove all the permissions from myfile:

        chmod a-rwx myfile
        ls -l myfile
        ---------- 1 owner 588 Jul 15 14:41 myfile

(Note: chmod a= myfile achieves the same effect.)


                                               117      Rajesh Deshmukh – Disha College
                                                       BCA I – Fundamentals Of I.T & O.S

To allow read and write permissions for all users:

       chmod ugo+rw myfile
       ls -l myfile
       -rw-rw-rw- 1 owner 588 Jul 15 14:42 myfile

To remove write permission for your groups and other users:
      chmod go-w myfile
      ls -l myfile
       -rw-r--r-- 1 owner 588 Jul 15 14:42 myfile

Finally, to allow only read permission to all users:
        chmod a=r myfile
        ls -l myfile
       -r--r--r-- 1 owner 58 Jul 15 14:43 myfile

Now the file is protected by allowing only read access; it cannot be written to or executed
by anyone, including you. Protecting a file against writing by its owner is a safeguard
against accidental overwriting, although not against accidental deletion.

chmod will also accept a permission setting expressed as a 3-digit octal number. To
determine this octal number, you first write a 1 if the permission is to be set and a 0
otherwise. This produces a binary number which can be converted into octal by grouping
the digits in threes and replacing each group by the corresponding octal digit according to
the table below.

TABLE 2. Symbolic to Octal Conversions


SYMBOLIC           BINARY              OCTAL

---                000                 0
--x                001                 1
-w-                010                 2
-wx                011                 3
r--                100                 4
r-x                101                 5
rw-                110                 6
rwx                111                 7



Thus, if the setting you want is rw-r--r--, determine the octal number with the following
method:




                                            118        Rajesh Deshmukh – Disha College
                                                   BCA I – Fundamentals Of I.T & O.S




This shows that the octal equivalent of rw-r--r-- is 644. The following example illustrates
that the permissions for myfile have been reset to the values with which we began.

       chmod 644 myfile
       ls -l myfile
       -rw-r--r-- 1 owner 588 Jul 15 14:44 myfile

To change the permissions back to read only, you can execute chmod as follows:
       chmod 444 myfile
       ls -l myfile
       -r--r--r-- 1 owner 588 Jul 15 14:45 myfile

As with files, directories may also have permissions assigned. When listing directories,
you may use the -d option to keep from descending into the directories you list.
Otherwise, the contents of the directories will be displayed as well as their names. Below
is an example of permissions assigned to a directory:
        ls -lgd home
       drwxrwxr-x 1 owner masc223 588 Jul 15 9:45 home

The directory home and the files and directories under it may be read and executed by
anyone, but written to only by the owner and users in the masc223 group. Assuming you
are the owner of this directory, you may decide to change the permission to allow only
yourself and the masc223 group to read and execute files in the home directory. You
would set the permissions accordingly:
        chmod o-rx home
        ls -lgd home
       drwxrwx--- 1 owner masc223 588Jul 15 9:46 home

You may decide that only you should be able to alter the contents of the directory. You
must remove the write permission for the group.
       chmod 750 home
       ls -lgd home
       drwxr-x--- 1 owner masc223 588 Jul 15 9:48 home

An alternative to the previous command is chmod g-w.

When you create a file the system gives it a default set of permissions. These are
controlled by the system administrator and will vary from installation to installation. If
you would like to change the default which is in effect for you, choose your own with the


                                           119      Rajesh Deshmukh – Disha College
                                                     BCA I – Fundamentals Of I.T & O.S

umask command. Note that the permission specified by the umask setting will be
applied to the file, unlike that specified in the chmod command, which normally only
adds or deletes (few people use the = operator to chmod).

First, issue the command without arguments to cause the current settings to be echoed as
an octal number:

       umask
       022

If you convert these digits to binary, you will obtain a bit pattern of 1's and 0's. A 1
indicates that the corresponding permission is to be turned off, a 0, that it is to be turned
on. (Notice that the bit patterns for chmod and umask are reversed.) Hence, the mask
output above is 000010010, which produces a permission setting of rwxr-xr-x (i.e., write
permission is turned off for group and other).

Suppose you decide that the default setting you prefer is rwxr-x---. This corresponds to
the masking bit pattern 000010111, so the required mask is 027:

       umask 27

Now, if you create a new file during this session, the permissions assigned to the file will
be the ones allowed by the mask value.




                                             120     Rajesh Deshmukh – Disha College

				
DOCUMENT INFO
Shared By:
Categories:
Tags:
Stats:
views:73
posted:7/27/2012
language:English
pages:120