This program is an emulator for the "Lynx 48K" and "Lynx 96K" microcomputers. These were manufactured in the UK in the early-to-mid 1980s by Cambridge-based firm, Camputers Ltd.
The 48K Lynx was my first computer. I have written this program, which I hope will be of interest to Lynx fans and "old computer" aficionados.
Jonathan Markland, August 2014
The latest program is always downloadable here (from GitHub - NO ROMS). This is presently for Microsoft Windows only :(
I will try to keep an up to date notice of where to get a FULL VERSION DOWNLOAD on my Tumblr Blog!
I feel I ought to release stuff on GitHub, so if you download the ROMLESS version from there, you should unzip the Jynx .ZIP to a spare folder, then copy the ROM files in. I'm not putting the ROM files on GitHub so you will have to install Pete's PALE emulator, and get them from his "Program Files (x86)\Pale" folder. These are the file names you need:
All five ROMS are needed to run the emulator. I use the same ROM files as Pete.
This software comes with NO WARRANTY, and is licensed under the GNU General Public License version 3
I want Linux and MAC OS and Raspberry PI RISC OS versions -- any skilled open-source C++ developers who can reproduce the program's UI on those platforms, and would be interested please contact me on GitHub (see above).
The easiest way to get started with a tape. When you select your tape, this resets the emulator, types in the load command needed, and away you go. Select your variety of Lynx first!
Allows the user to open a Lynx tape file (*.TAP). The file can be loaded with LOAD "FILENAME"
or MLOAD "FILENAME"
at the Lynx Basic prompt, depending on whether it is basic or machine code. Unfortunately you just have to know!
You can find out by loading the TAP file into a text editor. This contains the file name (in quotes) at the very start of the TAP file, followed by a letter 'B' for Basic, or 'M' for machine code.
You can use the Lynx BASIC "TAPE" command to speed up loading, e.g.: TAPE 5
. Unlike real cassette recorders, the emulator will supply TAP file data at the rate the Lynx expects.
Rewinds the virtual cassette recorder to the start.
Lists the tape directory for the current TAP by "typing it out" as REM statements on the lynx prompt!
Prepares a new, blank, "virtual cassette" onto which you can save a files with the Lynx Basic SAVE
command, or the Lynx machine-code monitor (MON).
You can do multiple SAVE
s from the Lynx to a single TAP file. The emulator stores this in memory. Once you are done, be sure to save the TAP file with "File | Save As TAP file...".
Saves the virtual cassette to the host file system.
Saves a snapshot of the Lynx state to a custom snapshot file format. This cannot be done while the Lynx is saving or loading a cassette, because the snapshot format does not support the cassette information. Any "virtual cassette" that may be present in the Lynx's "virtual tape recorder" is not included in the snapshot file.
Reloads a snapshot of the Lynx's state. This will wipe out the current state of the Lynx! The snapshot also records the type of the Lynx (48K or 96K). On loading, the machine type will be restored too.
Exits the emulator.
These options change the speed of the emulation. This will affect the pitch of the sound, um... and ability to type.
The system will engage super-speed mode when loading or saving tapes.
Warp speed is engaged by the system when RETURN is pressed. This continues until the Lynx performs a full-keyboard scanning sweep that returns no keys held down. Then the system returns to the speed set by the 50%..800% options. (The keyboard sweep is how we detect the BASIC / INPUT prompt appears / GET$/GETN/KEY$/KEYN is used). This may interfere in the running of programs, particularly games. No sound can be produced. You may need to turn this feature off. But try it out nontheless.
Give a 15 year old the Starship Enterprise, and this is what you would get...
Pauses the emulator until you untick this box. You can load a snapshot in this state, but it will not start until you un-pause.
These options select which Lynx model you would like to emulate. Changing the Lynx model will require a reset of the guest machine!
Intended to help people wanting to save snapshots just before their game's main screen appears!
This option resets the guest machine with a simulated hardware reset. This will lose the contents of the Lynx's memory completely.
Projects the Lynx's display so it fits tightly within the window. This may means that the guest pixels do not precisely map onto pixels on the host monitor.
Projects the Lynx's display so it fits within the host's window with the largest size possible, while mapping each guest pixel onto an integral number of pixels on the host monitor. As you re-size the display, the projects will "jump" between different sizes.
Stretch the Lynx's display to fill the window, ignoring aspect ratio.
Colour sets to emulate various 80's display devices.
Colour sets intended for use with Level 9 adventure games. These store data in the RED and BLUE screen memory, so this shows up on the display. However, I do not emulate the feature on the Lynx that can hide the RED and BLUE displays (it was rarely used). So, to be able to read the display while playing these games, use this option.
Toggle full screen. You can still get the menus in full screen mode. Press Alt-F for File (etc). Hint: Cursor left/right moves between menus. Alt-F4 to Exit.
This spools all sound produced by the Lynx to a .wav file on your computer. The format is fixed at 44,100Hz CD Quality MONO sound (16-bits per sample). Recording will continue until the "Finish Recording" option is selected, or you exit the emulator.
Ceases recording the Lynx's sound to a .WAV file on the host. The WAV file will only be complete, and ready to play, once recording is finished.
This option allows the user to monitor the tape sounds while the Lynx is saving and loading. The volume of these are reduced.
Yes, you can save the sound of the tape to a WAV file, with the above options!
The Lynx saves a SINE wave format, which is a bit of a waste of time because it reads it back using a voltage comparator, not a A/D converter! For this reason, the emulator presents the Lynx with a square-wave format when re-loading TAP files. This is why they sound a bit different.
Allows the host to play Lynx sounds. If you have a problem with sound, you should turn it off using this.
On the Microsoft Window platform, with sound ON, the emulation timing is effectively performed by the Windows sound sub-system. With sound off, a regular Windows timer is used to time the emulation. This may result in a slight discrepancy in speeds.
Captures text that the Lynx writes to its display to a file on the host. This does NOT include text the Lynx writes when accepting user input, since this uses text output to flash the cursor! Capturing text continues until the "Stop" menu option is selected (see below). This is intended for capturing Lynx BASIC program, and perhaps output from the Lynx monitor (MON
).
The file is recorded in UTF-8 format, using code points U+0020 to U+00FF, since Lynx Basic program listings can include characters outside the range 32..126. U+000A is used for line-ends. The emulator implements this facility by "spying" on the Lynx's character output routine in the ROM, and recording the characters. This happens in a non-invasive fashion.
Ceases recording lynx text. The file on the host is closed, and can be immediately opened by other programs on the host.
Automates the entry of a text file into the Lynx. The file must be ASCII or UTF-8 using code points U+0020 to U+00FF for general characters. Line endings can be Windows (U+000D U+000A), MAC (U+000D) or UNIX (U+000A). Entry of the text will start immediately. You can halt the text entry by pressing ESC.
At the moment, this option, when enabled, provides access to the built-in Z80 disassembler. This allows "REM
" commands to be entered into the Lynx which activate the disassembler. For example:
REM DISASM 85E 25
The above line will disassemble 25 lines of Z80 code starting at address 0x085E in the Lynx's address space. (In practice this will be the regular "User RAM" memory view that the users see, with the ROM switched in at address 0). The disassembler enters the disassembly text directly into the Lynx's console as a sequence of REM
commands. You can halt the process by pressing the ESC key.
Displays the About box!
On Microsoft Windows systems, the program saves user settings in the current user's "non-roaming" application data folder.
Please don't fiddle with this file! If you get it wrong, the program will ignore it on startup.
I've received feedback on the emulator, and I've added a command line parameter set.
Parameters are given by a switch name with two minus signs in front. This may be followed by a space and a parameter value. All switches are optional. Examples of usage:
--settings | Specify alternative location for settings file. |
--snapshot | Specify lynxsnapshot file to be immediately loaded on startup. |
--run | Specify TAP file to be immediately loaded on startup (--snapshot overrides this). |
--games | Put emulator into games mode. Does not pester on exit, and does not SAVE the settings file. |
Example command lines:
jynx.exe --settings "C:\users\jonathan\documents\Alternative Settings.txt" --snapshot "C:\users\jonathan\documents\snapshots\AIR RAID.lynxsnapshot" --games
jynx.exe --settings "C:\users\jonathan\documents\Alternative Settings.txt" --run "C:\users\jonathan\documents\snapshots\AIR RAID.TAP"
What's not emulated?
The 48K Lynx was my first computer, which my father bought after talking with the staff on the Camputers stand at the Northern Computer Exhibition in Belle-vue, Manchester, November 1983.
Camputers were very ambitious, in a tough market. Ultimately they didn't have enough software support, so the company folded with, I believe, only about 30,000 units sold.
Prior to this I am aware of only two Lynx emulators. The main one is PALE - Pete's Lynx emulator, and another older one which, I think, was DOS only. Pete's emulator tries to be comprehensive and does the 128K machine. The UI that I saw wasn't very polished, though. I also wanted the "square pixels" feature!
I wrote the Lynx emulator code ages ago, as part another Z80 project. It needed to be "extracted" and cleaned up a bit. I allowed myself a short timescale, and wanted to do a good, focussed job of providing a 48K machine emulator, and not to get distracted by the other machines. That said, the 96 is so similar to the 48, it's silly not to include it!
I'm not planning on doing the 128K machine because I have no "emotional" attachment to it. By the time Christmas 1985 rolled around, the Lynx was put away, and replaced with the Amstrad CPC 6128 + Colour monitor.
So - what help would be useful from the developer community for this project?
The brief would be very simple - to provide the equivalent user interface as I have in the Windows version. The code is separated into clearly marked "Portable" and OS-specific folders. The program is heavily separated using interface classes, so this should be a leg up. Also, a simple View-Model scenario is used. The Model class has all of the UI logic, so you just need to implement the View class (equivalent to MainForm) and provide the specific actions that the Model requires.
Your code provides the main() function and pretty much runs the show, calling into the emulator at 20ms intervals to perform another emulation "burst", which has the side-effect of mixing another buffer of sound samples for playback.
You need to provide the user interface, and let the Model tell you what to do, and when. There is no other UI logic required.
As you can see from the Windows version, there is a single executable, which is very small. I would expect this to be attainable on other systems too. A sorry symptom of "modern" software engineering practice appears to be that of dependency bloat...
I hope this setup would be workable.
Contributors would receive recognition on this project's main site, and a mention in the "About" box on all release platform versions.
It might be nice if the 30,000 people who owned Lynxes all those years ago, would look in the cupboards and see if there are any tapes that aren't on the internet. I really want to get QUACMAN ! It was an amazing PacMan version.
August 2014 - What happened to the camputerslynx.info web site? It was up a few months ago?
At the time of writing, this is MS-Windows only. The SLN file should be loaded into Visual Studio and it should just build!
I am hoping the Express edition of VS will be suitable. I'll try it sometime!