Europaisches Patentamt J) European Patent Office (") Publication number: 0 426 1 33 A2 Office europeen des brevets

EUROPEAN PATENT APPLICATION

© Application number: 90120837.1 © int. ci.5: G06F 3/06

© Date of filing: 30.10.90

© Priority: 31.10.89 JP 281738/89 © Applicant: Kabushiki Kaisha Toshiba 72, Horikawa-cho Saiwai-ku @ Date of publication of application: Kawasaki-shi(JP) 08.05.91 Bulletin 91/19 @ Inventor: Hibi, Kenji, c/o Intellectual Property ® Designated Contracting States: Division DE FR GB Kabushiki Kaisha Toshiba, 1-1 Shibaura 1-chome Minato-ku, Tokyo 105(JP)

© Representative: Henkel, Feiler, Hanzel & Partner Mohlstrasse 37 W-8000 MUnchen 80(DE)

© Personal for disabling resume mode upon replacement of HDD.

© When a hard disk pack (20) is removed from a F/F (67) that the hard disk pack (20) has been computer main body in a power-OFF state, a signal replaced. The CPU (11) disables a resume flag. As a level of a specific pin of a connector (61) is set at result, upon a power-ON operation, resume process- high level, and a signal of high level representing ing is not performed, and damage to the hard disk replacement of the hard disk pack (20) is set in a pack and overrun of a program can be prevented. flip-flop (F/F) 67. When a power switch is turned on, a CPU (11) determines from information set in the

+ 5V

:/71 HDCHG SIGNAL C4 < 73

CO

CO

20 CLEAR SIGNAL Q- 111 F I G. 3

Xerox Copy Centre EP 0 426 133 A2

PERSONAL COMPUTER FOR DISABLING RESUME MODE UPON REPLACEMENT OF HDD

The present invention relates to a personal puter having a detachable disk unit and a resume computer using a replaceable hard disk as an function, comprises the computer steps of: a) de- external storage medium. tecting and registering that the disk unit is de- In the field of personal in recent tached in a power-OFF state; b) when a power years, compact, lightweight, portable laptop per- 5 switch is turned on again, checking whether the sonal computers have been very popular in place disk unit is detached; and c) determining that the of conventional desk-top personal computers. De- disk unit is detached and invalidating the resume mand has increasingly arisen for more compact, function. lightweight, portable laptop personal computers. According to the present invention, a hard disk The most advanced laptop personal computer em- w pack replacement detector (powered from a bac- ploys a low-profile drive (FDD), and a kup power source) detects replacement of a hard display and a hard disk pack are detachably moun- disk pack in a power-OFF state, and this informa- ted in this personal computer. tion is stored as status information in a memory In order to improve user operability, a laptop backed up by a battery. When the power switch is personal computer has a resume mode as a stan- 75 turned on, a CPU checks the status information, dard mode. In the resume mode, a state (i.e., a detects replacement of the hard disk unit, releases content of a memory and contents of various types the resume mode, and causes a display to display of register) in the system is saved in a nonvolatile an alarm message to an operator. memory in a power-OFF state, and a state imme- This invention can be more fully understood diately before the power-OFF timing is restored 20 from the following detailed description when taken upon power-ON. Therefore, jobs can be continued in conjunction with the accompanying drawings, in regardless of a power-ON/OFF state. which: A hard disk pack is generally replaced in a Fig. 1 is a system diagram showing an power-OFF state to prevent attachment/detachment overall arrangement of a personal computer ac- of the hard disk pack while signal lines are kept 25 cording to the present invention; active. In the above personal computer, however, if Fig. 2 is a block diagram showing a main part of a hard disk pack is detachable and when it is the present invention; replaced in a power-OFF state, a change in content Fig. 3 is a circuit diagram showing a detailed of the hard disk pack is not detected and a job is arrangement of a hard disk pack replacement resumed in a resume mode. Therefore, the content 30 detector shown in Fig. 2; of the hard disk pack is broken, and a system may Fig. 4 is a flow chart showing a power-ON overrun. control program executed by a CPU 1 1 ; It is an object of the present invention to pro- Fig. 5 is a flow chart showing SETUP process- vide a personal computer, wherein replacement of ing for setting a resume flag; and a hard disk pack in a power-OFF state is detected, 35 Figs. 6 and 7 are flow charts showing resume and a resume mode is disabled to prevent the processing. content of the hard disk pack from damage and a Fig. 1 is a system block diagram showing an program from overrun. overall arrangement of a personal computer ac- According to the first aspect of the present cording to the present invention. invention, a personal computer comprises: means 40 Referring to Fig. 1, components 11 to 28, 51, for supplying a power to the personal computer; and 53 are connected to a system bus 10. The external storage medium means- detachably con- (CPU) 1 1 controls the over- nected to the personal computer; resume means all system and executes flow charts shown in Figs. for resetting a system to an immediately preceding 4 to 7. The CPU 11 serves as a host CPU when state of a power-OFF operation in response to a 45 viewed from a power control CPU 306 in a power power-ON operation after a power switch is turned supply 30 (to be described later). The read only off; status register means for detecting and regis- memory (ROM) 12 stores a basic input and output tering that the external storage medium means is program (BIOS). The BIOS includes programs replaced in the power-OFF state; and control shown in Figs. 4 to 7 and is executed in response means for referring to the status register means 50 to a system power supply. Setup information when the power switch is turned on and invalidat- stored in a specific area (or register) of the RAM 13 ing the resume means when the external storage is loaded, and a system atmosphere is judged. A medium means is determined to be replaced. boot block is loaded from the HDD 20A, and an According to the second aspect of the present operating system (OS) program stored in the HDD invention, a method for controlling a personal com- 20A is loaded in the RAM 13 by this boot block. EP0 426 133 A2

The random access memory (RAM) 13 stores the in the personal computer main body to rectify and operating system (OS), application programs, and smooth a commercial AC power and obtain a DC various . A power supply voltage VBK operating power having a predetermined voltage. is supplied from the power supply 30 to the RAM An expansion unit is selectively connected to an 13. Even if a system power switch is turned off, the 5 expansion connector 40. The intelligent power sup- memory contents are not lost. The direct memory ply (power controller) 30 comprises the power con- access (DMA) controller 14 performs direct mem- trol CPU 306 and supplies power to each unit ory access control. The controller (PIC) 15 is a described above. A battery (M-BATT) 31 A is a programmable interrupt controller which can be set detachable main battery pack constituted by a re- by a program. The timer (PIT) 16 is an interval w chargeable battery. A battery (S-BATT) 31 B is a timer which can be set by a program. When the sub-battery incorporated in the main body and con- interval timer 16 counts a time set by a program, stituted by a rechargeable battery. the timer 16 supplies a time-out signal as an inter- Fig. 2 is a block diagram showing a relation- rupt signal to the CPU 1 1 under the control of the ship between the hard disk pack 20, the hard disk programmable interrupt controller 15. The CPU 11 15 pack replacement detector 53, and the CPU 11. executes a vector interrupt routine in response to When the hard disk pack 20 is replaced in the this interrupt signal. The real-time clock (RTC) 17 power-OFF state, the hard disk pack replacement is a timepiece module having its own operation detector 53 detects it and registers it as status battery to display current time. The extending RAM information. Upon a power-ON operation, the CPU 1 8 is a large-capacity memory detachably mounted 20 11 reads the status information stored in the hard in an extending RAM card slot in a main body, and disk pack replacement detector 53 and determines a backup power (VBK) is supplied to the extending whether the hard disk pack is replaced in the RAM 18. The backup RAM 19 constitutes a data power-OFF state. storage area for realizing the resume function and Fig. 3 is a circuit diagram showing a detailed is supplied with the backup power (VBK). The hard 25 arrangement of the hard disk pack replacement disk interface 51 interfaces the CPU 11 with the detector 53. hard disk pack 20. The hard disk pack 20 is The hard disk pack 20 is detachably connected detachably mounted in a hard disk pack section of to the personal computer main body through a the main body. The hard disk pack 20 consists of, connector 61 . A specific connector pin on the hard connected e.g., a 2.5" (HDD) 20A and a hard 30 disk pack 20 side, e.g., the first pin, is disk controller (HDC) 20B for controlling access of to the ground potential. The first connector pin on this drive. the computer main body side is connected to a The hard disk pack replacement detector 53 backup power supply 65 through a pull-up resistor. detects that a hard disk pack is replaced in a The first pin of the connector 61 on the computer power-OFF state. The hard disk pack replacement 35 main body side is connected to a clock input detector 53 stores this detection information. The terminal CK of a flip-flop (F/F) 67 through a signal detection information is read by the CPU 11 when line 66. When the hard disk pack 20 is kept con- a power switch is turned on. nected to the computer main body, a signal of The floppy disk controller (FDC) 20F controls a logic "0" level is supplied to the clock input termi- 3.5" optional floppy disk drive (external FDD) 32 40 nal CK of the F/F 67. When the hard disk pack 20 and a 5" optional external floppy disk (external is detached from the computer main body, a signal FDD) 33. The controller 21 is connected to of logic "1" level is supplied to the clock input an external printer 34. The input/output interface 22 terminal CK of the F/F 67. Therefore, the signal of " is a universal asynchronous receiver/transmitter logic "1 level from the power supply 65 is sup- (UART). An RS-232C interface equipment 35 is 45 plied to the D input terminal of the F/F 67, and a connected to the interface 22, as needed. The signal of logic "1" level representing replacement keyboard controller (KBC) 23 controls a keyboard of the hard disk pack 20 is set in the F/F 67. The Q 36. The display controller (DISP-CONT) 24 controls output terminal of the F/F 67 is connected to an a liquid crystal display (LCD) 37. The video RAM open collector type gate 69. The output terminal of 25 is supplied with the backup power (VBK) and 50 the gate 69 is normally pulled up to the power stores video data. The kanji ROM 26 stores kanji supply ( + 5 V) through a pull-up resistor 71. An character patterns corresponding to kanji character output signal HDCHG from the gate 69 is supplied codes. The dictionary ROM 27 stores a correspon- to the CPU 11 through a signal line 73. dence between kana and kanji characters and a A normally voltage detector 75 monitors the kanji conversion dictionary. The power supply con- 55 power supply ( + 5 V) and outputs a signal of logic trol interface (PS-IF) 28 connects a power supply "1" level to an AND gate 77 in a normal voltage 30 to the CPU 11 through the system bus 10. A state (i.e., +5 V, 10%). When this power supply is power supply adapter (AC adapter) 29 is plugged set at low level, the voltage detector 75 outputs a EP 0 426 133 A2 signal of logic "0" level to the AND gate 77. A Fig. 6 shows save processing of resume pro- clear signal is supplied from the CPU 11 to the cessing. In response to a power-OFF operation, the other input terminal of the AND gate 77 through a CPU 11 saves system data such as contents of signal line 79. When the power supply voltage is registers of the CPU 1 1 , contents of various regis- normal and a high-level (active high) signal is sup- 5 ters, and the content of the program counter in the plied from the CPU 1 1 , the AND gate 77 supplies a RAM 13 in step S31. In step S32, the CPU 11 sets signal for clearing the F/F 67 to a clear terminal a system data save flag. CLR of the F/F 67. The AND gate 77 is arranged to Fig. 7 shows restore processing of the resume prevent the content of the F/F 67 from being processing. That is, in response to a power-ON broken upon power-ON/OFF. w operation, the CPU 11 determines in step S51 An operation of the embodiment having the whether the system data save flag is ON. If YES in above arrangement will be described with refer- step S51 , the CPU 1 1 restores, in step S52, various ence to a flow chart in Fig. 4. system data saved in the RAM 13. In step S53, the When an operator turns off the switch of the system data save flag is reset. computer main body and removes the hard disk 75 pack 20, the level of the signal line 67 is changed from low level (logic "0") to high level (logic "1 ") Claims by the backup power supply 65 and a pull-up resistor 63. As a result, a signal of logic "1 " level is 1 . A personal computer comprising: set in the F/F 67. Then, an HDCHG signal as a low- 20 means (30) for supplying a power to said personal level (logic "0") output signal from the gate 69 is computer; output. The operator connects a desired hard disk external storage medium means (20) detachably pack 20 to the computer main body through the connected to said personal computer; connector 61 and turns on the system switch. resume means (11, 12) for resetting a system to an In response to this power-ON operation, the 25 immediately preceding state of a power-OFF op- CPU 11 executes the flow chart in Fig. 4. More eration in response to a power-ON operation after a specifically, the HDCHG signal is read in step 81. power switch is turned off; The CPU 11 determines an HDCHG level in step status register means (67, 69) for detecting and 83. If the CPU 11 determines level "0" of the registering that said external storage medium HDCHG signal, i.e., determines that the hard disk 30 means is replaced in the power-OFF state; and pack 20 has been replaced, a resume mode flag control means (11, Fig. 4) for referring to said set in a register (not shown) is cleared in step 85. status register means when said power switch is In step 85, the CPU 11 clears the F/F 67 through turned on and invalidating said resume means the AND gate 77. In step 87, a message represent- when said external storage medium means is de- ing that resume processing is performed due to 35 termined to be replaced. replacement of the hard disk pack is displayed on 2. A computer according to claim 1, characterized the LCD 37, as needed. Resume operations from in that said status register means is backed up by step 85 are not performed, and system initialization a battery. processing is executed. Therefore, damage to the 3. A computer according to claim 1, characterized content of the hard disk pack by execution of the 40 in that said control means refers to said status resume processing can be prevented. register means every time said power switch is Fig. 5 is a flow chart showing SETUP process- turned on, and invalidates said resume means ing for setting a resume flag shown in step 85 of when said control means determines that said ex- Fig. 4. ternal storage medium means has been replaced. The operator depresses a function key or in- 45 4. A computer according to claim 1, further com- puts a predetermined command to start a setup prising means for clearing a content of said status program. The setup program contains various con- register means after said control means invalidates tents and is used to execute various processing said resume means. operations (step S1 1). When the current operation 5. A computer according to claim 1, characterized reaches enable/disable setup of the resume func- 50 in that said means for invalidating said resume tion, a menu inquiring whether the resume function means comprises flag means (Fig. 5) representing is enabled is displayed on the LCD 37 (step S12). disabling of said resume means. In response to this inquiry, the operator inputs from 6. A computer according to claim 1, characterized the keyboard 36 an instruction whether the resume in that said status register means comprises con- function is enabled. The input instruction is deter- 55 nector means (61), a specific pin of which is as- mined in step S13. When the input instruction signed to output a specific signal in response to represents enabling of the resume function, a re- attachment/detachment of said external storage sume flag is set (step S15). medium means. EP 0 426 133 A2

7. A method of controlling a personal computer having a detachable disk unit and a resume func- tion, comprising the computer steps of: a) detecting and registering that said disk unit is detached in a power-OFF state; 5 b) when a power switch is turned on again, checking whether said disk unit is detached; and c) determining that said disk unit is detached and invalidating the resume function. w

15

20

25

30

35

40

45

SO

55 EP0 426 133 A2

10 HARD DISK PACK REPLACEMENT DETECTOR ^53 f 20B20B 2020A ,20 h { f_ A , ; HDD C~~| IhDD(2.50)HDD(2.50) j|' CPU HOC ,« I/F I) ^

•12 — i i EXTERNAL FDD(3.50)j i ROM 20F- i FDC 33. fEXTERNAL~FDD(5 0 ) ~] 13 VBK 2! RAM PRT- ' — — I PRINTER CONT _j 14 22 35 - - J~RS~- 232C j DMAC UART 1 INTERFACE ! (MOUSE) 23 VIUUCD CJ | 15 KBC KEYBOARD ^-36 PIC 24

,16 DISP LCD -37 -CONT PIT 25 VRAM

17 KANJI :vbk ROM 26 RTC DICTIONARY W ROM 27 18 2 LU VBK EXTENDING PS -IF 28 RAM UJ O 19 { 306 VBK BACKUP Jln T 40 RAM PC CPU AC AC 'VBK POWER ADAPTER SUPPLY FIG.) T 30 29' 3IA M-BATT S-BATT .31B EP 0 426 133 A2

^ HDD DISK PACK CPU „ REPLACEMENT DETECTOR 53

\V HARD DISK " — PACK 20

F I G. 2

+ 5V

7\ f HDCHG SIGNAL

itr

? 7^ + 5V —f\J VOLTAGE DETECTOR \^

20 CLEAR SIGNAL 79

F I G. 3 EP 0 426 133 A2

( POWER ON )

READ HDD CHANGE 81 STATUS (HDCHG)

83 NO

YES

DISABLE RESUME FLAG

87 \r CLEAR HDCHG F/F

]==

F I G. 4 EP 0 426 133 A2

C SETUP )

sii OTHER PROCESSING

S12 DISPLAY INQUIRY MENU

SI3

OFF

SET RESUME DISABLE FLAG

SI4

i ( END )

F I G. 5 EP0 426 133 A2

( START )

SAVE SYSTEM S3 DATA

SET SYSTEM DATA SAVE FLAG S32

c END )

F I G.6

( START ^

S55 YES ( S52- NORMAL RESTORE SYSTEM BOOT SYSTEM DATA PROCESSING

S53 RESET SYSTEM DATA SAVE FLAG

S54 NORMAL OPERATION

F I G. 7

10