6502.org Forum  Projects  Code  Documents  Tools  Forum
It is currently Sat Nov 23, 2024 7:23 pm

All times are UTC




Post new topic Reply to topic  [ 19 posts ]  Go to page 1, 2  Next
Author Message
PostPosted: Tue Jul 26, 2016 7:38 am 
Offline

Joined: Fri Jul 22, 2016 2:05 pm
Posts: 8
Hello everybody,

I'm a total newbie to the world of 6502 based computers, and I have a very simple question that you probably already received a lot, but I can't find a definitive answer.
I'm looking forward to starting a small project on the 6502. I know that is extremely soon to talk about display/graphics, since I've never even touched a 6502 yet, but I would like to understand what can be done and what I could achieve in time when it comes to text display on a screen for a homebrew computer.
Looking on the net and on this forum I think I've narrowed the problem of showing text with modern VGA screens to the fact that those monitors require high frequency signals, around 25MHz, to operate. I believe that the solutions I've found to overcome such problem are basically:

- using a sufficiently fast microcontroller to handle the video control part;
- using off the shelf serial-to-VGA adapters;
- using smaller "smart" LCDs, being limited to, I believe, around 4 lines of text.

I'm not looking for complex colour graphics, and I think I would be more than satisfied with a monocrome text-only solution. What really bugs me is the idea of building a homebrew 6502 computer, and then using a far more powerful microcontroller just to control the display.
Is there any alternative to that?

Thank you for your kind help.

Cheers,

Davide


Top
 Profile  
Reply with quote  
PostPosted: Tue Jul 26, 2016 7:50 am 
Offline
User avatar

Joined: Fri Aug 30, 2002 1:09 am
Posts: 8546
Location: Southern California
The 6502 primer's chapter 15 is on displays:
http://wilsonminesco.com/6502primer/displays.html

(Do go through the whole primer though. It's organized in logical steps, so skipping around may not be very appropriate.)

_________________
http://WilsonMinesCo.com/ lots of 6502 resources
The "second front page" is http://wilsonminesco.com/links.html .
What's an additional VIA among friends, anyhow?


Top
 Profile  
Reply with quote  
PostPosted: Tue Jul 26, 2016 7:51 am 
Offline
User avatar

Joined: Fri Dec 11, 2009 3:50 pm
Posts: 3367
Location: Ontario, Canada
Pax_1601 wrote:
What really bugs me is the idea of building a homebrew 6502 computer, and then using a far more powerful microcontroller just to control the display.
It sounds as if you may be interested in the "Cheap Video" approach made popular by Don Lancaster. Cheap Video is a means of outputting video without the need for DMA hardware or a Video Controller chip and dedicated video memory. I've used Cheap Video extensively, and written about it here. For full details, consult Lancaster's books:

- TV Typewriter Cookbook
- the Cheap Video Cookbook, and
- Son of Cheap Video (!)

cheers,
Jeff

_________________
In 1988 my 65C02 got six new registers and 44 new full-speed instructions!
https://laughtonelectronics.com/Arcana/ ... mmary.html


Top
 Profile  
Reply with quote  
PostPosted: Tue Jul 26, 2016 8:25 am 
Offline

Joined: Fri Jul 22, 2016 2:05 pm
Posts: 8
GARTHWILSON wrote:
The 6502 primer's chapter 15 is on displays:
http://wilsonminesco.com/6502primer/displays.html

(Do go through the whole primer though. It's organized in logical steps, so skipping around may not be very appropriate.)


Thank you for your answer :) I'm in the process of reading the primer, and I have already read this chapter (it was the first one actually) :D I believe that all the three options I have presented in my first post are mentioned in the display chapter of the primer :)

Dr Jefyll wrote:
Pax_1601 wrote:
What really bugs me is the idea of building a homebrew 6502 computer, and then using a far more powerful microcontroller just to control the display.
It sounds as if you may be interested in the "Cheap Video" approach made popular by Don Lancaster. Cheap Video is a means of outputting video without the need for DMA hardware or a Video Controller chip and dedicated video memory. I've used Cheap Video extensively, and written about it here. For full details, consult Lancaster's books:

- TV Typewriter Cookbook
- the Cheap Video Cookbook, and
- Son of Cheap Video (!)

cheers,
Jeff


Thank you for your answer, I will definitely read your suggestions. Just to be clear, since as I stated I'm a total newbie: your "Cheap Video" solution allows to produce a video output in the form of composite video signal? Is composite still viable on modern TVs?

Thank you, and please pardon my ignorance :)

Davide


Top
 Profile  
Reply with quote  
PostPosted: Tue Jul 26, 2016 8:36 am 
Offline
User avatar

Joined: Fri Dec 11, 2009 3:50 pm
Posts: 3367
Location: Ontario, Canada
Pax_1601 wrote:
Just to be clear, since as I stated I'm a total newbie: your "Cheap Video" solution allows to produce a video output in the form of composite video signal? Is composite still viable on modern TVs?
Composite video is easily doable; or, if you like, you could have a separate SYNC signal. I imagine many modern TV's still accept composite video, although it's becoming less common. Cheap Video could be reworked for use on a VGA display (CRT or LCD), although the books (written decades ago) don't cover this.

_________________
In 1988 my 65C02 got six new registers and 44 new full-speed instructions!
https://laughtonelectronics.com/Arcana/ ... mmary.html


Top
 Profile  
Reply with quote  
PostPosted: Tue Jul 26, 2016 8:38 am 
Offline

Joined: Fri Jul 22, 2016 2:05 pm
Posts: 8
Dr Jefyll wrote:
Pax_1601 wrote:
Just to be clear, since as I stated I'm a total newbie: your "Cheap Video" solution allows to produce a video output in the form of composite video signal? Is composite still viable on modern TVs?
Composite video is easily doable; or, if you like, you could have a separate SYNC signal. I imagine many modern TV's still accept composite video, although it's becoming less common. Cheap Video could be reworked for use on a VGA display (CRT or LCD), although the books (written decades ago) don't cover this.


Thank you very much! ;)


Davide


Top
 Profile  
Reply with quote  
PostPosted: Tue Jul 26, 2016 12:04 pm 
Offline
User avatar

Joined: Sun Dec 29, 2002 8:56 pm
Posts: 460
Location: Canada
Quote:
Cheap Video could be reworked for use on a VGA display (CRT or LCD), although the books (written decades ago) don't cover this.

I wouldn't mind seeing a reworked cheap video for VGA. VGA's similar to composite except the horizontal frequencies doubled ? One aught to be able to use the faster 6502's for cheap video generation. For display on a modern TV however, something more like HDMI or DVI is required. Even VGA is becoming less common. It's easy enough to get VGA to HDMI converter box. To get HDMI output one really needs something that can do a lot of bit-fiddling with input signals that look like VGA. Needs an PLD (eg FPGA) of some sort - I don't think a micro-controller would be fast enough.

_________________
http://www.finitron.ca


Top
 Profile  
Reply with quote  
PostPosted: Tue Jul 26, 2016 2:46 pm 
Offline
User avatar

Joined: Wed Aug 17, 2005 12:07 am
Posts: 1250
Location: Soddy-Daisy, TN USA
If you want to drive the pixels yourself, then I certainly second the previous recommendations on the Don Lancaster books. I own several of his books and I think I have all of the cheap video series.

I'd like to throw out a few more options too. Don't dismiss microcontrollers completely. There are many examples of using a PIC to generate video. That's how I did it the first time. Using a 20 MHz PIC is not completely out of line.

Another microcontroller to use would be the Propeller from Parallax. I use them all the time. They are pretty fast (80 MHz with 8 cores) but they are SIMPLE to use. And the amount of support hardware is very minimal. They can easily produce B/W NTSC or even 64 color VGA.

Finally, take a look at this project. The L-Star. I have one and it's awesome. It's a minimal 65C02 computer with B/W NTSC video and PS2 keyboard. It emulates the Apple 1 (and others) very well.

https://github.com/jacgoudsmit/L-Star

_________________
Cat; the other white meat.


Top
 Profile  
Reply with quote  
PostPosted: Tue Jul 26, 2016 6:01 pm 
Offline
User avatar

Joined: Thu May 28, 2009 9:46 pm
Posts: 8510
Location: Midwestern USA
You could also take a look at Geoff Graham's VT100 terminal on a microcontroller. The MCU can be integrated into your design to supply a "conversational" text display via VGA. The MCU includes an interface to a standard PC-AT keyboard.

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


Top
 Profile  
Reply with quote  
PostPosted: Tue Jul 26, 2016 9:51 pm 
Offline
User avatar

Joined: Fri Aug 30, 2002 9:02 pm
Posts: 1748
Location: Sacramento, CA
Here's my two cents on simple video, having done it several ways myself.

Composite b/w text

Do the Don Lancaster "cheap video" method. It will work if you don't mind the extra board space.

Use a microcontroller - 1 or two chips and a few parts - here's the one I did -> http://sbc.rictor.org/vid2c.html

Composite Color graphics & text

I used the phase 1 DMA method to create a 320x200 x8bit color display using a CPLD to take care of the timing and addressing on my SBC-3 here -> http://sbc.rictor.org/info3.html

In my opinion, going much larger in resolution will require too much of the 6502 system to be really useful.

VGA

I tried one of those smart modules that provide a serial interface and all of the routines you need to be productive. For a small SBC, they would be great. I'm not sure of their current price range. The one I have is not made anymore. -> http://old.4dsystems.com.au/prod.php?id=213

There's a simple composite video to VGA converter out there - I have not tried it, but at $13, might be worth looking into.
https://www.amazon.com/Composite-S-Vide ... B003NUN7DG

HDMI

I have not actually put this into operation, but I played a little with the Raspberry Pi and it would be pretty easy to write a simple serial interface with command-driven operations similar to the VGA boards above, to drive an HDMI output in full color. At $25, the Pi is a worthy option (in my opinion).

_________________
Please visit my website -> https://sbc.rictor.org/


Top
 Profile  
Reply with quote  
PostPosted: Wed Jul 27, 2016 6:44 am 
Offline

Joined: Fri Jul 22, 2016 2:05 pm
Posts: 8
8BIT wrote:
Here's my two cents on simple video, having done it several ways myself.

Composite b/w text

Do the Don Lancaster "cheap video" method. It will work if you don't mind the extra board space.

Use a microcontroller - 1 or two chips and a few parts - here's the one I did -> http://sbc.rictor.org/vid2c.html



Thank you for your kind answer, I've been checking your great work, it's a very good reference :) Actually, I do believe I will use your SBC-2 as reference for my first project :)
Do you believe that the original, "microprocessor-less" approach by Don Lancaster, is possible too? I've found this link on the web for a TVT6 video typewriter: http://www.tinaja.com/glib/pop_elec/tvt ... 2_7_77.pdf
I perfectly understand that the resolution and sharpness of such circuit would be very low, but I'm not looking for performance in any case :D I've never been working on this kind of "old school" circuits and I would really like to try at least once. Then, if I see that the resolution is simply too low, I will switch to a better solution.

Cheers,

Davide


Top
 Profile  
Reply with quote  
PostPosted: Wed Jul 27, 2016 6:52 am 
Offline

Joined: Fri Jul 22, 2016 2:05 pm
Posts: 8
cbmeeks wrote:
If you want to drive the pixels yourself, then I certainly second the previous recommendations on the Don Lancaster books. I own several of his books and I think I have all of the cheap video series.

I'd like to throw out a few more options too. Don't dismiss microcontrollers completely. There are many examples of using a PIC to generate video. That's how I did it the first time. Using a 20 MHz PIC is not completely out of line.

Another microcontroller to use would be the Propeller from Parallax. I use them all the time. They are pretty fast (80 MHz with 8 cores) but they are SIMPLE to use. And the amount of support hardware is very minimal. They can easily produce B/W NTSC or even 64 color VGA.

Finally, take a look at this project. The L-Star. I have one and it's awesome. It's a minimal 65C02 computer with B/W NTSC video and PS2 keyboard. It emulates the Apple 1 (and others) very well.

https://github.com/jacgoudsmit/L-Star


Thank you for your answer :) My "adversity" against microcontrollers is purely "idealistic". A good professor of mine told me: "if your really want to understand something, you should do it yourself at least once in your life". I would love to use an "old school" circuit to understand the concept behind it, then, when I'm satisfied with that, I will certainly switch to better, cleaner and more powerful solutions. And for that, I am certainly considering PIC/ATMega based solutions, other than all the others you have proposed :)

BigDumbDinosaur wrote:
You could also take a look at Geoff Graham's VT100 terminal on a microcontroller. The MCU can be integrated into your design to supply a "conversational" text display via VGA. The MCU includes an interface to a standard PC-AT keyboard.


Thank you for your answer :) I believe this solution is presented in the primer too, if I'm not mistaken. The same as above applies, but clearly this is a neat solution! I'm building a list of possible solutions for the future, thank you again! :)

Cheers,

Davide


Top
 Profile  
Reply with quote  
PostPosted: Wed Jul 27, 2016 11:52 am 
Offline
User avatar

Joined: Fri Aug 30, 2002 9:02 pm
Posts: 1748
Location: Sacramento, CA
Pax_1601 wrote:
Do you believe that the original, "microprocessor-less" approach by Don Lancaster, is possible too? I've found this link on the web for a TVT6 video typewriter: http://www.tinaja.com/glib/pop_elec/tvt ... 2_7_77.pdf
I perfectly understand that the resolution and sharpness of such circuit would be very low, but I'm not looking for performance in any case :D I've never been working on this kind of "old school" circuits and I would really like to try at least once. Then, if I see that the resolution is simply too low, I will switch to a better solution.

Cheers,

Davide


Yes, this is certainly possible. To me, the down side of the TVT6 is you are using the 6502 (65C02, 65816) to drive the display. You will have an interrupt routine to feed the display which will reduce the performance of your system.

If I were to do it, I'd want the video system to drive itself, similar to how the Apple ][ did, so 100% of the processor time is available. My SBC-3 was loosely based on that. I just chose to package the whole thing into a programmable logic chip vs. using 10-15 discrete 74 series chips. Since the 65 series chips do not use the first half cycle for memory access, that is the perfect way to multiplex your main RAM with your video system. You only have to use the right system clock and ensure your memory has a fast enough access time to support two half cycle accesses.

I hope that helped.

Daryl

_________________
Please visit my website -> https://sbc.rictor.org/


Top
 Profile  
Reply with quote  
PostPosted: Wed Jul 27, 2016 2:11 pm 
Offline

Joined: Wed Jan 08, 2014 3:31 pm
Posts: 578
You might want to consider using a TMS9918a. During the 80's it was used in the TI 99/4a, the MSX computers, and the ColecoVision games console. So there are a ton available as new old stock and used system pulls on eBay. It requires its own RAM, and although it is designed to use dynamic RAM, some latches allow it to be used with static RAM. This is good because you can do bit mapped graphics without the frame buffer consuming the CPU's RAM. The Retrobrew computers wiki has some information on it's use, but I don't have the links right now.

I plan to use one for my next project, so I've been researching how to use it, and programatically they're simply to use. You memory map the TMS9918a into the 6502's address space. This gives the 6502 access to a register for the address bus of the TMS9918a's RAM. You can then write a byte to this address, and the address register auto-increments. for the next byte. If you don't want to use bit mapped graphics it supports text mode.

Given that they're late '70s technology they're designed with over-scan in mind, so the display is only 256x192 pixels in bit mapped mode. They can do 40x24 characters in character mode.


Top
 Profile  
Reply with quote  
PostPosted: Wed Jul 27, 2016 3:33 pm 
Offline
User avatar

Joined: Wed Aug 17, 2005 12:07 am
Posts: 1250
Location: Soddy-Daisy, TN USA
Martin beat me to the punch.

I was also going to mention the TMS9918 as another option.

_________________
Cat; the other white meat.


Top
 Profile  
Reply with quote  
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 19 posts ]  Go to page 1, 2  Next

All times are UTC


Who is online

Users browsing this forum: No registered users and 47 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: