• Updated 2023-07-12: Hello, Guest! Welcome back, and be sure to check out this follow-up post about our outage a week or so ago.

Mac-to-VGA monitor adapter struggles

bigmessowires

Well-known member
Wow, thanks! I am still confused about the sync though. After reading through the info on the 6-switch adapter Github, I see how manipulating the sense pins in various ways could be used to ID different types of monitors, so the Mac knows what signal to generate. An adapter can fool the Mac into thinking a particular size of fixed-resolution monitor is present.

But it still seems like the sync method will be whatever's normal for the size/type of monitor that's indicated by the sense ID, and there's no way to change that. At least in the case of the 6-switch adapter, HSYNC and VSYNC are both connected straight through to the VGA side, and CSYNC isn't connected at all. The 10-switch SABRE adapter you've analyzed attempts to permit some remapping, but it's not actually changing the sync signals, just controlling which pins they get mapped to. If the Mac is outputting sync on green, but the monitor can't handle that, there's nothing the adapter can do to help. If the Mac is outtputting composite sync, the adapter can optionally map it to the HSYNC pin (switch 5) but I don't really see how that helps things. Nothing is going to split the composite sync back into separate hsync and vsync signals.

In another thread you mentioned something about the 14 setting only working with your monitor setup because of sync on green, or proving that the IIci does sync on green, but I'm not sure what you meant.

Anyway, this is a very complicated topic! But my takeaway is this: these VGA adapters are not signal converters. All they're really doing is configuring the sense lines to fool the Mac into thinking a particular type of monitor is present. But if your PC-type multisync monitor can't handle that video signal format (either because of the resolution, scan or refresh rate, or sync method) then there's not much the adapter can do to help. Bottom line: you should probably blame the monitor and not the adapter.
 

NJRoadfan

Well-known member
I never tried to take it apart, but I sort of suspect my Belkin F3H1381 (rotory switch revision) might have a sync seperater chip in it. The manual doesn't state you need a monitor that supports SoG or composite sync to use it with various Macintosh models.


Problem is, I don't seem how something like a LM1881 would be powered, unless the sense lines put out enough juice to vampire the power. Some DB-15 configurations (Apple IIgs) do have power present on one of the pins, but I don't know if any Macs do.

VGA was always a standard that used seperate dedicated horizontal and vertical sync lines. It was always a bonus if a monitor supported SoG or composite sync (usually on the H-sync pin).
 

dougg3

Well-known member
If the Mac is outtputting composite sync, the adapter can optionally map it to the HSYNC pin (switch 5) but I don't really see how that helps things. Nothing is going to split the composite sync back into separate hsync and vsync signals.

It does seem like these cheap DIP switch adapters are mostly just sense ID choosers and dumb signal mappers. I'm also struggling to understand the purpose of being able to map the composite sync signal (switch 5). I think NJRoadfan is on the right track -- maybe it just allows compatibility with certain special VGA monitors that support composite sync on the HSYNC pin?

I never tried to take it apart, but I sort of suspect my Belkin F3H1381 (rotory switch revision) might have a sync seperater chip in it. The manual doesn't state you need a monitor that supports SoG or composite sync to use it with various Macintosh models.

I would love to take apart a DIP adapter to confirm too. A sync separator would definitely go a long way toward better compatibility...

In another thread you mentioned something about the 14 setting only working with your monitor setup because of sync on green, or proving that the IIci does sync on green, but I'm not sure what you meant.

Yeah -- I was trying to help figure out how to possibly get your IIci working with those monitors, or maybe get to the bottom of why they don't work with it, but it's clear you've discovered they likely just aren't compatible with the weird timings. I ended up going off on a tangent about the IIci's video output format instead, mostly for my own amusement. This probably isn't really relevant to anything anymore, but I'll still explain my logic in detail here for future reference:
  • I have an old crappy Rosewill LCD monitor that accepts my IIci's video signal with the DIP switch combination "14" on my 10-switch adapter. Phipli also confirms the same combination works on his ViewSonic.
  • My adapter, with no switches turned on, only passes through R, G, B, and ground.
  • Turning on switches 1 and 4 only accomplishes one extra thing: grounding ID.0 -- which chooses the "12 inch B&W/13 inch RGB monitor, 640x480 at 66.67 Hz" mode.
  • With none of switches 5-7 being turned on, none of the sync signals are being passed through from the DB-15 side to the VGA side.
  • Therefore I have to conclude that the IIci must be including sync info in one or more of the color channels. Otherwise the monitor would have no way of figuring it out. There are no other signals being passed through.
Also it looks like the IIci dev note (Table 5-2) points out that it doesn't even drive the HSYNC and VSYNC signals in its 640x480 mode. This is probably why so many references/people online say that the IIci requires a sync-on-green-compatible monitor. That's not entirely accurate, but here's what I think the final compatibility list looks like:
  • Use a DB-15 monitor that supports the weird 66.67 Hz timing and the composite sync signal directly (e.g. Apple 13" RGB)
  • Use a VGA monitor that supports the weird 66.67 Hz timing, and one of these 4 possibilities for sync:
    • Use a fancy adapter (if one exists) that has a sync separator built in and splits the composite sync signal to the standard VGA HSYNC and VSYNC signals, or...
    • The monitor supports receiving composite sync on the HSYNC pin, or...
    • Use a fancy adapter (if one exists) that can create VSYNC and HSYNC signals out of the green channel's sync info, or...
    • The monitor supports sync on green.
I think I can speak for us all when I say thank goodness Apple started supporting more VGA-compatible timings and sync signals after the IIci and IIsi.
 

Melkhior

Well-known member
It does seem like these cheap DIP switch adapters are mostly just sense ID choosers and dumb signal mappers
It's all that was needed... Sync-on-green wasn't so uncommon back then. It might still be in the hardware, even if it's not in the documentation...

I think I can speak for us all when I say thank goodness Apple started supporting more VGA-compatible timings and sync signals after the IIci and IIsi.
Agreed. But the signal they output is not that problematic in my experience, though it seems that differs from others. My homemade VGA adapter connects directly R/G/B/HS/VS and has switches for just the sense modes (equivalent to switch 1, 2, 3, 4 and 8, 9 in @dougg3 post). And yet it let my IIci output a picture to my IIyama ProLite E2473HS, a 'reasonably' modern Full HD LCD...

I suspect theses days, VGA interfaces are implemented by some sort of ADC for VGA that output something easier to understand by the digital-only display logic, something like an AD9983A. Those may or may not support SoG, but the AD9983A does; so do some of its siblings. BTW, add an ADV7513 HDMI transmitter, and you got yourself a VGA-to-HDMI w/ sync-on-green support (e.g. this article ).
 

Phipli

Well-known member
Use a fancy adapter (if one exists) that has a sync separator built in and splits the composite sync signal to the standard VGA HSYNC and VSYNC signals, or...
We tell people to use a ten switch because they can split and combine sync. That's what I understood.
 

bigmessowires

Well-known member
I'm also struggling to understand the purpose of being able to map the composite sync signal (switch 5). I think NJRoadfan is on the right track -- maybe it just allows compatibility with certain special VGA monitors that support composite sync on the HSYNC pin?
Yes, I think some monitors will accept CSYNC on the HSYNC input.
A sync separator would definitely go a long way toward better compatibility...
In an old thread here @NJRoadfan mentions that some adapters do have a sync separator built in, including a particular Belkin model (but the link is dead). There's also the LM1881 which could maybe be used to do it.
  • With none of switches 5-7 being turned on, none of the sync signals are being passed through from the DB-15 side to the VGA side.
  • Therefore I have to conclude that the IIci must be including sync info in one or more of the color channels.
Hmm, that's a really good point. But I'm still surprised the IIsi developer note has a long and detailed discussion of the video hardware and never mentions sync on green anywhere. In fact, it seems very clear that the standard 13" Apple RGB mode using composite sync.

Maybe it outputs composite sync and sync on green? It might be time to hook up an oscilloscope and end this mystery once and for all.

I'm no monitor expert, but after reading some LCD monitor spec sheets and thinking about it more, I don't believe the 67 Hz refresh rate is a problem. There's no analog timing circuit that must be matched like in a CRT. Most of the LCD monitor spec sheets say something like 57-75Hz refresh rate. So if the refresh rate isn't the problem, it must be the sync.
We tell people to use a ten switch because they can split and combine sync. That's what I understood.
That doesn't seem to be true for the 10-switch sample that @dougg3 mapped out. Maybe for other brands.

So... my personal computer and monitor situation is resolved for now, but my curiosity over this topic is still definitely high. Does the standard 13" Apple RGB mode use composite sync, or sync on green, or both? Is it the same for all Mac models and video cards, or do only some models like IIci and IIsi output sync on green?

I think I'd like to try designing a new MacVGA adapter similar to the 6-switch, but with support for composite sync mapping and with a sync separator built in. I don't think the LM1881 is the right chip though. It's designed to take a composite video input (not composite sync input) and it extracts the vertical sync but not the horizontal sync. I'm also not sure what video timings it supports - if it's specific to NTSC/PAL or if it also works for 640x480, 832x624, etc. And does it work for all the variations of positive and negative sync found in various resolutions/modes. Also I think this would only be useful if the IIci/IIsi output composite sync, since I don't know if the chip could handle sync on green. Maybe it could, since sync on green should be basically the same as composite video without any red or blue info.

Somewhere I have seen sync separators other than the LM1881 which do output HSYNC as well as VSYNC. The LMH1981 is one that should work, but it's not cheap. Alternatively there are circuit designs using latches and timers to do the hsync and vsync separation, like this one. But I assume the timers need to be specific to the video mode and scan rates used, and I'm not sure how it could be made adjustable or automatic.

Also in 2023, I feel like this is a problem you could throw a $0.70 RP2040 at and solve in software. The relevant signals are only kHz-range speed and should be well within the capability of software processing.

Who wants to collaborate on a new project? :)
 

Phipli

Well-known member
That doesn't seem to be true for the 10-switch sample that @dougg3 mapped out. Maybe for other brands.
But, surely just passing through all the syncs would be the answer if what dougg3 was saying was true?

The adapter does something with the syncs, and turning them off is pointless?

This would make a 10 switch less useful, while in fact, they're the only way to get the earliest Apple colour cards to work on newer monitors.
 

bigmessowires

Well-known member
The adapter does something with the syncs, and turning them off is pointless?

Actually it doesn't do anything with the syncs. Look at the mapping that Doug posted. The only interesting feature is an option to map CSYNC to the HSYNC pin. Turning off HSYNC and VSYNC would make sense if sync on green is used.

I don't think the LM1881 is the right chip though. It's designed to take a composite video input (not composite sync input) and it extracts the vertical sync but not the horizontal sync.
There's a simple circuit shown at https://www.epanorama.net/documents/vga2rgb/vgamonitor.html that post-processes the LM1881 signal to get HSYNC. It only needs a NAND and an AND. It looks simple enough, except I think it would have nanosecond-scale glitches due to the propagation delays through the combinatorial logic.
 

Phipli

Well-known member
Turning off HSYNC and VSYNC would make sense if sync on green is used.
But it wouldn't - stripping sync on green might because it tints the screen on some monitors, but that's the complex one.

Outputting fewer types of sync would just make fewer monitors work? They're on separate pins, there is no reason to remove them. You want as many as possible... Sync on green aside for the reason above.

Edit - ok, I see that hsync and csync share a pin on the VGA pinout, but that doesn't need several switches.
 
Last edited:

Phipli

Well-known member
It's covered what they're doing on your instructions :

IMG_3639(1).jpg

It maps either one or both of hsync and csync to pins 13 and 14 of VGA.

Plus Sync on Green, which it doesn't say what it does, but the IIci doesn't seem to do Sync on Green, so it probably overlays the syncs on the green channel, as previously stated.
 

NJRoadfan

Well-known member
Most VGA monitors don't care if you feed them C-sync as H-sync. Generally they tolerate it just fine as long as you also provide them with a separate V-sync signal. People outright abuse the LM1881 to extract the sync signal from SoG as well: https://www.instructables.com/Arcade-PS2-Sync-on-Green-Simple-Way-to-Remove-Gree/

I wish I still had a IIci to test the Belkin adapter theory. I have some notoriously fussy monitors that I know don't support SoG. One thing I can say, despite never reading about it, the Apple IIgs does output SoG in addition to composite sync. The OSSC requires you to select sync types on its inputs since it can't auto detect them. The IIgs works with SoG and composite sync modes.
 

Phipli

Well-known member
So the IIci supports three screens only, portrait, 12" and 13". When set to 13", it outputs CSync. Old articles refer to these adapters as being needing to support 'sync seperation' to work with some monitors.

Screenshot_20230924_170214_Drive.jpg
 

dougg3

Well-known member
Yes, I think some monitors will accept CSYNC on the HSYNC input.

In an old thread here @NJRoadfan mentions that some adapters do have a sync separator built in, including a particular Belkin model (but the link is dead). There's also the LM1881 which could maybe be used to do it.

Very interesting! It would be cool to test that theory, but sadly I don't have a Belkin adapter. I am pretty sure the 10-pin DIP switch model that we both have doesn't do this based on my results of mapping the pins and also what the instructions say.

Hmm, that's a really good point. But I'm still surprised the IIsi developer note has a long and detailed discussion of the video hardware and never mentions sync on green anywhere. In fact, it seems very clear that the standard 13" Apple RGB mode using composite sync.

Yeah, I agree that it's weird they don't mention that the sync info is available on the green channel. I didn't mention it last night because I didn't want to make my post even longer, lol, but if you look at Bomarc's schematics of the IIci, it uses an off the shelf Brooktree Bt478 RAMDAC chip (link goes to the datasheet). The datasheet says "sync on all three channels" in reference to the Bt471 and Bt478. I think the sync info is there on red, blue, *and* green.

The IIsi uses the ADV478 (datasheet linked again) which also mentions sync generation on all three channels.

Maybe it outputs composite sync and sync on green? It might be time to hook up an oscilloscope and end this mystery once and for all.

Yep, this is exactly what I was trying to say. The composite sync is being output, but it's also on the color channels if the monitor is capable of using that instead of the composite sync.

So... my personal computer and monitor situation is resolved for now, but my curiosity over this topic is still definitely high. Does the standard 13" Apple RGB mode use composite sync, or sync on green, or both? Is it the same for all Mac models and video cards, or do only some models like IIci and IIsi output sync on green?

Welcome to where my brain has been for the past couple of days, lol. I think the Apple 13" monitor likely makes use of the composite sync signal (see the excerpt that Phipli just posted), but the info is also available on the green channel (well, all of the color channels) for monitors that support it.

Who wants to collaborate on a new project? :)

I'm game! I'm tempted to just pull out my scope right now and look at what's going on with the different signals. I'm pretty sure we're going to find, based on the dev notes and the datasheets linked above, that in 640x480/66.67 Hz mode the composite sync pin has sync info, all of the color channels also have sync info, and the vsync and hsync pins have nothing.
 

dougg3

Well-known member
So the IIci supports three screens only, portrait, 12" and 13". When set to 13", it outputs CSync. Old articles refer to these adapters as being needing to support 'sync seperation' to work with some monitors.

Yeah, also interesting to note from that screenshot is that the 640x870 portrait mode does output vsync and hsync. So that mode might actually work without any weird sync compatibility needed -- except I'm guessing the portrait mode's timing is going to be less compatible with random monitors. It sort of works with my IIci and Rosewill monitor if I set the DIP switches to 23467. Everything appears blue, and the monitor thinks it's 1152x870, but I get a video signal.

Interestingly enough, 234 by itself doesn't work -- meaning that in portrait mode, sync on green doesn't work. It's definitely depending on the separate hsync and vsync signals. I think this actually makes sense, because the composite sync signal isn't driven in that mode -- and the RAMDAC uses the composite sync signal input to add sync info to the color channels. Hsync and Vsync, in comparison, are driven directly from Apple's chip to the DB-15 connector and aren't fed into the RAMDAC at all.
 

bigmessowires

Well-known member
Yeah, I think we need to bring in a scope or logic analyzer to reach ground truth here. But it's all starting to make sense, sort of.

So to make the IIci's 640x480 output work on a fussy LCD probably requires one or more of the following:
  • using something like LM1881 to separate the composite sync or sync on green into individual hsync and vsync signals
  • possibly also need to suppress the sync on green (and other colors too?) and only pass through the color pixel data
  • refresh rates - if the LCD doesn't like 67Hz refresh then there's nothing a cheapo adapter can do to fix it

interesting to note from that screenshot is that the 640x870 portrait mode does output vsync and hsync. So that mode might actually work without any weird sync compatibility needed

Yes this is also what I found. Two out of three fussy monitors sort-of worked with the IIci in 640x870 mode. But the image was blue and squashed. Refresh rate was 75 Hz.

Interestingly enough, 234 by itself doesn't work -- meaning that in portrait mode, sync on green doesn't work.

I wonder if everywhere that developer note mentions csync, it really means csync on the color channels, aka sync on green. Is the csync pin actually driven? Or is the video circuit designed such that you'll always get both csync and sync on green, or you'll get neither, but you can't have one without the other?

FYI there's one of the Belkin adapters @NJRoadfan mentioned available on eBay: https://www.ebay.com/itm/285433440465
 

Phipli

Well-known member
Looking at the 478 datasheet, it only outputs Sync on colours when pin 5 "SYNC" is high. On my IIci, this pin isn't tied high or low, but goes to pin 128 of UE9 "RBV".

I don't have a datasheet for UE9 because it is a custom chip, but this suggests sync on colour is software controlled. Given it isn't mentioned in the Dev note for the IIci... I really really suspect it is turned off. Really.

I don't want to probe pin 5 while my IIci is on. I've had this IIci since I was about 13.
 

Phipli

Well-known member
Heh, and a reminder of why we don't trust bomarc schematics. The BT datasheet says pin 5 is this, an input :

Screenshot_20230924_174914_Drive.jpg

Bomarc IIci schematic shows it tied to pin 128 of UE9 (correct), but also the Composite Sync on the Video output.

But... It is a digital logic input on the chip. So I doubt it is.
Screenshot_20230924_174810_Drive.jpg


Edit : I take it back, it is. How strange.

Well. I'm completely confused now.
 

dougg3

Well-known member
Yeah, I think we need to bring in a scope or logic analyzer to reach ground truth here. But it's all starting to make sense, sort of.

I agree. I'm going to try to test it today, but no promises.

I wonder if everywhere that developer note mentions csync, it really means csync on the color channels, aka sync on green. Is the csync pin actually driven? Or is the video circuit designed such that you'll always get both csync and sync on green, or you'll get neither, but you can't have one without the other?

I think it's designed such that CSYNC and sync on green are simultaneous. UE9's pin 128 goes to the DB-15 CSYNC pin *and* the 478's sync input. So if the video circuit is driving CSYNC, sync info is also getting fed into the 478, which inserts it into the color channels.

Looking at the 478 datasheet, it only outputs Sync on colours when pin 5 "SYNC" is high. On my IIci, this pin isn't tied high or low, but goes to pin 128 of UE9 "RBV".

That pin is the actual CSYNC pin, controlled by UE9. It also goes to pin 3 of the DB-15 connector through a series resistor. I don't interpret the 478 datasheet the same way you do though. It's saying that twiddling pin 5 on and off is how you insert sync info into the RGB analog outputs. Not that it automatically gets sync info added when you tie it high.

I don't have a datasheet for UE9 because it is a custom chip, but this suggests sync on colour is software controlled. Given it isn't mentioned in the Dev note for the IIci... I really really suspect it is turned off. Really.

Can you explain how combination "14" works for both of us then? It doesn't pass any of the sync pins through. Only red, green, blue, and ground.

My IIci is fitted with the Analog Devices part.

Interesting! Mine does have the Bt478. They're probably 100% pin compatible competitor parts.
 
Top