News:

Printed Amstrad Addict magazine announced, check it out here!

Main Menu

Amstrad 6128 HAL/PAL16L8 chip

Started by Porchy, 21:34, 03 December 13

Previous topic - Next topic

0 Members and 2 Guests are viewing this topic.

Porchy

Following on from my intro thread im now pleased to announce that my HAL16L8 chip recreation is ready for release.
The file is ready to be programmed to a GAL16V8 device and is a drop in replacement with no mods being required.

I have tested this with the following:
The Addams Family
Robocop (with speech)
Pac-Man emulator
Orion Prime.
various other original titles that I got with the system.

No problems encountered at all
I have NOT tested this with any external expansions. When Bryce gets time I think he will do the testing on everything he has and report any issues.

If anyone in the UK requires one of these and cannot program it themselves then I can provide a programmed chip.
Also, the equations that ive created are in no way a secret and will gladly give them to anyone that wants them or if someone want to include it in the wiki then please do

I would like to thank the following people:
arnoldemu for his truth tables, they saved me heaps of time
Charles MacDonald for discovering that latches were being used somewhere
TotO for sending me his chip to start working with
Anyone else that may provide feedback in the future.

Enjoy

TFM

WoW!!!!!!! That's amazing!!!!!!!!!!!!  :) :) :)
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

Bryce

I can also program them for people on this side of the water if needed.

Bryce.

TFM

You mean north of the lake Chiemsee?  ;)
TFM of FutureSoft
Also visit the CPC and Plus users favorite OS: FutureOS - The Revolution on CPC6128 and 6128Plus

IanS

Quote from: Porchy on 21:34, 03 December 13
Also, the equations that ive created are in no way a secret and will gladly give them to anyone that wants them or if someone want to include it in the wiki then please do
Can you post the equations in here?

Porchy

A15OUT = (!X2 & !X1 & A14
     # !X3 & !X2 & A14
     # A15);

!X1 = (!A15 & D7ANDD6 & RESET & !IOWR & D0
     # !X1 & RESET & IOWR
     # !X1 & !D7ANDD6 & RESET
     # !X1 & A15 & RESET);

!X2 = (!A15 & D7ANDD6 & RESET & !IOWR & D1
     # !X2 & RESET & IOWR
     # !X2 & !D7ANDD6 & RESET
     # !X2 & A15 & RESET);

!X3 = (!A15 & D7ANDD6 & RESET & !IOWR & D2
     # !X3 & RESET & IOWR
     # !X3 & !D7ANDD6 & RESET
     # !X3 & A15 & RESET);

!CAS1 = (X3 & !X1 & A15 & A14 & !NCAS & !RAMDIS & !CPU & CAS0
     # !X3 & !A15 & A14 & !NCAS & !RAMDIS & !CPU & CAS0
     # X3 & !X2 & X1 & !NCAS & !RAMDIS & !CPU & CAS0
     # !NCAS & CAS0 & !CAS1);

!CAS0 = (X3 & X2 & X1 & !NCAS & !RAMDIS & CAS1
     # X3 & !X1 & !A15 & !NCAS & !RAMDIS & CAS1
     # !X3 & A15 & !NCAS & !RAMDIS & CAS1
     # !X1 & !A14 & !NCAS & !RAMDIS & CAS1
     # !X3 & !A14 & !NCAS & !RAMDIS & CAS1
     # !NCAS & !RAMDIS & CPU & CAS1
     # !NCAS & !CAS0 & CAS1);

A14OUT = (A15 & A14
     # !X1 & A14
     # X3 & A14);

Bryce

#6
Hi Porchy,
       just wanted to confirm: I programmed a GAL16V8D-15QPN and stuck it in a spare 6128 (MC0023C). So far all fine, everything seems to work as normal. I'll leave it in for a few weeks and see if it ever causes a problem, but for now I'd say mission accomplished :) Great work.

Bryce.

The proof:


Porchy

Thanks for testing. I was a bit nervous opening the page when I got notification in case something had gone wrong  ;)

Bryce

Na, you're too negative. I was pretty confident that your work would be good. I have 2 or 3 other 6128 PCBs. I'll check what version they are and test them too if they are different. Then you can tick off which ones have been tested till all versions have been tried. If anybody wants one of these, then let me know (PM).

Bryce.

Porchy

Quote from: Bryce on 21:47, 10 December 13
Na, you're too negative. I was pretty confident that your work would be good. I have 2 or 3 other 6128 PCBs. I'll check what version they are and test them too if they are different. Then you can tick off which ones have been tested till all versions have been tried. If anybody wants one of these, then let me know (PM).

Bryce.

Your right, Ive never had much faith in my own abilities until quite recently and ive got the good people of the internet to thank for that really.

Have you tested the expansion hardware with it too? Thats my main concern right now.

Bryce

No, I only had an hour free today. But that's why I left it in the machine. I'll give it a serious testing over time, but I doubt I'll find any fault.

Bryce.

arnoldemu

My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Bryce

#12
Quote from: arnoldemu on 22:32, 10 December 13
@Bryce,great avatar!

I felt I needed to express my Christmas spirit[nb]I hate Christmas[/nb] :D It's also explains why I don't comment in the repaint / graphic enhancement threads :)

Bryce.

Bryce

Last night I took a look at what it would take to convert a 464 into a true 100% 6128 compatible 128K machine using this new GAL. My idea was to make a board that would plug under the Z80, as most of the required signals are available there. Although it is possible, it would unfortunately be a very messy mod, involving track cutting to implement the A14out, A15out and CAS0. It would also need quite a few fly-leads soldered to other spots on the board for the signals that aren't available on the Z80 socket (RAMDIS, IOWR, A14out, A15out, CAS0, NCAS and /CPU).

Bryce.

arnoldemu

I have created a page on the wiki with Porchy's JED and equations.
My games. My Games
My website with coding examples: Unofficial Amstrad WWW Resource

Porchy

Quote from: Bryce on 13:57, 12 December 13
Last night I took a look at what it would take to convert a 464 into a true 100% 6128 compatible 128K machine using this new GAL. My idea was to make a board that would plug under the Z80, as most of the required signals are available there. Although it is possible, it would unfortunately be a very messy mod, involving track cutting to implement the A14out, A15out and CAS0. It would also need quite a few fly-leads soldered to other spots on the board for the signals that aren't available on the Z80 socket (RAMDIS, IOWR, A14out, A15out, CAS0, NCAS and /CPU).

Bryce.


I just got my hands on a 464 yesterday and came to a similar conclusion. Shame but may mock something up to determine how messy a mod would be.

TotO

Quote from: Bryce on 13:57, 12 December 13it would unfortunately be a very messy mod, involving track cutting to implement the A14out, A15out and CAS0. It would also need quite a few fly-leads soldered to other spots on the board for the signals that aren't available on the Z80 socket (RAMDIS, IOWR, A14out, A15out, CAS0, NCAS and /CPU).
It's why, it's not really a good idea. Better to find a 6128 and keep the 464 save of hack.
"You make one mistake in your life and the internet will never let you live it down" (Keith Goodyer)

gerald

Thread resurrection !

I've had a look at the issue using the GAL in the following thread : New yerar, new CPC board
The problem also happen on a regular CPC6128 using the GAL instead of the orginal PAL and a memory extension.

The problem is caused by the handling of RAMDIS, which in the GAL version mask a part of the video fetch (hence the artefact).

I've updated the PAL wiki page with a fixed version which I've tested on a 6128 with and without a memory extension (XMEM and my own RAM extension).
Test where done with custom memory test (test C3/C4-C7 mode) and few game/demo (Orion prime/Phortem/Still rising/Pacman/Rtype)

For reference, the new equations are :

A14OUT     = !(  !A14
              #   !A15 & !Q0 & Q2 );

A15OUT     = !(  !A15 & !A14
              #   !A15 & !Q1
              #   !A15 & !Q0 & !Q2 );

Q0     = (  D7ANDD6 & nRESET & D0 & !A15 & !nIOWR
          #   !D7ANDD6 & nRESET & Q0
          #   nRESET & A15 & Q0
          #   nRESET & nIOWR & Q0 );

Q1     = (  D7ANDD6 & nRESET & D1 & !A15 & !nIOWR
          #   !D7ANDD6 & nRESET & Q1
          #   nRESET & A15 & Q1
          #   nRESET & nIOWR & Q1 );

Q2     = (  D7ANDD6 & nRESET & D2 & !A15 & !nIOWR
          #   !D7ANDD6 & nRESET & Q2
          #   nRESET & A15 & Q2
          #   nRESET & nIOWR & Q2 );

nCAS0     = (  nCAS
             #   RAMDIS & !nCPU & nCAS0
             #   !A15 & A14 & !nCPU & Q2 & nCAS0
             #   A15 & A14 & !nCPU & Q0 & !Q2 & nCAS0
             #   !nCPU & !Q0 & Q1 & !Q2 & nCAS0
             #   !nCAS1 );

nCAS1     = !(  !RAMDIS & !nCAS & !A15 & A14 & !nCPU & Q2 & nCAS0
             #   !RAMDIS & !nCAS & A15 & A14 & !nCPU & Q0 & !Q2 & nCAS0
             #   !RAMDIS & !nCAS & !nCPU & !Q0 & Q1 & !Q2 & nCAS0
             #   !nCAS & !A15 & A14 & Q2 & nCAS0 & !nCAS1
             #   !nCAS & A15 & A14 & Q0 & !Q2 & nCAS0 & !nCAS1
             #   !nCAS & !Q0 & Q1 & !Q2 & nCAS0 & !nCAS1 );


Munchausen

Quote from: gerald on 20:10, 03 October 15
Thread resurrection !

I've had a look at the issue using the GAL in the following thread : New yerar, new CPC board
The problem also happen on a regular CPC6128 using the GAL instead of the orginal PAL and a memory extension.

The problem is caused by the handling of RAMDIS, which in the GAL version mask a part of the video fetch (hence the artefact).

I've updated the PAL wiki page with a fixed version which I've tested on a 6128 with and without a memory extension (XMEM and my own RAM extension).
Test where done with custom memory test (test C3/C4-C7 mode) and few game/demo (Orion prime/Phortem/Still rising/Pacman/Rtype)

For reference, the new equations are :

A14OUT     = !(  !A14
              #   !A15 & !Q0 & Q2 );

A15OUT     = !(  !A15 & !A14
              #   !A15 & !Q1
              #   !A15 & !Q0 & !Q2 );

Q0     = (  D7ANDD6 & nRESET & D0 & !A15 & !nIOWR
          #   !D7ANDD6 & nRESET & Q0
          #   nRESET & A15 & Q0
          #   nRESET & nIOWR & Q0 );

Q1     = (  D7ANDD6 & nRESET & D1 & !A15 & !nIOWR
          #   !D7ANDD6 & nRESET & Q1
          #   nRESET & A15 & Q1
          #   nRESET & nIOWR & Q1 );

Q2     = (  D7ANDD6 & nRESET & D2 & !A15 & !nIOWR
          #   !D7ANDD6 & nRESET & Q2
          #   nRESET & A15 & Q2
          #   nRESET & nIOWR & Q2 );

nCAS0     = (  nCAS
             #   RAMDIS & !nCPU & nCAS0
             #   !A15 & A14 & !nCPU & Q2 & nCAS0
             #   A15 & A14 & !nCPU & Q0 & !Q2 & nCAS0
             #   !nCPU & !Q0 & Q1 & !Q2 & nCAS0
             #   !nCAS1 );

nCAS1     = !(  !RAMDIS & !nCAS & !A15 & A14 & !nCPU & Q2 & nCAS0
             #   !RAMDIS & !nCAS & A15 & A14 & !nCPU & Q0 & !Q2 & nCAS0
             #   !RAMDIS & !nCAS & !nCPU & !Q0 & Q1 & !Q2 & nCAS0
             #   !nCAS & !A15 & A14 & Q2 & nCAS0 & !nCAS1
             #   !nCAS & A15 & A14 & Q0 & !Q2 & nCAS0 & !nCAS1
             #   !nCAS & !Q0 & Q1 & !Q2 & nCAS0 & !nCAS1 );


This is great, nice work Gerald! How about a CPLD version of the gate array now? Hehe

gerald

Quote from: Munchausen on 10:31, 04 October 15
This is great, nice work Gerald! How about a CPLD version of the gate array now? Hehe
That's a bit more tricky, and I thing we may end up using obsolete part as well  ;D

Munchausen

I actually looked at the Xilinx XC9500XL, and if you used an I2C D2A for the video signals, you have exactly the right number of IO pins. Of course, discovering this was the easy part...

TotO

XL are 3.3V only... Better to use 5V versions if possible.
"You make one mistake in your life and the internet will never let you live it down" (Keith Goodyer)

Porchy

Quote from: gerald on 20:10, 03 October 15
Thread resurrection !

I've had a look at the issue using the GAL in the following thread : New yerar, new CPC board
The problem also happen on a regular CPC6128 using the GAL instead of the orginal PAL and a memory extension.

The problem is caused by the handling of RAMDIS, which in the GAL version mask a part of the video fetch (hence the artefact).

I've updated the PAL wiki page with a fixed version which I've tested on a 6128 with and without a memory extension (XMEM and my own RAM extension).
Test where done with custom memory test (test C3/C4-C7 mode) and few game/demo (Orion prime/Phortem/Still rising/Pacman/Rtype)

For reference, the new equations are :

A14OUT     = !(  !A14
              #   !A15 & !Q0 & Q2 );

A15OUT     = !(  !A15 & !A14
              #   !A15 & !Q1
              #   !A15 & !Q0 & !Q2 );

Q0     = (  D7ANDD6 & nRESET & D0 & !A15 & !nIOWR
          #   !D7ANDD6 & nRESET & Q0
          #   nRESET & A15 & Q0
          #   nRESET & nIOWR & Q0 );

Q1     = (  D7ANDD6 & nRESET & D1 & !A15 & !nIOWR
          #   !D7ANDD6 & nRESET & Q1
          #   nRESET & A15 & Q1
          #   nRESET & nIOWR & Q1 );

Q2     = (  D7ANDD6 & nRESET & D2 & !A15 & !nIOWR
          #   !D7ANDD6 & nRESET & Q2
          #   nRESET & A15 & Q2
          #   nRESET & nIOWR & Q2 );

nCAS0     = (  nCAS
             #   RAMDIS & !nCPU & nCAS0
             #   !A15 & A14 & !nCPU & Q2 & nCAS0
             #   A15 & A14 & !nCPU & Q0 & !Q2 & nCAS0
             #   !nCPU & !Q0 & Q1 & !Q2 & nCAS0
             #   !nCAS1 );

nCAS1     = !(  !RAMDIS & !nCAS & !A15 & A14 & !nCPU & Q2 & nCAS0
             #   !RAMDIS & !nCAS & A15 & A14 & !nCPU & Q0 & !Q2 & nCAS0
             #   !RAMDIS & !nCAS & !nCPU & !Q0 & Q1 & !Q2 & nCAS0
             #   !nCAS & !A15 & A14 & Q2 & nCAS0 & !nCAS1
             #   !nCAS & A15 & A14 & Q0 & !Q2 & nCAS0 & !nCAS1
             #   !nCAS & !Q0 & Q1 & !Q2 & nCAS0 & !nCAS1 );



Superb! Thank you
Ill update my list too

Munchausen

Quote from: TotO on 15:57, 04 October 15
XL are 3.3V only... Better to use 5V versions if possible.

Yeah there is a 5V part. Though the 3.3V versions are 5V compatible... not sure how compatible!

Kris

I just upgrade/update the GAL in my 6128; everything seems OK even after 2 hours watching demos :)
Nice job !

Powered by SMFPacks Menu Editor Mod