Author Topic: VGA display switching with debouncer/multiplexer/buffer circuitry?  (Read 9118 times)

0 Members and 1 Guest are viewing this topic.

Offline analogixTopic starter

  • Frequent Contributor
  • **
  • Posts: 252
  • Country: no
I've designed a video display output which attaches to a vintage Atari ST computer and allows (passive/mechanical) switching between VGA colour, VGA monochrome and Atari monitor connectors/modes using a 8P3T slide switch.
2350675-0
Although it should work fine in theory I've been told that ideally I should add debouncing circuitry to the switch or replace it (the mechanical switch) altogether with a multiplexer IC for solid state switching.
I've also read about similar circuits that include video buffering for the H-sync/V-sync signals and a sync separator in order to improve and stabilize the signal.

My question: which specific components are we talking about, and how do I incorporate it into my existing schematic?

« Last Edit: August 25, 2024, 08:14:41 pm by analogix »
 

Offline BrianHG

  • Super Contributor
  • ***
  • Posts: 8342
  • Country: ca
    • LinkedIn
__________
Follow me for 3 Classic Fitness Playlist Songs from the '70s to 2010s, Delivered Every Other Day!
www.linkedin.com/in/brianhg-ocean-fitness www.facebook.com/profile.php?id=61573174078303 https://x.com/BHGOceanFitness
 

Online Benta

  • Super Contributor
  • ***
  • Posts: 6483
  • Country: de
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #2 on: August 25, 2024, 11:18:57 pm »
I don't see any problem in your design. The "debouncing" hooey might be relevant when dynamically switching between channels, but frankly: static switching with a slide switch is no issue at all.
 

Offline BrianHG

  • Super Contributor
  • ***
  • Posts: 8342
  • Country: ca
    • LinkedIn
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #3 on: August 25, 2024, 11:59:32 pm »
I don't see any problem in your design. The "debouncing" hooey might be relevant when dynamically switching between channels, but frankly: static switching with a slide switch is no issue at all.
So long as you do not break all the GND connections, and you are using a low video bandwidth such as 15khz to ~31khz video, a quality mechanical switch should work fine.


For the opposite of what you are doing:
     In some old VGA switch-boxes, I've measured cross-talk when having 2 different sources to 1 monitor, however, you could not see it on the monitor most likely due to the 2 video sources weren't synced at all.
__________
Follow me for 3 Classic Fitness Playlist Songs from the '70s to 2010s, Delivered Every Other Day!
www.linkedin.com/in/brianhg-ocean-fitness www.facebook.com/profile.php?id=61573174078303 https://x.com/BHGOceanFitness
 

Offline analogixTopic starter

  • Frequent Contributor
  • **
  • Posts: 252
  • Country: no
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #4 on: August 26, 2024, 11:08:28 am »
https://www.analog.com/media/en/technical-documentation/data-sheets/MAX4885.pdf

That MAX4885 looks nice for the job, but as far as I can see it only switches between two outputs (I need three).
I suppose cascading two of these chips would do the job, but if the circuit already works fine I'd rather skip the complications of redesigning things unless there's a compelling reason to add it.


I don't see any problem in your design. The "debouncing" hooey might be relevant when dynamically switching between channels, but frankly: static switching with a slide switch is no issue at all.

What do you mean by "dynamically switching" and "static switching"?
Would I need to power down the computer when switching video output modes?

I've been told that if I go for my passive/mechanical switch solution as in my schematic, (and/or buffering -sorry, can't remember which) I will cause stress to the computer's video circuitry.
Is there any truth to this? What does buffering the video signals actually do, and is it required?
Will there be any downsides to my schematic?

Quote
So long as you do not break all the GND connections, and you are using a low video bandwidth such as 15khz to ~31khz video, a quality mechanical switch should work fine.

Yes, they're around that range, more specifically:

  • "High" resolution mode (monochrome, 640x400):  V-sync 71.2 Hz, H-sync 15.75 KHz
  • "Low/medium" mode (colour, 320x200 or 640x200): V-sync 50 Hz, H-sync 35.7 KHz

As for GND connections: they should be permanently attached (except for a "mono detect" pin which forces the computer to reboot into hires monochrome mode when pulled to GND).






Offline Nominal Animal

  • Super Contributor
  • ***
  • Posts: 7441
  • Country: fi
    • My home page and email address
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #5 on: August 26, 2024, 02:21:01 pm »
I wonder if a Vishay DG4052E per pair of signals (in TSSOP-16) would work.  It is a 4:1 analog multiplexer with 300MHz+ 3dB bandwidth at 50Ω load, and Mouser sells them in singles for 1.43€ apiece.  You would need four of them (for eight signals).  You'd also need a 5V supply, but I believe it should yield superior signal quality compared to a mechanical switch.

However, I found myself looking at the very cheap TI TS5V522C VGA multiplexer, which Mouser sells for 0.81€ apiece in singles.  With two, you'd have your three inputs.  With three, you'd have three inputs and three outputs, and the ability to choose any combination of the inputs on the outputs: ABC, ACB, BAC, BCA, CAB, or CBA.  That excludes the composite output, though.  Of course, with just one more TS5V522C, you could do two composite outputs.

As I like to use microcontrollers even in designs that don't need them, I'd be tempted to use a cheap 5V microcontroller like CH552G to control the switching, and maybe use a small 0.91" (128×16) OLED module to display the configuration (turning the display off after say ten seconds).
 

Online Benta

  • Super Contributor
  • ***
  • Posts: 6483
  • Country: de
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #6 on: August 26, 2024, 05:01:06 pm »
I don't see any problem in your design. The "debouncing" hooey might be relevant when dynamically switching between channels, but frankly: static switching with a slide switch is no issue at all.

What do you mean by "dynamically switching" and "static switching"?
Would I need to power down the computer when switching video output modes?

I've been told that if I go for my passive/mechanical switch solution as in my schematic, (and/or buffering -sorry, can't remember which) I will cause stress to the computer's video circuitry.
Is there any truth to this? What does buffering the video signals actually do, and is it required?
Will there be any downsides to my schematic?


I was told by someone...

Jokes aside, by dynamic I mean that the monitors are synched up all the time so you can switch between them on a frame-to-frame basis.

I don't expect you to move the slide switch at VSYNC speed, so your switching is static, eg, once a minute or hour or second or whatever.

As for "stressing" the video outputs: you can short-circuit them if you like, they'll be OK with that.

« Last Edit: August 26, 2024, 05:24:07 pm by Benta »
 

Offline BrianHG

  • Super Contributor
  • ***
  • Posts: 8342
  • Country: ca
    • LinkedIn
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #7 on: August 26, 2024, 05:17:09 pm »
https://www.analog.com/media/en/technical-documentation/data-sheets/MAX4885.pdf

That MAX4885 looks nice for the job, but as far as I can see it only switches between two outputs (I need three).
I suppose cascading two of these chips would do the job, but if the circuit already works fine I'd rather skip the complications of redesigning things unless there's a compelling reason to add it.

Not cascade, parallel and you get 4:1, or X 2x2.
Remember, you have a disable on each chip which isolates each side from each other, IE an open circuit...

Cascading means 1 video source will go through 2 chips in series, in effect doubling the ON state resistance.  IE: 1 video port will be a bit brighter than the other 2.
« Last Edit: August 26, 2024, 05:19:14 pm by BrianHG »
__________
Follow me for 3 Classic Fitness Playlist Songs from the '70s to 2010s, Delivered Every Other Day!
www.linkedin.com/in/brianhg-ocean-fitness www.facebook.com/profile.php?id=61573174078303 https://x.com/BHGOceanFitness
 

Offline BrianHG

  • Super Contributor
  • ***
  • Posts: 8342
  • Country: ca
    • LinkedIn
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #8 on: August 26, 2024, 05:22:33 pm »
Quote
So long as you do not break all the GND connections, and you are using a low video bandwidth such as 15khz to ~31khz video, a quality mechanical switch should work fine.

Yes, they're around that range, more specifically:

  • "High" resolution mode (monochrome, 640x400):  V-sync 71.2 Hz, H-sync 15.75 KHz
  • "Low/medium" mode (colour, 320x200 or 640x200): V-sync 50 Hz, H-sync 35.7 KHz

As for GND connections: they should be permanently attached (except for a "mono detect" pin which forces the computer to reboot into hires monochrome mode when pulled to GND).

You got your 2 H-scan rates backwards and I am not sure about the 50hz Vsync...
__________
Follow me for 3 Classic Fitness Playlist Songs from the '70s to 2010s, Delivered Every Other Day!
www.linkedin.com/in/brianhg-ocean-fitness www.facebook.com/profile.php?id=61573174078303 https://x.com/BHGOceanFitness
 

Offline analogixTopic starter

  • Frequent Contributor
  • **
  • Posts: 252
  • Country: no
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #9 on: August 26, 2024, 08:12:11 pm »
You got your 2 H-scan rates backwards and I am not sure about the 50hz Vsync...

Oops! You're right about mixing the two Hsync rates.
I looked them up again (service/user manuals) and the correct specs should be:

High resolution monochrome mode: 71.2 Hz (Vsync), 35.7 KHz (Hsync)
Low/medium resolution colour modes: 50 Hz (Vsync), 15.7 KHz (Hsync)

The 50Hz Vsync in colour mode is correct (or rather it's 50 or 60 Hz depending on which country the computer was sold in).

Offline Roehrenonkel

  • Frequent Contributor
  • **
  • Posts: 278
  • Country: de
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #10 on: August 26, 2024, 08:45:36 pm »
Hi analogix,
 
the MAX499 worked just well for us (best KVM-switch) 25 years ago.
It's an amp and mux with disable, so it can be cascaded to 8-->1.
 
Good luck
 

Offline analogixTopic starter

  • Frequent Contributor
  • **
  • Posts: 252
  • Country: no
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #11 on: August 31, 2024, 08:34:35 pm »
The big question is if I actually need multiplexing circuitry for my application.
It would make construction a lot easier if I could skip them altogether, unless there's a compelling reason to use them here.
On the other hand I see that finding an 8-pole, 3-way (8P3T) slide switch proves to be challenging.

I've been reading a bit up on MUX chips -how they work and so on, and I understand that for this particular circuit I basically need one with a single input and 3 outputs, which I believe are referred to as "1:3". In other words the solid state equivalent of a 1P3T switch.



And for all 7 separate signal lines I would need 7 of those; either in a single chip or multiple chips, all controlled by the same switching signals (which I understand are logic high/low voltage levels (+5V or 0V) going to several control inputs with their combinations determining the switch positions, right?
And they would have to be able to handle Vsync rates between approx 50-73Hz and Hsync rates between approx 15-36 KHz.

« Last Edit: August 31, 2024, 08:41:38 pm by analogix »
 

Offline BrianHG

  • Super Contributor
  • ***
  • Posts: 8342
  • Country: ca
    • LinkedIn
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #12 on: August 31, 2024, 11:48:31 pm »
The big question is if I actually need multiplexing circuitry for my application.
It would make construction a lot easier if I could skip them altogether, unless there's a compelling reason to use them here.
On the other hand I see that finding an 8-pole, 3-way (8P3T) slide switch proves to be challenging.

I've been reading a bit up on MUX chips -how they work and so on, and I understand that for this particular circuit I basically need one with a single input and 3 outputs, which I believe are referred to as "1:3". In other words the solid state equivalent of a 1P3T switch.

(Attachment Link)

And for all 7 separate signal lines I would need 7 of those; either in a single chip or multiple chips, all controlled by the same switching signals (which I understand are logic high/low voltage levels (+5V or 0V) going to several control inputs with their combinations determining the switch positions, right?
And they would have to be able to handle Vsync rates between approx 50-73Hz and Hsync rates between approx 15-36 KHz.

(Attachment Link)
1P:4T, 2 in sets in 1 chip exist like the 74HC4052.
However, unlike the MAX4885 chip I mentioned where you would use 2 of them, the MAX4885 has an ON resistance of 4 ohms and only requires a single 5v supply while a 74HC4052 has 60ohm on resistance with a +/- 5v supply.  (MAX4885 has a built in negative power supply generator...)
« Last Edit: August 31, 2024, 11:50:47 pm by BrianHG »
__________
Follow me for 3 Classic Fitness Playlist Songs from the '70s to 2010s, Delivered Every Other Day!
www.linkedin.com/in/brianhg-ocean-fitness www.facebook.com/profile.php?id=61573174078303 https://x.com/BHGOceanFitness
 

Offline analogixTopic starter

  • Frequent Contributor
  • **
  • Posts: 252
  • Country: no
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #13 on: September 05, 2024, 06:02:07 am »
1P:4T, 2 in sets in 1 chip exist like the 74HC4052.
However, unlike the MAX4885 chip I mentioned where you would use 2 of them, the MAX4885 has an ON resistance of 4 ohms and only requires a single 5v supply while a 74HC4052 has 60ohm on resistance with a +/- 5v supply.  (MAX4885 has a built in negative power supply generator...)

I see what you mean.
Unfortunately I don't have any experience/tools for mounting SMD type components, so if possible I'd like to stick with DIL chips.
And to answer a previous question of mine myself, regarding the need for a MUX-solution or not: I haven't been able so far to find a mechanical 7-pole (or 8 pole), 3-way slide switch. Rotary switches with that many poles may prove a different matter, but isn't what I want for this application, so I suppose going that route (although simpler to incrorporate into my schematic) isn't possible.

I must admit this (multiplexers) is a bit over my head, but I've tried to study the datasheets.
So, looking at the 74HC4052 for starters I understand this much:
It's got 8 in/out channels, like you said: 2 switches in one chip. Since they are labelled "In/out", does that mean they're all freely assignable to be used as either in or outs? How is that done? I couldn't find anything in the datasheet.


As for the actual switching, I understand this is done with a combination of logic high and low voltages to the pins marked S0 and S1, but the actual results make no sense to me. I just want one input and a choice of routing it to one of 3 outputs. And 7 of those (7 signal lines).
I suppose a 2-pole, 3-way slide switch could be wired up for the correct combination of high/low signals to the chip, and with multiple 74HC4052 chips (4 chips meaning 8 separate switches) I'd connect each chip's S0 and S1 lines to the same places on the switch (hence 8 switches being synchronized with one another).
« Last Edit: September 05, 2024, 02:52:01 pm by analogix »
 

Offline BrianHG

  • Super Contributor
  • ***
  • Posts: 8342
  • Country: ca
    • LinkedIn
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #14 on: September 05, 2024, 07:33:54 pm »
Yes, the connection between the 'com a/b' and 'a# / b#' when turned on is equivalent to being a 60 ohm resistor.  Like your mechanical switch with a series 60 ohm resistor in series on the common wiper.  The signal can move both ways like it would through a 60 ohm resistor.  For the unconnected channels, they are like a gigaohm resistor, so, basically an open circuit.

You appear to understand how to use the 74HC4052.
There exist equivalents which have a superior 'on' resistance.

Here is a SOP-10 package 4:1 analog mux with 2.35 ohm on resistance: MAX4634EUB
https://www.mouser.com/ProductDetail/Analog-Devices-Maxim-Integrated/MAX4634EUB%2b?qs=sGAEpiMZZMutXGli8Ay4kAk%2FWsVShuMFVwY8YeI%2FTgA%3D

Cheaper TI equivalent: TMUX1104  (Same specs as the Maxim part)
https://www.mouser.com/ProductDetail/Texas-Instruments/TMUX1104DGSR?qs=PqoDHHvF64%2FGMPQ%252BUVRygg%3D%3D

However, the allowable analog switch IO voltage range is between 0  and 5v.  If the AtariST video is like the Amiga video output, then it will be fine.  (The other ICs allow for -5v through +5v)


There also exist a 0.8ohm on resistance part, but, the max IO voltage is 4v, not 5v.
« Last Edit: September 05, 2024, 07:52:59 pm by BrianHG »
__________
Follow me for 3 Classic Fitness Playlist Songs from the '70s to 2010s, Delivered Every Other Day!
www.linkedin.com/in/brianhg-ocean-fitness www.facebook.com/profile.php?id=61573174078303 https://x.com/BHGOceanFitness
 

Offline analogixTopic starter

  • Frequent Contributor
  • **
  • Posts: 252
  • Country: no
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #15 on: September 06, 2024, 07:19:47 pm »
Yes, the connection between the 'com a/b' and 'a# / b#' when turned on is equivalent to being a 60 ohm resistor.  Like your mechanical switch with a series 60 ohm resistor in series on the common wiper.  The signal can move both ways like it would through a 60 ohm resistor.  For the unconnected channels, they are like a gigaohm resistor, so, basically an open circuit.

Ah! I totally missed the "COM" pins  :palm: I think I understand it a little better now.
So the MUX chip (74HC4052 in this case) basically works as a two-pole, 4-way switch, like this?


As for the actual switching I see that I also missed the EE pin. I understand this is for disabling the two switches altogether, right?
Since I won't be doing that I think I can just connect EE to GND permanently (logic low).


If I'm not mistaken I understand the rest of the logic as follows:
In the first option (red highlight) with low/low switch A connects between COM-A and A0, and likewise COM-B connects to B0.
So for my use I need a 3-way switch and therefore only need 3 of 4 possible switching-options (and can skip the "none" option at the end which doesn't connect either COM pin to anywhere).

But another question arises. Looking at my schematic I have unconnected pins to my 7 switches. Is it OK to leave them unconnected? I've learnt that logic signals should never "float", but have a definite +5V or 0V connection. But perhaps this doesn't apply here?



Quote
You appear to understand how to use the 74HC4052.
There exist equivalents which have a superior 'on' resistance.

Yes, I think I understand the basic concept a little better now. Do other MUX chips work much in the same way?



Quote
Here is a SOP-10 package 4:1 analog mux with 2.35 ohm on resistance: MAX4634EUB
Cheaper TI equivalent: TMUX1104  (Same specs as the Maxim part)

However, the allowable analog switch IO voltage range is between 0  and 5v.  If the AtariST video is like the Amiga video output, then it will be fine.  (The other ICs allow for -5v through +5v)

I think they're similar. I believe its output level is 1V peak-to-peak.
But I'm not sure about the "Mono detect" line which is pulled to GND in order to enable that mode (monochrome hires output), while having it disconnected the computer goes to colour low/medium resolution mode. I imagine it being +5V or less, but I need to do some research to be sure.

Quote
There also exist a 0.8ohm on resistance part, but, the max IO voltage is 4v, not 5v.

Wow! Hugely better than the 60 Ohms of the 74HC4052. Still, will there be noticeable signal degradation with 60 Ohms?
« Last Edit: September 06, 2024, 07:22:11 pm by analogix »
 

Offline BrianHG

  • Super Contributor
  • ***
  • Posts: 8342
  • Country: ca
    • LinkedIn
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #16 on: September 06, 2024, 09:09:32 pm »
Ah! I totally missed the "COM" pins  :palm: I think I understand it a little better now.
So the MUX chip (74HC4052 in this case) basically works as a two-pole, 4-way switch, like this?

Yes, it is a 4 position switch with 2 control input pins.
Remember, the device operates exactly like a mechanical 4:1 switch.  (Actually 5:1 if you count the EE as a switch position with nothing connected...)
The signals travel in both directions just like a mechanical switch.
You may have unconnected IO pins just like a mechanical switch.
The 2 most important points is that:
1. For the 74HC4052, the electricity on any of the switches IO pins cannot go below the Vee voltage, or go above the VCC voltage, otherwise, you will blow the chip.
2. The quality of the contacts of these switches are their on resistance, in the case of the 74HC4052, it is 60ohms.  It is like your switch is a really long resistive wire in circuit.

Wow! Hugely better than the 60 Ohms of the 74HC4052. Still, will there be noticeable signal degradation with 60 Ohms?

Remember, for the analog video mode, the monitor's analog input has a resistor of 75ohm to GND.
This means, if your analog switch when on has a 75 ohm series resistance, then the signal the monitor would get would be half bright because of the monitor's 75ohm load.  (This is an example, there is actually already another 75ohm series resistor in your Atari ST's video DAC output as well, so the loss is actually less...) Since the 74HC4052 has a 60ohm series resistance, the final picture would be a little brighter than 50%.  If the analog switch has a perfect 0 ohm short when on, then the monitor's brightness would be perfect.

So, for my recommended TI part#, TMUX1104, it has a <2ohm short when turned on if you powered it with 5v.  At 2 ohm, you will not see the ~1.3% drop in overall contrast (Assuming the Atari ST analog output has the standard 75ohm series resistor) in the image for analog picture modes (digital would have 0 effect).  If you powered the TMUX1104 at the absolute max 6v, it will approach ~1 ohm.

This is my PCB recommendation for a hand-wired switch-box solution:

Make a tiny 10x10cm 2 layer board with 1x TMUX1104, 1 or 2 decoupling caps, and a common through-hole connector on 1 side with GND, 5v, S0, S1, ENA.  All of your 8 PCBs for the 8 poles will have these ports all wired in parallel.  Use something like long gold standoff pins or thick single strand copper wire through all 5 pins of the 8 boards in parallel.  Actually, add a second GND pin.

On the other side of the PCB, make a 4 pin connector, COMMON (IE: Switch wiper), Position 1, Position 2, Position 3, Position 4.  Space these guys out for wiring.  Actually, add 2 additional GND pins so you may solder the 8 boards with the standoffs on both sides just to make it more sturdy.

10cmX10cm boards for first time buyers from a Chinese costs around 5$ for 10pcs delivery next day.
It is a cheap as you will get.  (You may be able to fit 2 or 4 TMUX1104 on a 10x10cm pcb.)

You will need to supply the MUXs with 5v.  A 78L05 and 2 caps and 9-24v adapter will do, or a quality USB 5v supply.

Quote
Yes, I think I understand the basic concept a little better now. Do other MUX chips work much in the same way?
For analog capable MUXs, yes they all work in a similar fashion.

For digital MUXs, they only discern between digital high and digital low, plus, they only transfer the signal in 1 direction.  Most digital MUXs go from the multiple input channels to a 1 common output.
« Last Edit: September 06, 2024, 10:39:09 pm by BrianHG »
__________
Follow me for 3 Classic Fitness Playlist Songs from the '70s to 2010s, Delivered Every Other Day!
www.linkedin.com/in/brianhg-ocean-fitness www.facebook.com/profile.php?id=61573174078303 https://x.com/BHGOceanFitness
 

Offline analogixTopic starter

  • Frequent Contributor
  • **
  • Posts: 252
  • Country: no
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #17 on: September 10, 2024, 11:31:57 am »
2. The quality of the contacts of these switches are their on resistance, in the case of the 74HC4052, it is 60ohms.  It is like your switch is a really long resistive wire in circuit.

Good to know!
And thanks for all the other explanations.

So basically I need to check any MUX's switch resistance, and compensate (if possible) for that in my specific application?
In this specific example: the Atari ST video output is 1V P-P while the official VGA specs say 0.7V P-P, so regardless of MUX or not I have to add resistors to the R, G and B output lines to make it more compatible with the 0.7V standard.
So with the MUX switch resistance I'll have to subtract that (60 Ohms for the 74HC4052) from the proposed resistor value I guess.

Of course, if there's no resistor to be added to the circuit to begin with there's a problem with a MUX switch's high resistance.
Is this an issue only with MUX chips made to handle analog signals?

Quote
So, for my recommended TI part#, TMUX1104, it has a <2ohm short when turned on if you powered it with 5v.  At 2 ohm, you will not see the ~1.3% drop in overall contrast (Assuming the Atari ST analog output has the standard 75ohm series resistor) in the image for analog picture modes (digital would have 0 effect).  If you powered the TMUX1104 at the absolute max 6v, it will approach ~1 ohm.

I understand. Seems like a better choice (according to some videos it appears that hand-soldering SMD chips with basic gear isn't as difficult as I first thought, so maybe I shouldn't put DIL chips in the criteria for which MUX to go for, but rather specs and cost  :)

Looking into the datasheets I found another one from TI called TMUX1109 which more or less appears to be more or less the same as the 1104, but with two switches instead of one! This would effectively halve the amount of MUX chips I need for this project.

OK, I've looked some further into all of this, so let me see if I understand the basic principles, here shown with the TMUX1109.
First, here's how I understand how one MUX's internal switches work, and how they're controlled with a 3-position slide switch:



The slide-switch connections are based on the datasheet's truth table:



Finally, for my specific application, here's how I propose setting up four TMUX1109 chips for a total of 8 individual switches (I'll be using 7), all controlled simultaneously with the 3-position slide switch:




Quote
This is my PCB recommendation for a hand-wired switch-box solution:

Good suggestion! And I didin't know that about cheap PCBs when ordering for the first time -will come in handy when I do get this and my other projects ready for ordering  :)

For this project I will be mounting it inside a new enclosure for the computer, so I don't need to worry about the size (within reason) of the PCB/PCBs.
I'm aiming for a single PCB which mounts on the rear panel of the enclosure with cutouts for the connectors and slide-switch. There will be a single cable that connects internally between the original Atari ST video output to this board (which includes a +12V line). I haven't looked that much into the power part yet, but if the +12V line doesn't suffice I could just connect it to the computer's power supply.



Quote
Quote
Yes, I think I understand the basic concept a little better now. Do other MUX chips work much in the same way?
For analog capable MUXs, yes they all work in a similar fashion.

For digital MUXs, they only discern between digital high and digital low, plus, they only transfer the signal in 1 direction.  Most digital MUXs go from the multiple input channels to a 1 common output.

Another project for this computer (Atari ST) is to switch between multiple peripherals attached to the serial (RS-232) port and likewise for the cartridge port.
I believe these ports both carry digital signals, and lots of them (40 pins for the cartridge port (around 37 unique signals) and 25 pins for the serial port (around 9 unique signals if I'm not mistaken) ).
What should I look for in order to find MUX chips suitable for switching 37 or 9 digital signal-lines at once?
« Last Edit: September 10, 2024, 09:52:30 pm by analogix »
 

Offline analogixTopic starter

  • Frequent Contributor
  • **
  • Posts: 252
  • Country: no
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #18 on: September 15, 2024, 11:37:46 am »
By the way, the UbeSwitch is a similar project as mine except it replaces the Atari ST video output connector (DIN13) with a VGA multisync output connector (HD15), and onboard logic which uses a momentary pushbutton to select the mode (monochrome or colour) and memorize it. It uses a TI TS5V330 MUX.



With the schematics freely available I've studied its design: the MUX contains 4x two-way switches, but the fundamental difference to mine is that it has a VGA output (HD15 connector) which replaces the original Atari video output while in my design I am adding a VGA output in addition to the original Atari video output.



So, wanting a "fool-proof" design I believe I need to isolate the common signals from each of the two connectors (i.e. a given signal is only available at one connector at a time), so that in case both an Atari monitor and a VGA monitor is attached they won't mess anything up.

Out of the 13 pins of the Atari video output, these are the ones which I need for the VGA connector (and thus need to switch):
  • Red
  • Green
  • Blue
  • Hsync
  • Vsync
  • Monochrome detect (sets the computer to 'monochrome mode' when pulled low (GND), when disconnected the computer boots into 'colour mode')
  • Monochrome (output signal in 'monochrome mode' instead of the R, G and B lines)

The rest of the 13 signals will go directly to the new DIN13 connector as they're not shared with the VGA connector.
GND signals will all be tied together though.


So in summary I probably need 7 signals to be switched for this particular setup (correct me if I'm wrong -if any of the signals above can go to two display outputs without messing things up), and it appears hard to find a MUX which has 7 (or more) channels and 3 (or more) switch positions, and also with very low switch resistance. They're (according to my findings) either with many channels (i.e. 8 channels) but with fewer switch positions (i.e. 2), or... less channels (i.e. 2) but with more switch positions (i.e. 4).
Unless someone can point me to a MUX which 'can do it all' I likely need to use several of them.
I see two possibilies with combinations of multiple chips:

1) MUX chips with many switch positions (i.e. 3 or 4):
8 pcs. TMUX1104 (1 switch in each chips), or 4 pcs. TMUX 1109, all connected to the same logic switching.

2) MUX chips with many switch channels (i.e. 8 ):
2 MUX chips which switch the signals into two 'groups' each, like here:

« Last Edit: September 15, 2024, 11:43:39 am by analogix »
 

Offline BrianHG

  • Super Contributor
  • ***
  • Posts: 8342
  • Country: ca
    • LinkedIn
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #19 on: September 15, 2024, 11:56:39 am »
Like this:

This way, you only get 3 ohm impedance instead of using 2 switches in series where you get 6 ohm impedance.

__________
Follow me for 3 Classic Fitness Playlist Songs from the '70s to 2010s, Delivered Every Other Day!
www.linkedin.com/in/brianhg-ocean-fitness www.facebook.com/profile.php?id=61573174078303 https://x.com/BHGOceanFitness
 
The following users thanked this post: analogix

Offline BrianHG

  • Super Contributor
  • ***
  • Posts: 8342
  • Country: ca
    • LinkedIn
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #20 on: September 16, 2024, 08:52:04 pm »
Remember when wiring it my way, use the Enable pin on each IC, and on the second IC with the switch it will be enabled with the switch selection going high or low.
__________
Follow me for 3 Classic Fitness Playlist Songs from the '70s to 2010s, Delivered Every Other Day!
www.linkedin.com/in/brianhg-ocean-fitness www.facebook.com/profile.php?id=61573174078303 https://x.com/BHGOceanFitness
 
The following users thanked this post: analogix

Offline analogixTopic starter

  • Frequent Contributor
  • **
  • Posts: 252
  • Country: no
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #21 on: September 17, 2024, 06:13:03 pm »
Like this:
This way, you only get 3 ohm impedance instead of using 2 switches in series where you get 6 ohm impedance.

Oops! I missed that one. And it makes perfect sense of course
Thanks for pointing it out.

Quote
Remember when wiring it my way, use the Enable pin on each IC, and on the second IC with the switch it will be enabled with the switch selection going high or low.

I had completely set aside the "enable" feature, thinking it had no use for my design, but having re-read the whole thread again plus your comments here I think I get it: namely to disable one of the the MUX chips in order to isolate it from the other!
That, along with selecting the switch groups of each MUX appears to do the trick.

Let me see if I've got it right here....
In the following illustrations the thick yellow arrows represent the 7 signal lines which need switching and isolating between the two video outputs.
There's a mechanical switch (green) at the bottom where the user selects the video mode.
The MAX4885 which you initially suggested seems to be an appropriate choice (8 signal channels, 2-way switching, low switch resistance and currently available).
OK, so for the 3 mechanical slide-switch modes:


'ATARI' mode:
Here, MUX2 is disabled (to disconnect it completely from MUX1).
The original Atari video output is passed on to the new Atari DIN13 output. MUX1 is only needed to isolate the signals from the rest of the circuit (i.e. enable/disable the MUX), so I'm hard-wiring the switch selection logic as I only ever need one switch setting and thus can save on input pins for the mechanical switch.



'VGA-mono' mode:
Now MUX1 is disabled, and MUX2's 'group A' switches are chosen for the VGA connector's monochrome mode



'VGA-colour' mode:
As in the previous VGA mode, MUX1 is disabled, but here the MUX2 'group B' switches are chosen for the VGA colour mode.


Have I understood it correctly?
If my aim is to save room on the PCB I think the above solution (two MAX4885 chips) might be a good way to do it, right?
But I could also do it with MUX chips having 3 or more switch positions, (and do away with the two "groups" of MUXes and the need for disabling one or the other), but that would probably mean using more PCB space (eight TMUX1104 or four TMUX1109).

the MAX4885 appears to have good specs (though a little higher switch resistance than the TMUX1104/1109 chips), but I see it has Hsync/Vsync buffering (which I understand is basically "signal conditioning) which must be a good thing. Also, I suppose having less chips to deal with probably demands less PCB design knowledge to route the traces correctly in order to avoid interference, signal degredation etc. as opposed to having many signals taken care of inside the chips themselves.

One question which the datasheet doesn't explain very well: what are DDC signals?
Two of the switches handle those, and I'm hoping these aren't dedicated switches for some specific signal, but can be used for anything?
I hope they can be used for the MONO DETECT and MONOCHROME signal lines from the Atari video output.
« Last Edit: September 18, 2024, 10:12:43 pm by analogix »
 

Offline BrianHG

  • Super Contributor
  • ***
  • Posts: 8342
  • Country: ca
    • LinkedIn
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #22 on: September 17, 2024, 06:36:47 pm »
OK, so long as your switches are wired correctly, and those mono/color resistors are correct, you should be good to go.

For MUX1, you do not need the A/B wiring, just the enable and hard-wire the switch into position B unless you want an extra position #4.

As for controlling the muxes with a switch, this is OK.  If you are worried about MUX1 and MUX2 being on at the same time for an instant, use a pull-up resistor to default disable them and use the switch contacts to pull them down to the GND.

Use a 3 position switch with 2 poles, 1 pole for the 2 different enables and the other for the A/B on MUX2.

The other method to insure that both MUXs wont get confused is to use a 74HC00 quad nand gate, 1 as an inverter an the other gates to select A/B for mus 2 where you may now has 2 wire control if you like it that way.  (Simple logic AND/NAND selection)

I assume you will use a 78L05 to convert the atari +12v to 5v for the MUXs.
« Last Edit: September 17, 2024, 06:44:11 pm by BrianHG »
__________
Follow me for 3 Classic Fitness Playlist Songs from the '70s to 2010s, Delivered Every Other Day!
www.linkedin.com/in/brianhg-ocean-fitness www.facebook.com/profile.php?id=61573174078303 https://x.com/BHGOceanFitness
 
The following users thanked this post: analogix

Offline analogixTopic starter

  • Frequent Contributor
  • **
  • Posts: 252
  • Country: no
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #23 on: September 19, 2024, 09:13:07 pm »
OK, so long as your switches are wired correctly, and those mono/color resistors are correct, you should be good to go.

Thanks for checking  :)
Yes, I need to go through the rest of the wiring again to be sure.

Quote
For MUX1, you do not need the A/B wiring, just the enable and hard-wire the switch into position B unless you want an extra position #4.

Yes, this is what I figured out after you reminded me of the "disable" option, and included that in my diagrams.
I could probably use a 8-channel, 1-way MUX, but there don't seem to be many 8 channel ones to choose between, so I'll just go for the 2-way chip (MAX4885). Maybe add small traces and through-holes on the PCB for the unused switches in case I find a need for them.

Quote
As for controlling the muxes with a switch, this is OK.  If you are worried about MUX1 and MUX2 being on at the same time for an instant, use a pull-up resistor to default disable them and use the switch contacts to pull them down to the GND.
Use a 3 position switch with 2 poles, 1 pole for the 2 different enables and the other for the A/B on MUX2.

I'm not sure what you mean, but something like this, and likewise for the other MUX?



Quote
The other method to insure that both MUXs wont get confused is to use a 74HC00 quad nand gate, 1 as an inverter an the other gates to select A/B for mus 2 where you may now has 2 wire control if you like it that way.  (Simple logic AND/NAND selection)

This sounds like a more streamlined method, but I will have to study this a bit more as it's a little over my head.


Quote
I assume you will use a 78L05 to convert the atari +12v to 5v for the MUXs.

Good point! It might be safer if I don't touch the +12V pin of the DIN13 connector (Atari video output) and connect this board directly to the power supply's +5V line. Possibly adding a resistor to limit the current?
That way I won't risk messing things up if an attached Atari monitor needs this +12V line for something, leaving the "new" DIN13 connector to be more or less identical to the original DIN13 output.
« Last Edit: September 19, 2024, 09:47:38 pm by analogix »
 

Offline BrianHG

  • Super Contributor
  • ***
  • Posts: 8342
  • Country: ca
    • LinkedIn
Re: VGA display switching with debouncer/multiplexer/buffer circuitry?
« Reply #24 on: September 19, 2024, 09:58:58 pm »
Yup, you are AOK with the pull-up resistor and a switch shorting the enable to GND.

Dont worry about the 74HC00, just keep it simple.

Yes, do use a 78L05 or equivalent.

A 78L05 will take in anywhere from 7.5v to 28v on it's Vin pin.
Tie it's GND pin to GND.
It's Vout pin will be a 5v supply.
Add 2x 0.1uf caps to the Vin and Vout pins to GND.

A 78L05 has a built in current limiter of 100ma, so you will be safe.

It's available in TO-92 3 pin transistor looking type through-hole package, or in an SO-8 pin ic package.
7805 can be used as well, just that they can deliver up to 1amp.
« Last Edit: September 20, 2024, 12:51:46 am by BrianHG »
__________
Follow me for 3 Classic Fitness Playlist Songs from the '70s to 2010s, Delivered Every Other Day!
www.linkedin.com/in/brianhg-ocean-fitness www.facebook.com/profile.php?id=61573174078303 https://x.com/BHGOceanFitness
 
The following users thanked this post: analogix


Share me

Digg  Facebook  SlashDot  Delicious  Technorati  Twitter  Google  Yahoo
Smf