Last Updated: 07/10/15
I am often asked how to transfer files from a QL system to a PC or other computer system. There are programs out there which will reformat data (e.g. Textidy and QL-2-PC can help with text file format conversion) and other programs such as Discover and QLTools which will help with copying between QL and other disk formats. Jonathan Hudson has also written some programs such as wxqt2, wxqltools and qxltool which can also help with file transfer between different media formats such as Windows and Linux - these programs are available from his website at http://www.daria.co.uk. Other file transfer utilities are available from this website - click here to visit the File Transfer page.
A second popular and easy way to transfer files is by using a QL emulator on the target computer. Most emulators are able to read and usually write QL disks, although some (e.g. QLay) may require that you use some form of utility program to transfer between QL disks and the emulator's own format.
Another popular way of transferring files between computers is via serial cable links. The QL, most PCs and many other types of computers all have serial ports, although the wiring may vary somewhat between computers. I'll focus here on QL and PC-style serial ports and start off with the connector pinouts.
1. 6-pin UK-style QL serial ports SER1 and SER2
|SER1 (DCE, or Data Communication Equipment, like a modem)|
|4||DTR (=RTS)||ready input|
|SER2 (DTE, or Data Terminal Equipment, a computer)|
|4||DTR (=RTS)||ready output|
TxD=Transmit Data, RxD=Receive Data, DTR=Data Terminal Ready, CTS=Clear To Send
On QL serial ports, DTR is really more like an RTS (Request To Send)
On a QL, SER1 is wired as a modem, whereas SER2 is wired as a computer.
USA 9 pin serial ports use the same pin numbers as a UK QL, so the USA QL is not wired the same as a 9-pin PC serial port, for example.
The diagram on the left shows the pin numbers of the QL serial port connector. Pin 6 is the pin nearest to the latching pin on one side of the plug. I do not know the type number of these plugs, but in the past I have bought a few of them from QL traders like Tony Firshman of TF Services. As it is not easy to crimp the plug to the flat cable, it is best to buy the QL connectors with cable already fitted if possible. Note that pin 6 actually carries +12volts and is not normally used (unless you need to tie some unused signal line high for example).
3. 9-pin D PC-style serial port
|4||DTR||OUT||Data Terminal Ready|
|6||DSR||IN||Data Set Ready|
|7||RTS||OUT||Request To Send|
|8||CTS||IN||Clear To Send|
Note: Direction is DTE (Computer) relative DCE (modem), i.e. the diagram above is for a computer, so RxD is IN from a modem.
The diagram on the left shows the pin numbers of the 9-pin D serial port connectors. One or more of the pin numbers are usually marked in tiny print near the pins. This view is from the solder terminals at the back of the cable socket.
|The diagram on the left shows the pin numbers of the 10 pin internal connector on a PC mainboard, in case you need to wire up a serial connector from there.|
4. 25-pin D PC-style serial port
|1||SHIELD||-||Shield Ground (Frame Ground)|
|4||RTS||OUT||Request To Send|
|5||CTS||IN||Clear To Send|
|6||DSR||IN||Data Set Ready|
|20||DTR||OUT||Data Terminal Ready|
Note: Direction is DTE (Computer) relative DCE (modem), i.e. the diagram above is for a computer, so RxD is IN from a modem. Do not connect SHIELD (1) to GND (7)
The diagram on the left shows the pin numbers of the 25-pin D serial port connectors. One or more of the pin numbers are usually marked in tiny print near the pins. This view is from the solder terminals at the back of the cable socket.
This article describes how to connect a QL and PC via a simple serial cable link, and assumes you will be using a QL with British-style 6 pin serial port connectors.
It's best to use serial port SER2 for QL to PC communication, as wiring is a bit easier. SER1 is basically wired as though it was a modem (called a DCE or Data Communications Equipment), with somewhat reversed wiring. SER2 is configured to be seen as a computer (called a DTE or Data Terminal Equipment). If you do use SER1, simply swap pin 2 and 3 over, and swap pin 4 and 5 over.
Although I don't have a USA QL (the type with 9-pin D serial connectors), I do have a note that the USA and German 9-pin D connectors are wired as in the table at th ebottom:
|QL SER1||QL SER2||QL CABLE COLOUR||DIRECTION||PC SIGNAL||PC 25-PIN D||PC 9-PIN D|
|pin 3 RxD||pin 2 TxD||white||-->||RxD||pin 3||pin 2|
|pin 2 TxD||pin 3 RxD||green||<--||TxD||pin 2||pin 3|
|pin 5 CTS||pin 4 DTR (=RTS)||blue||-->||CTS||pin 5||pin 8|
|pin 4 DTR (=RTS)||pin 5 CTS||red||<--||RTS||pin 4||pin 7|
|pin 1||pin 1||black||---||GND||pin 7||pin 5|
|N/A||N/A||-||-||DSR||pin 6||pin 6|
|N/A||N/A||-||-||DTR||pin 20||pin 4|
N/A means Not Applicable, the QL does not have DSR and DTR. The so-called DTR on a QL SER1 or SER2 pin 4 is actually more of an RTS, as shown by the DTR(=RTS) above. The table below lists the full names of the signal abbreviations shown above.
|RTS||Request To Send|
|CTS||Clear To Send|
|DSR||Data Set Ready|
|DTR||Data Terminal Ready|
You can find more information about QL serial ports in the Concepts section of the QL User Guide under "Communications RS232C". Note that although the QL has two serial ports, they are not identical despite having the same connector. This is to allow for the different types of serial connection applications the QL might be used for. SER1 is wired as a DCE or Data Communication Equipment. In other words, to anything plugged into SER1, the QL might seem to be a modem. SER2 is a DTE, or Data Terminal Equipment, in other words, it looks like a computer to anything connected to that serial port. For file transfer, I normally use SER2 since it makes it easier for my little brain to envisage computer to computer connection wiring!
You can then see that making up a serial cable of this type is a fairly simple matter of cross connecting the relevant signals, i.e. RxD to TxD and vice versa, and RTS to CTS and vice versa, and connecting the two ground signal lines together. If you get the TxD and RxD wires connected up right but not the other two handshaking ones, one sympton might be that the transfer works for very short files only, or only at very low baud rates. Go to a store like Maplins and get a serial port wiring tester, some have LEDs on them which light up to show what's happening, they save a lot of time and frustration with serial ports!
PCs generally have a 9-pin or 25-pin male plug connector, so you will need a 9-pin or 25-pin female (socket) connector for your cable. These usually have pin numbers printed or moulded on them in very small print near one or more of the solder connectors. You can also get non-solder connectors, such as press on IDC (Insulation Displacement Connector) where a flat ribbon cable is squeezed onto pre-formed terminals - these terminals bite through the insulation onto the wires as they are pressed on.
As far as software is concerned you shouldn't need anything extra. On the QL, just a COPY MDV1_filename TO SER2 should work (if you have Toolkit 2 use COPY_H instead of the COPY command to force it to copy the header). If you are copying to DOS or Windows you will need the equivalent command from DOS command line on the PC (in Windows XP, go to All Programs, Accessories, Command Prompt). In Windows XP anyway you can get help on its copy command with the command COPY /? (the /? switch telling it to print some help). From memory, I can't remember the full command, but it's something like: COPY COM1: C:\directory\filename .You can also include a switch in the DOS command to specify if it is an ASCII or binary file /A for ASCII (text) or /B for binary If you are copying using the QL emulator on the PC, simply use the COPY or COPY_H commands on the emulator as well: COPY ser1 TO win1_directory_filename (obviously use ser1 or ser2 depending on which serial port used on the PC).
You may find it easier to use a terminal software program to transfer the files between the two computers rather than trying to use Superbasic and DOS commands. You could use the QTPI software from Jonathan Hudson for the QL end, and Hyperterminal at the Windows end, for example.
I confess to being a bit of an idiot with serial links, or at least if not an idiot, lacking in confidence with them. Tony Firshman gave me a lot of help on the subject in the early days and he swears there is nothing hard about the subject, but I always seem to run into every problem possible when I try, so good luck. Once you have the correct cable, keep the baud rate low - 4,800 or 9,600 baud maximum on a standard QL - to connect to PC. If the QL has a Hermes IPC upgrade fitted, the QL may work up to 19,200 baud. Add-on fast serial ports such as SuperHermes may work at even higher baudrates, but of course the upper limit is determined by whatever the slower serial port involved can handle.
Also known as a Serial Laplink cable, this cabling is used for some PC to PC serial links. This uses 9-pin or 25-pin D connectors depending on what is fitted to the PC in question. This cabling may be useful for some file transfers between two PCs running QL emulators.
Here's wiring details for a null modem cable I found somewhere on the internet. This may prove useful for some forms of serial communication between PCs. If you are using SERNET between QL systems, Null Modem cables are usually recommended.
Note: in all three cable diagrams shown. DSR & CD are jumpered to fool programs to think they are online.
1. 9-Pin D Serial Port to 9-Pin D Serial Port
|9-PIN D||SIGNAL||SIGNAL||9-PIN D|
2. 25-Pin D Serial Port to 25-Pin D Serial Port
|25-PIN D||SIGNAL||SIGNAL||25-PIN D|
|9-PIN D||SIGNAL||SIGNAL||25-PIN D|
|2||TxD SER1, RxD SER2||9|
|3||RxD SER1, TxD SER2||4|
|4||DTR SER1, CTS SER2||8|
|5||CTS SER1, DTR SER2||3|
|Pins 1,2 and 6 on 9-pin D are NC|
Sernet is a software extension which implements serial port networking between two or more computers running SMSQ/E. The software is maintained by Bernd Reinhardt and is usually supplied with SMSQ/E as a file called SERNET_REXT or SERNET_RXT. The standard version uses a null modem cable to link the serial ports on two computers. Sernet can in theory work with more than two computers, but in this case the cabling needs to be 'circular' rather than the usual and simpler null modem cable between two computers.
Sernet requires split send and receive (SRX and STX) devices. These are provided by SMSQ/E but for QDOS or QXL SMSQ you will need the SimSer extensions from Hans-Peter Recktenwald, available from the Utilities Page on this website.
Below are links to a few articles and instructions for Sernet. As far as I know, the Sernet code itself is copyright material which cannot be offered here, but as it's available with SMSQ/E and most people who want to use Sernet will also be using SMSQ/E this should be no problem.
Sernet Instructions (9K) - a file
describing how to use Sernet.
Sernet article (5K) - an article about Sernet from QL Today
Q40 Sernet articles(3K) - an article from QL Today by Derek Stewart about using Sernet to connect up Q40 computers.
Return to section index | Return to home page