Copyright 1992, Jack G. Ganssle
Translation: 1997 (c) Savichev Andrey Viktorovich E-mail: master@satan.spb.su
About the author: Jack Ganssle, Principal Consultant TGG
RUSH> Incredible! We have all become so accustomed to the good old Z-80 - the heart of our Spectrums and don't even know that the company Zilog, its creator, did not stop at this model of its processor and continues to produce much more advanced descendants. It is hard to say what this will mean for the further development of Speccy, who knows, perhaps in the near future new models of Spectrums will be equipped with next-generation processors...
From the translator:
Some terms have been replaced with Russian equivalents, others left untranslated. Some of the author's "lyrical" digressions have been omitted. The Summary and one "dark" place for me have been left untranslated.
Abstract.
Z80 and its descendants continue to be extremely popular. Here is the current state of this architecture.
Preface.
I just go crazy reading advertisements in the press. Magazines want to convince us that the only viable processor, even for the simplest applications - is a 50 MHz 486 or RISC processor. But how many designers actually use these CPUs in embedded systems?
At an embedded systems conference, Andy Rappaport made a convincing argument that as long as we have a relationship between processor performance and its price, in many cost-sensitive applications, smaller CPUs will dominate over new architectures. Personally, I prefer 8 and 16-bit CPUs. They are cheap, have cheaper tools available, and are easier to work with. In fact, an 8-bit processor has the same bus width as most common peripheral devices and can use a simpler circuit with fewer components due to integration on the chip. 16 and 32-bit buses are often used to speed up the transfer of large arrays of information. A longer instruction length is used to perform more complex actions in one machine cycle. The gain in performance translates into a loss in cost. I think that four architectures best meet the needs of embedded system designers. Excluding 4-bit architectures, which are often the optimal solution for mass production, I can recommend the families 8051, 80186, Z80, and 6800 and their descendants. From time to time I will write articles about instances of these families. This time my choice fell on Z80.
Modern Z80 Technology
Z80 is essentially no different from the original version introduced back in the mid-70s. All modern CMOS versions have cosmic speeds. The latest offering from Zilog contains a 20 MHz processor. However, the increase in processor speed causes a similarly cosmic increase in the cost of ROM and RAM in the system. Therefore, 6 and 8 MHz Z80 still remain respectable (written in 92! : translator's note) Although the indexed instructions of the Z80 are weak, it is still undoubtedly the best C computer compared to the same 8051. The isolated Z80 would be a dead-end line if it were not for the highly integrated processors 64180 from Hitachi and Z180 from Zilog, which contain the Z80 processor core.
64180/Z180 microprocessors include functions traditionally associated with peripheral circuits. Designers chose an architecture compatible with Z80, allowing Z80 users to utilize the software they previously had access to. The old Z80 architecture can be transformed without financial costs for tool systems and without any loss of compatibility. The new design is more attractive due to an improved instruction set, lower power consumption, and a higher level of integration.
Description of 64180.
The peripherals of the 64180 include: two 16-bit counter/timers; a programmable refresh and wait cycle controller; two DMA controllers (PDP); three serial ports with programmable baud rates. Add a bit of memory and parallel I/O and you will have a ready-made computer.
Like the Z80, the 64180 supports 16-bit I/O addresses. Whenever an IN A,(C) or OUT (C),A instruction is executed, both the Z80 and 64180 issue the contents of C as the low order port address, and the contents of B as the high 8 bits of the address. Unlike the Z80, for which few users ever needed more than an 8-bit address, 16-bit port addresses are crucial to the chip's operation.
All internal peripherals of the 64180 for the programmer are I/O ports. Each device has a unique address, the upper 8 bits of which are zero. 64 addresses are reserved, which upon reset are in the range from 0000 to 003F. The start of the block of internal device registers can be initialized at addresses: 0000, 0040, 0080, 00C0. This is particularly useful for preventing conflicts with external I/O port addresses.
Programming the CPU bus.
The 64180 allows dynamic selection of several bus parameters, including the number of wait cycles for memory and I/O devices (to accommodate slow memory and external I/O devices) and refresh rates. Like the Z80, the 64180 automatically performs refresh cycles to maintain data in dynamic memory. When dynamic memory is absent, refresh cycles reduce processor performance, so the 64180 has the option to disable them. The refresh control register allows setting the refresh frequency, adding wait cycles for slow memory. Upon reset, the fastest refresh is set (Z80 compatibility mode). One small difference is that the 64180 generates an 8-bit address in the refresh cycle, while the Z80 generates a 7-bit one. Unfortunately, 1 Mbit dynamic RAM requires a 9-bit address during refresh, so an additional external chip must be used.
Timers.
The 64180 has two independent 16-bit timers, which are clocked by the CPU's clock. Each can be programmed to generate an interrupt when the contents cross zero. The timers automatically reload with a value from a special register. Each timer has a 16-bit data register that can be read and written at any time and a 16-bit register, the value of which is reloaded when the contents of the data register cross 0. The timer mode is set using a special control register.
Serial ports.
The 64180 contains three serial devices. Two of them are traditional asynchronous UARTs (ASCII 0 and ASCII 1). The third is a special port for synchronous communication. The interface supports full duplex, 7 or 8 bits of data, 1 or 2 stop bits, all types of parity (even/odd), some modem control signals, and programmable baud rates. An interrupt occurs when a character is received, an error occurs, or the transmit buffer is empty. The clocked synchronous port (CSI/O) is a simple synchronous 8-bit half-duplex port. It does not support SDLC and other synchronous connections, but provides communication with the synchronous port of the 8051 and similar ones in other processors.
Interrupt system.
Like the Z80, the 64180 can support one of three interrupt modes (0, 1, and 2), depending on the choice made by the programmer using IM instructions. Additionally, it supports new interrupt sources, both internal and external (2 new, a total of 4). The new external interrupt sources available through inputs INT1 and INT2 are always handled in mode 2 (vector mode), regardless of the mode chosen for the other inputs. When servicing an interrupt, the CPU refers to a table in memory to fetch the address of the interrupt service routine (the interrupt vector table). Similarly, interrupts from internal devices are handled (in mode 2). In the Z80, all vectors in mode 2 are formed from the contents of register I (initialized by the command LD I,A - the high byte of the address) and the 8 bits set by the external device in the interrupt acknowledge cycle - the low byte of the address. The same mechanism is preserved in the 64180 for input INT0. However, interrupts on inputs INT1, INT2, and from internal devices are handled differently. The new register IL contains bits 5, 6, and 7 of the interrupt vector table for INT1, INT2, and internal devices. The upper 8 bits are taken from register I, just like in the Z80. Inputs INT1, INT2, and internal sources have a fixed offset from the start of the interrupt vector table, so bits 4, 3, 2, 1, 0 are not changed by the programmer, and the starting address of the table can be set in registers I and IL.
Instruction set.
The 64180 executes each Z80 instruction exactly, but faster. All registers, flags, and addressing modes are identical to the Z80. This makes the transition for programmers from Z80 to 64180 very simple. A few new instructions are very useful in some applications. The SLP instruction puts the 64180 into a very low power consumption mode. Exiting SLEEP mode is possible only through an interrupt or reset. The 8-bit unsigned multiplication instruction that produces a 16-bit result is executed in 17 clock cycles (17 T-states) and provides an increase in overall processor performance during calculations (based on this instruction, processor performance can be increased in both integer arithmetic and floating-point arithmetic : translator's note). It works with the register pairs BC, DE, HL, or SP, with the input operands contained in the lower and upper bytes, and the result in the same register pair. Four types of TST instructions perform a non-destructive AND between the argument and the accumulator. TSTIO takes an 8-bit I/O port as an argument. The upper 8 bits of the 16-bit port are automatically reset to 0.
Memory management.
An important advantage of 16-bit processors was the ability to address large amounts of memory. While most 8-bit microprocessors, including the Z80, addressed 64 Kbytes of memory, 16-bit ones typically addressed 1-16 Mbytes. A larger memory volume allows for more data and more complex programs, thus with greater capabilities. The MMU is a mechanism by which the 64180 can access memory beyond 64 Kbytes while maintaining compatibility with the Z80 instruction set. All instructions are still executed as if in a 16-bit address space, while the MMU converts 16-bit addresses into 20-bit addresses. The space of "logical" addresses is converted into the space of "physical" addresses. The entire space of "logical" addresses is divided into 3 parts: 0-3FFFH is converted to any 16k segment of 1Mb, for example, 0-3FFFH 4000H-7FFFH is converted to any 16k segment of 1Mb, for example, 10000H-13FFFH 8000H-FFFFH is converted to any 32k segment of 1Mb, for example, 40000H-407FFH. Any configuration of virtual ("logical") memory is practically possible. A complete discussion of the MMU within this article is impossible; we can only point out that some compilers support this mechanism automatically for developing programs whose code exceeds 64K.
Other Z80 compatible CPUs.
64180/Z180 are not the only highly integrated descendants of the Z80. Both Zilog and Toshiba sell a range of processors with various combinations of peripheral devices and memory on one chip, and the nomenclature of this range is expanding daily. Both companies sell the 84013 and 84015, which include one SIO (Z80 specific serial I/O port), one CTC (again Z80 specific timer). The SIO and CTC in these chips are identical to their discrete ancestors. Additionally, the 84013 and 84015 include a Watchdog timer (a device for restarting during failures and program hangs: translator's note) and a clock generator. The 84015 comes to us (to my great regret) in the form of a 100-pin QFP, which is due to the presence of PIO, which requires 20 additional pins. Other chips are sold, the listing of which is of interest more to "hardware" people than programmers. These include the 84C50 with 2K of internal RAM and the 84C01 (Z80, with an integrated clock circuit).
Summary
Does anyone really know what processors most designers use? I believe this is a mystery. Chip vendors track volume sales of CPUs to determine which ones outsell the others. They're happy to sell 100 million CPUs to one customer. This tells us nothing about the number of designers working with a chip. A thousand applications being produced in hundred quantities amounts to few chip sales, but lots of engineering. What processors do you use? Why? Let me know and I'll pass the information on to your fellow readers. Softaid - Extraordinary Emulators for 8 and 16 bit CPUs 8310 Guilford Road, Columbia, MD USA. Phone: (410) 290-7760, Fax: (410) 381-3253 Email info@softaid.com
Contents of the publication: Rush #01
- AMIGA NEWS
Amiga Inc works on Amiga OS 3.5 with enhancements like CD drive and PowerPC support. Split development for M68K and PPC processors. Delayed release to late 1999 or early 2000.
- AMIGA NEWS
Description of the 'Fast JPEG 1.10' viewer for Amiga, focusing on its features, installation, and usage. It highlights advantages like fast processing without quality loss and provides user tips. Readers are encouraged to share their software experiences.
- AMIGA NEWS
Basic programming for classic Amiga, discussing challenges and sharing knowledge in Amiga coding. Overview of Amiga graphics capabilities and processor features. Introduction to Amiga assembly language specifics.
- AMIGA NEWS
Overview of events related to the Amiga platform from early to mid-1998. Highlights include new hardware, software releases, and notable company collaborations. Future updates and developments are scheduled for the next issue.
- AMIGA NEWS
Collection of cheats and secrets for classic Amiga games compiled by Postcard Man. Readers encouraged to share their findings on complex games. Selection of tips and level codes provided for various games.
- AMIGA NEWS
Discussion of Phase-5's graphics cards and Permedia 2 processor capabilities. Details on Permedia 2's 2D/3D acceleration and compatibility. Mention of GLINT Delta processors and comparison of prices and availability.
- AMIGA NEWS
Analysis of Amiga's survival in the 90s, highlighting community efforts and technological advancements. Discussion on hardware improvements and software development. Encouragement for further exploration and learning about the Amiga platform.
- Spectrum Programming
Explanation of a fast method for real-time 3D graphics on the ZX Spectrum. Introduces efficient rotation and deformation techniques for 3D objects. Emphasizes improvements over traditional methods with practical examples.
- Spectrum Programming - Ticklish Jim
Discussion of combining sound effects with music for Spectrum's AY chip. Examples from development of 'CSC: Deja Vu' and technical challenges faced. Contains practical guide and code examples.
- Spectrum Programming
Discussion on byte mirroring and background restoration in ZX Spectrum programming, with examples.
- Spectrum Programming
Comprehensive guide for system programmers with practical tips for creating efficient and user-friendly software, including coding techniques, device compatibility, and program testing strategies.
- Spectrum Programming
Advanced coding techniques and modern graphics methods for ZX Spectrum. Tips for optimizing graphical procedures and coding on assembly. Useful advice for programmers to improve performance and efficiency.
- The End
Reflections on the creation of the first issue of the magazine 'Rush', its goals, audience, and future development.
- ZX-SOFT - Вячеслав Медноногов
Development updates on Vyacheslav Mednoy's new game 'Black Raven II', including gameplay changes, new spell introductions, and performance improvements.
- ZX-SOFT
Overview of new features in the updated commander from REAL software for ZX Spectrum, including file management, autodetection, and media viewing. Improvements in text, font, and music handling. Questions addressed regarding future updates.
- ZX-SOFT
Debate on which demo deserved the top spot at Funtop'98: Forever by DR or Refresh by XTM. Discussions in the demoscene community highlight the clash between technical prowess and conceptual depth. Different opinions reflect on the evolution of demoscene preferences.
- Authors
Acknowledgment of contributors and partners in creating Rush magazine. Detailed roles of each author and collaboration insights. Recognition of technical support and media partnerships.
- Virtual Specky
Discussion on converting graphics from PC to Spectrum, featuring insights from various experts. Techniques for improving conversion quality and tools like Photoshop are detailed. Emphasis on post-conversion refinement in Spectrum graphics editors.
- Virtual Speccy
Discussion on the CBSpeccy emulator for ZX-Spectrum on Amiga, highlighting its features, community opinions, and technical performance. Criticisms and praises for its emulation capabilities, particularly compared to PC emulators. Examination of potential improvements and community debates around version updates.
- Virtual Speccy
FAQ on ZX-Spectrum emulation on PC, covering popular emulators and file formats. Instructions for using different emulators and managing file types like Hobeta and TR-DOS. Discussion on Russian ZX-oriented servers and resources for enthusiasts.
- Introduction
Introduction to the Rush magazine, emphasizing creativity, progressive scene, and the goal to create a superior information source. The magazine seeks to gather promising groups and offer a unique perspective. Focuses on content and atmosphere, welcoming creators to contribute.
- Introduction - Grunge
Introduction to Rush, a new scenemag for Speccy/Amiga enthusiasts, aims to provide quality content and news while encouraging reader feedback.
- Interview - Konex
Interview with ANTARES group after FUNTOP-98. Discussion on their demos, challenges, and future plans. Insight into the group's formation and dynamics.
- Interview - Kvazar, DUX
Interview with Alexander Seleznev (KVAZAR), discussing his history with computers, the state of the ZX Spectrum scene, and future plans.
- Interview - Kvazar
Interview with Vitebsk group POWER on demo 'Crazy Love', development experiences, and future projects.
- Informatorium
Exploration of a CD with emulators for various platforms, highlighting Spectrum. Details the content organization and diversity. Concludes with insights from the CD-ROM Project's Spectrum software collection.
- Informacrium
Compilation of interesting and useful Internet addresses related to Amiga resources, including magazines, hardware manufacturers, and software companies.
- Informacrium - Viator
Overview of existing and upcoming publications on the Amiga platform. Discussion of the availability and distribution challenges for Amiga literature. Appeal for collaboration with new publications.
- About the Magazine
Discussion on creating a multi-platform magazine focusing on Spectrum, Amiga, and PC. Emphasis on broader understanding of computer scene. Encourage professionalism and adaptation to changing technology.
- Parallel Worlds
Overview of the evolution of Windows OS and PC processors from 1981 to 2000. Development milestones of MS-DOS, Windows, Intel processors, and competition with AMD and Cyrix. Challenges in maintaining compatibility with new processor technologies.
- Parallel Worlds
Overview of Macintosh models and their relevance in design and graphics fields, covering prices and specifications from 1997-1998. Discussion includes the evolution of Apple's hardware, notably the PowerMac series, and compares new G3 processors with PC counterparts. It highlights the resurgence of Macintosh post-crisis and its ongoing influence in the market.
- Development of the Spectrum - Slider
The article discusses a new graphical extension for the ZX Spectrum that enhances color palettes without increasing resource demands. By using a modified flash signal, new colors are created without interfering with existing software compatibility. The article provides implementation details and addresses practical usage concerns.
- Development of Spectrum
Connecting a CDOS modem to the 'Compact-128' computer by addressing keyboard port conflicts. Description of hardware modifications to solve the issue. Solution includes automatic blocking using a transistor inverter.
- Development of Spectrum - Ars
Discussion on AZX-Monstrum 512K development, its hardware compatibility, processor options, and potential enhancements in graphics and OS.
- Development of SPECTRUM
Discussion of Clive Sinclair's new computer platform, the ZX2000, designed to outperform PCs with enhanced speed, affordability, and battery efficiency.
- Development of Spectrum - Андрей Савичев
Examination of the evolution and ongoing relevance of the Z80 processor, and its role in embedded systems. Comparison of Z80 with its successors, highlighting advantages like energy efficiency and command enhancements. Overview of integrated Z80-based CPUs and their peripherals.
- Advertisement
This article is an advertisement for Scorpion products including hardware for ZX Spectrum and Amiga software, along with pricing and ordering details.
- Advertising
Collection of advertisements for Amiga and ZX Spectrum hardware and software, with contact information for sellers and details about the new Amiga magazine subscription.
- Advertisement
Advertisement for X-TRADE's General Sound music board. Includes pricing, technical details, and purchase instructions. Features a FAQ section and compatibility info.
- Meaning Without Meaning - Viator
Philosophical reflections on existentialism, immortality, and human destiny. The narrative weaves through stories of ambition, the quest for eternal life, and a utopian downfall. A blend of introspection and speculative fiction.
- Scene vs Professionals
Exploration of the demoscene's creativity versus commercial game development. Discussion of potential for professional-quality programs by scene members. Call for collaboration with leading scene groups.
- Scene Chronicle - Андрей Савичев
Reflections on ZX Spectrum's enduring appeal, its community's resilience, and its potential resurgence in Russia.
- Scene Chronology
Overview of the Rush group's activities, including past projects, current endeavors, and future plans, with emphasis on software development and gaming.
- Scene Chronicles
The article discusses various ZX Spectrum scene news, including game releases, demoparties, and updates from developers and teams.
- Chronicles of the Scene
The article discusses the FUNTOP'98 international computer art festival held in Moscow, highlighting key events, notable attendees, and the various competitions held during the event.
- Scene Chronia
Discussion on Amiga scene development through collaboration, addressing user isolation and promoting network expansion.
- Shell Management
Статья описывает управление оболочкой для ZX Spectrum и Amiga, включая клавиши и функции для навигации. Упоминаются особенности работы на Amiga с PAL монитором и предоставляется контакт для поддержки. Также отмечено, что текстовые файлы имеют стандартную MS-DOS кодировку.