Welcome, Guest. Please login or register.


Author Topic: ZX Spectrum Emulator Card (Read 62248 times)

Online Zozosoft

  • EP addict
  • *
  • Posts: 14283
  • Country: hu
  • OS:
  • Windows 7/Server 2008 R2 Windows 7/Server 2008 R2
  • Browser:
  • Firefox 87.0 Firefox 87.0
    • View Profile
    • http://enterprise.iko.hu/
ZX Spectrum Emulator Card
« on: 2006.June.20. 12:01:53 »
I think the Spectrum Emulator Card is one of the most awaited hw for the Enterprise in Hungary.
When the user bought their Enterprise computers, there were only few programs in the shops. But the advertisments said: "the Spectrum Emulator is coming, with this, you can play hundreds of Spectrum games".
Users waiting, Emulator not coming... only articles, why not... but promising shortly coming...
After long time... yes! the Emulator in the shops!
But many users say: this is a disappointment...
The original version of the Emulator has lots of bugs. And the users did not understand why. The developers had so mcuh time...
And the developer company ('a' Studio) did not respond to the users complains.

What are the bugs?
-With the Emulator, you can use your Enterprise as Spectrum. To return to the EP mode you needed to unplug the Emulator. This is not good for the connectors...
-You can't use the Emulator with EXDOS. But who have disks, they do not want to hear tape sounds any more :-)
-Joysticks cannot be used (Internal or External) in games.
-Keyboard emulation has lots of bugs, some keys are often dead, or one key is detected as two...
-If the program uses Interrupt Mode, it will hang up... Many games the IM2 is used...
-FLASH attribute is absolutely not emulated, this cause: you cannot see the cursor in a lot of programs
 

The original Emulator has version 3.5 ROM
« Last Edit: 2021.April.09. 18:19:46 by szipucsu »

Online Zozosoft

  • EP addict
  • *
  • Posts: 14283
  • Country: hu
    • View Profile
    • http://enterprise.iko.hu/
Re: ZX Spectrum Emulator Card
« Reply #1 on: 2006.June.20. 12:24:21 »
Because the original Emulator have many bugs, I not buy it... but I get one as gift in 1993 :)
I try it... and after I totaly dismantled :)
When I understood how working it, I think the many bugs are easy corretable!
I fixed some hw bugs, and writed new ROM program, called as version 4.0

The solved problems:
-The computer works as normal Enterprise, the Emulator now is a normal EXOS ROM extension, the Spectrum mode can be started with the ZX command
-If you have bus extender unit for pluging more cards to the expansion port, you can use the Emulator with the EXDOS
-keyboard emulation totaly rewriten, and works corretly
-and yes, you can use the joysticks! Internal+ALT: Cursor/AGF/Protekt, External1: Sinclar1/Interface II. Left, External2: Sinclair2/Interface II. Right
-IM2 mode detected, and handled
-FLASH emulated as inverted colors, this enought to see the cursor in the programs

And the extra features:
-the Load/Save routine use the EXOS, you can load programs from disk.
-additional SCOPY utility included in the ROM for copy the Spectrum tapes to normal EXOS files.
-snapshot Load/Save functions!
-POKE load function

Online Zozosoft

  • EP addict
  • *
  • Posts: 14283
  • Country: hu
    • View Profile
    • http://enterprise.iko.hu/
Re: ZX Spectrum Emulator Card
« Reply #2 on: 2006.June.20. 13:10:52 »
The operation of the Emulator is a brilliant idea!

The logical circuits in the board, verifying all bus operation. And when detecting Spectrum type operations, generating NMI.
The NMI handler in the ROM, reading the ports of the board, and select which function needed to emulatad, and run the suitable emulation routine.
The ports of the board (40H-44H), contains the data of the Address and Data Bus and some additional information, at the NMI generating moment. 40H: A15-A8, 41H:A7-A0, 42H: D7-D0 (bits are mixed), 43H: bit7=1 when memory operations, 0 when I/O operations
Spectrum type operations:
-Read or write the FEH ports. Read used by keyboard scan, write for generating sound, and setting the border color.
-write to the attributom area of the screen, this is phisicaly at the segment FEH, from 1800H-1AFFH

About the keyboard bug of the original version:
In the ZX Spectrum using the following Z80 properties: when reading from I/O ports, the upper 8 bit of the address bus contains the value of the  A or the B register. With this value can be selected which keyboard line needed to reading.
The PCB have a bug, A15 not connected to U9...
Programer bugs: at the Enterprise the A15 and A14 not directly from the Z80! The Z80 A14-15 used by the DAVE for memory paging. The A15-14 at the bus port from the DAVE, and depends of the currently used segments!
In my new program I use four segments which have unique bit combination at the lowest two bits. This bits will coming to the bus as A15-14.
After the PCB is corrected, and with the new program, the keyboard emulation works correctly.

Because the NMI generation are not EXOS compatibe, needed to put a ON/OFF switch to a NMI line. When starting the 4.0 version of program, it is say turn on emulator. And when you want to exit, turn off the emulator, and press reset. After this you exit to BASIC (or the program where you called the emulator)

Online Zozosoft

  • EP addict
  • *
  • Posts: 14283
  • Country: hu
    • View Profile
    • http://enterprise.iko.hu/
Re: ZX Spectrum Emulator Card
« Reply #3 on: 2006.June.20. 14:26:24 »
Today we call the original version as ISS1, and the modified version as ISS2.
What is the ISS3? This is the most enhanced version from 2005 :)

In 2005 I heard, someone in UK want to build Spectrum Emulator.
I drawed the schematics of the Emulator.
And when I drawing, I found other big hw bug!
The board have capabilty for turn OFF/ON the NMI generating via software. Using write bit 7 off port 44H.
But when turn off the NMI, after few seconds automaticaly turning on.. and hanging up the EXOS...
What is the problem?
The developers not know enought how works the Z80...
At the port decoding only use the -IORQ signal, and not use the -RD or -WR. But when the Z80 accepting IRQ, then setting the -IORQ to low! (And the -RD, -WR stay a high)
Because this, the 44H port randomly overwritten when accepting IRQs!

To correct this bug, I build additional logical gates to the board for combine the port selection signals with the -RD,-WR signals.
The plus ICs called as U17, U18.

After this modification, not needed to put switch to NMI line, the emulator software can turn on or off the emulator when needed.
I put one LED to a not used pin of U15. When the LED is lighting, the NMI generating is switched ON.

For this ISS3 version, I writed new version of ROM: ZX version 4.1
Other additions: load support for .TAP and .TZX files. .Z80 support will coming in the 4.2 version.

On the ISS3 version the exiting from Spectrum mode is different than ISS2. The reset button is make reset on the "Spectrum". If you want to exit, hold down the STOP key, and press reset.

Offline Bagpuss22

  • EP fan
  • *
  • Posts: 167
  • Country: gb
    • View Profile
Re: ZX Spectrum Emulator Card
« Reply #4 on: 2006.June.21. 11:37:14 »
Thanks for the information,  I am currently looking at the ISS2
schematic but it may well be worth me moving over to the ISS3
and go from there. :?

regards

Russ P.
 :)

Online Zozosoft

  • EP addict
  • *
  • Posts: 14283
  • Country: hu
    • View Profile
    • http://enterprise.iko.hu/
Re: ZX Spectrum Emulator Card
« Reply #5 on: 2006.June.22. 10:38:13 »
When you builded the PLD version of the ISS3, can you upgrade with new functions?
I have some ideas for ISS4 :-)

Offline Bagpuss22

  • EP fan
  • *
  • Posts: 167
  • Country: gb
    • View Profile
Re: ZX Spectrum Emulator Card
« Reply #6 on: 2006.June.22. 12:01:17 »
I am looking at using an 84pin PLD so I am only using about 60%
of the availble connections.

The possibility of upgrading later will be available as long as we
do not use all of the pins.

The other option would be to use a bigger device later, depending
on what was required.

Russ.

Online Zozosoft

  • EP addict
  • *
  • Posts: 14283
  • Country: hu
    • View Profile
    • http://enterprise.iko.hu/
Re: ZX Spectrum Emulator Card
« Reply #7 on: 2006.June.22. 12:08:26 »
Ok, when the ISS3 version is working, start talking about the ideas for ISS4 :-)

Offline Bagpuss22

  • EP fan
  • *
  • Posts: 167
  • Country: gb
  • OS:
  • Windows XP Windows XP
  • Browser:
  • Microsoft Internet Explorer 7.0 Microsoft Internet Explorer 7.0
    • View Profile
Re: ZX Spectrum Emulator Card
« Reply #8 on: 2007.April.24. 11:56:23 »
Z,

Sorry about the delay in everything but I am now looking at the Spectrum Emulator again.
The hardware engineer who was designing the new board has moved on so I am
starting to get it sorted myself. :ds_icon_cheesygrin:

Question:  Have you looked at adding a ROM port to the Spectrum Emulator?  I was wondering
if it was possible to play the ROM cartridges.........

Russ.

Offline Bagpuss22

  • EP fan
  • *
  • Posts: 167
  • Country: gb
  • OS:
  • Windows XP Windows XP
  • Browser:
  • Microsoft Internet Explorer 7.0 Microsoft Internet Explorer 7.0
    • View Profile
Re: ZX Spectrum Emulator Card
« Reply #9 on: 2007.May.14. 11:57:17 »
Just to let you know that the Spectrum Emulator hardware
design is currently being finished off  :razz:  :razz:

This is going to consist of a single CPLD and a PROM.

Have had major issues getting the hardware design sorted as
engineers here are hard to get time from, but we are getting
there.....

Regards

Russ P.
 :lol:

Offline jackleather

  • Beginner
  • *
  • Posts: 32
  • Country: gb
  • OS:
  • Windows XP Windows XP
  • Browser:
  • Firefox 2.0.0.3 Firefox 2.0.0.3
    • View Profile
Re: ZX Spectrum Emulator Card
« Reply #10 on: 2007.May.14. 21:58:41 »
Just to let you know that the Spectrum Emulator hardware
design is currently being finished off  :razz:  :razz:

This is going to consist of a single CPLD and a PROM.

Have had major issues getting the hardware design sorted as
engineers here are hard to get time from, but we are getting
there.....

Regards

Russ P.
 :lol:

Hi Russ!

This is good news!

how many boards will you make?

p.s. the QWERTY keyboard is still working well - thanks again!

Offline Bagpuss22

  • EP fan
  • *
  • Posts: 167
  • Country: gb
  • OS:
  • Windows XP Windows XP
  • Browser:
  • Microsoft Internet Explorer 7.0 Microsoft Internet Explorer 7.0
    • View Profile
Re: ZX Spectrum Emulator Card
« Reply #11 on: 2007.May.14. 23:20:02 »
Hopefully a batch of 20 to start but it depends on how many
we can fit on a standard Eurocard.   :|

At present the board measures about 5cm by 5cm with a CPLD
on one side and a surface mount PROM on the other.

The hardware design and CPLD code will hopefully be complete by the
end of the month.

Z,  wa are using the Issue 2 design for the moment.  Once we are
happy then we can do the mods.     :)


Regards

Russ P.
 :lol:


Online Zozosoft

  • EP addict
  • *
  • Posts: 14283
  • Country: hu
  • OS:
  • Windows XP Windows XP
  • Browser:
  • Firefox 2.0.0.3 Firefox 2.0.0.3
    • View Profile
    • http://enterprise.iko.hu/
Re: ZX Spectrum Emulator Card
« Reply #12 on: 2007.May.15. 20:26:12 »
Z,  wa are using the Issue 2 design for the moment.
Ok, but when using this version, then needed to put switch on a NMI line.
ISS3 is a more comfortable, because it's can be switched on/off by the sw. (The hw bug of the original emulator fixed in the ISS3)
« Last Edit: 2007.May.15. 22:39:27 by Zozosoft »

Offline Bagpuss22

  • EP fan
  • *
  • Posts: 167
  • Country: gb
  • OS:
  • Windows XP Windows XP
  • Browser:
  • Microsoft Internet Explorer 7.0 Microsoft Internet Explorer 7.0
    • View Profile
Re: ZX Spectrum Emulator Card
« Reply #13 on: 2007.May.17. 10:35:12 »
Z,

On the ISS3 circuit diagram you are using 27512 PROM, is there a reason for this?

Can a 27256 be used in plac of this, as I have a surplus of these PROMs?

If they can then I may try and change to ISSĀ£ with a 256..


Russ. :)

Online Zozosoft

  • EP addict
  • *
  • Posts: 14283
  • Country: hu
  • OS:
  • Windows XP Windows XP
  • Browser:
  • Firefox 2.0.0.3 Firefox 2.0.0.3
    • View Profile
    • http://enterprise.iko.hu/
Re: ZX Spectrum Emulator Card
« Reply #14 on: 2007.May.17. 11:12:44 »
On the ISS3 circuit diagram you are using 27512 PROM, is there a reason for this?
More space for future expansions. Currently not important. (But you can use the free 32K for any ROM programs, if you use EXOS 2.3)
Can a 27256 be used in plac of this, as I have a surplus of these PROMs?
Yes 27256 can be used at 27512 socket.