Apparatus capable of varying number of wait states for access

Abstract: There is disclosed an information processing apparatus capable of varying the number of wait states for access to the memory according to the access time. The interchangeable external memory used in the present invention memorizes data on the number of wait states for access, and the apparatus reads the data and accordingly controls the number of wait states, thus realizing an optimum process speed.

Description: Field of the Invention The present invention relates to an information processing apparatus with an interchangeable external memory such as a ROM card. Related Background Art In the conventional information processing apparatus, the number of wait states of the CPU at the access to an interchangeable external memory is either fixed by an incorporated hardware, or controlled by a hardware provided in the external memory. However. such conventional structure has been associated with following drawbacks: (1) When the number of wait states for access to the external memory by the CPU is fixed by a hardware incorporated therein, the processing speed cannot be improved even with a memory of higher access speed, capable of functioning with a fewer number of wait states, as the number is fixed in the hardware. (2) When the number of wait states for access to the external memory by the CPU is controlled by a hardware of the external memory, each external memory has to be provided with such hardware for controlling the number of wait states. Also there is required a signal line for controlling the number of wait states in the interface with the external memory. SUMMARY OF THE INVENTION In consideration of the foregoing, a concern of the present invention is to provide an apparatus capable of varying the number of wait states for access to the external memory by the CPU. Another concern of the present invention is to provide an apparatus capable of effecting a process responding to the access time of the memory. IBM Technical Disclosure Bulletin, Vol. 31, No. 12, May 1982, pages 6256-6257; NY, USA; P.A. Beaven et al 'Matching processor timing sequence to different memories' and French Patent Specification No. FR-A-2,388,342 both disclose apparatus in which access to an external memory is carried out solely by utilising the access timing set by the external memory, this timing being obtained by the main apparatus by an initial interchange of information. In accordance with the present invention there is provided information processing apparatus as set out in claim 1. BRIEF DESCRIPTION OF THE DRAWINGS Fig. 1 is a block diagram of an information processing apparatus in accordance with an embodiment of the present invention; and Fig. 2 is a flow chart of a process for setting the number of wait states. DESCRIPTION OF THE PREFERRED EMBODIMENTS Now the present invention will be clarified in more detail by an embodiment thereof, of which block diagram is shown in Fig. 1. In Fig. 1 there are shown a CPU 1 for controlling the entire apparatus; an address bus 2 for transferring an address signal indicating the object of control of the CPU 1; a data bus 3 for transferring data among different units of the apparatus; a ROM 4 storing various programs and data, including a program for setting the number of wait states to be explained later, the ROM being replaceable by an equivalent device capable of storing programs and data; a RAM 5 used as a work area for the CPU 1; an interface circuit 6 composed ordinarily of a buffer circuit for an external memory; and an external memory 7 which can be a non-volatile memory such as a ROM or an NVRAM and to which access is made by the CPU 1 through the external memory interface circuit 6. A programmable wait state number control circuit 8 controls the number of wait states for access to the external memory 7 by the CPU 1, according to a number of wait state designated in the program of the CPU 1. A wait state number control signal 9 is supplied from the control circuit 8 to the CPU 1. Fig. 2 is a flow chart of a process for setting the number of wait state for access to the external memory. In the following there will be explained the sequence of setting the number of wait states for the access to the external memory 7, with reference to Fig. 2. At first, prior to the access to the external memory 7, a step S10 sets a largest settable number of wait states in the programmable wait state number control circuit 8. Then, in a step S11, the CPU 1 reads, through the external memory interface circuit 6, the information on the number of wait states provided in advance on the external memory 7 such as ROM or NVRAM. The information can be the number of wait states itself, or the access time of the external memory 7. A step S12 determines the number of wait states, based on the information on the number of wait states obtained in the step S11. The number is either obtained directly from the information if the information represents the number itself, or calculated by the CPU 1 if the information indicates the access time of the external memory 7. Then a step S13 sets the number of wait states, determined in the step S12, in the programmable control circuit. Through the above-explained process, the number of wait states for the access to the external memory 7 by the CPU 1 through the interface circuit 6 is set in the programmable wait state number control circuit 8, so that the access to the external memory 7 by the CPU 1 is thereafter made with thus set number of wait states. The foregoing embodiment allows the CPU 1 to make access to the external memory 7 with a number of wait states watching the access speed thereof, without a hardware for controlling the number in the part of the external memory. In the foregoing embodiment, the external memory 7 is assumed to have only one number of wait states, but memories with different numbers of wait states may be mixedly present in the external memory 7. In such case, information on such different numbers of wait states are stored in advance in memories in the external memory 7, and the step S11 in Fig. 2 reads the information respectively from the memories in the external memory 7 and selects the largest number of wait states among the information, whereby the access to the external memory 7 is made with the number of wait state matching the lowest access speed of the plural memories present in the external memory 7. As explained in the foregoing, the present invention is to obtain the information, on the number of wait states for access to an interchangeable external memory by the CPU, from the external memory and to control the number of wait states in the access of the CPU to the external memory according to the information, thereby enabling access to the external memory with a number of wait states matching the access speed thereof, without a hardware for controlling the number of wait states on the part of the external memory.

Claims: Information processing apparatus for accessing a detachable memory (7) having information for determining a number of wait states for access, the apparatus comprising reading means (1,2,6) for accessing and reading said information and characterised in that the apparatus further comprises means (4) for setting in said apparatus a maximum value for the number of wait states for access by the apparatus to said external memory, determining means (1) for determining from said information the number of wait states for access to the external memory, and control means (1,6,8) for controlling access to said external memory in accordance with the number of waiting states determined by said determining means. Apparatus according to claim 1, wherein said determining means is operative to determine the number of wait states from the information on the number of wait states in said external memory when the information represents the number of wait states. Apparatus according to claim 1, wherein said determining means can determine the number of wait states for access to said external memory from said information when said information indicates the access time of said external memory.

Inventors: SHIMURA AKIHIRO, SHIMURA, AKIHIRO
Applicants: CANON KK, CANON KABUSHIKI KAISHA
Application year: 1990
Main classification: G06F13
IPC codes: G06F13, G06F12