Showing posts with label IT. Show all posts
Showing posts with label IT. Show all posts
Thursday, 13 March 2014
Friday, 12 July 2013
C# .Net (CONSOLE APPLIACTION) Online Shopping using 5 compoment (project) - SOA Lab - IT Department - Final Year
ONLINE SHOPPING PROGRAM USING C#
DOWNLOAD AS TEXT FILE
DOWNLOAD AS WORD FILE
DOWNLOAD C# PROJECT FILE
program.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using computer;
using com_det;
using invoice;
using orderclass;
using customer;
namespace Exp1
{
class Program
{
static void Main(string[] args)
{
//string i;
int h;
Console.WriteLine(" Online Shopping ");
Console.WriteLine(" Computer Sales !!!! ");
Console.WriteLine(" 1. View Catalogue ");
Console.WriteLine(" 2. Exit ");
Console.WriteLine(" Enter your choice ");
h = Convert.ToInt32(Console.ReadLine());
switch (h)
{
case 1:
{
ara:
com ob1 = new com();
ob1.display();
co_det ob2=new co_det();
ob2.display();
cus ob3 = new cus();
ob3.display();
Console.WriteLine(" Do you want to view catalog (Y/N)");
string ch;
ch = Console.ReadLine();
if (ch == "y" || ch == "Y")
{
goto ara;
}
else
{
corder ob4 = new corder();
ob4.display();
inv ob5 = new inv();
ob5.display();
}
break;
}
default:
{
Console.WriteLine(" INVALID SELECTION ");
Console.ReadLine();
}
break;
}
}
}
}
computer.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace computer
{
public class com
{
int a;
public void display()
{
Console.WriteLine(" COMPUTERS BRAND ");
Console.WriteLine(" 1. Sony ");
Console.WriteLine(" 2. Dell ");
Console.WriteLine(" 3. HCL ");
Console.WriteLine(" 4. Samsung ");
}
}
}
com_det.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace com_det
{
class co_det
{
int d;
public void display()
{
Console.WriteLine(" SELECT YOUR DESIRED COMPUTER ");
d = Convert.ToInt32(Console.ReadLine());
switch (d)
{
case 1:
{
Console.WriteLine(" You have Selected SONY ");
Console.WriteLine(" Model - SV101");
Console.WriteLine(" ITEM ID : 001");
Console.WriteLine(" Price : Rs. 27,550 only /- ");
break;
}
case 2:
{
Console.WriteLine(" You have Selected DELL ");
Console.WriteLine(" Model - Inspiron ");
Console.WriteLine(" ITEM ID : 002");
Console.WriteLine(" Price : Rs. 29,550 only /- ");
break;
}
case 3:
{
Console.WriteLine(" You have Selected HCL ");
Console.WriteLine(" Model - ME ");
Console.WriteLine(" ITEM ID : 003");
Console.WriteLine(" Price : Rs. 25,550 only /- ");
break;
}
case 4:
{
Console.WriteLine(" You have Selected SAMSUNG ");
Console.WriteLine(" Model - ChromeBook ");
Console.WriteLine(" ITEM ID : 004");
Console.WriteLine(" Price : Rs. 15,550 only /- ");
break;
}
default:
Console.WriteLine(" Invalid Selection");
break;
}
}
}
}
customer.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace customer
{
public class cus
{
string name;
string add;
string phno;
string email;
public void display()
{
int q;
Console.WriteLine(" Do you want to Continue ...! ");
Console.WriteLine(" Fill the customer form ");
Console.WriteLine();
Console.WriteLine(" 1. YES ");
Console.WriteLine(" 2. NO ");
q = Convert.ToInt32(Console.ReadLine());
switch (q)
{
case 1:
{
Console.WriteLine(" Enter your name : ");
name=Console.ReadLine();
Console.WriteLine(" Enter your address : ");
add=Console.ReadLine();
Console.WriteLine(" Enter your Phone Number : ");
phno=Console.ReadLine();
Console.WriteLine(" CONFIRM YOUR SHIPPING DETAILS ");
Console.WriteLine(" Name : "+name);
Console.WriteLine(" Address : "+add);
Console.WriteLine(" Phone : "+phno);
Console.ReadLine();
break;
}
}
}
}
}
invoice.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace invoice
{
class inv
{
public void display()
{
Console.WriteLine(" Your Product will be delivered on : "+DateTime.Now.Date.AddDays(2).ToString("dd-MM-yyyy"));
Console.ReadLine();
}
}
}
orderclass.cs
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace orderclass
{
public class corder
{
int s;
public void display()
{
Console.WriteLine(" Select your payment method ");
Console.WriteLine(" 1. CHEQUE");
Console.WriteLine(" 2. CASH ");
s = Convert.ToInt32(Console.ReadLine());
switch (s)
{
case 1:
{
Console.WriteLine(" Enter your account number : ");
Console.ReadLine();
Console.WriteLine(" Name of the bank : ");
Console.ReadLine();
Console.WriteLine();
Console.WriteLine(" Your Order is Confirmed ");
}
break;
case 2:
Console.WriteLine(" Your orderis confirmed ");
break;
}
}
}
}
OUTPUT:
Tuesday, 9 July 2013
IT2032 SOFTWARE TESTING VII Semester - Final Year - IT Department (ELECTIVE)
IT2032 SOFTWARE TESTING (ELECTIVE)
UNIT I INTRODUCTION
Testing as an Engineering Activity – Role of Process in
Software Quality – Testing as a
Process – Basic Definitions – Software Testing Principles
– The Tester’s Role in a
Software Development Organization – Origins of Defects –
Defect Classes – The Defect
Repository and Test Design – Defect Examples –
Developer/Tester Support for
Developing a Defect Repository.
UNIT II TEST CASE DESIGN
Introduction to Testing Design Strategies – The Smarter
Tester – Test Case Design
Strategies – Using Black Box Approach to Test Case Design
Random Testing –
Requirements based testing – positive and negative
testing -–– Boundary Value
Analysis – decision tables - Equivalence Class
Partitioning state-based testing– causeeffect
graphing – error guessing - compatibility testing – user
documentation testing –
domain testing Using White–Box Approach to Test design –
Test Adequacy Criteria –
static testing vs. structural testing – code functional
testing - Coverage and Control Flow
Graphs – Covering Code Logic – Paths – Their Role in
White–box Based Test Design –
code complexity testing – Evaluating Test Adequacy
Criteria.
UNIT III LEVELS OF TESTING
The Need for Levels of Testing – Unit Test – Unit Test
Planning –Designing the Unit
Tests. The Test Harness – Running the Unit tests and
Recording results – Integration
tests – Designing Integration Tests – Integration Test
Planning – scenario testing –
defect bash elimination -System Testing – types of system
testing - Acceptance testing –
performance testing - Regression Testing –
internationalization testing – ad-hoc testing -
Alpha – Beta Tests – testing OO systems – usability and
accessibility testing
UNIT IV TEST MANAGEMENT
People and organizational issues in testing –
organization structures for testing teams –
testing services - Test Planning – Test Plan Components –
Test Plan Attachments –
Locating Test Items – test management – test process -
Reporting Test Results – The
role of three groups in Test Planning and Policy
Development – Introducing the test
specialist – Skills needed by a test specialist –
Building a Testing Group.
UNIT V CONTROLLING AND MONITORING
Software test automation – skills needed for automation –
scope of automation – design
and architecture for automation – requirements for a test
tool – challenges in automation
- Test metrics and measurements –project, progress and
productivity metrics – Status
Meetings – Reports and Control Issues – Criteria for Test
Completion – SCM – Types of
reviews – Developing a review program – Components of
Review Plans– Reporting
Review Results. – evaluating software quality – defect
prevention – testing maturity
model
TOTAL : 45
PERIODS
TEXT BOOKS:
1. IIene Burnstein “Practical Software Testing” Springer
International Edition Chennai,
2003
2. Srinivasan Desikan and Gopalaswamy Ramesh, “ Software
Testing – Principles and
Practices”, Pearson education, 2006.. 3. Aditya P.Mathur,
“Foundations of Software Testing”, Pearson Education,2008.
IT2042 INFORMATION SECURITY - VII Semester - Final Year - IT Department (ELECTIVE)
IT2042 INFORMATION SECURITY (ELECTIVE)
UNIT I INTRODUCTION
History, what is Information Security, Critical
Characteristics of Information, NSTISSC
Security Model, Components of an Information System,
Securing the Components,
Balancing Security and Access, The SDLC, The Security
SDLC
UNIT II SECURITY INVESTIGATION
Need for Security, Business Needs, Threats, Attacks,
Legal, Ethical and Professional
Issues
UNIT III SECURITY ANALYSIS
Risk Management : Identifying and Assessing Risk,
Assessing and Controlling Risk
UNIT IV LOGICAL DESIGN
Blueprint for Security, Information Security Poicy,
Standards and Practices, ISO
17799/BS 7799, NIST Models, VISA International Security
Model, Design of Security
Architecture, Planning for Continuity
UNIT V PHYSICAL DESIGN
Security Technology, IDS, Scanning and Analysis Tools,
Cryptography, Access Control
Devices, Physical Security, Security and Personnel
TOTAL : 45 PERIODS
TEXT BOOK:
1. Michael E Whitman and Herbert J Mattord, “Principles
of Information Security”, Vikas
Publishing House, New Delhi, 2003
76
REFERENCES:
1. Micki Krause, Harold F. Tipton, “ Handbook of
Information Security Management”,
Vol 1-3 CRC Press LLC, 2004.
2. Stuart Mc Clure, Joel Scrambray, George Kurtz,
“Hacking Exposed”, Tata McGraw-
Hill, 2003
3. Matt
Bishop, “ Computer Security Art and Science”, Pearson/PHI, 2002.
IT2403 SOFTWARE PROJECT MANAGEMENT - VII Semester - Final Year - IT Department
IT2403 SOFTWARE PROJECT MANAGEMENT
UNIT I INTRODUCTION TO SOFTWARE
PROJECT MANAGEMENT
Project Definition – Contract Management – Activities
Covered By Software Project
Management – Overview Of Project Planning – Stepwise
Project Planning.
UNIT II PROJECT EVALUATION
Strategic Assessment – Technical Assessment – Cost
Benefit Analysis –Cash Flow
Forecasting – Cost Benefit Evaluation Techniques – Risk
Evaluation.
UNIT III ACTIVITY PLANNING
Objectives – Project Schedule – Sequencing and Scheduling
Activities –Network
Planning Models – Forward Pass – Backward Pass – Activity
Float – Shortening Project
Duration – Activity on Arrow Networks – Risk Management –
Nature Of Risk – Types Of
Risk – Managing Risk – Hazard Identification – Hazard
Analysis – Risk Planning And
Control.
UNIT IV MONITORING AND CONTROL
Creating Framework – Collecting The Data – Visualizing
Progress – Cost Monitoring –
Earned Value – Priortizing Monitoring – Getting Project
Back To Target – Change
Control – Managing Contracts – Introduction – Types Of
Contract – Stages In Contract
Placement – Typical Terms Of A Contract – Contract
Management – Acceptance.
UNIT V MANAGING PEOPLE AND ORGANIZING
TEAMS
Introduction – Understanding Behavior – Organizational
Behaviour: A Background –
Selecting The Right Person For The Job – Instruction In
The Best Methods – Motivation
– The Oldman – Hackman Job Characteristics Model –
Working In Groups – Becoming
A Team –Decision Making – Leadership – Organizational
Structures – Stress –Health
And Safety – Case Studies.
TOTAL: 45PERIODS
TEXT BOOK
1. Bob Hughes, Mikecotterell, “Software Project
Management”, Third Edition, Tata
McGraw Hill, 2004.
REFERENCES
1. Ramesh, Gopalaswamy, "Managing Global
Projects", Tata McGraw Hill, 2001.
2. Royce, “Software Project Management”, Pearson
Education, 1999.
3. Jalote,
“Software Project Management in Practice”, Pearson Education, 2002.
CS2401 COMPUTER GRAPHICS Syllabus - VII Semester - Final Year - IT Department
CS2401 COMPUTER GRAPHICS
UNIT I 2D PRIMITIVES
Output primitives – Line, Circle and Ellipse drawing algorithms
- Attributes of output
primitives – Two dimensional Geometric transformation -
Two dimensional viewing –
Line, Polygon, Curve and Text clipping algorithms
UNIT II 3D CONCEPTS
Parallel and Perspective projections - Three dimensional
object representation –
Polygons, Curved lines, Splines, Quadric Surfaces,-
Visualization of data sets - 3D
transformations – Viewing -Visible surface
identification.
UNIT III GRAPHICS PROGRAMMING
Color Models – RGB, YIQ, CMY, HSV – Animations – General
Computer Animation,
Raster, Keyframe - Graphics programming using OPENGL –
Basic graphics primitives –
Drawing three dimensional objects - Drawing three
dimensional scenes
UNIT IV RENDERING
Introduction to Shading models – Flat and Smooth shading
– Adding texture to faces –
Adding shadows of objects – Building a camera in a
program – Creating shaded objects
– Rendering texture – Drawing Shadows.
UNIT V FRACTALS
Fractals and Self similarity – Peano curves – Creating
image by iterated functions –
Mandelbrot sets – Julia Sets – Random Fractals – Overview
of Ray Tracing –
Intersecting rays with other primitives – Adding Surface
texture – Reflections and
Transparency – Boolean operations on Objects.
TOTAL :45PERIODS
TEXT BOOKS:
1. Donald Hearn, Pauline Baker, Computer Graphics – C
Version, second edition,
Pearson Education,2004.
2. F.S. Hill, Computer Graphics using OPENGL, Second
edition, Pearson
Education,200UNIT III
REFERENCES:
1. James D. Foley, Andries Van Dam, Steven K. Feiner,
John F. Hughes, Computer
Graphics-
Principles and practice, Second Edition in C, Pearson Education, 2007.
IT2402 Mobile Communication Syllabus - VII Semester - Final Year - IT Department
IT2402 MOBILE COMMUNICATION
UNIT I WIRELESS COMMUNICATION 7
Cellular systems- Frequency Management and Channel
Assignment- types of handoff
and their characteristics, dropped call rates & their
evaluation -MAC – SDMA – FDMA –
TDMA – CDMA – Cellular Wireless Networks
UNIT II WIRELESS NETWORKS 9
Wireless LAN – IEEE 802.11 Standards – Architecture –
Services – Mobile Ad hoc
Networks- WiFi and WiMAX - Wireless Local Loop
UNIT III MOBILE COMMUNICATION SYSTEMS 11
GSM-architecture-Location tracking and call setup-
Mobility management- Handover-
Security-GSM SMS –International roaming for GSM- call
recording functions-subscriber
and service data mgt –-Mobile Number portability -VoIP
service for Mobile Networks –
GPRS –Architecture-GPRS procedures-attach and detach
procedures-PDP context
procedure-combined RA/LA update procedures-Billing
UNIT IV MOBILE NETWORK AND TRANSPORT
LAYERS 9
Mobile IP – Dynamic Host Configuration Protocol-Mobile Ad
Hoc Routing Protocols–
Multicast routing-TCP over Wireless Networks – Indirect
TCP – Snooping TCP – Mobile
TCP – Fast Retransmit / Fast Recovery – Transmission/Timeout
Freezing-Selective
Retransmission – Transaction Oriented TCP- TCP over 2.5 /
3G wireless Networks
UNIT V APPLICATION LAYER 9
WAP Model- Mobile Location based services -WAP Gateway
–WAP protocols – WAP
user agent profile- caching model-wireless bearers for
WAP - WML – WMLScripts - WTA
- iMode- SyncML
TOTAL :45PERIODS
TEXT BOOKS: 1. Jochen Schiller, “Mobile
Communications”, Second Edition, Pearson Education,
200UNIT III
2. William Stallings, “Wireless Communications and
Networks”, Pearson Education,
2002.
REFERENCES:
1. Kaveh Pahlavan, Prasanth Krishnamoorthy, “Principles
of Wireless Networks”, First
Edition, Pearson Education, 200UNIT III
2. Uwe Hansmann, Lothar Merk, Martin S. Nicklons and
Thomas Stober, “Principles of
Mobile Computing”, Springer, 200UNIT III
3. C.K.Toh,
“AdHoc Mobile Wireless Networks”, First Edition, Pearson Education, 2002.
IT2401 Service Oriented Architecture Syllabus - VII Semester - Final Year - IT Department
IT2401 SERVICE ORIENTED ARCHITECTURE
UNIT I
Roots of SOA – Characteristics of SOA - Comparing SOA to
client-server and distributed
internet architectures – Anatomy of SOA- How components
in an SOA interrelate -
Principles of service orientation
UNIT II
Web services – Service descriptions – Messaging with SOAP
–Message exchange
Patterns – Coordination –Atomic Transactions – Business
activities – Orchestration –
Choreography - Service layer abstraction – Application
Service Layer – Business
Service Layer – Orchestration Service Layer
UNIT III
Service oriented analysis – Business-centric SOA –
Deriving business services- service
modeling - Service Oriented Design – WSDL basics – SOAP
basics – SOA composition
guidelines – Entity-centric business service design –
Application service design – Taskcentric
business service design
UNIT IV
SOA platform basics – SOA support in J2EE – Java API for
XML-based web services
(JAX-WS) - Java architecture for XML binding (JAXB) –
Java API for XML Registries
(JAXR) - Java API for XML based RPC (JAX-RPC)- Web
Services Interoperability
Technologies (WSIT) - SOA support in .NET – Common
Language Runtime - ASP.NET
web forms – ASP.NET web services – Web Services
Enhancements (WSE)
UNIT V
WS-BPEL basics – WS-Coordination overview -
WS-Choreography, WS-Policy, WSSecurity
TOTAL : 45 PERIODS
TEXT BOOKS:
1. Thomas Erl, “Service-Oriented Architecture:
Concepts, Technology, and Design”,
Pearson Education, 2005.
REFERENCES:
1. Thomas Erl, “SOA Principles of Service Design “(The
Prentice Hall Service-Oriented
Computing Series from Thomas Erl), 2005.
2. Newcomer, Lomow, “Understanding SOA with Web
Services”, Pearson Education,
2005.
3. Sandeep Chatterjee, James Webber, “Developing
Enterprise Web Services, An
Architect’s Guide”, Pearson Education, 2005.
4. Dan Woods and Thomas Mattern, “Enterprise SOA
Designing IT for Business
Innovation”
O’REILLY, First Edition, 2006
Saturday, 25 May 2013
IT2351 Network Programming and Management Excepted Question May/June 2013
Network Programming and Management IT2351
UNIT I-V
1. Explain select and Poll Function in detail.
2. Explain in detail about TCPIIP protocols for lnternetworking and Management
3. Create a TCP socket for acting as a multiple server and echoing the information from the client.
4. write notes on Iterative Server and Concurrent Server Operation
5. Describe about the different socket option for internet operation and control
6. Discuss lPv6 support in DNS
7. Explain the purpose and usage of UDP socket and their different functions.
8. Explain DNS in Detail
9. Explain Trace route program with sample code and example
ao.Explain how a TCP echo server using threads is created and also give their advantages
ii. Elaborate about raw socket creation, input and output
12.Write a Short note on mutexes and Condition variables
13. Explain the syntax of the various SNMPvi. message format
14. Explain lpv4 and lpv6 interoperability in details
15. Explain Network monitoring in detail.
16.Explain the architecture of SNMPv3 with neat diagram
17. Compare SNMPv2 And SNMPv3.
i8.Explain the architecture of SNMP entity and traditional SNMP manager as specified in
RFC2 271
19.What is meant by trap-directed polling? Discuss
Wednesday, 22 May 2013
IT2353 Web Technology - Expected Question For Anna University Exam | Unit Wise | Important Question
IT2353 Web Technology
Important Unit
UNIT WISE
Unit 1
1. Describe IP?
2. Explain any 4 HTML Element.
3. Explain List, Table, Frame, Form Element.
4. Different between HTML & XHTML
5. HTTP request and HTTP response.
6. Web Server
7. URL
UNIT 2
1. Explain all Selector Strings.
2. CSS
3. What is Statement in JavaScript? Explain.
4. Explain Functions in JavaScript.
5. Explain JavaScript Array.
6. JavaScript Debugging.
7. Local and Global Functions.
UNIT 3
1. Document Tree.
2. DOM Event Handling.
3. Explain about SERVLET.
4. Explain Session.
5. Dynamic content generation by servlet.
6. Explain how java Servlet performs handling.
UNIT 4
1. XML Syntax and Rules.
2. How XML document displayed in browser.
3. Information in JSP Document.
4. Xpath Node.
5. AJAX Object.
6. JavaBeans Component.
7. XML namespace.
8. XML path language.
9. MVC Architecture.
UNIT 5
1. XML Schema
2. JDBC database Access.
3. SOAP.
4. WSDL
5. Creation of Java Web Server
THANKS :)
Important Unit
UNIT WISE
Unit 1
1. Describe IP?
2. Explain any 4 HTML Element.
3. Explain List, Table, Frame, Form Element.
4. Different between HTML & XHTML
5. HTTP request and HTTP response.
6. Web Server
7. URL
UNIT 2
1. Explain all Selector Strings.
2. CSS
3. What is Statement in JavaScript? Explain.
4. Explain Functions in JavaScript.
5. Explain JavaScript Array.
6. JavaScript Debugging.
7. Local and Global Functions.
UNIT 3
1. Document Tree.
2. DOM Event Handling.
3. Explain about SERVLET.
4. Explain Session.
5. Dynamic content generation by servlet.
6. Explain how java Servlet performs handling.
UNIT 4
1. XML Syntax and Rules.
2. How XML document displayed in browser.
3. Information in JSP Document.
4. Xpath Node.
5. AJAX Object.
6. JavaBeans Component.
7. XML namespace.
8. XML path language.
9. MVC Architecture.
UNIT 5
1. XML Schema
2. JDBC database Access.
3. SOAP.
4. WSDL
5. Creation of Java Web Server
THANKS :)
Thursday, 2 May 2013
NOTES FOR THE 6th SEMESTER .......... INFORMATION TECHNOLOGY DEPT
NOTES FOR THE 6th SEMESTER .......... INFORMATION TECHNOLOGY DEPT
pls click the link below to download the notes.........https://docs.google.com/file/d/0B1MEIl-F-DIQbncyM3VmekplTDA/edit?usp=sharing
BITSA wishes all its subscribers all success for the exams!!!!!!!!
further notes to be updated soon.........
Wednesday, 13 March 2013
IT2354 - Embedded System notes - "INTERRUPT"
DOWNLOAD AS WORD FILE
InterruptsBasicsBusy-wait I/O is extremely inefficient—the CPU does nothing but test the device statuswhile the I/O transaction is in progress. In many cases, the CPU could do useful work inparallel with the I/O transaction, such as:ücomputation, as in determining the next output to send to the device or processingthe last input received, andücontrol of other I/O devices. To allow parallelism,we need to introducenewThe interrupt mechanism allows devices to signal the CPU and to force execution of aparticular piece of code. When an interrupt occurs, the program counter’s value is changedto point to an interrupt handler routine (also commonly known as a device driver) thattakes care of the device: writing the next data, reading data that have just become ready,and so on. The interrupt mechanism of course saves the value of the PC at the interruptionso that the CPU can return to the program that was interrupted. Interrupts therefore allowthe flow of control in the CPU to change easily between different contexts, such as aforeground computation and multiple I/O devices. As shown in Figure, the interfacebetween the CPU and I/O device includes the following signals for interrupting:ü the I/O device asserts the interrupt request signal when it wants service from theCPU; andü the CPU asserts the interrupt acknowledge signal when it is ready to handle the I/Odevice’s request.The I/O device’s logic decides when to interrupt; for example, it may generate aninterrupt when its status register goes into the ready state. The CPU may not be able toimmediately service an interrupt request because it may be doing something else that mustbe finished first—for example, a program that talks to both a high-speed disk drive anda low-speed keyboard should be designed to finish a disk transaction before handling akeyboard interrupt. Only when the CPU decides to acknowledge the interrupt does theCPU change the program counter to point to the device’s handler. The interrupt handleroperates much like a subroutine, except that it is not called by the executing program.The program that runs when no interrupt is being handled is often called the foregroundprogram; when the interrupt handler finishes, it returns to the foreground program,wherever processing was interrupted.The interrupt mechanism.Ø Priorities and VectorsProviding a practical interrupt system requires having more than a simple interruptrequest line. Most systems have more than one I/O device, so there must be some mechanismfor allowing multiple devices to interrupt.We also want to have flexibility in the locations of theinterrupt handling routines,the addresses for devices,and so on. There are two ways in whichinterrupts can be generalized to handle multiple devices and to provide more flexible definitionsfor the associated hardware and software:ü interrupt priorities allow the CPU to recognize some interrupts as more importantthan others, andü interrupt vectors allow the interrupting device to specify its handler.Prioritized interrupts not only allow multiple devices to be connected to the interruptline but also allow the CPU to ignore less important interrupt requests while it handles moreimportant requests. As shown in Figure, the CPU provides several different interrupt requestsignals, shown here as L1, L2, up to Ln. Typically, the lower-numbered interrupt lines are givenhigher priority, so in this case, if devices 1, 2,and n all requested interrupts simultaneously, 1’srequest would be acknowledged because it is connected to the highest-priority interrupt line.Rather than provide a separate interrupt acknowledge line for each device, most CPUsuse a set of signals that provide the priority number of the winning interrupt in binary form (sothat interrupt level 7 requires 3 bits rather than 7). A device knows that its interrupt request wasaccepted by seeing its own priority number on the interrupt acknowledge lines.Prioritized device interrupts.How do we change the priority of a device?Simply by connecting it to a different interrupt request line. This requires hardwaremodification, so if priorities need to be changeable, removable cards, programmable switches, orsome other mechanism should be provided to make the change easy.The priority mechanism must ensure that a lower-priority interrupt does not occur whena higher-priority interrupt is being handled. The decision process is known as masking. Whenan interrupt is acknowledged, the CPU stores in an internal register the priority level of thatinterrupt. When a subsequent interrupt is received, its priority is checked against the priorityregister; the new request is acknowledged only if it has higher priority than the currently pendinginterrupt.When the interrupt handler exits, the priority register must be reset. The need to reset thepriority register is one reason why most architectures introduce a specialized instruction to returnfrom interrupts rather than using the standard subroutine return instruction. The highest-priorityinterrupt is normally called the non maskable interrupt (NMI).The NMI cannot be turned offand is usually reserved for interrupts caused by power failures—a simple circuit can be usedto detect a dangerously low power supply, and the NMI interrupt handler can be used to savecritical state in nonvolatile memory, turn off I/O devices to eliminate spurious device operationduring power down, and so on.Most CPUs provide a relatively small number of interrupt priority levels, such as eight.While more priority levels can be added with external logic, they may not be necessary in allcases. When several devices naturally assume the same priority (such as when you have severalidentical keypads attached to a single CPU), you can combine polling with prioritized interruptsto efficiently handle the devices.Using polling to share an interrupt over several devices.Vectors provide flexibility in a different dimension, namely, the ability to define theinterrupt handler that should service a request from a device. Figure shows the hardwarestructure required to support interrupt vectors. In addition to the interrupt request andacknowledge lines, additional interrupt vector lines run from the devices to the CPU. After adevice’s request is acknowledged, it sends its interrupt vector over those lines to the CPU. TheCPU then uses the vector number as an index in a table stored in memory as shown in Figure.The location referenced in the interrupt vector table by the vector number gives the address ofthe handler.There are two important things to notice about the interrupt vector mechanism.First, the device, not the CPU, stores its vector number. In this way, a device can be givena new handler simply by changing the vector number it sends, without modifying the systemsoftware. For example, vector numbers can be changed by programmable switches.The second thing to notice is that there is no fixed relationship between vector numbersand interrupt handlers. The interrupt vector table allows arbitrary relationships between devicesand handlers. The vector mechanism provides great flexibility in the coupling of hardwaredevices and the software routines that service them.Most modern CPUs implement both prioritized and vectored interrupts. Prioritiesdetermine which device is serviced first, and vectors determine what routine is used to servicethe interrupt. The combination of the two provides a rich interface between hardware andsoftware.
Subscribe to:
Posts (Atom)

