基本的BIOS概念(1)ppt課件_第1頁
基本的BIOS概念(1)ppt課件_第2頁
基本的BIOS概念(1)ppt課件_第3頁
基本的BIOS概念(1)ppt課件_第4頁
基本的BIOS概念(1)ppt課件_第5頁
已閱讀5頁,還剩43頁未讀, 繼續(xù)免費(fèi)閱讀

下載本文檔

版權(quán)說明:本文檔由用戶提供并上傳,收益歸屬內(nèi)容提供方,若內(nèi)容存在侵權(quán),請進(jìn)行舉報或認(rèn)領(lǐng)

文檔簡介

1、The Basic BIOS ConceptsPresent by Judy Mei2003-8 1.The Basic BIOS Concepts 1. BIOS Introduction 2. System Memory Map 3. BIOS Components and Features 4. BIOS Services and Interrupts 5. I/O Ports Addresses 6. Power-On-Self-Test(POST) 7. Conclusion2.1. BIOS Introduction 1.1 What is BIOS 1.2 Types of BI

2、OS 1.3 Parts of the ROM BIOS3.1.1 What is BIOS? BIOS stands for Basic Input/Output System. The system BIOS is the lowest-level software in the computer; it acts as an interface between the hardware (especially the chipset and processor) and the operating system. The BIOS provides access to the syste

3、m hardware and enables the creation of the higher-level operating systems (DOS, Windows 95, etc.) that you use to run your applications. The BIOS is responsible for allowing you to control your computers hardware settings, for booting up the machine when you turn on the power or hit the reset button

4、, and various other system functions.Layer#Layer0Hardware1System BIOS2Operating System3Application4.The BIOS and Hardware Independence In order to allow operating systems and applications to run on a PC, (almost irrespective of its age), the BIOS provides a standard layer of services that the operat

5、ing system can use to talk to the hardware. In turn, the operating system provides standard services to applications to perform their functions. This means that one layer has to know how to communicate with the layer above (or below) only. This layering of services allows applications to run on virt

6、ually any PC regardless of the type of hardware.5.1.2 Types of BIOS There are three standard BIOS present in most systems and located pretty much at the same place: System BIOS:The main system BIOS is located in a 64KB block of memory from F0000 h to FFFFF h. VGA Video BIOS: This is the BIOS that co

7、ntrols your video card. It is normally in the 32KB block from C0000 h to C7FFF h IDE Hard disks and other peripherals BIOS:The BIOS that controls your IDE hard disk, if you have IDE in your system (which most do) is located from C8000 h to CBFFF h.6.1.3 Parts of the ROM BIOSThe system ROM elements i

8、n a computer usually are:POST,the ROM BIOS itself, andthe BIOS Setup utility.The following graphic depicts these elements:PostExecutes at Power-on and system resetBIOS setup utilityDiagnostics and Utility softwareSystem BIOSExecutes only when you presswhen “Hit to run SETUP to displayedExecutes only

9、 when you presswhen “Hit to run SETUP to displayedAlways available as interface between hardware and software7.2. X86 Memory Map000FFFFFh1024K00000000hDOS core program000F0000h000C0000h000C8000h000B0000h000B8000h000A0000h000XXXX0hROM BIOS runtime program(64K)Reserve for expansion cardEGA/VGA BIOSBla

10、ck&white text dataColor text dataEGA/VGA color graph dataDOS application area960K800K768K736K704K640K0KUpper memory block(1M)Base memory4GB(4096K)HMA(High Memory Area)1088K00110000hFFFFFFFF h.Extend memory8.Memory Map9.10.3.BIOS Components and Features 3.1 System RAM 3.2 CMOS RAM 3.3 ROM BIOS11.3.1

11、Data in System RAMData AreaLocationRemarkInterrupt Vector Table000h-3FFhInterrupt vector saved as segmentsBIOS Data base400h-4FFhBIOS working area, including description of HDD, FDD, Keyboard, video and other BIOS characteristics and functions 12. 3.2 CMOS RAM CMOS (Complimentary Metal Oxide Semicon

12、ductor) RAM is a small amount of volatile memory in a special RAM chip that stores the real time clock settings and configuration information for a PC. Plug-and-Play BIOS uses additional non-volatile memory to hold Extended System Configuration Data (ESCD). This is used to store system resource sett

13、ings of system devices such as IRQ and I/O addresses.Data AreaI/O port(Read/Write)SizeDescriptionCMOS RAM data070h&071h64ByteStore the Clock, POST and system configuration data.13.Data in CMOS RAMI/O addressRead/WriteDescription0070hWCMOS RAM address register:Bite 7 = 1 disable NMI = 0 able NMI0071h

14、 R/WCMOS RAM data register To read CMOS RAM, use the following Intel x86 assembler instructions: OUT 70h,Register Number IN AL,71h To write to CMOS RAM, use the following instructions: OUT 70h,Register Number OUT 71h,New_Value14.PARTS of CMOSCMOS RAM is divided into several parts:LocationLength Desc

15、ription 00h 0Fh 16 bytes Real Time Clock data. 10h 2Fh 32 bytes ISA configuration data. 30h 3Fh 16 bytes AMIBIOS-specific configuration data. 40h 7Fh 64 bytes Extended CMOS RAM. Available in many computers. Many chipsets incorporate this additional CMOS RAM to store advanced configuration informatio

16、n. 15.3.3 Data in ROM BIOS Version Information,Location of BIOS routines,BIOS compatibility information,Floppy Disk Drive Parameter Table,Hard Disk Drive Parameter Table,Hard Drive Data Transfer Rates,Video Parameter Table,System Configuration Data Table,Data Transmission Rate Initialization Table,C

17、ompatibility Information Tables.16.ROM Compatibility Table(1) Address BIOS Service Table FE05Bh POST entry point FE2C3h NMI Handler entry point FE3Feh INT 13h Hard Disk Drive Service entry point FE401h Hard Disk Drive Parameter Table FE6F2hINT 19h Boot Load Service entry point FE6F5h Configuration D

18、ata Table FE729h Data Transmission Rate Generator Table FE739h INT 14h Serial Communications Service entry point FE82Eh INT 16h Keyboard Service entry point17.ROM Compatibility Table(2)Address BIOS Service Table FE987h INT 09h Keyboard Service entry point FEC59h INT 13h Floppy Disk Service entry poi

19、nt FEF57h INT 0Eh Floppy Disk Hardware Interrupt Service Routine entry point FEFC7h Floppy Disk Controller Parameter Table FEFD2h INT 17h Parallel Printer Service entry point FF045h INT 10h Video Service Functions 00h through 0Fh entry point FF065h INT 10h Video Service entry point FF0A4hMDA and CGA

20、 Video Parameter Table (INT 1Dh)FF841h INT 12h Memory Size Service entry point FF84DhINT 11h Equipment List Service entry point18.ROM Compatibility Table(3)Address BIOS Service Table FF859h INT 15h Systems Services entry point FFA6Eh Low-order 128 characters of the 320 x 200 and 640 x 200 graphics f

21、ontsFFE6Eh INT 1Ah Time-of-Day Service entry point FFEA5h INT 08h System Timer Interrupt Service Routine entry point FFEF3h Initial Interrupt Vector offsets loaded by POST FFF53h IRET Instruction for Dummy Interrupt Handler FFF54hINT 05h Print Screen Service entry point FFFF0hPower-On entry point FF

22、FF5h ROM Date (in ASCII). Eight characters in xx/xx/xx format (e.g 05/01/99)FFFFE hSystem Model ID (always FC h). 19.4.BIOS services and Interrupts4.1 BIOS Services4.2 Types of Interrupts4.3 Interrupt vectors20.4.1 BIOS ServicesBIOS services usually actions like reading and writing from the hard dis

23、k, processing information received from devices, etc.Some specific examples of BIOS services are: Geometry Translation for IDE/ATA Hard Drives Over 504 MB Plug-and-Play Year 2000 Compliance Support for IDE/ATA Hard Drives Over 2 GB 21.4.2 Types of InterruptsInterrupt Type Description Range Processor

24、 Generated or processed by the CPU. 00h 04 h Hardware Generated by hardware devices. Eight of these are hardwired to either the CPU or the motherboard. IRQ2, 8, 9, and 11 15 are reserved. 08h 0F h70h 77 h Software Handled by the BIOS. 05h, 10h through 1Ah, and 40h, 41h, 42h, 43h, 46h, and 4Ah are re

25、served. The rest are available for re-vectoring to programmer-written routines. 05h 07 h10h 1F h40h 5F h DOSOnly available when DOS is active. INT 20h through 3Fh are reserved for DOS 20h 3Fh BASIC Reserved 80h BF h UserINT 67h is used for EMS. All others available for re-vectoring to user-written r

26、outines. 60h 6F h 22.4.3 Interrupt VectorsThe originator of the interrupt does not need to know the memory address of the required interrupt handler. It only needs to know the interrupt number. The interrupt number points to the interrupt vector table, a table in low memory that contains the segment

27、ed address of the interrupt handling subroutine.Each time the BIOS initializes the computer, it creates a table of interrupt vectors (pointers to the location of the interrupt service routine entry point at 0:0000h).10h Video display services13h Diskette and hard disk services16h Keyboard services19

28、h Reboot11h Equipment determination14h Serial I/O services17h Printer services1Ah Real time clock services12h Memory size determination15h Miscellaneous services18h BASIC40h Floppy Disk23.Interrupt Request Line (IRQ)24.IRQ Numbers(1)SystemInterrupt IRQ NumberTypical Use08hIRQ0System timer09hIRQ1Keyb

29、oard0AhIRQ2Cascade interrupt for IRQ 8-150BhIRQ3Second serial port(COM2)0ChIRQ4First serial port (COM1)0DhIRQ5LPT2 Parallel Port 0Eh IRQ6 Floppy disk drives 0Fh IRQ7 LPT1, Parallel Port 25.IRQ Numbers(2). SystemInterrupt IRQ NumberTypical Use70h IRQ8 Real Time Clock Interrupt 71h IRQ9 Vertical Retra

30、ce Interrupt from Video Display Adapter 72h IRQ10 Reserved 73h IRQ11 Reserved 74h IRQ12 Reserved in ISA. Mouse controller in EISA. 75h IRQ13 Math coprocessor interrupt on any error 76h IRQ14 IDE or MFM hard disk drive controller 77h IRQ15 Second IDE hard disk drive controller. Sometimes used for pow

31、er management 26.5. I/O Ports Addresses5.1 I/O Address Map 5.2 I/O Ports Addresses5.3 CGA Video I/O Ports 5.4 Monochrome Video I/O Ports 5.5 I/O Programmer Access27.5.1 I/O Address Map28.5.2 I/O Ports AddressEach port is identified by a 16-bit port number (from 0 65,535, or 00000h 0FFFF h). The I/O

32、port addresses from 0000h00FFh are used by components mounted on the motherboard. The I/O ports addresses: The I/O port addresses from 0100h03FFh are used by ISA ports. The I/O ports addresses: The I/O port addresses above 0400h are used by PCI and EISA ports.29.5.3 Monochrome Video I/O Ports I/O Po

33、rt Read/Write Description 03B4h WCRTC index register 03B5h WIndex 00hHorizontal total Index 01hHorizontal displayedIndex 02hHorizontal sync position Index 03hHorizontal sync pulse widthIndex 04hVertical total Index 05hVertical displayedIndex 06hVertical sync position Index 07hVertical sync pulse wid

34、thIndex 08hInterlace mode Index 09hMaximum scan linesIndex 0AhCursor start Index 0BhCursor endIndex 0ChStart address, high byte Index 0DhStart address, low byteIndex 0EhCursor location, high byte Index 0FhCursor location, low byteIndex 10hLight pen, high byte Index 11hLight pen, low byte 03B8hWMode

35、control register03BAh RCRT status register30.5.4 CGA Video I/O Ports I/O PortRead/Write Description 03D4hWCRTC index register 03D5hWIndex 00hHorizontal total Index 01hHorizontal displayedIndex 02hHorizontal sync position Index 03hHorizontal sync pulse widthIndex 04hVertical total Index 05hVertical d

36、isplayedIndex 06hVertical sync position Index 07hVertical sync pulse widthIndex 08hInterleaved mode Index 09hMaximum scan linesIndex 0AhCursor start Index 0BhCursor endIndex 0ChStart address, high byte Index 0DhStart address, low byteIndex 0EhCursor location, high byte Index 0FhCursor location, low

37、byteIndex 10hLight pen, high byte Index 11hLight pen, low byte 03D8hWMode control register 03D9hWPalette register 03DAhRCRT status register 03DBhWClear light pen latch 03DChWPreset light pen latch 31.5.5 I/O Programmer Access A programmer can use the Intel assembly language instructions IN and OUT t

38、o write to and read from I/O port addresses. For example: MOV DX,03CCh;read video register address IN AL,DX;read byte from I/O port OR AL,10h;set bit 4 for RAMDAC control MOV DX,03C2h;write register address OUT DX,AL;write value to I/O port 32.6. Power-On-Self-Test(POST)6.1 System Boot Operation6.2

39、POST Phases 6.3 POST Functions 6.4 POST Error Handling 6.5 POST Memory Test 6.6 BIOS Configuration Summary Screen6.7 ROM Extensions 6.8 POST Checkpoint Codes 33.6.1 System Boot Operation - cold boot(1)The internal power supply turns on and initializes.When the reset button is released, the processor

40、 will be ready to start executing. The BIOS performs the Power-on self. If there are any fatal errors, the boot process stops. Post beep codes can be found in this area of the Troubleshooting. The BIOS looks for the video card. In particular, it looks for the video cards built in BIOS program and ru

41、ns it.The BIOS then looks for other devices ROMs to see if any of them have BIOS. The BIOS displays its startup screen.The BIOS does more tests on the system, including the memory count-up test which you see on the screen. 34.6.2 System Boot Operation Cold Boot(2)The BIOS performs a system inventory

42、 of sorts, doing more tests to determine what sort of hardware is in the system. If the BIOS supports the Plug and Play standard, it will detect and configure Plug and Play devices at this time and display a message on the screen for each one it finds. The BIOS will display a summary screen about yo

43、ur systems configuration. The BIOS begins the search for a drive to boot from.Having identified its target boot drive, the BIOS looks for boot information to start the operating system boot process. If it finds what it is looking for, the BIOS starts the process of booting the Operating System(OS),

44、using the information in the boot sector. If no boot device at all can be found, the system will normally display an error message and then freeze up the system.35.Run ProcessBoot Block StartRun setupPOST StartRuntime StartFinish the POST Give Control to Runtime modulesDecompress POST modulesDecompr

45、ess POST modulesDecompress Setup modulesDecompress Runtime modulesPress YesNo36.Starting POST Starting POSTWhat the BIOS Does Turn the computer on. Jumps to the address pointed to by the processor reset vector (FFFF0h). All POST tests and initializations are then executed. If successful, POST calls

46、INT 19h Bootstrap Loader.Press the reset button Jumps to the address pointed to by the processor reset vector (FFFF0h). All POST tests and initializations are then executed. If successful, POST calls INT 19h Bootstrap Loader. Press . The INT 09h keyboard hardware interrupt service transfers control

47、to POST. POST does not test memory above 64 KB, but all other tests and initializations are performed. POST then calls INT 19h Bootstrap Loader 37.6.2 POST PhasesBefore NMI are enabled, the BIOS POST:StepDescription 1Writes data in all motherboard and adapter card memory locations to establish that

48、parity is good. 2Enables the onboard and 32-bit slot memory parity checks by writing to I/O port 61h with data bit 2 set to zero. 3Enables the I/O channel check signal by writing to I/O Port 61h with data bit 3 set to zero. 38.6.3 Post Function The ROM BIOS includes BIOS Power-On Self Test diagnosti

49、c and booting code that tests the computer components, initializes certain data structures, and boots DOS. POST performs several functions:Executes a diagnostic and reliability test of the computer, the ROM programs, and RAMInitializes the chips and the standard parts of the computer and places a re

50、cord of the system configuration in CMOS RAM and in low system memorySets up the interrupt vector table,Detects optional equipmentBoots the operating system39.POST Functions Test sequence(1) Processor Register Test ROM BIOS Checksum Test Keyboard Controller Test CMOS Shutdown Register Test System Ti

51、mer Test The CH-1 timer error or CH-2 timer error Memory Refresh Test Base 64 KB Test Cache Memory Test 40.POST Functions Test sequence (2) CMOS RAM Battery Test Display Verification Enter Protected Mode Address Line Test Conventional and Extended Memory Test DMA Controller Test Keyboard Test System

52、 Configuration Verification If the contents of 0Fh at CMOS RAM location 0Fh (Shutdown Byte) is 00h, POST performs all tests and initializations.41.6.4 POST Error Handling A primary POST function is to find any conditions that prevent proper operation. POST diagnostic routines look for system errors

53、and report them in the following manner.If.Then. The error occurs before the display is initialized.A series of beeps sound. Beep codes indicate that a fatal error has occurred. The error occurs after the display is initializedThe error message is displayed. Displayed BIOS messages are described in Appendix A. A prompt to press also appears on the screen.42.6.5 Memory TestAMIBIOS (C) 1997 American Megatrends Inc.XXXXX KB OKHit if you want to run SETUP(C) American Megatrends Inc.XX-XXXX-XXXXXX-XXXXXXXX-XXXXXX-

溫馨提示

  • 1. 本站所有資源如無特殊說明,都需要本地電腦安裝OFFICE2007和PDF閱讀器。圖紙軟件為CAD,CAXA,PROE,UG,SolidWorks等.壓縮文件請下載最新的WinRAR軟件解壓。
  • 2. 本站的文檔不包含任何第三方提供的附件圖紙等,如果需要附件,請聯(lián)系上傳者。文件的所有權(quán)益歸上傳用戶所有。
  • 3. 本站RAR壓縮包中若帶圖紙,網(wǎng)頁內(nèi)容里面會有圖紙預(yù)覽,若沒有圖紙預(yù)覽就沒有圖紙。
  • 4. 未經(jīng)權(quán)益所有人同意不得將文件中的內(nèi)容挪作商業(yè)或盈利用途。
  • 5. 人人文庫網(wǎng)僅提供信息存儲空間,僅對用戶上傳內(nèi)容的表現(xiàn)方式做保護(hù)處理,對用戶上傳分享的文檔內(nèi)容本身不做任何修改或編輯,并不能對任何下載內(nèi)容負(fù)責(zé)。
  • 6. 下載文件中如有侵權(quán)或不適當(dāng)內(nèi)容,請與我們聯(lián)系,我們立即糾正。
  • 7. 本站不保證下載資源的準(zhǔn)確性、安全性和完整性, 同時也不承擔(dān)用戶因使用這些下載資源對自己和他人造成任何形式的傷害或損失。

最新文檔

評論

0/150

提交評論