6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Sat Apr 20, 2024 4:14 pm

All times are UTC




Post new topic Reply to topic  [ 733 posts ]  Go to page Previous  1 ... 34, 35, 36, 37, 38, 39, 40 ... 49  Next
Author Message
PostPosted: Wed Dec 14, 2016 9:20 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 632
Location: Gillies, Ontario, Canada
Thanks!
It actually surprises me that it works!
The 4096 colors was just over the top.

Brad

BigDumbDinosaur wrote:
Oneironaut wrote:
Even if I do eventually to a PCB, I will still take it through a hand wired board first.
The hand made oak / glass cabinet will have windows to both sides of the board to show off the insanity as well.

Yep! Aside from its functional abilities, the mess 'o wires is very impressive to gaze upon. With my background in areas such as PBX switching systems and early "computers," places where a lot of wiring was commonplace, I can fully appreciate a breadboarded contraption like this. :D No reason to not show it off "under glass."


Top
 Profile  
Reply with quote  
PostPosted: Sun Dec 18, 2016 2:08 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 632
Location: Gillies, Ontario, Canada
Looks like I am taking the coward's way out!

After putting in 30+ control lines, I realized that it would be a monumental task to debug anything that wasn't working correctly.
And as I have found out, there will always be something wrong with a design that moves from paper to circuit.

Like I said, using 74HC163 counters in place of 74HC191 counters adds a massive amount of complexity (3x the number of control ICs).

So I have decided to spare the frustration, and went back to my original plan to low-level test the Destination Counters first.

Image
An AVR uses all of its IO just to test half the counters!

Even with just the basic X/Y functions connected for half of my counters, the AVR required 30 IO lines!
On my old system, this test only required 6 IO lines.... big difference going to a synchronous counter.

So once I write a whack of code for the AVR, I should manage to see a static single color block on the screen.
Seems like a lot of effort (and 3 days of work) to just test a few counters, but I know it will save time in the end.

If I can actually get these 163 monsters to behave, then I will try to automate the X/Y logic and then test the other half.
All of this for a few nanoseconds. Is it worth it.... Hell yeah!

Brad


Top
 Profile  
Reply with quote  
PostPosted: Mon Dec 19, 2016 1:59 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 632
Location: Gillies, Ontario, Canada
After writing some code for the AVR, I managed to get an image up on the screen.
There are definitely some timing quirks to work out!
I also noticed a glitchy green pixel on the second Video Buffer - most likely a loose wire.

I must admit that I do not like the design of the 74HC163 counters.

With an asynchronous counter, you just drop the Load line, and the counter is preset instantly.
On a synchronous counter like the 74HC590, the same happens, but due to the latch/buffer, the next clock sees the new value.

On the 74HC163, you actually have to be holding the Load line at the same time as the clock cycles... bad design in my opinion.
This adds an entire host of external control circuitry to manage this sequence and ensure proper timing.

When I win my first 10 million dollar lottery jackpot and can afford to play in IC design, I will redo the 74HC163 to work like this...

- To preload / preset the counter, a low level must be present on the LD line.
- On the rising edge of LD, the value to be loaded is latched into the counter immediately.
- On the next transition of the Clock Line, the preset value will be present on the outputs.
- LD will happen regardless of the state of the Clock, with the new value ready on the next clock transition.

In other words... just like the 74HC590 counter, which works perfectly with minimal support circuitry!

Brad


Top
 Profile  
Reply with quote  
PostPosted: Sat Feb 04, 2017 9:39 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 632
Location: Gillies, Ontario, Canada
I have been very busy with a new career lately, but plan to get some progress made soon.
The latest test is a revision of the Sync Generator, which "should" offer the following upgrades...

- Fully programmable VGA Modes for more flexibility.
- 640x480 with 4096 colors rather than just 400x300.

This is a full rework of the Syncgen, and removes the 74HC688 comparators completely.
The Sync Pulses, Blanking Signal, and XY Counter Resets will stream from a parallel connected SRAM.
This decreases total propagation in the Video generator from 48ns to only 35ns, which is 28.5 MHz.
Timing calculations are based on realistic expectations as per the 74HC parts datasheet.

I wired up 90% of this circuit for testing, and will shoot some photos when it is powered up.

Cheers!
Radical Brad


Top
 Profile  
Reply with quote  
PostPosted: Sun Feb 26, 2017 12:38 am 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 632
Location: Gillies, Ontario, Canada
Wow, finally a free afternoon to hack in my basement lab!
It's been far too long.

I have had much time to consider design ideas as I get ready to breadboard the final version of Vulcan -74, and today I had the chance to successfully test one of these ideas... HD Video with a 4094 color display! And when I say HD, I mean 720x400 or 640x480 resolution.

Sure, 640x480 is nothing compared to today's display standards, but Vulcan has to do it only with 7400 logic gates!
I really wasn't happy with only 400x300, and 256 colors (8 bit color) seemed too restrictive for rich graphics.

The latest VGA Generator pushes the breadboard and the 74HC logic right to the datasheet ratings, but it worked perfectly!
At 25 MHz or 28 MHz, every signal has to make it from point A to B in under 40 nanoseconds, and not 1 nanosecond more.
By ditching all of the 74HC688 comparators and putting the control signals in a "lookup SRAM", I gained a lot of speed.

I should have done this from the start, and it was an old game system I did in 2007 that reminded me of how well this really works.
it does require the CPU to "initialize" the "Sync Memory" first, but that is just a few lines of 6502 code to deal with.
This design also allows multiple video modes to be programmed by the user, so modes like 512x480 or 400x300 are still possible.

Here are the signals that were originally generated by comparators that now live in the Sync Memory...

Code:
BIT 0 : Video Blanking
BIT 1 : Horizontal Sync
BIT 2 : Vertical Sync
BIT 3 : X Counter Reset
BIT 4 : Y Counter Reset
BIT 5 : Y Counter Clock


The Video Memory is 16 bits wide, but only uses 12 of those bits for color as RRRR-GGGG-BBBB.
The Sprite Memory will use the extra few bits to control its own counter wrapping and clocking.

This change was so radical that I decided to breadboard it on my tiny board as a stand alone system.
I am using my trusty 6502 Simulator (AVR 1284) to send the image to the memory through an FTDI USB to Serial chip.
The 720x400 image is way too large for any AVR memory now... 576,000 Bytes per image!

here is the test circuit all hacked up and ready to go...

Image
Everything is 74HC logic and Static RAM.

This design is so much simpler than the latest comparator based version. Just a few counters and SRAMs.
As usual, X and Y are generated by chained 74HC590 counters, set to wrap at intervals determined by the bits from the Sync Memory.
The data is then latched out through various register levels (74HC574s) to keep all the bits in sync and on time.
This is also only a single buffer version being tested. The final version will have double the Video Memory, and an extra Sync Memory.

Does it work?
Well, my monitor thinks so!...

Image
An old friend being immortalized with retro logic!

The image is not perfect yet because the DAC is not perfect, and my converter program simply divides by 16 to go from 8 to 4 bits.
I know there is a better way to convert 24 bit RGB bitmaps to 12 bit, but I have to learn how. Dividing by 16 is just a hack for now.
Also note the frame frequency of 71Hz instead of 70Hz. The VGA standard wants a 28.322Mhz clock, but I had a 28.636Mhz clock available.

I also plan to go to 640x480 instead of 720x400, as this is a more favorable aspect ratio for most monitors, and for game graphics.
But hey... I had to see if I could crank out 720 HD Video using nothing but 1980's logic chips!
So far, this is the best image that Vulcan-74 has achieved, and I have only done slightly better on a Spartan-6 FPGA!

The 4096 color, high resolution display offers a very rich experience...

Image
Not bad for 12 resistors and some logic gates!

Imagine this image being scrolled at 60 frames per second form the 2048x2048 Sprite memory!
640 x 480 will actually look even better due to the increased vertical resolution.
I intend to make a dual buffer version next, and add this to the large breadboard.

Not sure when my next free day is coming, but I will chime in when I have something else to show.
Vulcan-74 is almost out of the prototype stage now, and will soon get more work on the Sound System.

Cheers!
Radical Brad


Top
 Profile  
Reply with quote  
PostPosted: Tue Feb 28, 2017 5:23 am 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 632
Location: Gillies, Ontario, Canada
I did a bit of fine tuning tonight, and now the image looks much better.
Instead of dividing each of the 8 bit color values by 16 (to go from 8 bits to 4), I use a table.

The values are best match to one of these 16 values...
0,17,34,51,68,85,102,119,136,153,170,187,204,221,238,255

This seems to blend the shades between colors a bit better.
I can also save an "advanced bitmap" from photoshop as 4x4x4, and that looks good as well.

I also tweaked my serial routine to receive the entire 640x480 16 bit image in 15 seconds.
This is pretty fast, considering an image is 614,400 bytes in size!
Serial loading my be the final option for loading cartridges into the final design.

The resistor DAC is still a bit too "hot" at .85 volts, but the image sure looks decent now...

Image
640x480 with 4096 simultaneous colors.

I will probably go to an R2R DAC (4 bits x 3) to see if it can get closer to the desired .7 volt signal.
The R2R option will be easier to build using common resistor values.
Might also try an op amp buffer if I can find something that will keep up to the 25MHz pixel clock.

Anyhow, things are looking great with the new VGA Generator.
I am seriously pleased with the results, and plan to move ahead on the large breadboard with this version.

Everything on the board is still just common 74HC logic and Static Ram.
No AC logic, or hard to find out of production parts will ever be used.

Later!
Radical Brad


Top
 Profile  
Reply with quote  
PostPosted: Thu Mar 02, 2017 1:35 am 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 632
Location: Gillies, Ontario, Canada
Alright... Vulcan-74 now has a new Video Generator design!
I replaced the simple 4 resistor DAC with a triple R2R DAC using 750 ohm resistors.
The R value is 375 ohms (750 in parallel), and the R2 value is 750 ohms.
This works out to .72 volts, which is much better than what I had before.
The results are so much better now, only the last shade of white is a bit too hot.

I am seriously pleased with the image, and plan to use this in the new Vulcan-74 design.
The massive breadboard will once again start taking on millions of wires!

What is shown below is only half of the Video Generator (single buffer)...

Image
Sync Logic has been replaced by an SRAM lookup table.

The Video Memory is addressed as 1024 (10 bits) by 480 (9 bits).
Since the Pixel Data is 12 bits wide, it takes two 512K SRAMs to make a single Video Buffer.

The Sync Memory is addressed as 50 (6 bits) by 525 (9 bits). A 32K SRAM would suffice.
The reason for the 50 x 525 Frame is due to the way I divide the VGA standard down...

Code:
// [25.174 MHZ /16 HORIZONTAL VIDEO TIMING FOR 640]
// HBP : 03 FROM 00 TO 02
// HPX : 40 FROM 03 TO 42
// HFP : 01 FROM 43 TO 43
// HSP : 06 FROM 44 TO 49 (-)
// TOT : 50 (6 BITS) / 39.72 NS

// [60 HZ /2 VERTICAL LINE TIMING FOR 480]
// VBP : 016 FROM 000 TO 015
// VLN : 240 FROM 016 TO 255
// VFP : 005 FROM 256 TO 260
// VSP : 001 FROM 261 TO 261 (-)
// TOT : 262 (9 BITS)

// [SYNC MEMORY BITS]
// BIT 0 (01) : VIDEO BLANKING  (-)
// BIT 1 (02) : COUNTER RESET X (-)
// BIT 2 (04) : COUNTER RESET Y (-)
// BIT 3 (08) : HORIZONTAL SYNC (-)
// BIT 4 (16) : VERTICAL SYNC   (-)


Here is the triple 4 Bit Dac that generates the video...

Image
Three R2R DACs, each with 4 bits.

Yep, it's just a bunch of cheap resistors. We don't need no high end digital DAC!
The resulting image is actually amazing... crisp and vibrant.
Here are a few of my favorite Amiga images made into a 3x3 mosaic...

Image
640 x 480 VGA with 4096 simultaneous colors on screen!

And a video showing how I send the image from my PC to the 6502 Simulator...

https://youtu.be/SjJHQ0xiMdQ

I will now begin planning the revised IC placement on the massive breadboard.
There are not a lot more ICs in this design, but I do have to start completely over now.
I am also going to have to solder a bunch of 512K SRAMs onto sockets again!

Can't wait to see some animations at this resolution and color depth!
Hopefully some free time will become available again soon.

Cheers!
Radical Brad


Top
 Profile  
Reply with quote  
PostPosted: Thu Mar 02, 2017 1:53 am 
Offline

Joined: Tue Jul 24, 2012 2:27 am
Posts: 672
That's really clean, both board & pixels. I love seeing the updates on here. :)

_________________
WFDis Interactive 6502 Disassembler
AcheronVM: A Reconfigurable 16-bit Virtual CPU for the 6502 Microprocessor


Top
 Profile  
Reply with quote  
PostPosted: Thu Mar 02, 2017 3:44 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 632
Location: Gillies, Ontario, Canada
Thanks!

Every time one of these crazy "upgrade" ideas actually works, it just drives me to keep on building this thing! When I first started building video systems using logic gates, I was amazed to see a 256 x 240 image being displayed with 256 colors. Even last year, I would never have thought that getting 640 x 480 with 4096 colors from a breadboard would even be remotely possible. The only other 640 VGA generator I have seen out there uses AC logic, and can only push mono color using the old shift register technique. Vulcan-74 also follows the posted VGA spec to the exact nanosecond in every way. Not one clock cycles is lost during the entire 460,000 cycle frame.

Using only 74HC logic (withing specs) was certainly a challenge, but thanks to many register levels (74HC574), it has been possible. So instead of trying to get from point A to point B in 40 nanoseconds, I simply alter the course, and go from point A to point B then from point B to point C, running each race in under 40 nanoseconds. Not cheating... just altering the rules!

This register level system does have its limits though. I have found that 28MHz is the absolute maximum speed that a 10ns SRAM can register data. 16ns from the counters, 10ns from the SRAM, and 8ns setup time for the register equals 34 nanoseconds, which is 29.41 MHz. At 28MHz, 720x400 VGA is possible, but I chose 640x480 because it has a better aspect ratio, and only requires a 25MHz clock speed.

I am going to strip the two giant breadboards completely bare this week, and start rebuilding Vulcan-74 with this new 16 bit Video system, which also includes the Sprite Generator. I will probably start making posts on my Vulcan74.com site since there will be a LOT more detail and photos in the final breadboard build. I will still keep updating this thread as well.

Thanks for all the comments and suggestions so far!
Brad



White Flame wrote:
That's really clean, both board & pixels. I love seeing the updates on here. :)


Top
 Profile  
Reply with quote  
PostPosted: Sat Mar 11, 2017 4:09 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 632
Location: Gillies, Ontario, Canada
SYS64738... REBOOT!

Vulcan-74 is officially getting rebuilt.
Faster, stronger, and more colorful.

Now that I have tried several design ideas to see what works and what doesn't, it is time for the final breadboard.
After the breadboard prototype is functional, I intend to hand wire another duplicate on hand driller perforated board.

The two massive breadboards have been striped clean, and are awaiting re-population...

Image
That 19 inch monitor looks small beside those huge boards.

I probably won't run out of board space, but you never know!

Image
There are 48 panels here, for a total of 42,336 connection points!

The new VGA System is 640x480 with 4096 colors.
The new Blitter system will also use 12 bit color, and an epic amount of SRAM.
Vulcan-74 will be able to copy and scroll Bitmaps of 2048 x 2048 in size!
The sound generator will have its own 2MB of dedicated SRAm as well.

For this kind of performance, you need a lot of high speed (10ns) SRAM...

Image
This is 13,107,200 bytes of Static RAM.

Yes, I now have to hand wire 25 of those 36 pin packages to their DIP sockets!
I might not be reporting back for a while. It's going to be a monumental task of patience.

Once I have all of the SRAM mounted, the rebuild shall begin.

Later!
Radical Brad


Top
 Profile  
Reply with quote  
PostPosted: Sat Mar 11, 2017 4:58 pm 
Offline
User avatar

Joined: Tue Nov 16, 2010 8:00 am
Posts: 2353
Location: Gouda, The Netherlands
that ain't gonna work, dude!


Top
 Profile  
Reply with quote  
PostPosted: Sat Mar 11, 2017 5:26 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 632
Location: Gillies, Ontario, Canada
Arlet wrote:
that ain't gonna work, dude!


...fuel for the fire!


Top
 Profile  
Reply with quote  
PostPosted: Sat Mar 11, 2017 7:45 pm 
Offline
User avatar

Joined: Thu May 28, 2009 9:46 pm
Posts: 8138
Location: Midwestern USA
Arlet wrote:
that ain't gonna work, dude!

:lol: :lol: :lol:

_________________
x86?  We ain't got no x86.  We don't NEED no stinking x86!


Top
 Profile  
Reply with quote  
PostPosted: Sat Mar 11, 2017 7:46 pm 
Offline
User avatar

Joined: Thu May 28, 2009 9:46 pm
Posts: 8138
Location: Midwestern USA
Oneironaut wrote:
SYS64738... REBOOT!

You need a bigger video monitor so it doesn't look lost among those boards. :D

BTW, I wonder how many understand the significance of SYS64738.

_________________
x86?  We ain't got no x86.  We don't NEED no stinking x86!


Top
 Profile  
Reply with quote  
PostPosted: Sat Mar 11, 2017 8:16 pm 
Offline
User avatar

Joined: Mon May 25, 2015 2:25 pm
Posts: 632
Location: Gillies, Ontario, Canada
BigDumbDinosaur wrote:
BTW, I wonder how many understand the significance of SYS64738.


It definitely dates us!


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 733 posts ]  Go to page Previous  1 ... 34, 35, 36, 37, 38, 39, 40 ... 49  Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 5 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to: