Oberon #04: Hardware: Connecting Hayes Modems to ZX Spectrum

Connecting internal Hayes-compatible modems to the Spectrum.

----------------------------------------
First of all, I want to say a few words about everything that follows. In principle, this scheme has been published more than once, but... Not everyone has the St. Petersburg electronic newspaper ZX-News, in the 15th issue of which there was a similar article. And even more so, not everyone has access to the echo conference ZX.SPECTRUM in the FidoNet network. Therefore, we took it upon ourselves to convey this material to you, dear readers. Moreover, here we will also talk about the nuances of connection that we encountered ourselves. The COPYRIGHT for the controller scheme belongs to Mikhail Kondratiev. The author of the article, under the impression of which this was written, is Igor Gruzdev. In the very first lines, I want to dispel the myth that a normal hayes-compatible modem can only be connected to a Scorpion. Nothing of the sort! It's just that all the necessary signals are already brought out on the Scorpion's system connector, while owners of, for example, Pentagons will have to extend them themselves. Moreover, it is still unknown who is luckier, the owners of the Scorpion or the Pentagons - the "pentagonists" do not need to assemble a circuit that blocks the internal ports of the computer. And the coordination of internal and external signals /NMI in the Scorpion is implemented somewhat unsuccessfully (at least for this connection scheme).

So, less talk, more action. To implement the controller for the internal (!!!) HAYES-compatible modem, you will need three microchips and 8-10 resistors. Microchips: DD1 - LL1, DD2 - LN1, DD3 - TM2. Any series, whether 1533 or 555, does not matter fundamentally. Resistors of any value in the range from 1 to 15 kOhm.



As you can see, the scheme is quite simple. On the left side are the names of signals and pin numbers (A - top row, B - bottom) for the Scorpion, on the right - for the Hayes-compatible modem. A +5V supply should be applied to the 1st input of the trigger (DD3) through a 1 kOhm resistor for more reliable operation of the circuit. To power the microchips, +5V should be applied to their 14th pin and ground to the 7th pin. As can be seen from the scheme, the controller decodes using only one address signal - A4, while its full address is #xEF. Therefore, if you have a Scorpion or any other computer that does not analyze signal A4 when decoding internal ports, you will also need to assemble a circuit to generate the /IORQGE signal, which you can find in this same issue, in the article about connecting the C-DOS modem. The input signals for this scheme will be: /IORQ and A4, the output - /IORQGE.

Now about how the pinout of the modem slot and the system connector of the computer will look (the pin numbers are given for the Scorpion: A - top, B - bottom: on the modem: top - upper part of the board where all the microchips are located, the numbering of the slot pins starts from the side of the connector for the telephone line and continues along the modem):

Scorpion Modem
┌------┬---┐ ┌---┬------┐
│A 8 │A26│----> │A31│ A 0 │
│A 9 │B27│----> │A30│ A 1 │
│A10 │A27│----> │A29│ A 2 │
│D 0 │A6 │----> │A9 │ D 0 │
│D 1 │A7 │----> │A8 │ D 1 │
│D 2 │A8 │----> │A7 │ D 2 │
│D 3 │A11│----> │A6 │ D 3 │
│D 4 │A12│----> │A5 │ D 4 │
│D 5 │A10│----> │A4 │ D 5 │
│D 6 │A9 │----> │A3 │ D 6 │
│D 7 │A3 │----> │A2 │ D 7 │
│ │ │ │A28│ A 3 │ -┐
│ │ │ │A27│ A 4 │ │ to
│ │ │ │A26│ A 5 │ │ +5V
│ │ │ │A25│ A 6 │ │through
│ │ │ │A24│ A 7 │ │3-10K
│ │ │ │A23│ A 8 │ │
│ │ │ │A22│ A 9 │ -┘
│ │ │ │A21│ A10 │ -┐ to
│ │ │ │A20│ A11 │ -┘ ground
│ │ │ │A11│ AEN │ to ground
│ +5v │B3 │----> │B3 │ +5v │
-->│ +12v │B17│----> │B9 │ +12v │
-->│ -12v │A16│----> │B7 │ -12v │
-->│ -5V │A18│----> │B5 │ -5v │
│ GND │A30│----> │B1 │ GND │
│ GND │B30│----> │B31│ GND │
(*)│/IORQG│B13│-│н │ │ │ │
│/RESET│B20│-│а │ │ │ │
│ /RD │A18│-│ │ │ │ │
│ A4 │B24│-│п │ │ │ │
│/IORQ │A17│-│л │-│B2 │ RESET│
│ /WR │A19│-│а │-│B14│ IOR │
│ A11 │B28│-│т │-│B13│ IOW │
│ /NMI │A14│-│у │-│B24│ IORQ4│
└------┴---┘ └---┴------┘

signal signal

Designations on the left:
--> - bring the signal to the system connector.
(*) - only for computers where it is necessary to block internal ports (signal /IORQGE).

The modem itself should be set to COM1, which corresponds to address #3F8 and request for interrupt IORQ4. Read about how to do this with jumpers in the instructions for your modem.

Well, now there is very little left to do - just a bit to finalize your computer.

First. It is necessary to implement proper coordination of the /NMI signals received from the system connector (if it is not present on your connector - bring it out) and from the Magic button circuit. This is done by adding just one microchip 5SSЛИ1 (or any other series). For this, near the processor, cut the trace leading to its 17th pin, and insert a logic "AND" element (К5SSЛИ1) into the gap, to which the /NMI signal from the system connector should be brought to the second input. The changes will look as follows:

┌-------

17│
------┬---х-----┬--┤ Z80
│ 1┌---┐ │ │
└--┤& │3 │ │
/NMI 2│ ├--┘ │
---------┤ │ └------
└---┘

Secondly. If you do not have a Pentagon or a Profi, and the signal A4 does not participate in decoding internal ports (for example, in the Scorpion, the modem controller will conflict with internal port #FF), then you need to take care to bring the signal /IORQGE to the system connector. If you do not have it, then again, read about this in the article on connecting the C-DOS modem - you will only need to add one resistor to the board.

Thirdly. Negative voltages for the modem. One of the most painful questions, because if these contacts on your modem connector are used, it is MANDATORY to supply the corresponding voltage to them!!! That is, for example, if the modem uses contacts B5 (-5v) and B7 (-12v), then these voltages must be supplied. If you have an IBM power supply, then all these voltages are present, and you do not need to worry.

Fourthly. The most painful question - correcting the error in the ROM. As many probably know, the standard ROM-48 contains a gross error in the procedure for handling non-maskable interrupts. At address #006D instead of the command JR Z,#70 (codes #28 #01), there is the command JR NZ,#70 (codes #20 #01). In theory, it should work like this: upon receiving a non-maskable interrupt, the processor starts the procedure at address #66, which takes the vector (address) of the handling procedure from cell #5CB0: if this cell is 0, i.e., the vector is not defined, control returns to the interrupted program: if the vector is defined, a jump is made to it. Due to the error, the jump to the vector occurs precisely when it is not defined i.e., equal to 0. As a result, the computer resets.

Unfortunately, there is only one way to fix this error - to reprogram the ROM-48. However, some programs do not use non-maskable interrupts from the modem, but that is why they, as they say, "do not fully utilize" all the capabilities of hayes-compatible modems. Therefore, our advice to you: try to find a way to reprogram your ROM. Although, if you are the owner of a Scorpion with a shadow monitor version 2.95 or higher, then this error has already been fixed for you.

Well, we have connected the modem, but how to check it now. For this, get some terminal program that works with this implementation of the controller and run it. For example, a terminal for IS-DOS, written by Mikhail Kondratiev himself.

To check the connection between the computer and the modem, enable echo mode in the modem (send the modem the command ATE1), although usually, in most modems, this mode is enabled by default. In this case, the modem will return every byte sent to it. If the connection is stable, then each character you enter will be duplicated on the screen (one from the keyboard, the second - echo from the modem). It should also be remembered that in some terminal programs (for example, in the terminal by Alex Globa for IS-DOS) the mode for outputting entered characters is disabled, and all characters displayed on the screen are echoes from the modem. Here it is even simpler - if, for example, you pressed the "I" key and the letter Q appeared, then this is incorrect, but if I - everything is fine.

That's basically it. Now the doors to the fascinating world of BBS, electronic networks, and other technological wonders are open to you. You will be able to download any file from your IBM friend. You will be able to access IBM's BBS, and if you're lucky, also to FidoNet nodes.

And you will definitely gain access to the Spectrum Network being organized now in Samara on hayes-compatible modems.

And finally, for those interested in how the controller works. The selection of modem ports is carried out when A4=0, at this point signals A8-A10 specify one of the seven modem registers. But... As can be seen from the scheme, another address signal - A11 - also participates in this. It does not participate directly in the selection of the modem, it only sets the state of the interrupt key, assembled based on the trigger DD3. When writing to any modem register, the key takes the state of line A11. And why is all this necessary? - you may ask. Here’s why. With the key closed (5th pin DD3 = 1), the output of the controller - the input of the computer signal /NMI is always equal to 1, regardless of the state of the modem signal IORQ4. That is, the interrupt request pulses generated by the modem will never reach the computer.

When writing to the register with A11=0, the key opens, and the state of the signal /NMI directly depends on IORQ4. When the computer is RESET, the key closes again.

Thus, the addresses of the modem registers are determined by the mask:

F E D C B A 9 8 7 6 5 4 3 2 1 0
-------------------------------
х х х х 1 r r r 1 1 1 0 1 1 1 1 - 0EF-7EF
х х х х 0 r r r 1 1 1 0 1 1 1 1 - 8EF-FEF

х - state is not considered.
r - corresponding bit of the three-bit modem register number.

There. Now that's all. Assemble, connect, and enjoy.

(C) Evgeny Milun
MUSIC ВУ : MARKET SOFT

-════════════════════════════════════════ * * *

Contents of the publication: Oberon #04

  • From the Editorial
    This editorial discusses the legal 'charges' against the creators of Oberon #4 as a humorous narrative, highlights the challenges faced in publishing this issue, and announces a potential hiatus for the magazine.
  • Scroll
    Analysis of the game 'Chaos' by Julian Gollop. Simplified gameplay mechanics and strategic elements. Description of creatures, spells, and tactics.
  • Scroll - Unbeliever
    Description of a mathematical game for ZX Spectrum where players collect formula symbols while navigating gears.
  • Scroll - M.M.A
    Discussion of 'Doc the Destroyer', a unique fighting and adventure game for ZX Spectrum. The article covers controls, character customization, and game mechanics. Compatibility issues on different ZX Spectrum models are also addressed.
  • Overview - M.M.A
    The article provides a review of games for ZX Spectrum, including KOMANDO 2, WRESTLING SUPERSTARS, TAG TEAM WRESTLING, and CAPTAIN PLANET. It highlights the features, graphics, and gameplay of each game, noting both strengths and weaknesses. The review concludes with recommendations and comparisons to other platforms and games.
  • Overview
    Overview of various ZX Spectrum games, highlighting their unique features, gameplay mechanics, and design elements. Includes critique on sound effects, graphics, and technical issues. Discusses games like 'Stryker in the Crypts of Trogan', 'Phileas Fogg's Balloon Battles', and 'Survival'.
  • Overview - Alex Noman
    The article reviews games for the ZX Spectrum, including BOOVIE, MOTOR MASSACRE, SOCCER PINBALL, and HUXLEY PIG 1 & 2. Each game is detailed in terms of gameplay, graphics, and unique features. The discussion includes comparisons to other games and highlights specific technical aspects.
  • Review
    A review of various games, including Little Computer People and Lost Caves, highlighting their features and versions. It also discusses 75Occ Grand Prix by Codemasters with its limitations. The article provides insights into game mechanics and versions.
  • Review
    Detailed review of various assemblers like Alasm 3.8, TASM 4.12, and others, highlighting their features and shortcomings.
  • About Everything
    Announcement of the creation of the SamZxNet network in Samara and the challenges of setting it up with HAYES modems. Explanation of the modems' power requirements and potential difficulties. Invitation for technical advice from experienced readers.
  • About Everything
    Description of travel to ENLIGHT'97 and meeting various demoscene participants. Observations of event organization and issues. Insights into participant experiences and scene discussions.
  • About Everything
    Report on the second day of ENLIGHT'97: events, challenges, and reflections. Describes voting results and organizational difficulties. Highlights future prospects for Spectrum demo parties.
  • About Everything
    The article features reader feedback on Oberon #04, critiquing design and content choices and discussing issues with software protection and game enhancements.
  • About Everything
    Discussion of the adventure game KAYLETH with gameplay tips and advice. Includes a game dictionary and suggestions from the author and their team. Calls for a local artist for future RPG development.
  • About Everything
    Reflection on the closure of the 'ZX-REVIEW' magazine and the adaptation of its article for 'Oberon'. Discussion on the development of ultra-short boot loaders. Optimization techniques for writing one-sector boot loaders on ZX Spectrum.
  • About Everything
    Exploration of amateur contributions to electronics, music, and computing history, highlighting figures like Faraday and Babbage. The evolution from handmade instruments to personal computers. Discussion on jazz, blues, and rock'n'roll's informal origins.
  • About Everything
    The story of Lieutenant Edward Roberts' journey from radio kits to creating the first PC, the Altair 8800, overcoming skepticism and challenges.
  • About Everything
    The article explores the rise and evolution of the computer industry, highlighting the transformation from passionate hobbyists to corporate dominance by giants like IBM and Microsoft.
  • About Everything
    An exploration of Sir Clive Sinclair's project after selling the Sinclair brand, detailing the features of the Cambridge Computers Z88 laptop.
  • About Everything
    Discussion of software market problems in 1997 for ZX Spectrum, highlighting lack of new software and user reluctance to pay.
  • Announcement - M.M.A
    Announcement of 'Black Raven' game by V. Mednonogov, focusing on gameplay, technical challenges, and upcoming features.
  • Announcement
    Discussion of the decline in ZX Spectrum development, reviews of new games and utilities, and announcements of future projects.
  • Educational Program
    The article provides an overview of FidoNet, a non-commercial computer network often considered the predecessor of the Internet, detailing its origins, growth, and unique cultural aspects.
  • Hardware
    Instructions for connecting the 'ALEGRO' modem to computers with normal port #FF, detailing hardware modifications required for proper signal handling.
  • Hardware
    Connecting Hayes-compatible modems to ZX Spectrum, focusing on Scorpion and Pentagon models, detailing hardware modifications. Specific instructions for internal port blocking and signal alignment provided. Step-by-step process and technical intricacies explained.
  • Hardware
    Discussion of the transition from 5.25' to 3.5' floppy disks for ZX Spectrum, including installation issues and solutions for compatibility with existing software.
  • Let's Feast
    A satirical story about a Rabbit who lost his house to a cunning Fox and how a Rooster helped him reclaim it.
  • Let's Gourmet
    A humorous tale about Malysh and Karlson's adventures with technology, drawing parallels between computers and everyday life, culminating in a comic mishap with an AMIGA computer.
  • Advertising
    Article discusses free advertising policy of Oberon, catalog of programs and hardware for ZX Spectrum, and adventure game engagement.
  • Advertisement - Kano
    Promotional campaign by Magic Soft and RPSG in Russia for Amiga multimedia computers, offering exhibitions, sales, and consultations. They highlight Amiga's advantages over other systems, describe various models, and provide price lists. Collaboration with 'Computers for Population' for distribution and services.