Z80 emulation?

A place to discuss general QL issues.
User avatar
tofro
QL Wafer Drive
Posts: 1060
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: Z80 emulation?

Postby tofro » Mon Feb 20, 2017 6:22 pm

swensont wrote:... and had Sun-2 workstations in his office.

Tim



...at least a proper CPU, then ;)

Tobias


User avatar
Haemogoblin
Chuggy Microdrive
Posts: 53
Joined: Fri May 20, 2016 12:17 am

Re: Z80 emulation?

Postby Haemogoblin » Wed Feb 22, 2017 10:49 pm

Hey guys

Just want to give a big thank you to everyone for sharing such a wonderful wealth of information.

I was wondering if anyone could comment of the emulation side. At what point did the emulating the Speccy on the Ql become a thing? My own research suggests 1984.


User avatar
Haemogoblin
Chuggy Microdrive
Posts: 53
Joined: Fri May 20, 2016 12:17 am

Re: Z80 emulation?

Postby Haemogoblin » Sat Feb 25, 2017 8:20 am

If anyone could spare to time, I'd really appreciate some comments on the emulation side of things. Which hasn't yet been touched on.


User avatar
tofro
QL Wafer Drive
Posts: 1060
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: Z80 emulation?

Postby tofro » Sat Feb 25, 2017 9:32 am

The fact that nobody is covering the topic of Spectrum emulation on the QL might be proof of how popular it was/is: Not much.

In the early days of QL history, there were a quite a number of magazine articles that covered how to port a ZX basic program to QL SuperBasic - I remember a series of articles in QL world on the topic. That wouldn't necessarily be called "Emulation", though.

The bare QL wasn't really in a shape that was able to properly emulate a Zilog Z80 at appropriate speed - It is just too slow. There were ZX81 emulators pretty early (The ZX81 is much slower than the Spectrum), but I do not think there really was a market for ZX81. The first Spectrum emulators that were able to cope with the emulated Spectrum's speed real time came up when sophisticated high-end hardware upgrades like the Gold and SuperGold Card expansions became available. Without that, you'd maybe get half the speed of a Spectrum which wasn't really acceptable. Note that sophisticated hardware was only available starting from about 1992, when the QL was actually no longer marketed.

Other than speed, the amount of available colours was a problem for emulation (8 in the QL low res, 16 in the Spectrum) and the different QL/Spectrum pixel format (an emulated Spectrum screen looks distorted on a QL). Also getting programs to the emulated Spectrum on the QL was a pretty un-solved problem: Formats like TAP or .z80 were not invented yet, the QL couldn't easily connect to a tape recorder and the microdrive format was incompatible between the two computers. That left the unreliable serial port or Interface I or a disk system which most people did not have as a means of transfer.

Only very late Emulators, like the ZM emulation system that apparently compiled rather than interpreted Z80 machine code were able to emulate a Spectrum close to the original speed. But then it was maybe already too late for such a product.

My own experience as a long-time owner of all Spectrums ever made who changed to the QL soon after its launch: I operated the two computers in parallel: The Spectrum was used for games, the QL for more down-to-earth things like programming and "serious applications". I never really went into emulation and never felt the need to go into it. I'm pretty sure I never even tried an emulator back in the days. The few things I brought over to the QL from the Spectrum were text files and databases, those were transferred using the serial port and the ZX network. Today, speed of emulated machines is no longer really a problem - But why should you emulate a Spectrum on an emulated QL when you can do the same thing directly on the PC?

Tobias


User avatar
Haemogoblin
Chuggy Microdrive
Posts: 53
Joined: Fri May 20, 2016 12:17 am

Re: Z80 emulation?

Postby Haemogoblin » Sat Feb 25, 2017 9:24 pm

Tobias thank you ever so much for that, it was invaluable. Born 1980, I missed much of Sinclair history and only entered the fray during the later Amstrad years. So any insight to these years is greatly appreciated as it lays a bedrock to build something resembling an informed opinion. :D


User avatar
janbredenbeek
Over Heated PSU
Posts: 143
Joined: Wed Jan 21, 2015 4:54 pm
Location: Hilversum, The Netherlands

Re: Z80 emulation?

Postby janbredenbeek » Sat Feb 25, 2017 10:04 pm

tofro wrote:(...)
My own experience as a long-time owner of all Spectrums ever made who changed to the QL soon after its launch: I operated the two computers in parallel: The Spectrum was used for games, the QL for more down-to-earth things like programming and "serious applications". I never really went into emulation and never felt the need to go into it. I'm pretty sure I never even tried an emulator back in the days. The few things I brought over to the QL from the Spectrum were text files and databases, those were transferred using the serial port and the ZX network. Today, speed of emulated machines is no longer really a problem - But why should you emulate a Spectrum on an emulated QL when you can do the same thing directly on the PC?
Tobias

I had a Spectrum for two years before buying a QL and did lots of programming on both machines. The architecture of the QL is very different from the Spectrum, even when only considering Basic programming. The Spectrum's Basic is unstructured and needs GOTOs and GOSUBs, while SuperBasic looks more like Pascal and C.

Nevertheless, I have written similar applications for both machines. One of the more ambitious projects was BASICODE, which was a common Basic programming standard with programs aired over the radio (at the time very popular in Holland but also in Germany). It was based on Microsoft Basic and very difficult to implement on the Spectrum as the Spectrum's Basic was incompatible in a number of ways (e.g. string variable names and arrays) and I ended up rewriting half of the Spectrum's Basic interpreter to make it compatible. I've also written BASICODE for the QL and the main challenge here was not SuperBASIC but how to make a cassette interface for the QL. I eventually succeeded by using the Network interface with some simple electronics (after all it's just a 'bit banging' interface like the Spectrum's cassette port).
So, having BASICODE on both machines, it was indeed possible to port BASIC programs, albeit with soms limitations :)

Jan.



Return to “General QL Chat”

Who is online

Users browsing this forum: Bing [Bot] and 2 guests