Sunday, March 22, 2026

The advantage of leveraging FPGA for 1130 related designs - 1627 Plotter behavior discovery

ATTACHING 1627 PLOTTER TO IBM 1130

The IBM 1627 Plotter is a private labeled and slightly modified version of the Calcomp 565 or Calcomp 563 depending on the model of the 1627. It moves continuous paper forward and backwards over a drum, with a pen that moves left and right along the drum. The drum and the pen move in increments of 1/100 inch to draw graphs and other images. The pen can be raised to move without drawing and then lowered to put ink on the paper. 

IBM supports the plotter by installing a double width Solid Logic Technology (SLT) card into a specific pair of sockets in one compartment of the 1130. This 5806223 card implements the device controller logic to permit software running on the 1130 to draw using the plotter. A cable from the 1627 has two Standard Modular System (SMS) paddle cards that plug into the 1130, one providing 115VAC power and the other connecting signals between the 1627 and 1130. 

The 1627 is a very simple device. Pulses into the machine command movements, which the plotter accomplishes, but does not provide any feedback to the 1130 about movements or status. The only signal from the 1627 connects to an internal power supply that produces -24V, thus the 1130 can see if the wire is at -24V to determine if the 1627 is connected and powered on. 

The controller card in the 1130 responds to the 1130 instruction XIO (execute input output). If an XIO with the device address of the plotter - area code 5 - is issued, the controller card looks at the contents of a memory location pointed to by the XIO instruction.

The first six bits of the word at the memory location are used to request one or more movements. Movements can be combined in one XIO instruction of type Write. Going from left to right, they request:

  1. Drop the pen down onto the paper
  2. Roll the drum upwards (backwards on paper)
  3. Roll the drum downward
  4. Move the carriage with the pen to the right
  5. Move the carriage with the pen to the left
  6. Raise the pen up from the paper
The controller generates the proper duration pulse to the 1627 to cause the movement. It also maintains status of what it believes is happening in the 1627 since there is no feedback from the plotter. When the controller believes the movement has completed it raises a request to the 1130 to interrupt the currently executing instructions and instead execute interrupt handler software. 

An XIO instruction of type Sense Device is used to see the status as the controller card sees it. The card sets bits that the XIO Sense Device will place in the 1130 Accumulator (ACC) register for interrogation by software. When the controller is requesting an interrupt, bit 0 is set to 1; this is interpreted as operation complete. If the 1627 is not powered on or not attach, the lack of the -24V will cause the card to report the plotter as not ready by setting bit 15 to a 1. Finally, if an XIO Sense Device is issued after an XIO Write but before the interrupt is requested by the card, then bit 14 is set to 1 to indicate that the plotter is busy accomplishing some movement. 

The more common model of the 1627, model 1, takes about 3.9 milliseconds to complete a movement of the drum or carriage. Raising or lowering the pen takes about 100 milliseconds to complete. Thus the time from an XIO Write to the interrupt request is 3.9 or 100 ms. Bit 14 reports the plotter is busy during those intervals.

DISCOVERED SUBTLETY IN BEHAVIOR

In reading the 1130 Functional Characteristics manual which informs programmers how instructions and peripheral devices will behave, I discovered something I had missed in my earlier implementation. If the 1627 is not powered on or not connected to the 1130, when an XIO Write is executed for the plotter, the machine will immediately generate an interrupt request. Thus an XIO Sense Device immediately after the write will return bits 0 and 15 set to 1 without the time delays that occur if the request went to an operational plotter. 

VALUE OF A SOFT IMPLEMENTATION USING AN FPGA ON THE CARD

My first implementation of a substitute for the 5806223 IBM card used multiple integrated circuits including timers and other combinatorial logic. I switched to a card that uses a Digilent CMOD S7 FPGA as a daughterboard and just a couple of glue logic chips. 

This makes it very simple to change the functionality to include the behavior when the 1627 is not ready so that it does trigger the interrupt request immediately after an XIO Write. Had I not used the FPGA which can be reloaded, as in the earlier implementation, I would have had to redesign and probably manufacture a new printed circuit board. 

1 comment:

  1. Two thoughts:
    1. What is the expected behavior if the command requests two contradictory behaviors? For example pen left and pen right?
    2. This may already exist, but it would be nice to be able to capture the plotter command stream, and later play it back, for example to a laser printer or svg file.

    ReplyDelete