Video Card for Arduino and DIY Computers #1: TMS9918 and Arduino on a Breadboard

  Рет қаралды 12,191

Doctor Volt

Doctor Volt

Күн бұрын

Пікірлер: 52
@flyguille
@flyguille 2 жыл бұрын
Color blend artifacs is not about bad desing of the v99x8, it is about the limitations of NTSC and PALs color encoding, the U V color angle that is pointing can't turn abruply too quickly because the TV NORM is out of bandwidth, so, when you try to use a opposite color pixel next to a 180º oppose color, it starts doing glytches, the color oscilates , if you draw a vertical line of just 1 pixel, plus another vertical line of a 180º color side by side, the two vertical lines blend about COLOR, not about LUMINANCE, NTSC and PAL is perfectly able to do full pixel resolution luminance without glytches. TV NORMs were made for image photographs , real life filming, not for computer graphics. This is a complete different issue not related to the tile systems which as it lacks of RAM and lacks of accesses SLOTs it can't do bitmap at 256x192, it has just few slots per scanlines to read the pattern number, the and the pattern graphics line, and the color graphics for that line, that is 3 slots access of VRAM (3 bytes per 8 pixels in the screen) in high resolution graphics. Computers with z80 a 3.5mhz clock has to insert two NOP commands before reading or writing the VRAM, between the ADDRESS PRESET procedure and the actual READ/WRITE, the reason there is not enough SLOT of vram free for pumping graphics data to/from the VRAM through the TMS. The evolution, the v9938 and v9958 works with faster RAM, and the NOP was not necessary anymore, but a single NOP is inserted before trying to read the first byte, but not for writing, that most of the cases writing is the 99% of the accesses. Sadly, the first generation doesn't has RGB output, what was the designer thinking, don't know, maybe to give a ALL IN CHIP solution for cheapness. But, the seconds third and fourth generation really has RGB output and is expected to be convert to VIDEO OUT on the PCB.
@DoctorVolt
@DoctorVolt 2 жыл бұрын
Thank you for this very detailed explanation
@brettb.345
@brettb.345 2 жыл бұрын
I was looking at the TMS9918 for my homebrew 6502, but went with the MC6847 using dual port SRAM. Color is not great, there’s no sprites, and it’s limited to 32 text columns, but I rather like it.
@senorverde09
@senorverde09 Жыл бұрын
And having the inbuilt character ROM is a plus. I like the 6847 for its simplicity.
@brettb.345
@brettb.345 Жыл бұрын
@@senorverde09 True, though I went with custom character ROM. Unfortunately, it makes semi-graphics mode worthless.
@CaptainDangeax
@CaptainDangeax 3 ай бұрын
I'm working on a homebrew computer using tms9929 VDP. I choose this one because it has yuv output for a better image quality. I also own a C128, and an Amiga 500. C128 80 columns output and amiga 500 have rgb output, so the picture is as crispy as vga using scart connector. For the 40 columns output of the c128, I changed the rf modulator for a svideo module, and the picture is far better, although not as good as rgb
@microhobbyist
@microhobbyist Жыл бұрын
I tried many modern LCDs, and I always had issues. I found a CRT TV, and it looks great. I think I'll try a scan converter like the retrotink.
@DoctorVolt
@DoctorVolt Жыл бұрын
I also tried with an USB frame grabber, and it looks also terrible. I think that these chips were designed to look great on CRT TVs. Unfortunately I don't have a color CRT TV to test.
@microhobbyist
@microhobbyist Жыл бұрын
@@DoctorVolt I was fortunate to have found one at a thrift store .
@richardtwyning
@richardtwyning 11 ай бұрын
You should check out the Yamaha V9938. It was a successor to the 9918/9929 and is software compatible, but offers so much more, including 256 * 424 in 256 colours, and 512 * 424 in 16 colours, but with a palette of 19200 colours. Each pixel can also have a unique colour
@static-san
@static-san 11 ай бұрын
The 9918 was incredibly powerful for its time. But I think you may have mis-characterized Graphics I. On most home computers that used this chip, Graphics I was the "text" mode and the way the colour set was done was merely an oddity but no less useful. Just different. Colourful displays and games were abundant using this mode.
@berthoogenboom8458
@berthoogenboom8458 2 жыл бұрын
My MSX with a V9938 (compatible with TMS9918) works fine on on a Salora TV (PAL mode)
@andyhu9542
@andyhu9542 2 жыл бұрын
There is a chip named MB8118 that operates on 5V only and it is a 16K*1bit DRAM chip (which I presume will work witht the TMS9918). There is also the Intel 2118, but I cannot find any available. The TMS9118 can still be bought for few dollars in China, but strangely not the TMS9128 and the TMS9129.
@DoctorVolt
@DoctorVolt 2 жыл бұрын
These may be an alternativ to the 4118. But as they are way more expensive on Ebay, and we still need 8 of these, I´d rather go for the workaround with the SRAM and the D-latches.
@andrewwasson6153
@andrewwasson6153 11 ай бұрын
I’ve got a couple of experimental systems with TMS9118 video chips. They’re the successor of the TMS9918 and don’t rely on the 8 RAM chips. One uses 2 - TMS4464 Dynamic RAM chips for 16K of video ram. The other uses 2 - Toshiba D41464 D RAM chips for 16K video RAM. I had a TI99 4/A back in the early 80’s and these video chips bring back that vibe.
@andyhu9542
@andyhu9542 11 ай бұрын
@@andrewwasson6153 Yes, I know about those 9118 chips.
@WaldoHazeleger
@WaldoHazeleger Жыл бұрын
Would it be possible to make a C64 VIC-II replacement with this chip?
@DoctorVolt
@DoctorVolt Жыл бұрын
No, because these chips are completely different in their capabilities.
@yt4krist0f
@yt4krist0f 9 ай бұрын
Cool!
@DavidAsta
@DavidAsta Жыл бұрын
Great video. Thanks for sharing. I built the same circuit as you and text mode works fine, but in any graphics mode I have an issue: lines are duplicated in alternated lines. For example I print "HELLO" and I have HELLO in first and third line. Then I print "WORLD" and I have WORLD in second and fourth line. Same when I use imgserial. Lines appear repeated in pairs in alternated lines. What could be the cause? Thanks a lot in advance.
@DoctorVolt
@DoctorVolt Жыл бұрын
I assume there is in error in the wiring of the RAM or the RAM itself, so the TMS reads the same content from multiple addresses.
@DavidAsta
@DavidAsta Жыл бұрын
@@DoctorVolt Thanks a lot for the quick reply. I thought the same, but I checked at least 3 times and my PCB schematic has the same connections as yours. I made a small code to show me the contents of the VRAM after vdp_print and I see all is where is supposed to be, and not duplicated. So there must be something that makes the VDP reading twice, but I'm clueless.
@DavidAsta
@DavidAsta Жыл бұрын
@@DoctorVolt Finally found the problem. It was a power supply problem 😲 Reading the VDP manual I noticed that the indicated current supply need is 200-250mA. I was connecting my circuit to the +5 GND of the Arduino. So I connected it instead to a bench power supply and voila, it works!!! And indeed my circuit consumes 190 mA. Thanks a lot again for sharing your circuit.
@DoctorVolt
@DoctorVolt Жыл бұрын
Yes, these old chips always do weird things when the voltage is too low.
@lelandclayton5462
@lelandclayton5462 2 жыл бұрын
I got a chip for you to check out, the NS405-b18N. It's a all-in-one terminal on a chip from the 80's. Would probably work well with your Z80 build.
@DoctorVolt
@DoctorVolt 2 жыл бұрын
That chip wold be perfect, but it is hard to find. So I am trying this with the TMS9918 now.
@lelandclayton5462
@lelandclayton5462 2 жыл бұрын
@@DoctorVolt check your email
@obsoletepowercorrupts
@obsoletepowercorrupts 2 жыл бұрын
How about two of the TMS9918 and with more Video RAM?
@DoctorVolt
@DoctorVolt 2 жыл бұрын
Multiple TMS9918 can be cascaded so that one overlays the output of the previous
@obsoletepowercorrupts
@obsoletepowercorrupts 2 жыл бұрын
@@DoctorVolt If two such TMS9918 chips are used cascaded please describe how and answer can they share Video RAM? Candidate SRAM chips could be TMS4416 or TMS4116 or TMS4164 or TMS4464 _(depending on the breadboard's population of glue logic, nor gates, and so on)._ Thank you.
@DoctorVolt
@DoctorVolt 2 жыл бұрын
You can feed the video output of a VDP into Pin 35 of another one. It is however not possible to share the same RAM. Every VDP must have its own RAM. And the maximum is 16KB.
@obsoletepowercorrupts
@obsoletepowercorrupts 2 жыл бұрын
@@DoctorVolt A TMS9918 can be connected on a breadboard so that it has no RAM and so the CPU drives the RAM for it. It is slower however, maybe that would be a (tantamount) way for two TMS9918 chips to "sort-of-share" RAM? It wouldn't quite be VRAM. Thanks for the info about the Pin 35. Is it possible, by some other mechanism, to have two TMS9918 chips produce two video outputs "stitched ogether" (instead of an overlay) so as to effectively increase screen resolution? So for example, instead of one chip having an image of 288x192 pixels, a TV could show that image directly above another chip's image so as to have 288x384?
@DoctorVolt
@DoctorVolt 2 жыл бұрын
I think that you might run into some severe timing issues if two TMS9918 share the same RAM, if the one tries to write and the other tries to read at the same time. I also cannot see a way how the two images can be stacked on the screen to get the double number of lines. I´d rather go for a more advanced chip like the V9938
@ruhrpottradio
@ruhrpottradio Ай бұрын
hallo doctor volt, ich finde dein projekt echt super und ich sehe du hast ein herz für alte RETRO COMPUTER ???! hier meine idee: Und es wäre auch sehr super wenn das sehr wenigen dumme "16 RAM VRAM" da mit einen schnellen PI PICO vielleicht "emuliert" werden könnte ??? ala eines c64 Kungfu oder gameboy flash... Sowas wie NO-Limit VRAM "Emulation" wäre da für alle alten RETRO Computer Systeme wie TI99,MSX 1,2 und das SEGA MASTER System DA super geil!!!! Besonders da so ein moderner "PI PICO" Chip kaum etwas kostet,okay plus einige handvoll level shifter chips für 30 cent... aber wir wissen ja alle ,das ein schneller DUALCORE "PI PICO" CHIP sogar dann die harte MATHE RECHNEN Arbeit als neuer SUPER FX "Co-Prozessor" für sogar 3D ,das VRAM "Doppel Buffering" und weitere sehr interessante "SUPER FX" EFFEKTE dann machen könnte...z.b. DATEN nachladen von SD karte dazu mehr eigenen PI PICO "SPI" RAM... NO LIMIT VRAM-wäre SUPER GEIL!! Besonders für mein sehr altes "RETRO" Lieblings System "Sega Master System" was da aber 32 Farben aus 64 Farben darstellen kann, wäre DASS die beste "TOP" HARDWARE Knaller IDEE!!! Auch wenn dann die beiden alten RAM Chips dann rausgenommen wie gesockelt werden müssen,ABER der Aufwand ist dann 100% wert,da aus den kleine 8 BIT SMS dann ein richtiges SNES wird!!! Sowas wie "SUPER FX VRAM " wäre auch eine super Hardware Erweiterung für alle o.g. nur 8 BIT RETRO Systeme ohne genügend "VRAM" Speicher wie auch CPU Rechnenpower.
@DoctorVolt
@DoctorVolt Ай бұрын
Die Idee klingt gut. Damit wäre vielleicht sogar Videowidergabe möglich, wenn nicht der VDP, sondern der Pi Pico selbst das emulierte DRAM beschreibt.
@ruhrpottradio
@ruhrpottradio 24 күн бұрын
@@DoctorVolt Ja, danke schön! ich würde sehr darüber freuen,wenn es endlich jemand geben würde der sowas hardware technisch umsetzen könnte! so ein "pi" chip ist mit seinen zwei kernen und hoher mhz und eingebauten 256 KB SRAM ,ja hoffentlich schnell genug ??? Und es geht hier ja nur um 320x200 bzw. 256x240 pixel ,wobei dann der "PI" das "Double Buffer" macht.und in der zwischen Zeit die aufwendige Be und Umrechnung z.b. für einfaches "MPEG 1" da wohl schaffen könnte ???
@ruhrpottradio
@ruhrpottradio 24 күн бұрын
also technisch habe ich mir dass ungefähr so vorgestellt:die alten VDP drams chips kommt raus, wie dann sockel drauf,und eine pi "adapter" Platine wird so tunen als wäre es "DRAM". Der schnelle "PI" wird dann auf die LESE oder Schreibe BYTE "ANFRAGEN" des jeweiligen "VPD" Chips dann schnell genug "beantworten".Über einen zweiten billigen "MCU" mit "SPI" der vielleicht sogar MP3 Audio dann abspielen könnte, kann sich dann die alte CPU z.b. Z80 mit den modernen "PI" dann "unterhalten" und neue PI-Funktionen per "Programm" aufrufen z.b. anzeigen von 3D Objekte, MPEG 1 Video etc..
@ruhrpottradio
@ruhrpottradio 23 күн бұрын
@@DoctorVolt ja, ich glaube der passende fachbegriff heisst "ram" oder ROM emulator ? so als bestes Beispiel PROJEKT "Pi Pico Game Boy Flash Cart" wo der hardware entwickler einen PI RP2040 dazu 3 mal Texas Instruments TXB0108 level shifters,genommen hat. Ich würde dass gleiche zwar auch nehmen aber dazu noch ein 8 oder 16 MB SPI RAM ,dazu einen SD karten sockel wie auch die alten Z80 CPU als CMOS updaten plus den atmega 32/64 als moderne "SPI" Controller,SD Karten Leser UND für den wichtigen schnellen SPI "Datenaustausch" mit den modernen "PI" als unsere neue SUPER "GPU" oder 3D "Blitter" CO-Prozzessor.
@ruhrpottradio
@ruhrpottradio 23 күн бұрын
Es ist echt sehr schade dass niemand bisher sowas gebaut hat! Denn dieser schneller "PI Video RAM Emulator" wäre ein Super universelles GFX Hardware "ADDON" auch für andere alte 8 BIT Retro Computer wie CPC,Atari XL,C64 ,sowie natürlich die vielen MSX Computer , das SEGA Mastersystem wie SEGA Mega Drive...wie natürlich als 3D "UPDATE" für ältere ISA PC-Dosen EGA/VGA Karten oder als VGA DISPLAY "Schield" für kleine Arduino-Homebrew computer... DA dann der moderne "PI" quasi unbeschränkt Video-RAM für SIE simulieren kann,wie auch die harte MATHE "rechnenleistungen" für einfaches 3D ala eines SNES SUPER "FX" CHIP so für bunte grosse Bitmaps als "SPRITES",z.b. was sehr interessant ist für alle CPC Benutzer mit den armseeligen 6845 Grafikchip! Oder warum nicht schnelle 3D Spiele ala DOOM,Wolfenstein,oder 3D Weltraum "ELITE" da auf alten 8 BIT RETRO Computer spielen ??? Ja,der "PI" kann sowie das "Video Frame Buffer" da spielen könnte für echtes MPEG1,wobei natürlich das "LIMIT" da NUR ihre eigenen "Grafikchips" dann sein werden, in der besten Pixel Auslösung und möglichen Farb ANZAHL. ich würde echte freuen ,wenn jemand endlich sowas bauen,kann um den alten retro computer ein schöne 3D GPP Upgrade zu verpassen! 😉
@lyanaducky
@lyanaducky 2 жыл бұрын
youtube algorithm hi
@d4ny3l23
@d4ny3l23 2 жыл бұрын
Hola, me gustaría colaborar.
@SolarLantern424
@SolarLantern424 Жыл бұрын
It's a shame it can't do 80 columns. Would it be possible to make a board that used this chip instead? en.wikipedia.org/wiki/Motorola_6845 Not sure about its availability but it looks interesting.
The world's worst video card?
32:47
Ben Eater
Рет қаралды 6 МЛН
Synyptas 4 | Жігіттер сынып қалды| 3 Bolim
19:27
kak budto
Рет қаралды 1,4 МЛН
Human vs Jet Engine
00:19
MrBeast
Рет қаралды 117 МЛН
My Daughter's Dumplings Are Filled With Coins #funny #cute #comedy
00:18
Funny daughter's daily life
Рет қаралды 35 МЛН
Life hack 😂 Watermelon magic box! #shorts by Leisi Crazy
00:17
Leisi Crazy
Рет қаралды 80 МЛН
My modified Ben Eater 6502 Computer PCB!
11:51
The Invent0r
Рет қаралды 41 М.
TMS9918A on Arduino
19:44
krallja
Рет қаралды 13 М.
I Hacked a Mouse into a Camera!
10:04
Doctor Volt
Рет қаралды 179 М.
I built my own graphics card
15:34
jdh
Рет қаралды 1,5 МЛН
DIY Laser Image Projector (100ft+ Range!)
20:08
Ben Makes Everything
Рет қаралды 395 М.
This 8-Bit Computer Has Two CPUs (And One Acts As A GPU!)
24:29
Noel's Retro Lab
Рет қаралды 150 М.
OLED display on a 6502 Single Board Computer using i2c #65uino
14:24
Anders Nielsen
Рет қаралды 2,8 М.
I Made My Own Computer | Let's See How It Works
7:51
3DSage
Рет қаралды 797 М.
DIY Video RAM #1 VGA Signals on a Shoestring
7:36
Slu4
Рет қаралды 12 М.
Can you build a brand new Commodore 64 from (nearly) 100% new parts?
20:49
Synyptas 4 | Жігіттер сынып қалды| 3 Bolim
19:27
kak budto
Рет қаралды 1,4 МЛН