KR970002405B1 - A protecting mode display method using a keyboard - Google Patents

A protecting mode display method using a keyboard Download PDF

Info

Publication number
KR970002405B1
KR970002405B1 KR1019890007261A KR890007261A KR970002405B1 KR 970002405 B1 KR970002405 B1 KR 970002405B1 KR 1019890007261 A KR1019890007261 A KR 1019890007261A KR 890007261 A KR890007261 A KR 890007261A KR 970002405 B1 KR970002405 B1 KR 970002405B1
Authority
KR
South Korea
Prior art keywords
mode
keyboard
flag
state
protected mode
Prior art date
Application number
KR1019890007261A
Other languages
Korean (ko)
Other versions
KR900018814A (en
Inventor
안성환
Original Assignee
엘지전자 주식회사
이헌조
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 엘지전자 주식회사, 이헌조 filed Critical 엘지전자 주식회사
Priority to KR1019890007261A priority Critical patent/KR970002405B1/en
Publication of KR900018814A publication Critical patent/KR900018814A/en
Application granted granted Critical
Publication of KR970002405B1 publication Critical patent/KR970002405B1/en

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Quality & Reliability (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Debugging And Monitoring (AREA)

Abstract

A method for displaying the protected mode operation of a CPU is provided to display the protected mode operation through a lamp installed in the keyboard. The method comprises storing the real mode status of the system when it is changed to the protected mode; making a protected mode scripter; initializing the internal registers and memories after activating the system gate address 20; changing the real mode to the protected mode; storing an LED light command in the AL register; outputting the LED light command to the keyboard after checking status of the keyboard; and changing the protected mode to the real mode after deactivating the system gate address 20 upon completion of the execution of a program in the protected mode.

Description

키이보드를 이용한 보호모드 동작 표시방법How to display the protection mode operation using the keyboard

제1도는 본 발명의 보호모드 동작 상태 표시 회로도.1 is a protection mode operation state display circuit diagram of the present invention.

제2도는 본 발명에 따른 상태 바이트 설명도.2 is a state byte explanatory diagram according to the present invention.

제3도는 본 발명에 따른 보호모드 동작 상태 표시 회로의 흐름도.3 is a flowchart of a protection mode operation state display circuit according to the present invention;

* 도면의 주요부분에 대한 부호의 설명* Explanation of symbols for main parts of the drawings

1 : 키이보드 콘트롤러 2 : 키이 스캐닝 콘트롤러1: Keyboard Controller 2: Key Scanning Controller

3~6 : 램프 Rp1~Rp4 : 풀업저항3 ~ 6: Lamp Rp1 ~ Rp4: Pullup resistor

CLK : 클럭CLK: Clock

본 발명은 키이보드(Key Board)를 이용한 보호모드 동작 표시방법에 관한 것으로 특히, 키이보드의 LED온/오프 루틴(Routine)을 이용하여 cpu(80286/80386)의 보호모드 동작(protected mode operation)시 램프를 온시키고, 리얼모드(Real mode)에서 동작시 램프를 오프시켜 사용자로 하여금 시스템(system)의 현재 사용상태를 쉽게 인식하도록하여 모드 상태에 따른 사용자의 실수로 인한 에러(Error)의 발생을 줄여서 시스템의 효율을 높이도록 한 키이보드를 이용한 보호모드 동작 표시방법에 관한 것이다.The present invention relates to a method of displaying a protected mode operation using a key board, and more particularly, to a protected mode operation of a cpu 80286/80386 using an LED on / off routine of a keyboard. Turn on the lamp and turn off the lamp when operating in real mode so that the user can easily recognize the current state of use of the system. The present invention relates to a method of displaying a protected mode operation using a keyboard to reduce the efficiency and increase the efficiency of the system.

본 발명의 기술구성은 제1도에 도시된 바와 같이 리셋신호

Figure KPO00001
의 칩선택신호
Figure KPO00002
및 입출력 리드/라이트신호(IO R/W), 데이타버스(XD0-XD7), 클럭(CLK)이 연결되는 키이보드 콘트롤러(1)는 키이스캐닝(Key Scanning)콘트롤러(2)와 연결되고, A20 게이트를 통하여 cpu에 연결되며, 키이스캐닝 콘트롤러(2)는 전원(+5[v])이 인가된 풀업(pull-up)저항(Rp1~Rp4)에 연결됨과 동시에 접지된 램프(3~6)에 연결되는 구성으로써, 상기와 같은 구성의 동작상태 및 작용효과를 첨부도면에 따라 상세히 설명하면 다음과 같다.The technical configuration of the present invention is a reset signal as shown in FIG.
Figure KPO00001
Chip selection signal
Figure KPO00002
And a keyboard controller (1) to which input / output read / write signals (IO R / W), data buses (XD0-XD7), and clock (CLK) are connected, is connected to a key scanning controller (2), and A20 It is connected to the cpu through the gate, and the key scanning controller 2 is connected to the pull-up resistors Rp1 to Rp4 to which a power source (+5 [v]) is applied and at the same time, a grounded lamp (3 to 6). As the configuration connected to, when described in detail the operation state and the effect of the configuration as described in the accompanying drawings as follows.

우선 리얼모드에서 보호모드로 cpu(central processing unit)의 동작모드를 바꾸는 경우를 설명하면 제3도(a)에 도시된 바와 같이 레지스터와 세그먼트(segment) 및 오프셋(OFF Set)을 세이브(SAVE)시키는데 이것은 cpu가 보호모드에서 프로그램(program)을 수행하다가 다시 리얼모드로 복귀할 경우 바뀌기전의 리얼모드의 시스템상태를 보관하여 원래의 루틴으로 복귀할 경우 프로그램의 수행을 계속할 수 있게 하기 위한 것이며 여기서 레지스터란 cpu내부의 DX(Data Register), Ax(Accumulator), Cx(Counter Register), Bx(Base Register), Bp(Base pointer) 및 상태 플래그(Flag) 레지스터를 말하며 세그먼트와 오프셋은 프로그램 및 데이타 영역을 지정하기 위한 cpu의 내부 레지스터로써 메모리의 데이타 영역을 지정하기 위해서는 ES(Extra segment)와 DS(Data segment) 및 SI(Source index Register), DI(distination index Register)가 항상 한쌍으로 필요하며 명령의 코드(code)영역을 지정하기 위해서는 CS(code segment)와 IP(Instruction pointer)가 항상 한쌍으로 이루어지며, 시스템의 현재 상태를 보관하기 위한 메모리내의 번지를 지정하는 것으로 SS(stack segment)와 sp(stack pointer)가 사용된다.First of all, the operation mode of the central processing unit (cpu) is changed from the real mode to the protection mode. As shown in FIG. 3 (a), the register, the segment, and the offset (OFF Set) are saved. This is to ensure that when the CPU executes a program in protected mode and then returns to real mode, it keeps the system state of the real mode before the change and can continue the program execution when returning to the original routine. Refers to DX (Data Register), Ax (Accumulator), Cx (Counter Register), Bx (Base Register), Bp (Base Pointer) and Status Flag (Flag) registers inside the CPU. The internal register of the CPU to designate the data area of the memory to specify the ES (Extra segment), DS (Data segment), SI (Source index register), DI (distation index) Registers are always needed in pairs. In order to designate the code area of a command, CS (code segment) and IP (Instruction pointer) are always paired, and address in memory to keep the current state of the system is designated. The SS (stack segment) and sp (stack pointer) are used.

이후 cpu가 보호모드로 동작시 메모리의 인터럽트루틴(interrupt Routine), 데이타영역, 코드영역, 스택(stack) 영역등을 지정하기 위한 디스크립터(discripter)를 만들고, cpu동작모드가 리얼모드에서 보호모드로 전환하기 위해서 먼저 시스템의 어드레스 20을 온시킨 후 IDT(interrupt discripter table) 및 GDT(Gloval Disripter table)을 로드(Load)하여서 보호모드를 수행키위한 cpu내부 레지스터 및 메모리의 사용을 초기화(initialize)하고, MSW(machine status word Register)의 비트를 1로 세트하므로써 보호모드로 전환하게 된다.After the CPU runs in protected mode, it creates a descriptor to specify the interrupt routine, data area, code area, and stack area of memory, and the CPU operation mode is changed from real mode to protected mode. To do this, first turn on address 20 of the system and then load the interrupt discripter table (IDT) and global disripter table (GDT) to initialize the use of cpu internal registers and memory to perform protected mode. In this case, the protection mode is switched by setting the bit of the MSW (machine status word register) to 1.

이와 같이 보호모드로 전환되면 제2도에 도시된 바와 같이 시스템롬 Bias내의 상태바이트(4Bø번지)인 플래그(KB-FLAG-4)의 비트 7을 1로 세트한 후 제3도(b)를 수행한다.As shown in FIG. 2, bit 7 of the flag (KB-FLAG-4), which is the status byte (address 4Bø) in the system ROM Bias, is set to 1 as shown in FIG. Perform.

이후 제3도(b)에서와 같이 AL(Accmulator Low Byte)레지스터에 LED라이트(write) 코멘드(command) EDH(H는 16진수를 의미함)를 넣고 키이보드가 명령을 받을 준비가 되었는가를 체크하여 준비가 된 경우 출력포트(A)에 AL값 EDH를 출력하고 준비가 안된 경우는 기다리거나 키이보드가 에러인지를 체크하여 에러이면 시스템에 에러임을 알려주어서 명령수행을 할 수 없음을 표시한다.Then, as shown in Fig. 3 (b), the LED write command EDH (H means hexadecimal) is inserted into the AL (Accmulator Low Byte) register, and the keyboard is ready for command. If it is ready, it outputs AL value EDH to output port (A) and if it is not ready, it waits or checks whether the keyboard is an error and informs the system that it is an error.

이후 제1도의 램프(3~6)를 온/오프시키기 위해 현재의 램프 상태를 보관하는 제2도의 플래그 KB-FLAG-2의 값을 구하게 되는데 이때 비트 3의 보호모드 인디게이터(protected mode indicator)는 보호모드 동작중임을 나타낼 경우 플래그 KB-FLAG-4의 보호모드 상태 비트인 비트 7이 반드시 1로 세트되어 있어야 하고 보호모드 동작을 종료하고 리얼모드로 복귀했을 경우는 비트 7이 0로 클리어(clear)되어야 하며, 제2도의 플래그 KB-FLAG의 상태를 cpu내부의 AL레지스터 안으로 넣어주어 램프(3~5)의 온/오프를 결정하며, cpu내부 레지스터 CX의 하이바이트(High byte)인 CH를 이용하여 보호모드인지 리얼모드인지를 나타내기 위한 값을 제2도 도시된 바와 같은 KB-FLAG-4의 내용에 따라서 0 또는 1을 갖게 된다.Then, to turn on / off the lamps 3 to 6 of FIG. 1, the value of the flag KB-FLAG-2 of FIG. 2 storing the current lamp state is obtained. In this case, the protected mode indicator of bit 3 is Bit 7, the protection mode status bit of the flag KB-FLAG-4, must be set to 1 to indicate that protection mode is in operation, and bit 7 is cleared to 0 when the protection mode operation is terminated. The state of the flag KB-FLAG of FIG. 2 is inserted into the AL register inside the cpu to determine the on / off of the lamps 3 to 5, and the CH, which is the high byte of the register CX inside the cpu, is determined. The value indicating whether the protection mode or the real mode is used is 0 or 1 according to the contents of KB-FLAG-4 as shown in FIG.

이후 cpu레지스터 AL의 비트배열을 제2도에 도시된 플래그 KB-FLAG-2의 상태와 같도록 하며, 플래그 KB-FLAG-2를 키이보드로 보내고 제3도(c)로 점프(Jump)하면 제3도(c)에서는 플래그 KB-FLAG-4의 비트 7의 상태를 판단하는데 이때 플래그 KB-FLAG-4의 비트 7의 상태는 상기에서 설명한 바와 같이 제3도(a)에서 리얼모드에서 보호모드로 cpu동작모드가 바뀐상태이므로 1이 되어 제1도의 램프(4)를 온시키고 제3도(a)의 ⓐ이후 동작을 하게 된다.After that, if the bit array of the cpu register AL is equal to the state of the flag KB-FLAG-2 shown in FIG. 2, the flag KB-FLAG-2 is sent to the keyboard, and the jump to the third diagram (c) is performed. In FIG. 3 (c), the state of bit 7 of flag KB-FLAG-4 is determined. At this time, the state of bit 7 of flag KB-FLAG-4 is protected in real mode in FIG. 3 (a) as described above. Since the cpu operation mode has been changed to the mode, the state becomes 1, the lamp 4 of FIG. 1 is turned on, and the operation after ⓐ of FIG.

즉, 보호모드에서 프로그램을 수행하게 되며 보호모드 수행을 종료한 후 리얼모드로 전환하려면 게이트 어드레스 비트 20을 오프한 후 cpu내부 레지스터 MWS(machine stastus word Register)의 비트 ø를 ø로 클리어 시켜서 리얼모드로 전환하게 되며, 리얼모드에서 프로그램을 수행함과 동시에 제3도(c)에서와 같이 플래그 KB-FLAG-4의 비트 7=ø가 되어 제1도의 램프(6)를 오프시키고 cpu는 리얼모드에서 동작하게 된다.That is, the program is executed in the protected mode. To switch to the real mode after the protected mode is finished, turn off the gate address bit 20 and clear bit ø of the MWS (machine stastus word register) cpu to real mode. When the program is executed in real mode, bit 7 = ø of flag KB-FLAG-4 is turned off as shown in FIG. 3 (c) to turn off lamp 6 of FIG. 1 and cpu is in real mode. It will work.

따라서 본 발명에 따른 키이보드를 이용한 보호모드 동작 표시방법은 cpu가 리얼모드에서 동작중인지 보호모드에서 동작중인지 램프를 이용하여 사용자가 쉽게 인식할 수 있으므로 모드에 따른 차이점을 구별하여 시스템을 운영시킴으로써 시스템에 대한 효율을 높일 수 있고 사용자의 실수로 인한 에러를 방지할 수 있는 효과를 갖게 된다.Therefore, the method of displaying the protection mode operation using the keyboard according to the present invention can be easily recognized by the user by using the lamp whether the CPU is operating in the real mode or the protection mode. It is possible to increase the efficiency and prevent the error caused by user error.

Claims (1)

리얼모드에서 보호모드로 변환할 때 리얼모드 상태를 저장하는 단계와, 상기 리얼모드 상태 저장단계후 보호모드 디스크립터를 만드는 단계와, 상기 단계후 시스템의 게이트 어드레스 20를 온시킨다음 내부 레지스터 및 메모리를 초기화하는 단계와, 상기 단계후 리얼모드를 보호모드로 전환하는 단계와, 상기 단계후 AL레지스터에 LED라이트 코멘드를 저장하고 키이보드의 준비상태와, 키이보드 상태를 점검하는 단계와, 상기 단계후 키이보드가 명령을 받을 준비가 되면 AL레지스터에 저장된 LED라이트 코멘드를 출력하는 단계와, 상기 단계후 현재의 램프상태를 보관하는 플래그 KB-FLAG-2를 만들고 보호모드인 경우 램프(6)를 온시키는 단계와, 상기 단계후 보호모드에서 프로그램을 수행하고 게이트 어드레스 20를 오프하여 리얼모드로 전환하는 단계와, 상기 단계후 플래그 KB-FLAG-4상태를 0로 하여 램프(6)를 오프시키는 단계를 포함하여 구성된 것을 특징으로 하는, 키이보드를 이용한 보호모드 동작 표시방법.Storing the real mode state when switching from real mode to protected mode, creating a protected mode descriptor after the real mode state storing step, and after turning on gate address 20 of the system, Initializing, switching the real mode to the protected mode after the step, storing the LED light command in the AL register after the step, checking the ready state of the keyboard, the keyboard state, and after the step Outputting the LED light command stored in the AL register when the keyboard is ready to receive the command, and after the step, create the flag KB-FLAG-2 to keep the current lamp state and turn on the lamp 6 in the protection mode. Performing a program in the protection mode after the step and turning off the gate address 20 to the real mode; Group protected mode operating method using a display, a key board, characterized in that configured by a step after the step of turning off the lamp (6) to the flag KB-FLAG-4 to state 0.
KR1019890007261A 1989-05-30 1989-05-30 A protecting mode display method using a keyboard KR970002405B1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
KR1019890007261A KR970002405B1 (en) 1989-05-30 1989-05-30 A protecting mode display method using a keyboard

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
KR1019890007261A KR970002405B1 (en) 1989-05-30 1989-05-30 A protecting mode display method using a keyboard

Publications (2)

Publication Number Publication Date
KR900018814A KR900018814A (en) 1990-12-22
KR970002405B1 true KR970002405B1 (en) 1997-03-05

Family

ID=19286577

Family Applications (1)

Application Number Title Priority Date Filing Date
KR1019890007261A KR970002405B1 (en) 1989-05-30 1989-05-30 A protecting mode display method using a keyboard

Country Status (1)

Country Link
KR (1) KR970002405B1 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR100863268B1 (en) * 2008-05-29 2008-10-15 통명석재 주식회사 Natural stone manhole cover

Also Published As

Publication number Publication date
KR900018814A (en) 1990-12-22

Similar Documents

Publication Publication Date Title
KR900016866A (en) Data processing systems
US5594890A (en) Emulation system for emulating CPU core, CPU core with provision for emulation and ASIC having the CPU core
KR100403995B1 (en) Interrupt control device that responds flexibly to many interrupt processing with small hardware scale
US5408611A (en) Auto-switching device for CPU logic circuits
SU1541619A1 (en) Device for shaping address
US5680632A (en) Method for providing an extensible register in the first and second data processing systems
US4037204A (en) Microprocessor interrupt logic
US5553301A (en) Programmable sequencher having internal components which are microprocessor read/write interfacable
KR970002405B1 (en) A protecting mode display method using a keyboard
KR100385493B1 (en) Microcontroller with a reconfigurable program status word
US6230238B1 (en) Method and apparatus for accessing misaligned data from memory in an efficient manner
EP0503498A2 (en) Single-chip microcomputer with program/data memory flag
KR910001545A (en) CPU core
KR960024962A (en) Microcontroller development system that can be integrated into the chip of the microcontroller
KR940006829B1 (en) Interruptable digital processor
KR940009427B1 (en) Method and device for changing address space
KR950025534A (en) Multiplexing Circuit of Interrupt Signal
KR890015130A (en) Microprocessor
JPH0550016B2 (en)
JP2619416B2 (en) emulator
KR0181592B1 (en) I/o module and special module of plc slot selection device
JPH0193838A (en) Microprocessor for debug
JPH06187140A (en) Processor
KR0162763B1 (en) Apparatus and method for implementing the configuration space of a pci device using mux
JPH0679278B2 (en) Microcomputer development equipment

Legal Events

Date Code Title Description
A201 Request for examination
G160 Decision to publish patent application
E701 Decision to grant or registration of patent right
GRNT Written decision to grant
FPAY Annual fee payment

Payment date: 20070221

Year of fee payment: 11

LAPS Lapse due to unpaid annual fee