27
1 Paulo N.M. Sampaio Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira - UMA Paulo N.M. Sampaio Organização da disciplina Programa Teórico 1. Introdução (IPCHW 1) 2. Microprocessadores para PCs (IPCHW 3-14) 3. Chips de Memória (IPCHW 15) 4. Chipsets (IPCHW 16) 5. Interrupções e DMA (IPCHW 17) 6. RAM CMOS e RealtimeClock (IPCHW 18, 19) 7. Arquitecturas e Sistemas de BUS (IPCHW 20, 22, 25) 8. Dispositivos de Amazenamento (IPCHW 28, 29, 30, 31) 9. Periféricos (IPCHW 32, 33, 34, 35, 37)

Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

  • Upload
    others

  • View
    6

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

1

Paulo N.M. Sampaio

Arquitectura de Sistemas Computacionais

Prof. Dr. Paulo Sampaio

Universidade da Madeira - UMA

Paulo N.M. Sampaio

Organização da disciplina

Programa Teórico

1. Introdução (IPCHW 1)

2. Microprocessadores para PCs (IPCHW 3-14)

3. Chips de Memória (IPCHW 15)

4. Chipsets (IPCHW 16)

5. Interrupções e DMA (IPCHW 17)

6. RAM CMOS e RealtimeClock (IPCHW 18, 19)

7. Arquitecturas e Sistemas de BUS (IPCHW 20, 22, 25)

8. Dispositivos de Amazenamento (IPCHW 28, 29, 30, 31)

9. Periféricos (IPCHW 32, 33, 34, 35, 37)

Page 2: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

2

Paulo N.M. Sampaio

Device Operation

• The CPU needs a way to communicate with other devices in the computer to tell them what they should be doing.

• Devices need a way to send data to and receive data from the CPU.

• The Soutbridge and Northbridge handle these jobs.

Paulo N.M. Sampaio

The Acronym BIOS

• Initially the acronym BIOS was:– Basic Input Output System

• As technology has developed the BIOS acronym has come to mean:– Basic Input Output Service.

Page 3: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

3

Paulo N.M. Sampaio

The Relation between BIOS and CMOS

• Initially, motherboards contained two chips referred to as the system BIOS and CMOS chips.

• The BIOS chip contained a small program used to:– check the status of vital computer hardware and find the operating

system.

• BIOS then passed control of the computer to the operating system.

• CMOS stores changeable data used by BIOS

Paulo N.M. Sampaio

CMOS specifically

• CMOS – Complementary Metal Oxide Semiconductor.

• The CMOS chip is an Electronically Erasable Programmable Read Only Memory chip. (EEPROM)

• Using the CMOS set-up program we are able to change the data stored in the CMOS chip using the PC keyboard.

• BIOS reads data from the CMOS chip when the machine is booted.

Page 4: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

4

Paulo N.M. Sampaio

BIOS

• A special kind of program is required to enable the CPU to talk to other devices

• A ROM chip stores these programs

• These programs are collectively known as the Basic Input/Output Service (BIOS)

Paulo N.M. Sampaio

BIOS

• Each program is called a service

• Programs stored on ROM chips are known as firmware

• Programs stored on erasable media are called software

Keyboard controller

chip

Page 5: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

5

Paulo N.M. Sampaio

BIOS

• BIOS and its relation to memory addressing:

– The wire pattern generated by the address bus is called the address space

– The BIOS stored on the ROM chip attached to the motherboard is called the system BIOS

– The ROM chip that stores the system BIOS is called the system ROM

Paulo N.M. Sampaio

Core Group of Hardware

• Hardware that is common, necessary and never changes– Keyboard, speaker

• Stored on the system BIOS chip

BIOS is a group of programs. ROM is a hardware chip used to store BIOS.

Page 6: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

6

Paulo N.M. Sampaio

CMOS Group of Hardware

• Hardware that is common, necessary but may change

– RAM, hard drives, floppy drives, serial and parallel ports

– Complementary metal-oxide semiconductor

– Programs are stored on the system BIOS chip, while the changeable data is stored on a CMOS chip

All other hardware is non-core like mice, sound cards, and CD-ROMs.

Paulo N.M. Sampaio

CMOS Setup Utilities

Page 7: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

7

Paulo N.M. Sampaio

The CMOS Setup Program

• The data on the CMOS chip can be accessed and updated via the CMOS setup program.

• American Megatrends (AMI), Award software, and Phoenix Technologies are the main manufacturers of BIOS.

• Computer companies do not write their own BIOS programs.

• The CMOS setup can be accessed when the system boots, but there are different ways of doing that.

Paulo N.M. Sampaio

Accessing CMOS Setup

• During the Boot process while the screen is still black and white:– Look for a line that reads something like:

• To Enter CMOS Setup press DEL

• This is well before the Windows splash screen.

• Each BIOS, (computer) company may use a different set of key strokes to enter CMOS setup.

Page 8: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

8

Paulo N.M. Sampaio

Accessing the CMOS

• AMI and Award– Press DEL

• Phoenix– Press Ctrl-Alt-Esc or

F2

Other possible key combinations are: DEL, Ctrl-Alt-Ins, Ctrl-A, Ctrl-S, Ctrl-F1, F2, F10

Paulo N.M. Sampaio

CMOS Setup

• The floppy drive, hard drive, and the date/time settings can be changed using the standard CMOS setup

• Modern computers provide extra CMOS settings for memory management, password and booting options, error handling, and power management

Page 9: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

9

Paulo N.M. Sampaio

CMOS Setup for AwardMain Menu

Paulo N.M. Sampaio

CMOS Setup

• The following CMOS setting options are available:

– CPU soft menu – Enables you to set the voltage and multiplier settings on the motherboard for the CPU.

– Advanced BIOS feature – Used for selecting boot options.

– Advanced chipset features – Deals with extremely low-level chipset functions.

Page 10: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

10

Paulo N.M. Sampaio

CMOS Setup

• The following CMOS setting options are available (continued):

– Integrated peripherals – Allows you to configure, enable, or disable onboard ports.

– Power management setup – Used to setup power management settings for the system.

– PnP/PCI configurations – Used for assigning IRQs to certain resources.

Paulo N.M. Sampaio

CMOS Setup

• Other options include:

– Load Fail-Safe Defaults: used when low-level problems occur

– Load Optimized Defaults: sets the CMOS to the best possible speed and stability of the system

– Set Password

– Save and Exit Setup

– Exit Without Saving

Page 11: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

11

Paulo N.M. Sampaio

Soft Menu

Paulo N.M. Sampaio

Standard CMOS Features

Page 12: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

12

Paulo N.M. Sampaio

Advanced BIOS Features

Paulo N.M. Sampaio

Advanced Chipset Features

Page 13: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

13

Paulo N.M. Sampaio

Integrated Peripherals

Paulo N.M. Sampaio

Power Management Setup

Page 14: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

14

Paulo N.M. Sampaio

Plug and Play Configurations

Paulo N.M. Sampaio

CMOS Password

Page 15: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

15

Paulo N.M. Sampaio

Phoenix BIOS Setup

Paulo N.M. Sampaio

Older Award CMOS Setup

Page 16: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

16

Paulo N.M. Sampaio

CMOS Maintenance

• Common causes of loosing CMOS data are

– Battery run out, dirt, faulty power supply, electrical surges, and chip creeps

– The CMOS settings can be checked by memorizing settings, using Optimized defaults, and backing up a copy of the CMOS

To backup your CMOS to a floppy, use a third-party program such as cmossave.zip

Paulo N.M. Sampaio

Battery

• Since the data stored on a CMOS chip can be saved, power is required when the computer is turned off

• Power is supplied by a battery on the motherboard

• Batteries are mounted in one of three ways:– External battery (now obsolete)

– Onboard battery– Built-in battery (battery inside the CMOS chip, very common today)

Page 17: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

17

Paulo N.M. Sampaio

Clues to a Weak Battery

• Clock in Windows begins to slow down

• System keeps losing CMOS data when you turn it off

• If you have an external battery, check it with a voltmeter (3.6 or 6 volts)

• If a built-in battery dies, replace the motherboard (seldom happens)

Paulo N.M. Sampaio

BIOS and Device Drivers

Page 18: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

18

Paulo N.M. Sampaio

BYOB

• Because computer makers could not predict all the new types of hardware that may come out, ways to bring your own BIOS(BYOB) were invented:

– Option ROM is a BIOS chip embedded on the adapter card itself –every video card today comes with its own BIOS

– Most new hardware devices use device drivers to tell the BIOS how to talk to the CPU

– Most devices with onboard BIOS use it only for internal needs (internal function) and use a device driver to talk to the CPU

Paulo N.M. Sampaio

Device Drivers

• A device driver is a file that contains the BIOS commands necessary to communicate with the devices they support– Loaded in to the RAM when the system boots

• All devices come with their own device drivers

Page 19: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

19

Paulo N.M. Sampaio

Where are the Device Drivers?

• Registry – Binary file that contains the configuration settings and device driver

information

• Control Panel – Applets that enable the configuration of a broad range of system

devices

• Device Manager – Used for changing or removing drivers for any particular device

Paulo N.M. Sampaio

Manually Edit the Registry

• REGEDIT and REGEDIT32 – Enables you to access and update the Registry directly.

• Always make a backup before making manual changes to the Registry.

Page 20: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

20

Paulo N.M. Sampaio

CONFIG.SYS

• CONFIG.SYS is a special file through which DOS loads the device drivers– Located in the root directory of the C: drive– The EDIT/SYSEDIT program is used for editing such files

– Used to load extra BIOS for hardware that is not supported by the system BIOS

Paulo N.M. Sampaio

SYSTEM.INI

• The SYSTEM.INI file is located in the \Windows directory

– Broken up into groups and each group is identified by the name in square brackets that starts the section

– Standard sections are [boot], [keyboard], [boot description], [386Enh], and [drives]

– Most drivers that load are located in the [386 Enh] section

Page 21: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

21

Paulo N.M. Sampaio

SYSTEM.INI

Paulo N.M. Sampaio

SYSEDIT

Page 22: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

22

Paulo N.M. Sampaio

Control Panel

Paulo N.M. Sampaio

Device Manager

Page 23: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

23

Paulo N.M. Sampaio

Editing the Registry

Paulo N.M. Sampaio

The PC’s Real-Time Clock

Page 24: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

24

Paulo N.M. Sampaio

Non-Volatile Memory

• The original IBM-PC had no internal clock

• Users had to run a utility program to reset the date and time after any system reboot

• This defect was eliminated in the IBM-AT

• A special battery-powered peripheral was added to keep track of the time and date

• It also provided a small amount of memory which could retain configuration settings

Paulo N.M. Sampaio

Motorola’s MC146818A

• PC-AT’s Real-Time Clock plus RAM was manufactured by Motorola Corporation

• Other companies have ‘cloned’ this chip

• Its capabilities are described online in an official datasheet by Dallas Semiconductor (see ‘Maxim’ integrated circuit: DS12887)

• You can also get the Motorola datasheet (by writing to its corporate headquarters)

Page 25: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

25

Paulo N.M. Sampaio

Features of DS12887

• Can operate over ten years without power

• Counts seconds, minutes, hours, days, day-of-the-week, date, month, and year (with leap-year compensation), valid up until the year 2100 AD, with options for 12/24-hour clock and Daylight Savings

• Can use binary or BCD representation

• Provides 114 bytes of nonvolative storage

Paulo N.M. Sampaio

Programming Interface

• The RTC interfaces with system software as an array of 128 bytes, accessed via i/o ports 0x70 and 0x71 using a multiplexing scheme:

port 0x70: address-portport 0x71: data-port

Page 26: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

26

Paulo N.M. Sampaio

Ten clock/calendar bytes

Current seconds

Alarm seconds

Current minutes

Alarm minutes

Current hours

Alarm hours

Day-of-the-Week

Date of the Month

Current Month

Current Year

0x0

0x1

0x2

0x3

0x4

0x5

0x6

0x7

0x8

0x9

Range is 0..59

Range is 0..59

Range is 0..59

Range is 0..59

Range is 0..23 or 1..12

Range is 0..23 or 1..12

Range is 1..7 (Sunday=1)

Range is 1..31

Range is 1..12 (January=1)

Range is 0..99

Paulo N.M. Sampaio

Operating Capabilities

• The RTC can be programmed to generate an interrupt under any combination of the following three conditions:

1) time/date counters were updated

2) current time equals the alarm time

3) periodic frequency interval restarts

• The frequency of the periodic interrupt is a selectable rate (e.g., from 122 to 500ms)

Page 27: Arquitectura de Sistemas Computacionaiscee.uma.pt/edu/asc/2004-2005/material/Cap06.pdf · Arquitectura de Sistemas Computacionais Prof. Dr. Paulo Sampaio Universidade da Madeira -

27

Paulo N.M. Sampaio

Other NVRAM locations

• Besides these 14 dedicated RTC bytes, there are 114 byte locations which can serve as nonvolatile storage in whatever manner the system designer decides

• IBM has established some ‘standard’ uses for many (but not all) of these locations

• A fairly complete CMOS Memory Map is accessible online

Paulo N.M. Sampaio

Organização da disciplina

Programa Teórico

1. Introdução (IPCHW 1)

2. Microprocessadores para PCs (IPCHW 3-14)

3. Chips de Memoria (IPCHW 15)

4. Chipsets (IPCHW 16)

5. Interrupções e DMA (IPCHW 17)

6. RAM CMOS e RealtimeClock (IPCHW 18, 19)

7. Arquitecturas e Sistemas de BUS (IPCHW 20, 22, 25)

8. Dispositivos de Amazenamento (IPCHW 28, 29, 30, 31)

9. Periféricos (IPCHW 32, 33, 34, 35, 37)