VGER-20... A Multi-Media Expansion Cartridge.

Modding and Technical Issues

Moderator: Moderators

User avatar
Radical Brad
Vic 20 Devotee
Posts: 256
Joined: Sat Jun 24, 2017 8:18 pm
Website: http://www.AtomicZombie.com
Location: Kakabeka Falls, ONT
Occupation: hACKER

VGER-20... A Multi-Media Expansion Cartridge.

Post by Radical Brad »

Based on some of the work I have been doing on my other project called "The VIC-2000 Expander", I have decided to make a similar project using modern components instead of 1980's logic.

My original work in progress...
http://sleepingelephant.com/ipw-web/bul ... =11&t=8734

The reason for this side project is because I do not always have access to my Basement Hacking Lab, and I need a project that is a lot more portable. The other project spans 50 breadboards, and takes up 32 square feet of bench space!

VIC-Fusion will take up only 16 square inches of space and live on a single small breadboard.

I have also had several emails from members here saying that they would be interested in building a project like this, but my breadboard version will probably cost $1000 or more when completed, as it will use 400-500 logic ICs, and require a massive PCB.
This FPGA based version however, will not be expensive, and easily reproduced or modified by anyone wanting to mess with it.

The final goals for this project are similar to the original, so I will just recap the basics...

1) VIC-20 must remain 100% unmodified, and the new hardware will only use the Expansion Port.
2) A final VGA resolution of 400 x 300 with 4096 colors, and a blazing fast blitter system.
3) The original NTSC VIC output will also be active, so this will be a dual display system.
4) Sound will be 4 channel sample playback with effects. Similar to The Amiga.
5) The stock VIC-20 will run the Operating System, IDE, Assembler, and Tools (original display).

This version of the Expander will have a few features that the Retro version does not...

1) Fast 32 bit addition, subtraction, multiplication, division, and sine lookup.
2) Access to modern external memory devices like SD and USB to load and save programs.

I will post build photos as soon as my 74LVC245 buffers arrive.
For now, here is a quick schematic I will be using to build the initial prototype...

Image

The FPGA generates the Secondary Display, and Stereo Audio.
The FPGA is basically a "Bus Listener", and just draws to the VGA based on commands form the VIC-20.
The AVR will handle Boot Loading of the OS, and access to External Storage devices.
Like my other project, the VIC-20 has access to 16 pages of 32K to run its Operating System from.

The VIC-20 is driving the bus (literally!), and its 6502 is the only processor in the system.

Let the fun re-begin!
Radical Brad
Last edited by Radical Brad on Mon Dec 18, 2017 9:17 pm, edited 1 time in total.
User avatar
RobertBe
Vic 20 Elite
Posts: 2304
Joined: Sat Jul 14, 2007 2:48 pm

Re: VIC-20 Fusion. A Multi-Media Expansion Cartridge.

Post by RobertBe »

Very interesting!

Back in California,
Robert Bernardo
Fresno Commodore User Group
http://www.dickestel.com/fcug.htm
User avatar
Radical Brad
Vic 20 Devotee
Posts: 256
Joined: Sat Jun 24, 2017 8:18 pm
Website: http://www.AtomicZombie.com
Location: Kakabeka Falls, ONT
Occupation: hACKER

Re: VIC-20 Fusion. A Multi-Media Expansion Cartridge.

Post by Radical Brad »

Thanks!

I forgot to mention that on the FPGA side, there is 4 Megabytes of 10ns SRAM.
This is where the Blitter and Sound System will get their assets from.

The VIC will say... "Hey Blitter, move that boing ball to position 360,240", and it will be done at warp speed.

Here is my hacked up FPGA board that I plan to use for this project...

Image

I only soldered 4 of the eight 512K SRAM chips in place for prototyping, but I think VIC will be ok with 2MB for a while!
The FPGA is a Spartan-6 series, internally clocked at 100MHz for the GPU, and external at 40MHz for the VGA.

As for the AVR, it has very limited function, basically just on bootup or when VIC asks for a data transfer.
The AVR will take a USB stream (SD, USB, Flash, etc) and turn it into much more manageable 8 bit data.
I intend to let VIC ask for a 32 bit address, so it will have access to over 4 gigabytes of "drive" space.

I do have some good "drawing board" info on the filesystem structure, but that's for a much later date.
First, I need to get my level translators bridging the gap between old and new.

I will say though, my VIC-20 is very eager to make an Amiga look bad!
... he can be so competitive at times!

Cheers,
Brad
User avatar
Radical Brad
Vic 20 Devotee
Posts: 256
Joined: Sat Jun 24, 2017 8:18 pm
Website: http://www.AtomicZombie.com
Location: Kakabeka Falls, ONT
Occupation: hACKER

Re: VIC-20 Fusion. A Multi-Media Expansion Cartridge.

Post by Radical Brad »

As I contemplate all of the wonderful things my VIC-20 will soon be able to do, I can't help but think of VGER...

Image

A massive, state of the art machine that exists only to serve a small bit of ancient technology.

This project is much the same.
Without the VIC, all of my hardware can do nothing at all.
With my hardware, the VIC will excel way beyond any 8 bit computer.

I can only think of one other example of a 6502 commanding so much technology... The T-800 Model 101.
As you can see from some of these captures, it does in fact run 6502 machine code...

Image

Still waiting for parts... ack!
Brad
cobracon
Vic 20 Dabbler
Posts: 74
Joined: Thu Nov 11, 2010 5:46 pm

Re: VIC-20 Fusion. A Multi-Media Expansion Cartridge.

Post by cobracon »

I can not wait to see this get done. I will be watching with baited breath.
User avatar
RobertBe
Vic 20 Elite
Posts: 2304
Joined: Sat Jul 14, 2007 2:48 pm

Re: VIC-20 Fusion. A Multi-Media Expansion Cartridge.

Post by RobertBe »

Radical Brad wrote:As I contemplate all of the wonderful things my VIC-20 will soon be able to do, I can't help but think of VGER...
Maybe the cartridge should be called V'ger-20! ;)

Merry Christmas!
Robert Bernardo
Fresno Commodore User Group
http://www.dickestel.com/fcug.htm
norm8332
Vic 20 Nerd
Posts: 626
Joined: Sun Nov 13, 2016 11:04 am
Location: USA

Re: VIC-20 Fusion. A Multi-Media Expansion Cartridge.

Post by norm8332 »

Great! You know I'm all for this :D
“In religion and politics people’s beliefs and convictions are in almost every case gotten at second-hand, and without examination... whose opinions about them were not worth a brass farthing.”

-Autobiography of Mark Twain
User avatar
eslapion
ultimate expander
Posts: 5458
Joined: Fri Jun 23, 2006 7:50 pm
Location: Canada
Occupation: 8bit addict

Re: VIC-20 Fusion. A Multi-Media Expansion Cartridge.

Post by eslapion »

Radical Brad wrote:I will post build photos as soon as my 74LVC245 buffers arrive.
I suspect these are not the right type of buffers at all for what you want to do.

These are designed to adapt 5V CMOS level signaling to low voltage CMOS signaling. The VIC-20, just like the C64, uses TTL level signaling.

Gideon Zweijtzer uses 74CBTD16211 buffers for the 1541 ultimate series.
Be normal.
User avatar
Radical Brad
Vic 20 Devotee
Posts: 256
Joined: Sat Jun 24, 2017 8:18 pm
Website: http://www.AtomicZombie.com
Location: Kakabeka Falls, ONT
Occupation: hACKER

Re: VIC-20 Fusion. A Multi-Media Expansion Cartridge.

Post by Radical Brad »

Thanks for the info. I am going to have to revisit my datasheets.

When I looked at all of the available level shifters, having a DIP package available was important so I could use them on both my active breadboard projects.

I found the 74LVC245 used in a few TTL <-> 3.3v projects, and my initial viewing of the datasheet did confirm that the levels would be good in both directions. Basically, the 74LVC245 simply acts as a 5v tolerant input device from TTL when its VCC is powered at 3.3v. From 3.3 to TTL, the levels also seem within the acceptable range.
I also require a manually controlled direction pin. This is part of my design.
Auto-sensing level shifters like the TXB0108 are quirky as hell, and so I won't go there again.

If there is a better solution, then I am all for it.
Looking at the 74CBTD16211 datasheet, it seems to be an expensive one way buffer only available in a small pitch surface mount package. It would be a good choice for this FPGA project if it was bidirectional.

I ordered a bunch of capacitor kits for my VIC collection as well as a stick of 74LVC245 buffers, and they are sitting at my post office for pickup today. Since they are drop in replacements for the 74HC245 buffers that I am already torturing as level converters, I will see how these work.

For sure the 74HC245's (running at 3.3v VCC) have issues, as they are not made for this purpose.
On a few of the address lines, I need weak pullups. On a few others, I need weak pulldowns!
This also differs from one VIC to the other.

Here are the levels I have been considering, 5V TTL (left), and 3.3V CMOS (right)...

Image

Looking at the above chart, the only consideration is the 3.3V device being able to tolerate the higher VOH of the TTL device, which will probably be something like 4 volts.

The 74LVC245 buffer seems to fit this bill, from what I can see so far.
Nothing beats a real-world test though.

Here is one of the examples I found of the 74LVC245 being used between an FPGA and retro TTL.
In this case, a slot cart for an Apple ][...

https://www.bigmessowires.com/2017/12/0 ... -apple-ii/

Hope to get this bridge to the modern world worked well soon.
The rest of this project will be mostly code.

Thanks,
Brad
eslapion wrote:
Radical Brad wrote:I will post build photos as soon as my 74LVC245 buffers arrive.
I suspect these are not the right type of buffers at all for what you want to do.

These are designed to adapt 5V CMOS level signaling to low voltage CMOS signaling. The VIC-20, just like the C64, uses TTL level signaling.

Gideon Zweijtzer uses 74CBTD16211 buffers for the 1541 ultimate series.
User avatar
Radical Brad
Vic 20 Devotee
Posts: 256
Joined: Sat Jun 24, 2017 8:18 pm
Website: http://www.AtomicZombie.com
Location: Kakabeka Falls, ONT
Occupation: hACKER

Re: VIC-20 Fusion. A Multi-Media Expansion Cartridge.

Post by Radical Brad »

Yeah, I think I like that name better, thanks for the suggestion.
Thanks to Robert, this project shall know be known as... VGER-20
Would it bork anything up if I edited the topic name on this forum?

Cheers!
Brad
RobertBe wrote:
Radical Brad wrote:As I contemplate all of the wonderful things my VIC-20 will soon be able to do, I can't help but think of VGER...
Maybe the cartridge should be called V'ger-20! ;)

Merry Christmas!
Robert Bernardo
Fresno Commodore User Group
http://www.dickestel.com/fcug.htm
User avatar
eslapion
ultimate expander
Posts: 5458
Joined: Fri Jun 23, 2006 7:50 pm
Location: Canada
Occupation: 8bit addict

Re: VIC-20 Fusion. A Multi-Media Expansion Cartridge.

Post by eslapion »

Radical Brad wrote:Looking at the 74CBTD16211 datasheet, it seems to be an expensive one way buffer only available in a small pitch surface mount package. It would be a good choice for this FPGA project if it was bidirectional.
I can assure you it is bidirectional.

The CBTD16211 consists of 2 independently controlled 12 lines bidirectional buffers. The description in the datasheet clearly says "5Ohms connection between 2 ports". It will just lower voltage signaling to 3.3V. It simply buffers a total of 24 lines which is equivalent to three 74LVC245 without a need to specify the direction of the buffering.

You also mentioned using 74HC245 as level shifters, these should be replaced with 74HCT245 for correct TTL level input compatibility.
Be normal.
User avatar
Radical Brad
Vic 20 Devotee
Posts: 256
Joined: Sat Jun 24, 2017 8:18 pm
Website: http://www.AtomicZombie.com
Location: Kakabeka Falls, ONT
Occupation: hACKER

Re: VIC-20 Fusion. A Multi-Media Expansion Cartridge.

Post by Radical Brad »

Ok, good to know they are bi-directional.
Also good to see them used in a similar TTL <-> LVTTL33 project.
I may explore them for use on the final PCB when I get to that stage.

Comparing them to the 74LVC245's, here is what I found...

The 74CBT is $5.00 per unit, and I will require 2 of them (I need 29 IO).
The 74LVC is only $.60, so 4 of them will still cost $7.60 less then the 74CBT.
The 74LVC is listed as active by 5 companies, while the 74LBT has only one source not discontinued.

The big kicker for me is that I do need to control direction for what I plan to do.
I may be able to get away with the 74CBT, but do not know for sure yet.

Perhaps tonight I will have time to test the 74LVC buffers that are waiting in the box for me to pick up.

Brad

eslapion wrote:
Radical Brad wrote:Looking at the 74CBTD16211 datasheet, it seems to be an expensive one way buffer only available in a small pitch surface mount package. It would be a good choice for this FPGA project if it was bidirectional.
I can assure you it is bidirectional.

The CBTD16211 consists of 2 independently controlled 12 lines bidirectional buffers. The description in the datasheet clearly says "5Ohms connection between 2 ports". It will just lower voltage signaling to 3.3V. It simply buffers a total of 24 lines which is equivalent to three 74LVC245 without a need to specify the direction of the buffering.

You also mentioned using 74HC245 as level shifters, these should be replaced with 74HCT245 for correct TTL level input compatibility.
User avatar
eslapion
ultimate expander
Posts: 5458
Joined: Fri Jun 23, 2006 7:50 pm
Location: Canada
Occupation: 8bit addict

Re: VIC-20 Fusion. A Multi-Media Expansion Cartridge.

Post by eslapion »

Radical Brad wrote:The 74CBT is $5.00 per unit, and I will require 2 of them (I need 29 IO).
The 74LVC is only $.60, so 4 of them will still cost $7.60 less then the 74CBT.
The 74LVC is listed as active by 5 companies, while the 74LBT has only one source not discontinued.
Only the 74CBTD16211 specifically is about 5$ each. The 74CBTD is actually a family of products.

If you have 29 IOs to buffer between 3.3V and 5V signaling (TTL really isn't 5V but it is usually higher than 3.3V) then perhaps you could use a CBTD16210 (2 x 10 lines buffer) along with a CBTD3861 (1 x 10 lines) or CBTD3384 (2 x 5 lines). I didn't check the exact price but it would be considerably cheaper than 2 CBTD16211 which can actually buffer a total of 48 lines.

Of course, this may be a foul ball if you absolutely require to control the buffering direction.

As for the 74LVC, the correct part for TTL to LV CMOS buffering is 74LVT245 and Digi-Key carries a wide variety from 4 manufacturers. Exactly the same price as the 74LVC245.
Be normal.
User avatar
Radical Brad
Vic 20 Devotee
Posts: 256
Joined: Sat Jun 24, 2017 8:18 pm
Website: http://www.AtomicZombie.com
Location: Kakabeka Falls, ONT
Occupation: hACKER

Re: VIC-20 Fusion. A Multi-Media Expansion Cartridge.

Post by Radical Brad »

I appreciate all that information.
When this project is done, I want it to be more than just a hack, so proper level translation will be important.
I will have a close look at the LVT to see what differs from the LVC I have now.

I just dropped these 74LVC245s in place of the 74HC245s I have been torturing, and the are working well so far.

Image
74LVC245 Bi-Directional Buffers

I have a basic GPU in the FPGA now, and it can swap dual buffers and do basic pixel draw.
Next test will be to have the VIC draw some stuff from Basic.
I always like seeing a stock VIC draw to VGA in Basic.

I will report back when the next round of tests are complete.

Oh, I also upgraded my resistor DAC, and now the GPU does 32,768 colors.
The VIC can program any of the 32K colors into an indexed palette of 256 colors.
So, basically it's what VGA called "HighColor" back in the day.

Hey VIC, you now have 28,672 more colors than the Amiga-500 had!

Cheers!
Radical Brad
eslapion wrote:
Radical Brad wrote:The 74CBT is $5.00 per unit, and I will require 2 of them (I need 29 IO).
The 74LVC is only $.60, so 4 of them will still cost $7.60 less then the 74CBT.
The 74LVC is listed as active by 5 companies, while the 74LBT has only one source not discontinued.
Only the 74CBTD16211 specifically is about 5$ each. The 74CBTD is actually a family of products.

If you have 29 IOs to buffer between 3.3V and 5V signaling (TTL really isn't 5V but it is usually higher than 3.3V) then perhaps you could use a CBTD16210 (2 x 10 lines buffer) along with a CBTD3861 (1 x 10 lines) or CBTD3384 (2 x 5 lines). I didn't check the exact price but it would be considerably cheaper than 2 CBTD16211 which can actually buffer a total of 48 lines.

Of course, this may be a foul ball if you absolutely require to control the buffering direction.

As for the 74LVC, the correct part for TTL to LV CMOS buffering is 74LVT245 and Digi-Key carries a wide variety from 4 manufacturers. Exactly the same price as the 74LVC245.
User avatar
eslapion
ultimate expander
Posts: 5458
Joined: Fri Jun 23, 2006 7:50 pm
Location: Canada
Occupation: 8bit addict

Re: VIC-20 Fusion. A Multi-Media Expansion Cartridge.

Post by eslapion »

Radical Brad wrote:I will have a close look at the LVT to see what differs from the LVC I have now.
The logic threshold level... which seems to totally elude MCes...

The Low Voltage to TTL buffers considers anything above 1.3V to be a logic high on the TTL side. The Low Voltage to CMOS buffers considers anything above 2.5V to be a logic high. Same difference as 74HC vs 74HCT. The 74HCT/74LVT has the same logic threshold level as 74LS family of logic ICs.

That's why GandALF which uses a XC9572XL absolutely requires a 74HCT74 (or 74LS which consumes more power), since one of the inputs is attached to the output of an analog op-amp, the logic threshold must be exactly the right level for proper operation.

See: https://www.fairchildsemi.com/applicati ... AN-368.pdf
Be normal.
Post Reply