This web site is under construction and contains details of products that will become available in 2024. Details of current DryFire products may be found at: www.dryfire.com

DCPE: a dongle emulator project

"Probably the most exciting thing since you last watched paint dry!" Mike Lake, Christmas, 2022.

The Dongle and Cassette Port Emulator (DCPE) project came about in December 2022 after a moment of nostalgic madness by Brian Edmundson and Mike Lake. Please drop us an email if you are interested.

Contents:

Background

Mike was one of the three people in the room (the other two being Pete Dowson and Graham Heggie) when the world's first dongle was invented (in Graham's kitchen) to protect the Wordcraft word processor running on the Commodore PET. Brian ended up manufacturing tens of thousands of dongles.

For those who don't know much about the PET there is an excellent video on YouTube by The 8-Bit Guy.

The photo below shows (on the left) the world's first dongle manufactured by Graham - the electronics were embedded in epoxy resin to keep them safe from prying eyes. On the right is one of the later dongles manufactured in 1982 by Brian who not only assembled them but also injection moulded the enclosures.

To be strictly accurate there was one earlier dongle - a prototype made from Veroboard and wires that dangled from the cassette port of a Commodore PET while Graham soldered the 74LS165 chip in place and Pete wrote the code to test it. Unfortunately, the Veroboard prototype did not stand the test of time!

Please click here to see a selection of the dongles we made.

Myths, lies and "dongle"

Over the years a lot of myths have grown up about when the dongle was invented, by whom and how it got its name. One cheeky ad from an American company in 1992 claimed it was invented by "Dan Gall"! Click the image below for the full ad.

The reality is much simpler - the "dangling" prototype became a "dongle" over a cup of tea after the prototype worked. We should have patented the invention and registered the trademark - but we didn't, we wanted to shift tens of thousands of Wordcraft packages - which we did - mainly thanks to Paul Handover's marketing efforts.

So, not only did we invent a gizmo but we (Pete, Graham, and Mike) also added a word to the English laguage!

Dongle FAQ

Question Answer
When were dongles invented? Saturday, 12th May, 1979, between lunch and tea time.
Who invented them? Graham Heggie, Pete Dowson and Mike Lake.

Graham was an electronics engineer, Pete was a software manager at ICL (International Computers Limited) in Stoke and Mike was a teacher in Derby having left Rolls Royce computer department a few years before.

Where were they invented? Coventry, England - in Graham's kitchen.
Who did the electronics prototype? Graham. A 74LS165 shift register on a piece of Veroboard.
Who did the test code? Pete. Written in 6502 Assembler.
Why "dongle"? Graham's Veroboard prototype dangled out of the back of a PET. "Dangle" became "dongle" over a cup of tea.
What was it for? To protect the newly written Wordcraft word processor.

Pete wrote the Wordcraft code (in BCPL and Assembler), Mike did the testing and documentation - using Wordcraft and a Qume Daisy Wheel printer.

When did Wordcraft go on sale? Summer 1979 soon after the Commodore 2040 5.25", 180KB, disk drive was released. Initially sold by Mike through "Hipposoft" then by Paul Handover of Dataview in Colchester.
What happened to Wordcraft? Microsoft Word came along!

Wordcraft morphed into Typecraft (digital typesetting - also protected with a dongle) and then LaserFax which became the standard PC software supplied with most of the world's multi-functional peripherals (print, fax, scan).

Wordcraft, the company, is still going. Read more here.

Who manufactured dongles? Initally Graham, then Brian Edmundson in Draycott, Derbyshire.
Who else used dongles? Paul Handover used them for some Dataview products (including "DTL BASIC" and "The Financial Director"). He also sold dongles to a variety of other software companies, mainly in the UK.
What PCs did they work with? Initially the Commodore PET, then IBM compatible PCs using 25-pin and 9-pin serial ports. Also Sirius, DEC and Apricot computers.

The photo below shows three types: 25-pin serial, PET cassette port and 9-pin serial. The central one was used to protect Dataview's DTL Basic software.

How much protection did they give? Not much. The 74LS165 has eight parallel data lines which can be tied to ground or 5V giving 256 possible combinations. The data is shifted out serially using three lines: load, clock and data. On the PET cassette port these were the Sense, Write and Read lines.
Was that good enough? Yes. Dongle numbers were random and tied to an individual copy of the software. Pete's self-modifying code existed in executable form for a few microseconds only when it read the dongle.
Was it patented? No. Nor did we trademark the name!
Was it copied? Yes.

Here are a few we know about - click the image for a larger version.

They are mainly for the PET cassette port but one is for the User Port and another is for 9-pin serial. The top right hand one was for the Compsoft DMS (Data Management System) and the horrible bottom one was for the Office Mate accounts system - both are from 1982.

Imitation is the sincerest form of flattery - but our dongles looked the most professional!

Did anyone rip it off? Someone produced a switch-selectable dongle emulator with four 74LS165 shift registers daisy chained to give 256 x 256 x 256 x 256 (42,949,667,296) combinations. Careful examination of the switches shows that only the first bank of eight was ever used. That was naughty and its use was illegal because it encouraged others to break our copyright. He was spoken to by our Palermo Copyright Enforcement Office. He stopped.

Evidence behind the facts

The dongle was invented in 1979.

The text below is taken from "I(C)PUG - 20 YEARS NOT OUT!" by Brian Granger. ICPUG was the Independent (Commodore) PET User Group.

"The first group meeting occurred on October 8th 1978 in Bedfordshire courtesy of Robin Leaver, a local businessman. That first meeting had about a dozen people present from all over the country. ... At this meeting was a certain Pete Dowson and he talked about a word processor that he was developing. That turned into Wordcraft which was a popular package on the PET and more so on the PC before the big guns got into the act. Pete was the first example of an ICPUG member making it big in the computer world."

Mike became Secretary and Treasurer of ICPUG and, while still a teacher, started "Hipposoft".

Page 10 of Printout Magazine December 1979 lists Hipposoft as selling Wordcraft for £325 (£1943 in 2022 prices). This was almost 50% of the price of a PET!

Those who want more details, and more proof of where dongles came from, can read Mike's "Early Days" article.

Dongles and PETs

Click the image below to see one of Mike's PETs (he has three!)

Dongles were plugged into the cassette port at the back of the PET motherboard.

Click the image below for a larger version showing how dongles were fitted. The silk-screened grey dongle is an RS232C version suitable for the original 25 pin serial port on many early "IBM compatible" PCs and the "demo" version allowed dealers to demonstrate Wordcraft with some restrictions on functionality.

You can never have too many dongles!

Click the image below for a larger version.

The translucent ones are prototype 3D printed enclosures for some 2022 versions of the dongle - which we may get round to making.

DCPE - a dongle for today!

DCPE was designed and developed by Brian and Mike over a quiet weekend in December 2022.

DCPE reads dongles plugged into the right hand side (which, as far as the dongle is concerned, is a Commodore PET cassette port) and pretends to be a dongle with a 12-way connector (as found on the Commodore Cassette drive) on the left hand side.

In honour of the dongle's heritage (!) and the motherboard of the first PETs, we used through-hole and socketed components where possible (and where still available).

Below the 128 x 32 pixel OLED display is a 28 pin ATmega328 microprocessor (in the role of the PET) and to the left we have a 74LS165 shift register and PCF8574 port expander.

Schematic

Click the image below for a larger version of the schematic of the DCPE.

Layout - DCPE building blocks

Over the years, professional electronics and software developers build up a mental kit of parts - like Lego blocks. Any new project is usually made up of about 80% existing parts and 20% new. Need a charging circuit? Got one of those. Need an OLED display routine? Got one of those. However, there is always new stuff to learn - which is what makes it fun!

Click the image below for a larger version of the layout.

  • 1: USB socket for programming and charging.
  • 2: Battery charging.
  • 3: Battery: 700mAh/850mAh CR123 16340 Li-ion.
  • 4: Dongle out.
  • 5: 74LS165 shift register.
  • 6: PCF8654 I2C port expander.
  • 7: 128 x 32 OLED I2C display.
  • 8: Dongle in.
  • 9: Voltage conversion (3.3V to 5V).
  • 10: ATmega328 microprocessor.
  • 11: Microswitch.
  • 12: ISP programming port.

BOM (Bill Of Materials)

Aliexpress is a good source of parts - if you want enough and you are willing to wait between two and four weeks. Unit prices will be higher if purchased from a local distributor.

You will also need a CR123A 16340 Li-ion rechargeable battery and these can vary in price from £1 to £10 each. It is "buyer beware" with Li Ion batteries.

Part Description Price
ATmega328P 28 pin DIP Microprocessor (Hard to get until mid 2023 - try here) £2.00
74LS165 14 pin DIL shift register £0.20
PCF8574 14 pin DIL I2C port expander £1.50
TP4056 Battery charging IC £0.15
DW01A Battery protection IC £0.10
CH340G Serial/USB bridge £0.30
Crystal 16MHz 16MHz crystal for ATmega328 £0.20
Crystal 12MHz 12MHz crystal for CH340G £0.20
MT3608 Step up convertor (from 3.3V to 5.0V) £0.10
Inductor 22UH inductor for power conversion circuit £0.15
OLED 128 x 32 I2C OLED display module £1.00
Connector 12-way edge connector £1.04
Microswitch Microswitch to detect dongle insertion £0.20
USB socket Micro USB socket £0.05
Miscellaneous LEDs, resistors, capacitors, diodes, MOSFET, headers, sockets £0.50
PCB Printed circuit board £0.50

Firmware

The ATmega328 can be programmed via the ISP header - you will need something like the AVR ISP Mkii and Atmel Studio - now renamed Microchip Studio following Microchip's takeover of Atmel.

Add the Arduino bootloader to the Amega328 and it can be programmed over USB using the Arduino IDE.

The code is not rocket science and uses standard routines to drive the OLED, read the dongle, set up the output 74LS165 via a port expander and read the voltages on the board and from the battery.

No doubt the code will develop over time but the current version may be downloaded from here.

Note: this is a fun project and is not supported in any way - however, we are very happy to hear (via the email address at the top of this page) from anyone interested.