- The LaST Upgrade -
PART 20 - 020 CPU booster
Project started April 30, 2015 - Last updated July 19, 2015
Rodolphe Pineau
1 - Introduction 2 - Current prototype 3 - Signals resync
Future
|
July 14, 2015 Update
|
|
This is the current MegaSTE prototype board as it was sent to the PCB house.
The board should be back by the end of July (2015). |
July 18, 2015 Update
|
|
The PCB has arrived. Now time to solder. |
July 19, 2015 Update
|
|
The PCB is now assembled. I now need to finish the CPLD coding and start the testing and debugging. There are a few jumpers as you can see. These are used to route some signals either directly to/from the 68020 to/from the 68000 socket or via the ATF1502. As the goal is to first get this working at bus speed, only some signals need to be routed to the ATF1502 to generate the "missing" 68020 signals. Once that work the jumper will allow me to route more signals to/from the 68020 and 68000 bus via the ATF1502 to try to get the CPU to run at 33MHz all the time. There might be an intermediary state where I'll use the frequency switching code from the Booster V2 to switch between 33MHz and the bus frequency. |
July 26, 2015 Update
|
I was able to run the first test in the MegaSTE. So it doesn't work .. yet. I could see some bus cycle after fixing some of the CPLD code. I think there might be a few errors in the code for the Motorola application note AN944. I was able to fix the /AS00 timing (that the /AS that goes to the mother board) and make sure it was properly delayed to match the S2 cycle. Also the AN944 equation seem to have the output of AS00 inverted, at lest it was inverted on my logic analyzer output. So there is progress and it seems to start booting as I see TOS access (/CE of ROM is triggered and match /AS00 and /DTACK). I've noticed that /BG is doing something really weird as it follows /DTACK !!! If I disconnect the cpu /BG20 signal from the mother board the signal is a steady HI for the length of my sampling but the ST_BG (so from the mother board) still shows the weird signal following /DTACK. If I put back the 68000 on the machine and sample the same signals /BG is fine. So there is something weird going on there and I need to investigate. I might have some time to do more test next weekend. |
August 1st, 2015 Update
|
Click on the picture for the full size |
So I spent time this week reviewing the equation, make some fix and tweak. The machine obviously boot on the TOS but crashes after 7 seconds.. which is not right as the MegaSTE with the 68000 displays the Atari logo after 4s or so. So something is not responding on the bus and the CPU keeps trying .. I guess until it gets a bus error. I checked that /VPA is asserted when accessing the ACIA (see ACIA access trace). DTACK (connected to DSACK1) also respond properly. /ST_AS is delayed by 1 half clock cycle as expected to land on S2 of the 68000 bus cycle. At this point I'm a little bit in the dark as to what is going on as the card seems to work as it boots the TOS. I used my Saleae to get proper timing as I discovered that the Open Bench logic sniffer was giving me wrong timing even when sampling at 200MHz (25 times the 8MHz bus frequency). |
August 8th, 2015 Update
|
Click on the picture for the full size |
More progress were made this weekend.
|
September 10th, 2015 Update
|
Click on the picture for the full size |
Weird issues
|
December 10th, 2015 Update
|
Lots of progress since last update. We have the board working in 8/32Mhz mode on STE, in 8/32 MHz mode on Mega STE and sometimes also 16/32MHz on MegaSTE (this doesn't always work and tend to freeze the machine when it switches from 8MHz to 16MHz).
Here are some result on a MegaSTE in 8/32MHz mode in comparison to what a stock STE would be :
GEM Bench v4.03 Ofir Gal - 3 March 95 ============================================ Mega STE TOS 2.06 AES v3.20 GEMDOS v0.32 MiNT not present Blitter Enabled NVDI not present Video Mode: 640*400*2 FPU not present Run and Malloc from STRAM Ref: STE + Blitter, ST High ============================================ GEM Dialog Box: 5.485 100% VDI Text: 5.315 103% VDI Text Effects: 10.665 138% VDI Small Text: 5.840 104% VDI Graphics: 11.255 209% GEM Window: 1.530 103% Integer Division: 1.560 1153% Float Math: 10.735 124% RAM Access: 2.945 213% ROM Access: 2.535 248% Blitting: 1.720 106% VDI Scroll: 3.970 107% Justified Text: 5.105 106% VDI Enquire: 2.480 107% New Dialogs: 7.010 108% ============================================ Graphics: 117% CPU: 434% Average: 201%The main issue was a problem on /DSACK0. In the code we were setting the DSACK0.oe to 0 to disable it as we don't need it in the current code. But somehow this wasn't working thus driving /DSACK0 to 0 all the time. This meant that the 68020 always saw the bus transfer as a 32 bits transfer instead of 16 bits. Once this was found by Juliusz, the card started working and we had our first boot to desktop. |
December 29th, 2015 Update
|
So I got some 20ns SRAM to replace my cache and after that I was able to enable the cache at 16MHz.
So the cache can work with faster SRAM.
I ran into more issue mostly on the 8 to 16MHz switch. If the system clock (from the 68000 socket) is directly connected to the 68020, the 8 to 16 MHz switch works most of the time (I still get some craches 3 out 5 times on boot when CPX are loaded as GENERAL.CPX is what does the frequency switch).
Once at 16MHz I can enable the cache. If I save the config with 16MHz with cache enable, it's almost a 100% crash are CPX load time.
So I think that when the MSTE switch frequency the switch is not clean and we get some glitches that the 68020 doesn't like (but apparently doesn't cause issues with the 68000 .. probably because it's slower). I'm guessing a DTACK arrives to early, the 68020 decodes it (even though we delay by 1 clock cycle to resync with the ST on a 4 clock cycle) and tries to read data on the bus when it's not yet valid. We might not have that issue later when we run the 68020 at full 32MHz async.
Also, the MSTE doesn't support enabling the cache at 8MHz (I wanted to test 8/32 MHz with cache).
If you write $FD (8MHz with cache) to $ffff8e21.w and re-read it, it return $FC .. aka 8MHz no cache.
I've look at the MSTE cache schematics and will see if there is a way to force enable the cache by forcing one of the GAL signal (not sure that's going to work but I'll see).
The pure gain of just the 68020 is not that great overall. Also this is with our first version of the CPLD code. A lot of progress has been made but I didn't have time to test the new code on this machine yet. I'll try to post some result at 8/32 (without the cache for now) to show the difference the
clock can make.
MegaSTE 68000 at 16MHz with 16K cache MegaSTE 68020 at 16MHz with 16K cache GEM Bench v4.03 Ofir Gal - 3 March 95 GEM Bench v4.03 Ofir Gal - 3 March 95 ============================================ ============================================ Mega STE TOS 2.06 Mega STE TOS 2.06 AES v3.20 AES v3.20 GEMDOS v0.32 GEMDOS v0.32 MiNT not present MiNT not present Blitter Enabled Blitter Enabled NVDI not present NVDI not present Video Mode: 640*400*2 Video Mode: 640*400*2 FPU not present FPU not present Run and Malloc from STRAM Run and Malloc from STRAM Ref: MSTE + Blitter, ST High Ref: MSTE + Blitter, ST High ============================================ ============================================ GEM Dialog Box: 4.745 96% GEM Dialog Box: 5.220 87% VDI Text: 5.040 99% VDI Text: 5.605 89% VDI Text Effects: 12.250 100% VDI Text Effects: 11.400 107% VDI Small Text: 5.520 99% VDI Small Text: 6.170 88% VDI Graphics: 14.230 100% VDI Graphics: 11.055 128% GEM Window: 1.340 98% GEM Window: 1.410 93% Integer Division: 8.815 100% Integer Division: 3.095 286% Float Math: 7.170 101% Float Math: 7.130 101% RAM Access: 3.155 99% RAM Access: 2.005 157% ROM Access: 3.145 100% ROM Access: 2.030 155% Blitting: 1.740 100% Blitting: 1.785 97% VDI Scroll: 3.925 101% VDI Scroll: 4.135 96% Justified Text: 4.850 100% Justified Text: 5.310 91% VDI Enquire: 1.755 94% VDI Enquire: 1.790 93% New Dialogs: 6.065 95% New Dialogs: 6.325 91% ============================================ ============================================ Graphics: 98% Graphics: 96% CPU: 100% CPU: 174% Average: 98% Average: 117% |
December 29th, 2015 Update
|
Here is a test with our latest 8/32MHz version of the ATF1504 code. Here the reference is a Mega STE at 16MHz with the 16KB cache enabled.
GEM Bench v4.03 Ofir Gal - 3 March 95 ============================================ Mega STE TOS 2.06 AES v3.20 GEMDOS v0.32 MiNT not present Blitter Enabled NVDI not present Video Mode: 640*400*2 FPU not present Run and Malloc from STRAM Ref: MSTE + Blitter, ST High ============================================ GEM Dialog Box: 4.840 94% VDI Text: 4.510 111% VDI Text Effects: 9.145 134% VDI Small Text: 4.875 112% VDI Graphics: 10.275 138% GEM Window: 1.380 95% Integer Division: 1.560 567% Float Math: 10.705 67% RAM Access: 2.940 107% ROM Access: 2.075 151% Blitting: 1.650 105% VDI Scroll: 3.575 111% Justified Text: 4.450 109% VDI Enquire: 2.295 72% New Dialogs: 6.340 91% ============================================ Graphics: 106% CPU: 223% Average: 137% |
January 28th, 2016 Update
|
Quick update. We've made some progress on running at constant 32MHz.. but it crashes on memory test and other bus access. So not there yet. We're also running into issues with the CPLD IDE (WinCUPL) that make coding on this very ... painful to be polite. So we've made the decision to do a v2 board and use a Xilinx CPLD : XC95144XL (100-pin TQFP). This means a new round of board, learning to solder these with my new reflow oven (aka learning to lay down the solder paste in the right quantity then fix bridges between pin), learning the Xilinx tools (and VHDL)... So we're making progress and learning from our mistakes along the way. Rodolphe |
September 23rd, 2016 Update
|
We've made huge progress. The STE board has been tested in a MegaSTE and is now working at full 32MHz (no clock switching) and was tested up to 35MHz. We tried 40MHz but got a black screen. So for now we're continuing with 32MHz. We still have a few issues to fix, mostly slow rising time on tri-state pins so we need to change some pull-up from 4.7K to 1K to see if it helps. This is needed to allow us to use the expansion bus and allow a bus master on it. The new code is fully written in VHDL using the Xilinx tools and gives us a lot more options and is easier to modify/maintain. We still need to do a few things:
Rodolphe |