From Surf Wiki (app.surf) — the open knowledge base
Intel MCS-48
Family of 8-bit microcontrollers
Family of 8-bit microcontrollers
The MCS-48 microcontroller series, Intel's first microcontroller, was originally released in 1976. Its first members were 8048, 8035 and 8748. The 8048 is arguably the most prominent member of the family. Initially, this family was produced using NMOS (n-type metal–oxide–semiconductor) technology. In the early 1980s, it became available in CMOS technology. It was manufactured into the 1990s to support older designs that still used it.
The MCS-48 series has a modified Harvard architecture, with internal or external program ROM and 64 to 256 bytes of internal (on-chip) RAM. The I/O is mapped into its own address space, separate from programs and data.
Though the MCS-48 series was eventually replaced by the very successful MCS-51 series, it remained quite popular even by the year 2000 due to its low cost, wide availability, memory-efficient one-byte instruction set, and mature development tools. Because of this, it is used in high-volume, cost-sensitive consumer electronics devices such as TV remotes, computer keyboards, and toys.
Uses
| Note: All other programmer-visible registers and stack are allocated in RAM. |
|---|
|}
The MCS-48 series was commonly used in computer and terminal keyboards, converting key presses into protocols that can be understood by digital circuits. This also allows the possibility of serial communication, reducing the number of conductors needed in cables on external keyboards. Microprocessors had been used in keyboards since at least 1972, simplifying earlier discrete designs. The 8048 has been used in this application since its introduction in 1978.
The Tandy/Radio Shack TRS-80 Model II, released in 1979, used the 8021 in its keyboard. The 8021 processor scans the key matrix, converts switch closures to an 8-bit code and then transmits that code serially to the keyboard interface on the main system. It will also accept commands to turn indicator LEDs on or off. The 8021 was also used in the keyboards for the TRS-80 Model 12, 12B, 16, 16B and the Tandy 6000/6000HD.
The original IBM PC keyboard and the keyboard for its precursor the IBM System/23 Datamaster used an 8048 as its internal microcontroller. The PC AT replaced the PC's Intel 8255 peripheral interface chip at I/O port addresses with an 8042 accessible through port addresses and . As well as managing the keyboard interface, the 8042 controlled the A20 line gating function for the AT's Intel 80286 CPU and could be commanded by software to reset the 80286 (unlike the 80386 and later processors, the 80286 had no way of switching from protected mode back to real mode except by being reset). Later PC compatibles integrate the 8042's functions into their super I/O devices.
The 8048 was used in the Magnavox Odyssey² video game console, the Korg Trident series, and the Korg Poly-61, Roland Jupiter-4 and Roland ProMars analog synthesizers. The Sinclair QL used the closely related Intel 8049 to manage its keyboard, joystick ports, RS-232 inputs and audio. The ROM-less 8035 variant was used in Nintendo's arcade game Donkey Kong to generate the background music and some of the game's sound effects.
Instruction set
All MCS-48 instructions are one or two bytes long with 70% of the instructions being one byte. The MCS-48 can address 4096 bytes of program memory, 256 bytes of RAM, 256 bytes of external memory, and eight port I/O addresses. Most arithmetic and logical operations use the accumulator as a parameter and destination. Eight memory locations are mapped as registers so they can be addressed by a 3-bit field embedded in many instructions. Two of those registers can be used as memory pointers. Conditional branches can only access the current 256-byte page. JMP and CALL can directly access 2048 locations. To access the entire 4096 byte program space, a clunky select memory bank instruction must be used. The RET instruction can, however, return anywhere in the address space. Interrupts are well supported with alternate registers for quick context switches and the ability to restore the state of the flags with the RETR instruction. All instructions execute in one or two machine cycles. Each machine cycle takes 15 external clocks.
| Opcode | rowspan=2 | Operand | rowspan=2 | Mnemonic | rowspan=2 | Cycles | rowspan=2 | Description | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 | Operand | Mnemonic | Cycles | Description | RRR or R | 3 | 2 | 1 | 0 | colspan=2 | ALU | colspan=2 | ALUI #immed | RRR or R | 3 | 2 | 1 | 0 | colspan=2 | ALU | colspan=2 | ALUI #immed | ||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| 0 | 0 | 0 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 0 | 0 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ALUI | 0 | 0 | 1 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| addhi | 0 | 0 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 0 | 0 | I | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 0 | 0 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 0 | 0 | 0 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 0 | 0 | 0 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 0 | 0 | 0 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ALU | 0 | 0 | 0 | R | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| ALU | 1 | RRR | — | INC XCH ORL ANL ADD ADDC | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| MOVaA DEC XRL MOVAa | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| BIT | 1 | 0 | 0 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| addhi | 1 | 0 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 0 | 0 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 0 | 0 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 0 | 1 | T | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 0 | 1 | F | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 0 | 1 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 0 | 1 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 0 | 1 | 1 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 0 | 1 | 1 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 1 | 0 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 1 | 0 | T | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 1 | 0 | F | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 1 | 0 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 1 | 0 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 1 | 1 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 1 | 1 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 1 | 1 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 1 | 1 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 1 | 1 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 0 | 1 | 1 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 0 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 0 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | N | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 0 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 0 | 0 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 0 | 0 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 0 | 0 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 0 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 0 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | N | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 0 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 0 | 1 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 0 | 1 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 0 | 1 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 1 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 1 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 1 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 1 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 1 | 0 | N | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 1 | 0 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 1 | 0 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 1 | 0 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 1 | 1 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 1 | 1 | N | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 1 | 1 | F | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 1 | 1 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 1 | 1 | 0 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 1 | 1 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| R0 @R0 | 0 | 0 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| R1 @R1 | 0 | 0 | 0 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| R2 | 0 | 0 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| R3 | 0 | 0 | 1 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| R4 | 0 | 1 | 0 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| R5 | 0 | 1 | 0 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| R6 | 0 | 1 | 1 | 0 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| R7 | 0 | 1 | 1 | 1 | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 0 | 1 | 0 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 1 | 0 | 0 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 1 | 0 | 1 | |||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
| 1 | 1 | 1 | 1 |
Example code
The following assembler source code is for a subroutine named that adds two 32-bit integers stored in little endian order. One addend is pointed to by R0 and the other addend and result are pointed to by R1.
|}
Variants



The 8049 has 2 KB of masked ROM (the 8748 and 8749 had EPROM) that can be replaced with a 4 KB external ROM, as well as 128 bytes of RAM and 27 I/O ports. The microcontroller's oscillator block divides the clock input frequency by three and then further divides the result into five machine states. Using the 11 MHz maximum crystal frequency will produce 0.73 MIPS of single-cycle instructions. Some 70% of instructions are single byte and single cycle ones, but 30% need two cycles or two bytes, so its typical performance would be closer to 0.5 MIPS.
| Device | Program memory | Data memory | Remarks | ||||||
|---|---|---|---|---|---|---|---|---|---|
| 8020 | 1K × 8 ROM | 64 × 8 RAM | subset of 8048, 20 pins, only 13 I/O lines | ||||||
| 8021 | 1K × 8 ROM | 64 × 8 RAM | subset of 8048, 28 pins, 21 I/O lines | ||||||
| 8022 | 2K × 8 ROM | 64 × 8 RAM | subset of 8048, A/D-converter | ||||||
| 8035 | none | 64 × 8 RAM | |||||||
| 8038 | none | 64 × 8 RAM | |||||||
| 8039 | none | 128 × 8 RAM | |||||||
| 8040 | none | 256 × 8 RAM | |||||||
| 8048 | 1K × 8 ROM | 64 × 8 RAM | 27× I/O ports | ||||||
| 8049 | 2K × 8 ROM | 128 × 8 RAM | 27× I/O ports | ||||||
| 8050 | 4K x 8 ROM | 256 × 8 RAM | |||||||
| 8648 | 1K × 8 OTP EPROM | 64 × 8 RAM | Factory OTP EPROM | ||||||
| 8748 | title=Computer Architecture and Organization | last=Hayes | first=John P. | isbn=0-07-027363-4 | date=1978 | publisher=McGraw-Hill International Book Company | pages=57-59}} | 64 × 8 RAM | 4K program memory expandable, 2× 8-bit timers, 27× I/O ports |
| 8749 | 2K × 8 EPROM | 128 × 8 RAM | 2× 8-bit timers, 27× I/O ports | ||||||
| 87P50 | ext. ROM socket | 256 × 8 RAM | Has piggy-back socket for 2758/2716/2732 EPROM |
| Device | Program memory | Data memory | Remarks |
|---|---|---|---|
| 8041 | 1K × 8 ROM | 64 × 8 RAM | Universal Peripheral Interface (UPI) |
| 8041AH | 1K × 8 ROM | 128 × 8 RAM | UPI |
| 8741A | 1K × 8 EPROM | 64 × 8 RAM | UPI, EPROM version of 8041 |
| 8741AH | 1K × 8 OTP EPROM | 128 × 8 RAM | UPI, OTP EPROM version of 8041AH |
| 8042AH | 2K × 8 ROM | 256 × 8 RAM | UPI |
| 8242 | 2K × 8 ROM | 256 × 8 RAM | UPI, preprogrammed with keyboard controller firmware |
| 8742 | 2K × 8 EPROM | 128 × 8 RAM | UPI, EPROM version |
| 8742AH | 2K × 8 OTP EPROM | 256 × 8 RAM | UPI, OTP EPROM version of 8042AH |
Derived microcontrollers
Philips Semiconductors (now NXP) owned a license to produce this series and developed their MAB8400-family based on this architecture. These were the first microcontrollers with an integrated I²C-interface and were used in the first Philips (Magnavox in the US) Compact Disc players (e.g. the CD-100).
Mitsubishi M5M80C39P-6.jpg|Mitsubishi Electric M5M80C39P-6 MBL8742H.jpg|Fujitsu MBL8742H KL USSR KM1816BE i8748 Black Background.jpg|Kvazar Kiev KM1816VE48 (Soviet Union – 8748 clone) NS87PC48D.jpg|National Semiconductor NS87PC48D (piggyback variant) Ic-photo-Signetics--SCN8048A-(8048-MCU).png|Signetics SCN8048A NEC D8749HD.png|NEC μPD8749HD Ic-photo-Philips--MAF 8049H PB A064--(8049-MCU).JPG|Philips MAF 8049H
References
Bibliography
;MCS-48
;UPI-41
References
- (2008-07-30). "Oral History Panel on the Development and Promotion of the Intel 8048 Microcontroller".
- "TRS-80 Model II Technical Reference Manual". Radio Shack.
- (1985). "Tandy 6000/6000HD Service Manual". Tandy/Radio Shack.
- (April 1984). "Technical Reference: Personal Computer". [[IBM]].
- (September 1985). "Technical Reference: Personal Computer AT". IBM.
- "Korg Trident Service Manual". Korg.
- "Korg Poly-61 Service Manual".
- Gordon Reid. (November 2004). "The History Of Roland, Part 1: 1930–1978". Sound On Sound Magazine.
- (September 1980). "MCS-48 Family of Single Chip Microcomputers User's Manual". Intel.
- Hayes, John P.. (1978). "Computer Architecture and Organization". McGraw-Hill International Book Company.
- (November 1994). "UPI-41AH/42AH Universal Peripheral Interface 8-bit Slave Microcontroller". Intel.
- [http://arquivo.pt/wayback/20160515111736/http://www.datasheetarchive.com/dl/Datasheets-110/DSAP005622.pdf Datasheet (pdf)] Philips MAB8400-Family
This article was imported from Wikipedia and is available under the Creative Commons Attribution-ShareAlike 4.0 License. Content has been adapted to SurfDoc format. Original contributors can be found on the article history page.
Ask Mako anything about Intel MCS-48 — get instant answers, deeper analysis, and related topics.
Research with MakoFree with your Surf account
Create a free account to save articles, ask Mako questions, and organize your research.
Sign up freeThis content may have been generated or modified by AI. CloudSurf Software LLC is not responsible for the accuracy, completeness, or reliability of AI-generated content. Always verify important information from primary sources.
Report