IE62039B1 - Microcontroller peripheral expansion bus - Google Patents

Microcontroller peripheral expansion bus

Info

Publication number
IE62039B1
IE62039B1 IE388289A IE388289A IE62039B1 IE 62039 B1 IE62039 B1 IE 62039B1 IE 388289 A IE388289 A IE 388289A IE 388289 A IE388289 A IE 388289A IE 62039 B1 IE62039 B1 IE 62039B1
Authority
IE
Ireland
Prior art keywords
microcontroller
control
controller
control logic
sfr
Prior art date
Application number
IE388289A
Other versions
IE893882L (en
Inventor
Robert Wickersheim
Hamed Hajizadeh Amini
Original Assignee
Intel Corp
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 Intel Corp filed Critical Intel Corp
Publication of IE893882L publication Critical patent/IE893882L/en
Publication of IE62039B1 publication Critical patent/IE62039B1/en

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F13/00Interconnection of, or transfer of information or other signals between, memories, input/output devices or central processing units
    • G06F13/10Program control for peripheral devices
    • G06F13/12Program control for peripheral devices using hardware independent of the central processor, e.g. channel or peripheral processor
    • G06F13/124Program control for peripheral devices using hardware independent of the central processor, e.g. channel or peripheral processor where hardware is a sequential transfer control unit, e.g. microprocessor, peripheral processor or state-machine

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Microelectronics & Electronic Packaging (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Microcomputers (AREA)
  • Executing Machine-Instructions (AREA)

Abstract

A microcontroller with the capability of allowing a user to expand the capabilities of the controller such that the added functionality performs as if the controller were designed with that added functionality onboard. This capability is implemented by providing 71 at the pinouts of the controller access to a special function register area 25 onboard the controller, as well as certain internal control signals. Each peripheral controller which is desired to be interfaced with the microcontroller must have a special address decoding block added. Thus, a microcontroller can be customized to a user's specifications without the costs associated with a custom designed chip.

Description

BACKGROUND OF THE INVENTION 1. Field Of The Invention This invention relates to the field of single chip microprocessors and controllers. In particular, this invention relates to circuitry which brings certain internal signals of a controller to the user interface to allow a user to customize the controller for use with peripheral devices without the expertise of custom layout and device/circuit engineers. 2. Prior Art Single chip microcontrollers having onboard functionality usually performed by peripheral controllers are well known devices. A representative controller sold by Intel Corporation having such onboard functionality is known as an 8051 microcontroller which incorporates a serial channel which provides input/output for serial devices. In the 8051 controller, a special function register (SFR) area is provided which is used by the software to talk to the outside world. Although not part of a standard 8051 controller, other frequently desired functionality includes analog-digital and digital-analog converters as well as various special purpose controllers. While it is possible in the prior art to provide such additional functionality by allocating one or more of the onboard ports as an address and data bus, since not all controller instructions can address the data and address bus normally used to interface with peripheral devices, additional programming is necessary which necessarily slows down input/output, requires additional memory space and generally results in poorer performance. For example, in an 8051 microcontroller, only 4 out of 76 instructions, and none of the bit manipulation instructions, can directly access a peripheral device controller attached to a port.
SUMMARY OF THE INVENTION A microcontroller is disclosed having the capability of allowing a user to expand the capabilities of the controller such that the added functionality performs as if the controller were designed with that added functionality onboard. The invented controller implements this capability by providing at the pinouts of the controller access to the SFRs as well as certain internal control signals. While each peripheral controller which is desired to be interfaced with the microcontroller must have a special address decoding block added, the benefits made o available by the invention far outweigh the additional costs associated with adding a special decoding block to a peripheral controller. For example, whether a peripheral controller is onboard or external to the microcontroller will be totally transparent to a user. Additionally, since there is no one set of functionality which is useful to all users, it is impossible to design a chip which includes onboard all possible desired functionalities at an acceptable cost. By the present invention, a user can tailor a microcontroller to his specifications without the costs associated with a custom designed chip.
BRIEF DESCRIPTION OF THE DRAWINGS Figure 1 is a block diagram showing the main elements of a single jchip microprocessor Figure 2 is a block diagram showing an implementation of SFR 5 buffer control block 71.
Figure 3 is a block diagram showing the SFRB of the present invention.
Figure 4 is a table showing the SFR area.
DETAILED DESCRIPTION OF THE INVENTION A method and apparatus is disclosed for implementing in a single , chip microcontroller. Specific numbers of bytes, bits, registers, addresses, clock signals, control signals, etc. have been set forth for purposes of explanation in order to provide a thorough understanding of the invention. However, it should be apparent to one skilled in the art that the present invention may be practiced without these specific details. In other instances, well known circuits and devices are shown in block diagram form in order not to obscure the present invention unnecessarily.
In order to simplify the understanding of the invention, rather than describing the invention in abstract terms, many of the descriptions herein are in terms of a specific processor, namely the Intel 8051 microcontroller, as specified in a publication entitled 15 Microcontroller Handbook, Order No. 210918-004 available from Intel Corporation, Santa Clara, California. However, it should be understood that the invention is not limited for use by any specific processor.
Referring now to Figure 1, the main components of a microprocessor with three onboard ports is shown. The microprocessor 2q comprises an arithmetic/logical unit (ALU) 11, a system bus 15, an instruction register (IR) 17, timing and control logic 21, special function register (SFR) area 25, latch registers 27, 31, 33 and input buffers/output drivers 27’, 3Γ, 33' corresponding respectively to ports PO, P2, and P3. Also shown are accumulator (ACC) 39, RAM address register 41, random access memory (RAM) 43, additional registers B 45, Tempi 47, and Temp2 49, program counter (PC) 51, PC incrementer 52, ROM 53, program memory address register 55, program status word (PSW) register 57, buffer 59, stack pointer 61 and data memory pointer 5 (DTPR) 63, all of which are well known in the art and usually needed for proper operation of a single chip microprocessor or controller. The particular manner in which these elements are coupled to each other and operate, as well as additional components, depends upon the particular architecture utilized, which details will be described herein -, o only to the extent necessary for a complete understanding of the invention.
Coupled to ports PO and P2 through an 8 bit bus there may be an external program memory and an external data memory. Timing and control signals for the two external memories are generated through port P3. The program memory contains processor instructions of the usual type. Data to be manipulated by the microprocessor is stored in the data memory. Details regarding the accessing and loading of instructions from the program memory and manipulating data in the data memory are well known in the art and therefore, except to the extent necessary for a proper understanding of the subject invention, will not be described.
Figure 1 differs from a prior art microcontroller mainly by the addition of SFR buffer logic control block 71 which reads and writes the eight address signals SAD0-SAD7 and generates the eight control/clock signals SALE, SPBSL, SPOC, SRDL, SWRL, SPH2S, SS1ES, and SPH2. In Figure 1, SFR buffer logic control block 71 includes buffers 75 and SFR control logic 79. In this connection, the inputs and outputs of SFR buffer logic control block 71 utilize the pinouts that would otherwise be used by port 1. However, SFR buffer logic control block 71 could have its own pinouts if port 1 is needed, but of course a different packaging would be needed with 16 additional pinouts to accommodate the inputs and outputs of SFR buffer logic control block 71.
Although not part of the invention, the following discussion of 8051 microarchitecture is provided so that the invention may be better understood.
The 8051 clock is internally divided to generate two nonoverlapping phases. One phase is equal to one external clock cycle. Two phases, called Phi and Ph2, constitute a State. One state is equal to two external clocks. Six states make a Cycle. The states, within a cycle, are numbered from 1 to 6; i.e. SI, S2.. S6. The cycles are numbered from 1 to 4; i.e. Cl, C2, C3, C4. Instructions execute in integer multiples of cycles. Most of the instructions take one or two cycles to execute.
Timing and control logic 21 of the CPU accesses SFR registers as follows. The 8 bit address of a SFR register 25 is specified in the second byte of an instruction. This byte is available on internal bus 15 during Ph2 of S4. Control logic 21 asserts a signal IB%ARS indicating that the address matches that of one of the SFR registers. This information is stored for the duration of the instruction execution. In the next state, 55, control logic 21 asserts a read signal RD. The contents of the addressed SFR register is placed on internal bus 15, for storage into one of she temporary registers 47 and 49 of ALU 11. In the following state, 56, ALU 11 performs an arithmetic/logical operation on the data and 5 places the results on internal bus 15. This modified data is latched into the addressed SFR register.
In short, the address of a SFR is made available in S4. The selected register is read in S5. And Anally the data is written into the SFR in S6. In the case of two cycle instructions, the same steps are q θ followed, but in different cycles.
The Intel 8051 family of microcontrollers allows up to 128 SFR registers which are used as internal control and status registers, although only a few are used. The onboard I/O ports P0, Pl, if present, P2 and P3 are addressed through this register space. The instructions which read, write, read-modify-write, and bit manipulate the SFRs, belong to the SFR space.
Referring now to Figure 2, the various signals generated and utilized by SFR buffer logic control block 71 will be described.
SFR buffer logic control block 71 allows the SFR registers 25 to 20 talk” to peripheral devices designed to be interfaced with the invented device over a SFR bus (SFRB) which includes the address and data signals SAD0-SAD7, the control signals SWRL, SALE, SDRL, SPOC and SPBSL, and the clock signals SPH2, SPH2S and SS1ES generated by SFR control block 71, each of which will now be described.
The SFRB is a synchronous bus which allows peripheral cells external to the controller to be accessed through the onboard SFRs. SAD0-SAD7 is a static bus used for address and data which is driven by the controller when it is sending information to a peripheral cell address and which is driven by the peripheral cell when it is sending information to the controller.
SWRL is an active low signal and transfers the contents of SADOSAD7 to the data register of the peripheral cell during S6, or during S4 for bit addressable instructions. SWRL corresponds to the controller’s o internal address write (WR) signal which is designated IB%AR.
SALE is an active high signal which indicates that the SAD0-SAD7 contain a valid address of a peripheral cell. SALE occurs during S4 and SI. Of course, each peripheral cell coupled to the SFRB should have a unique address and an address decoder as described below. SALE 15 corresponds to the controller's internal address latch enable (ALE) signal which is designated IB%ARS.
SDRL is an active low signal and transfers the contents of the data register of the peripheral cell which was addressed when SALE was asserted. SDRL occurs during S5. SDRL corresponds to the controller's 2q internal read (RD) signal which is designated AR%1B.
SPOC is an active high signal generated by the controller and is used to set all internal registers of the addressed peripheral cell to a known state. SPOC corresponds to the controller’s internal reset (POC) signal.
SPBSL is an active low signal corresponding to the controller's port buffer select signal (PBSL). This signal is active during instructions which read the latch of an I/O port rather than the port's input pins. ,That is, referring to figure 1, when SPBSL is asserted, data which is in one of latches 27, 31 or 33 is read, modified by the accumulator and then written back to the latch. Such instructions are usually bit manipulation instructions SPH2 corresponds to the controller's internal PH2 signal and is used to synchronize the peripheral cells to the controller clock. It is also 0 used by the peripheral cells as part of their internal two phase clocking scheme.
SPH2S corresponds to the controller's internal phase 2 sleep clock PH2S. It is used to synchronize peripheral cells which are to be active during the IDLE mode of the controller and as part of their internal two phase clocking scheme.
SS1ES corresponds to the controller's internal state 1 early sleep signal. It begins during state 6, phase 2 (S6P2) which is the last state of an instruction, and lasts until S1P1. This signal is active during the IDLE mode of the controller. All other timing states that a peripheral cell 2o may require can be generated from SS1ES.
SFR buffer logic control block 71 may be implemented by buffers 75 and SFR control logic 79. In this connection, buffers 75, which are a set of tri-stateable, bi-directional buffers, take the internal controller data and address signals on bus 15 which are to be output, and generate signals appropriate to be placed on the pinouts, or, when receiving signals from a peripheral cell, take the signals on SAD0-SAD7 and place them on bus 15.
SFR control logic 79 may be implemented as a set of non-inverting 5 buffers, take the internal controller control and clock signals which are to be output, and generate signals appropriate to be placed on the pinouts. SFR control logic 79 does not receive any inputs from the peripheral cells.
Referring now to Figure 3, peripheral address decoding block 83 1 0 receives the signals SAD0-SAD7 as well as the control and clock signals SWRL, SALE, SDRL, SPOC, SPBSL, SPH2, SPH2S and SS1ES.
The SFR Peripheral Cell Decoding Scheme The manner in which peripheral address decoding block 83 may be implemented will now be described. Any cell which is directly connected to the SFRB is referred to as an SFR cell or peripheral cell.
The controller accesses these cells by reading/writing their address memory locations in the SFR area. To use these cells, at least one unique memory location must be associated with each cell. Each peripheral cell may contain multiple registers, and each register in the cell will have a different SFR address associated with it.
Peripherals can be placed at most of the available locations within the memory map of the SFR area. If a peripheral holds more than one register, the register with the lowest address will be programmed at II one address and the other registers associated with the SFR peripheral cell will be programmed to the addresses following the first register. When a peripheral cell holds more than one register it is restricted to *XOH, *X4H, *X8H and 'XCH as valid addresses within the SFR memory map, where X is 0-F hexidecimal.
To make the SFR memory location of these registers programmable, each peripheral cell has 16 signals, each of which will have the corresponding SAD0-SAD7 line, VCC, or VSS tied to it, depending on the address the register is to be placed. The pins are o called AD0-AD7 and ADBAR0-ADBAR7. Each peripheral cell also has a pin called BITADDR which will be tied high if the first register of the block is bit-addressable, otherwise it will be tied low.
If a specific bit of the SFR cell address contains a 1, then the corresponding SAD0-SAD7 line should be tied to the corresponding AD0-AD7 line. If a specific bit of the SFR cell's address contains a 0, then the corresponding SAD0-SAD7 line should be tied to the corresponding ADBAR0-ADBAR7 line. Once all the SAD0-SAD7 lines have been tied to either an AD0-AD7 line or an ADBAR0-ADBAR7 line, the AD lines that do not have an input must be tied to VCC and 0 the AD lines that do not have an input must be tied to VSS. For example, if the SFR peripheral cell address were C8H, then the following connections would be made: SADO - ADBARO SADI - ADBAR1 SAD2 - ADBAR2 SAD3 - AD3 SAD4 - ADBAR4 SAD5 - ADBAR5 5 SAD6 - AD6 SAD7 - AD7 ADO, ADI, AD2, AD4 and AD5 - VCC ADBAR3, ADBAR6 and ADBAR7 - VSS A bit-addressable SFR cell can reside at any location inside a row 1 o in the SFR area memory map. The only requirement is that only one bit-addressable peripheral cell is allowed per row, with the rest of the locations for that row being used as non-bit-addressable addresses. What distinguishes a bit-addressable module from a non-bitaddressable module is the BITADDR pin. For a peripheral cell to be bit1 5 addressable, the BITADDR pin must be tied high.
As an example, a bit-addressable SFR cell is placed at address 0C3H. If bit 5 of the module is to be cleared, then CLR 0C5H will do the job. Similarly, if bit 7 is to be set, then SETB 0C7H will suffice. No other locations in the same row will be affected since they all will have their BITADDR's lines tied low.
Figure 4 is the SFR memory map showing what addresses are available for placing peripheral cells. That is, except for the locations which indicated as being in use, all other SFR locations are available for use by peripheral cells.

Claims (8)

1. An integrated circuit microcontroller having an internal bus, an arithmetic logical unit for manipulating data on said internal bus, a special function register area which includes an addressing space for accessing certain registers on board the microcontroller used by the arithmetic logical unit, and timing and control logic for generating timing and control signals necessary for the operation of the microcontroller based upon a microcontroller instruction to be executed by said microcontroller, said microcontroller comprising: a plurality of buffer means, each coupled to a corresponding set of input/output pins and to said internal bus, each of said sets of input/output pins for coupling to a peripheral cell external to the microcontroller, each of said buffer means for transferring address information and data information from said special function register area to its said corresponding set of input/output pins, and for transferring address information and data information to said special function register area from said corresponding set of input/output pins; and control logic means coupled to said internal bus and to a set of control pins for coupling to said peripheral cell for transferring certain of said internal control and timing signals generated by said timing and control logic to said control pins
2. The apparatus defined by claim 1, wherein said set of control pins are dedicated for use by said control logic means.
3. The apparatus defined by Claim 1 wherein each of said plurality of buffer means comprises a tristateable, bi-directional buffer.
4. The apparatus defined by Claim 1 wherein said 5. Control logic means places the signals SWRL, SALE, SDRL, SPOC, SPBSL, SPH2, SPH2S and SSIES on said control pins.
5. The apparatus defined by Claim 3 wherein said control logic means comprises a non-inverting buffer for each of said signals SWRL, SALE, SDRL, SPOC, SPBSL, 6. 10 SPH2, SPH2S and SSIES.
. 6. An integrated circuit microcontroller having an internal bus, an arithmetic logical unit for manipulating data on said internal bus, a special function register area which includes an addressing
7. 15 space for accessing certain registers on board the microcontroller used by the arithmetic logical unit, and timing and control logic for generating timing and control signals necessary for the operation of the microcontroller, substantially as hereinbefore described
8. 20 with reference to the accompanying drawings.
IE388289A 1988-12-23 1989-12-05 Microcontroller peripheral expansion bus IE62039B1 (en)

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
US28919888A 1988-12-23 1988-12-23

Publications (2)

Publication Number Publication Date
IE893882L IE893882L (en) 1990-06-23
IE62039B1 true IE62039B1 (en) 1994-12-14

Family

ID=23110467

Family Applications (1)

Application Number Title Priority Date Filing Date
IE388289A IE62039B1 (en) 1988-12-23 1989-12-05 Microcontroller peripheral expansion bus

Country Status (4)

Country Link
JP (1) JPH02264380A (en)
GB (1) GB2226433B (en)
IE (1) IE62039B1 (en)
IL (1) IL92748A0 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5307464A (en) * 1989-12-07 1994-04-26 Hitachi, Ltd. Microprocessor and method for setting up its peripheral functions
JPH04195481A (en) * 1990-11-28 1992-07-15 Hitachi Ltd Single-chip microcomputer and multifunctional memory

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US4782439A (en) * 1987-02-17 1988-11-01 Intel Corporation Direct memory access system for microcontroller

Also Published As

Publication number Publication date
GB8925224D0 (en) 1989-12-28
IE893882L (en) 1990-06-23
IL92748A0 (en) 1990-09-17
GB2226433B (en) 1993-01-27
JPH02264380A (en) 1990-10-29
GB2226433A (en) 1990-06-27

Similar Documents

Publication Publication Date Title
US5047922A (en) Virtual I/O
US5426769A (en) System and method for producing input/output expansion for single chip microcomputers
US4349870A (en) Microcomputer with programmable multi-function port
US5251304A (en) Integrated circuit microcontroller with on-chip memory and external bus interface and programmable mechanism for securing the contents of on-chip memory
JP4226085B2 (en) Microprocessor and multiprocessor system
US5210847A (en) Noncacheable address random access memory
US5317750A (en) Microcontroller peripheral expansion bus for access to internal special function registers
EP0757316B1 (en) External device selection unit for data processor
US4460972A (en) Single chip microcomputer selectively operable in response to instructions stored on the computer chip or in response to instructions stored external to the chip
US5535349A (en) Data processing system and method for providing chip selects to peripheral devices
US6622244B1 (en) Booting from a reprogrammable memory on an unconfigured bus by modifying boot device address
US7310717B2 (en) Data transfer control unit with selectable transfer unit size
EP4266185A1 (en) Microcontroller chip containing multi-protocol communication interface peripheral and operation method therefor
EP1164490B1 (en) Re-configurable memory map for a system on a chip
US6058467A (en) Standard cell, 4-cycle, 8-bit microcontroller
IE62039B1 (en) Microcontroller peripheral expansion bus
EP0020972B1 (en) Program controlled microprocessing apparatus
JPH03668B2 (en)
US5860129A (en) Data processing system for writing an external device and method therefor
CN118311916B (en) Programmable logic system and microprocessor
KR100399674B1 (en) Data processor and access method
JP4008196B2 (en) Register control device and multi-CPU system
JPH1011316A (en) Single-chip microcomputer and its test
Processor ADSP-BF542/ADSP-BF544/ADSP-BF547/ADSP-BF548/ADSP-BF549
JP2002132579A (en) Register control apparatus

Legal Events

Date Code Title Description
MK9A Patent expired