CDP6402 Adapter to Replace DC319


Where can I buy a DC319

I assume that many don’t have a DC319. It still was often used by digital and was sold to the public, but not many have them still in stock. It implements all the features of a DLV11 plus some additional options, e.g. programmable baudrate and system clock outputs. They can still be purchased, but all offers I know of require you to purchase a minimal quantity. This might or might not be a solution.

The other UART often used by computers from digital and form other vendors of serial interfaces for the PDP-11 was the CDP6402 or one the many predecessors for which the CDP6402 was a pin compatible replacement. Note that very old versions of this type of UART require at least two voltages, for example the TR1602A required -12V on Pin 2. Others had an option to switch modes using Pin 2, e.g. the CDP1854A

Typically the CDP6402 et.al. are more expensive than a DC319, but on the other hand they can be bought in smaller quantities down to single units.

Therefore I decided very soon to provide a small adapter that uses a CDP6402 UART and replaces the on-board DC319 of the DCJ11 SBC.

Unfortunately the first adapters really were just a hack to be compatible with the PDP-11/Hack characteristics of the DCJ11 SBC and this adapter also worked well for simple projects, but at the end it was not a very good replacement. Be aware that it is not easy to make a 100% compatible replacement with a small adapter that will be software compatible in all aspects.

In the meantime I played with various versions of the small CDP6402 adapters with increasing compatibility and here I will present you the various evolutionary steps.

First of all if you intend to use one of the adapters described in this chapter using a CPD6402 UART or a compatible device, then do not install the pin header for the baud-rate jumpers. All these Adapters do not support jumper selected baud-rate, rather the baudrate is one 1/16th of the crystal clock. Today you want the highest speed possible. The CDP6402 supports a crystal clock of 1.8432MHz which will give you a console baud-rate of 115'200baud. First 1.8432MHz crystal oscillators are still available, not like 614.400kHz required by the DC319. Therefore I recommend to install a 1.8432MHz crystal osczillator when using an adapter.

Alternative UART Devices

The challenge for a DCJ11 UART that can be used as console is that it must be ready without initialization. Which means it must have a minimal set of features when powered on. This comes from the time when serial interfaces were not configured via configuration registers but with jumpers, solder bridges or wire-wrap posts as this was much cheaper. I know that there were other UARTs available that could be jumpered to a mode where they act as a basic serial interface without preprogramming configuration registers, but I could not find any that is still available not even as NOS. If you know of such a device please let me know.

Overview of Adapters and their Compatibility

Adapters 1., 2. and 5. have actually been built. Adapter 3. has not been built as an adapter, but the logic of the GAL has been used for the second serial interface on breadboard and the Multi IO adapter. Adapter 4. exists as KiCAD project only.

First Adapter using a GAL16V8

This version implements only the minimal features and really only serves as console and works with ODT and with the FIG Forth described later, but be aware that I had to modify the terminal IO routines in FIG Forth to make Forth run with this Adapter. Other software might not work without modification. The main reasons are, that it does not implement the BRK bit which is required when you need to send the RS-232 BREAK signal. Also unused bits in the registers will not necessarily return 0but may return any arbitrary value.

Not recommended as adapter as it has been functionally been replaced by adapter 3.

Second Adapter using three SMD TTL devices

Has the exact same features as the first adapter, except that it does implement the logic in the GAL using three TTL devices. Due to space constraints I had to use SOIC packages with a 1.27mm pitch. This still can be soldered with standard equipment that is also used for through hole components. As with the first Adapter it works with ODT and the modified FIG Forth.

Third Adapter using a GAL16V8

This Adapter implements the BREAK bit. But still undefined bits in the register still return arbitrary values.

Forth Adapter using five SMD TTL devices

SMD TTL version of the third adapter using a GAL16V8

Fifth Aadapter using a ATF1504 CPLD

This is rather a nasty adapter, you need to solder a 0.8mm pitch TQFP-44 package and the JTAG interface is just implemented as 6 pin headers.

It implements the BRK bit, the RTR bit and unused bits in the register return 0. This adpater is most likely to work with any software that also works with a DC319.

CDP6402 Adapter with GAL16V8

CDP6402 Adapter

PCB

A small PCB has been designed that acts as a bridge between the CDP6402 and the DC319 socket on the DCJ11 SBC.

PCB Edge

Building

When building the CDP6402 mini adapter you should first solder the SMD capacitors. C1 and C3 are mandatory, C2 is optional as there is already one on the main board. You can either use a socket for the CDP6402 or solder it directly to the PCB. I recommend to use a socket, so you can re-use the CDP6402 in another project, e.g. the expansion card.

For the GAL you need to use a socket, else you will not be able to reprogram it. However if you are brave enough you can also solder a programmed GAL16V8.

If you are using a socket for the GAL16V8 you should solder it as after the SMD capacitors followed by the single inline pins that plug into the DC319 socket. Finally you can solder the CDP6402 or the socket for the CDP6402.

PCB Edge

On the bottom you need to solder two rows of DIL pins that will plug into the DC319 socket of the DCJ11 SBC. These are special pin headers with thin pin shafts that fit into the pins of machined sockets. You must not use the pin header single row connecters with square pins.

PCB Edge

Installation

The Adapter replaces the DC319 and is inserted into the socket. Make sure that there are not shorts between the pin headers for the baudrate jumper and the PCB and as will that there is no contact between the crystal oscillator and any metal parts of the adapter PCB. As mentioned earlier, if you are going to use a CDP6402 adapter it is best to not even equip the DCJ11 SBC with the pin headers for the baud rate jumpers and to be on the save side put some capton or isolation tape on the crystal oscillator cap.

PCB Edge

CDP6402 Adapter using simple TTL logic

This adapter was just made because I wanted to have another adapter that did not require to program a GAL. The logic as a DC319 replacement is only minimal and just implements the two status bits DR and TBRE as bit 7 in the registers RCSR and XCSR.

PCB Edge

As space is limited I had to use SMD packages for the TTL devices. However I was using the normal SOIC packages with a 1.27mm pitch which can be soldered by hand without any problems. Provided you use sufficient flux to assure easy soldering and to avoid any solder bridges. Here you can see the adapter installed in the prototype DCJ11 SBC, replacing the DC319.

PCB Edge

CDP6402 Adapter with GAL16V8 inkluding BRK support

As mentioned this adapter has not been built. In fact the only differences to adapter 1. are some additional connections to support the BRK feature and the GAL design file that implements the BREAK signal to the RS-232 transmit signal.

CDP6402 Adapter

The PCB looks exactly the same as the PCB for adapter 1. Only some traces for the new connections to support the BRK bit have been added, not really something you can see on a photograph.

The reason why I did not build this version of adapter is because I decided to build the Multi IO card instead and used the GAL designed for this adapter as the glue logic of the CDP6402 on the Multi IO board.

CDP6402 Adapter using TTL logic with BRK support

This is just a design study and has not been built. First I wanted to check if there is enough space to place all 5 necessary TTL devices to the small space but when I was routing the PCB I already started on adapter 5 with the CPLD which was unexpectedly simple so I decided not to produce any of this adapter and directly jump to adpater 5.

PCB Edge

CDP6402 Adapter using an ATF1504 CPLD

The last adapter I designed and built uses a small CPLD, an ATF1504 as the glue-logic. This has the advantage that I can implement a lot of features that should be close enough to a real DC319, so it can be used as Serial Line Unit in real operating systems, like RT-11. The adapter implements the BRK bit and the two interrupt enable bit. More over it returns correctly overflow errors and frame errors. It produces the same RCVIRQ and XMTIRQ signals like a DC319 and all undefined bits properly return a zero value.

PCB Edge

They outline of the adapter is still the same, the TQFP-44 package with 0.8mm just fits between the pads for the DC319 socket connector

PCB Edge

It is used in exactly the same way as the other adapters for the CDP6402

PCB Edge

Building

Basically the same rules apply as given for the first adapter. However soldering a TQFP-44 package is more challenging than soldering SMD capacitors or SOIC packages with 1.27mm pitch. The ATF1504 comes in a TQFP-44 package with 0.8mm pitch which is not as bad as the modern 0.5mm pitch of QFP packages or 0.4mm pitch of QFN packages, it is still doable with a normal 2mm solder iron, but it is almost impossible to solder without sufficient flux. There are many tutorials in Youtube that show how to solder QFP packages and from my own experience I can say that using a lot of flux and only very very little solder wire is the key to success. Even to remove solder bridges a dry solder iron, with a previously cleaned tip, and flux is almost always sufficient to remove them. I also recommend that you check for proper connections and shorts with an Ohm meter.

As always when using SMD parts you should solder the flatests parts first, in our case the ATF1504. The rest of the setup is the same as shown for the first adapter.

The JTAG header is proprietary and is built using a 2x4 pin header with the two middle pins on one side removed. You will need to use Dupont Wires to connect the JTAG interface header with the programmer. This works pretty well. Depending on the programmer you need to make sure that all GND pins are connected.

Downloads

KiCAD project for adapter 1 using a GAL CUPL project including JED file to program the GAL KiCAD Project for adapter 2 using simple TTL logic KiCAD project for adapter 3 with break support using a GAL CUPL project including JED file to program the GAL KiCAD Project for adapter 4 with break support using TTL logic KiCAD project for adapter 5 using a CPLD CUPL project including JED file to program the CPLD