Monday, September 10, 2012

C language

Short notes about of C language.
'C' was developed from an language 'Basic Combined Programing Language' called 'B' developed in the 1960's at Cambridge University 'B' language was modified by Dennis Ritchit and was implemented at Bell laboratories in 1972. The new language was named is 'C' since it was developed along with the Unix operating system it is strongly associated with Unix. Today 'C' is running under a number of operating systems including MS DOS.

Advantages or Importance of 'C' language.
1. Program written in 'C' are efficient and fast.
2. Several standard build in functions are available which can be used for developing programs.
3. 'C' is highly portable, programs written for one computer can be run on another with little or new modification.
4. It is robest can be used to write any complex program.

Features of 'C' language.

1. 'C' is a structured programming language hence.
2. Programs can be written quickly with less mistakes.
3. It increases the preadability of the programs and finaly, flexibility of the program is improved.
4. Sequence, condition and loop structures are present in 'C'.
5. 'C' is Case-sensitive.
6. 'C' Can reference a memory locations by means of it's address using pointers hence 'C' is suitable for system programming.
7. Every Statement in 'C' should end with a semi colon.

Structure of a 'C' program.
Documentation section
Link section
Definition section
Global declaration section
Main () funtion section
{
Declaration part
Executable part
}
Sub program section
Function 1
Funtion 2
.
.                       }- User defined function definitions
.
Function n

The Documentation section consist of a set of comment lines giving the name of the program author and explanation about program.

The link section provides instructions to the complies to link functions from the library.
The definition section defines all symbolic constants.

In the global declaration section variables that are shared by all the functions are declared.
Every 'C' program must contains main () section. The main () section contains 2 parts declaration part and executable part.

There declaration parts declares all the variables used in the executable part.
The is atleast one statement in the opening and closing brace the program execution beings at opening brace '{' and end at closing brace '}' whic is the logical end of program. All statement in the declaration and executable part end with semi colon.

The sub program section contains user defined functions definition.

Except main () function section all the other sections may be absent in a program when they are not required.

Short notes.
'C' Character set:

The characters in 'C' are grouped in to following categories.

1. Letters - A-Z, a-z
2. Digits - 0-9
3. Special characters.
4. White spaces.

'C' tokens:

Individual words and punctuation names are called tockens.

In a 'C' program the smallest individual units are known as 'C' tockens. They are grouped in to Identifiers, Keywords, Constants, Symbols and Operators.

Identifiers:

Identifiers refer to the names of the variable function and arrays. These are user-defined names.

Rules of Identifiers:

1. Identifiers may contain sequence of letters and digits with a letter as first character, 2. Both uppercase and lower case letters are commonly used but uppercase variable and lower case variable are permitted.

Example:
             main
             amount

Keywords:

All keywords have fixed meaning and these meaning cannot be changed. Keywords save as a basic building blocks for program statements all the keywords must be written in lower case.

Example:
            float
            white

Constants:

Constants refer to fixed values that don't change during the execution of a program 'C' supports several types of constants, as shown below.

Constants - Numeric, Character.
Numeric - Integer, Real.
Character - Single character, String.

Integer Constant:

They refer to sequence of digits there are three types of integers.

1. Decimal Constant: It consists of set of digits 0 of through 9. Example: -123, 9.
2. Octal Constant: It consists of set of digits 0 through 7 with leading 0. Example: 037, 0. Rules: May be precedent by on optional + or -.
3. Hexa Decimal Constant: A sequence of digits preceded by ox. They may also include alphabets A through F, 10 represent No. 10 to 15. Example: ox2, ox9F Rules: Embedded  spaces, Commas, & non digit characters are not permitted.

Real Constants:

These quantities refer to the nos containing fractional part A real no may also be expressed in exponential notation. Example: 0.00083, -0.75.

Single Character Constant:

A single character constant refer a single character closed with in pair of single quote mark character constant have integer value known as ASCII value. Example: 'S', 'X', 'A'.

Back Slash Character Constant or Escape Sequence:

'C' Supports some special back slash character constants that are used in output functions although they consist of 2 characters the represent one character. These character combinations are know as Escape sequences. For example in represents new line character.
'\a' - alert (bell).
'\b' - Back Space.
'\f' - form feed.
'\n' - New line.
'\r' - Charrage return.
'\t' - Horizontal tab.
'\v' - Vertical tab.
'\'' - Single quote.
'\"' - Double quote.
'\?' - Question mark.
'\0' - Null character.

String Constant:

A string constant is a sequence of characters enclosed in double quotes. Example: "Hello", "Good", "r".

Saturday, July 11, 2009

Operating System (OS).

Operating System (OS).
Operating System is a program. That acts as an intermediatly between a user of computer and the computer hardware. The purpose of Operating System is to Provide environmental in which the user can execute the Program. An Operating System is similar to government. The component of compurer system. Systems are hardware, software and datas. The Operating System provides the means for the uses of resources in the Operation of the computer system. The Operating System perform no useful function by itself. If simply Provides and enviromental with in which other program can do successful work.

Friday, July 10, 2009

Modes of operation.

Modes of operation.

wireless network interface controller WNIC is a network card which connects to a radiobased computer network, unlike a regular network interface controller NIC which connects to a wirebased network such as token ring or ethernet. A WNIC, just like a NIC, works on the Layer and Layer of the OSI Model. A WNIC is an essential component for wireless desktop computer. This card uses an antenna to communicate through microwaves. A WNIC in a desktop computer usually is connected using the PCI bus. Other connectivity options are USB and PC card. Integrated WNICs are also available, typically in Mini PCIPCI Express Mini Card form.In an infrastructure mode network the WNIC needs an access point all data is transferred using the access point as the central hub. All wireless nodes in an infrastructure mode network connect to an access point. All nodes connecting to the access point must have the same service set identifier SSID as the access point, and if the access point is enabled with WEP they must have the same WEP key or other authentication parameters.

In an adhoc mode network the WNIC does not require an access point, but rather can directly interface with all other wireless nodes directly. All the nodes in an adhoc network must have the same channel and SSID.NICs are designed around the IEEE . standard which sets out lowlevel specifications for how all wireless networks operate. Earlier interface controllers are usually only compatible with earlier variants of the standard, while newer cards support both current and old standards.Wireless range may be substantially affected by objects in the way of the signal and by the quality of the antenna. Large electrical appliances, such as a refrigerators, fuse boxes, metal plumbing, and air conditioning units can block a wireless network signal. The theoretical maximum range is only reached under ideal circumstances and true effective range is typically about half of the theoretical range. Specifically, the maximum throughput speed is only achieved at extremely close range less than feet . m or so at the outer reaches of a devices effective range, speed may decrease to around Mbits before it drops out altogether.

Wireless network interface card.

Wireless network interface card.

WNICs are designed around the IEEE . standard which sets out lowlevel specifications for how all wireless networks operate. Earlier interface controllers are usually only compatible with earlier variants of the standard, while newer cards support both current and old standards.Wireless range may be substantially affected by objects in the way of the signal and by the quality of the antenna. Large electrical appliances, such as a refrigerators, fuse boxes, metal plumbing, and air conditioning units can block a wireless network signal. The theoretical maximum range is only reached under ideal circumstances and true effective range is typically about half of the theoretical range. Specifically, the maximum throughput speed is only achieved at extremely close range less than feet . m or so at the outer reaches of a devices effective range, speed may decrease to around Mbits before it drops out altogether. The reason is that wireless devices dynamically negotiate the top speed at which they can communicate without dropping too many data packets.

In computer networking, a Media Access Control address MAC address or Ethernet Hardware Address EHA, hardware address, adapter address or physical address is a quasiunique identifier assigned to most network adapters or network interface cards NICs by the manufacturer for identification. If assigned by the manufacturer, a MAC address usually encodes the manufacturers registered identification number.Although intended to be a permanent and globally unique identification, it is possible to change the MAC address on most of todays hardware, an action often referred to as MAC spoofing. Three numbering spaces, managed by the Institute of Electrical and Electronics Engineers IEEE, are in common use for formulating a MAC address MAC, EUI, and EUI. The IEEE claims trademarks on the names EUI and EUI, where EUI stands for Extended Unique Identifier.A host cannot determine a priori from the MAC address of another host whether that host is on the same OSI Layer network segment as the sending host or a network segment bridged to that network segment.

Network interface controller.

Network interface controller.

A MAC Address is a unique bit network hardware identifier that is burned into a ROM chip on the NIC to identify that device on the network. The first bits is called the Organizationally Unique Identifier OUI and is largely manufacturer dependent. Each OUI allows for ,, Unique NIC Addresses.Smaller manufacturers that do not have a need for over unique NIC addresses may opt to purchase an Individual Address Block IAB instead. An IAB consists of the bit OUI, plus a bit extension taken from the potential NIC portion of the MAC addressA wireless network interface controller WNIC is a network card which connects to a radiobased computer network, unlike a regular network interface controller NIC which connects to a wirebased network such as token ring or ethernet. A WNIC, just like a NIC, works on the Layer and Layer of the OSI Model.

A WNIC is an essential component for wireless desktop computer. This card uses an antenna to communicate through microwaves. A WNIC in a desktop computer usually is connected using the PCI bus. Other connectivity options are USB and PC card. In an infrastructure mode network the WNIC needs an access point all data is transferred using the access point as the central hub. All wireless nodes in an infrastructure mode network connect to an access point. All nodes connecting to the access point must have the same service set identifier SSID as the access point, and if the access point is enabled with WEP they must have the same WEP key or other authentication parameters.In an adhoc mode network the WNIC does not require an access point, but rather can directly interface with all other wireless nodes directly. All the nodes in an adhoc network must have the same channel and SSID.

Network interface controller.

Network interface controller.

There are four techniques used to transfer data, the NIC may use one or more of these techniques.Polling is where the microprocessor examines the status of the peripheral under program control.Programmed IO is where the microprocessor alerts the designated peripheral by applying its address to the systems address bus.Interruptdriven IO is where the peripheral alerts the microprocessor that its ready to transfer data.DMA is where the intelligent peripheral assumes control of the system bus to access memory directly. This removes load from the CPU but requires a separate processor on the card.A network card typically has a twisted pair, BNC, or AUI socket where the network cable is connected, and a few LEDs to inform the user of whether the network is active, and whether or not there is data being transmitted on it. Network Cards are typically available in Mbits varieties. This means they can support a transfer rate of , or Megabits per second.

A Network Interface Controller NIC is a hardware interface that handles and allows a network capable device access to a computer network such as the internet. The NIC has a ROM chip that has a unique Media Access Control MAC Address burned into it. The MAC address identifies the vendor and the serial number of the NIC which is unique to the card. Every NIC has a unique MAC address which identifies it on the LAN. The NIC exists on both the Physical Layer Layer and the Data Link Layer Layer of the OSI model.Sometimes the word controller and card is used interchangeably when talking about networking because the most common NIC is the Network Interface Card. Although card is more commonly used, it is in less encompassing. The controller may take the form of a network card that is installed inside a computer, or it may refer to an embedded component as part of a computer motherboard, a router, expansion card, printer interface, or a USB device.

Network Card.

Network Card.

A Network card, Network Adapter, LAN Adapter or NIC network interface card is a piece of computer hardware designed to allow computers to communicate over a computer network. It is both an OSI layer physical layer and layer data link layer device, as it provides physical access to a networking medium and provides a lowlevel addressing system through the use of MAC addresses. It allows users to connect to each other either by using cables or wirelessly.Although other network technologies exist, Ethernet has achieved nearubiquity since the mids. Every Ethernet network card has a unique bit serial number called a MAC address, which is stored in ROM carried on the card. Every computer on an Ethernet network must have a card with a unique MAC address. No two cards ever manufactured share the same address. This is accomplished by the Institute of Electrical and Electronics Engineers IEEE, which is responsible for assigning unique MAC addresses to the vendors of network interface controllers.

Whereas network cards used to be expansion cards that plug into a computer bus, the low cost and ubiquity of the Ethernet standard means that most newer computers have a network interface built into the motherboard. These either have Ethernet capabilities integrated into the motherboard chipset, or implemented via a low cost dedicated Ethernet chip, connected through the PCI or the newer PCI express bus. A separate network card is not required unless multiple interfaces are needed or some other type of network is used. Newer motherboards may even have dual network Ethernet interfaces builtin.The card implements the electronic circuitry required to communicate using a specific physical layer and data link layer standard such as Ethernet or token ring. This provides a base for a full network protocol stack, allowing communication among small groups of computers on the same LAN and largescale network communications through routable protocols, such as IP.

Printer.

Printer.

In computing, a printer is a peripheral which produces a hard copy (permanent human-readable text and/or graphics) of documents stored in electronic form, usually on physical print media such as paper or transparencies. Many printers are primarily used as local peripherals, and are attached by a printer cable or, in most newer printers, a USB cable to a computer which serves as a document source. Some printers, commonly known as network printers, have built-in network interfaces (typically wireless or Ethernet), and can serve as a hardcopy device for any user on the network. Individual printers are often designed to support both local and network connected users at the same time.
In addition, a few modern printers can directly interface to electronic media such as memory sticks or memory cards, or to image capture devices such as digital cameras, scanners; some printers are combined with a scanners and/or fax machines in a single unit, and can function as photocopiers. Printers that include non-printing features are sometimes called Multifunction Printers (MFP), Multi-Function Devices (MFD), or All-In-One (AIO) printers. Most MFPs include printing, scanning, and copying among their features. A Virtual printer is a piece of computer software whose user interface and API resemble that of a printer driver, but which is not connected with a physical computer printer.

Speakers.

Speakers.

Computer speakers, or multimedia speakers, are external speakers, commonly equipped with a low-power internal amplifier. The standard audio connection is a 3.5mm (1/8 inch) stereo jack plug often colour-coded lime green (following the PC 99 standard) for computer sound cards. A plug and socket for a two-wire (signal and ground) coaxial cable that is widely used to connect analog audio and video components. Also called a "phono connector," rows of RCA sockets are found on the backs of stereo amplifiers and numerous A/V products. The prong is 1/8" thick by 5/16" long. A few use an RCA connector for input. There are also USB speakers which are powered from the 5 volts at 200 milliamps provided by the USB port, allowing about half a watt of output power.
Computer speakers range widely in quality and in price. The computer speakers typically packaged with computer systems are small plastic boxes with mediocre sound quality. Some of the slightly better computer speakers have equalization features such as bass and treble controls, improving their sound quality somewhat.
The internal amplifiers require an external power source, known as a 'wall-wart'. More sophisticated computer speakers may have a 'subwoofer' unit, to enhance bass output, and these units usually include the power amplifiers both for the bass speaker, and the small 'satellite' speakers.
Some computer displays have rather basic speakers built-in. Laptops come with integrated speakers. Unfortunately the tight restriction on space inevitable in laptops means these speakers unavoidably produce low-quality sound.

Mouse.

Mouse.

In computing, a mouse (plural mouses, mice, or mouse devices) is a pointing device that functions by detecting two-dimensional motion relative to its supporting surface. Physically, a mouse consists of an object held under one of the user's hands, with one or more buttons. It sometimes features other elements, such as "wheels", which allow the user to perform various system-dependent operations, or extra buttons or features can add more control or dimensional input. The mouse's motion typically translates into the motion of a pointer on a display, which allows for fine control of a Graphical User Interface.
The name mouse, originated at the Stanford Research Institute, derives from the resemblance of early models (which had a cord attached to the rear part of the device, suggesting the idea of a tail) to the common mouse.