Raspberry Pi to RBG Video on Sony PVM

I have a 15” Sony PVM CRT monitor in my workshop that I use occasionally for my Nintendo, but mostly use for watching DVD’s on.  I also had a Raspberry Pi 3 that I installed RetroPie and Kodi on, and I wanted a way to connect it to my PVM through its RGB inputs, and not using the standard RCA composite output on the Pi. 

I dug around the Raspberry Pi documentation and various forums and managed to come up with the following solution with what I had on hand.

The following parts were used:

1 x HDMI to VGA adapter
1 x BNC “T” connector.  Female on the top part of the “T”, and Male at the bottom
1 x VGA to RGBS breakout cable.  Male VGA to Male BNC.  This cable comes in various lengths, so keep in mind where you want to place your Pi in relation to your monitor, and buy accordingly.

(OPTIONAL) 1 x 3.5mm headphone to stereo RCA adapter. Used for connecting sound. This guide doesn’t go in depth on connecting sound, but when buying parts it’s good to take this into consideration.

All of these parts were acquired off of ebay for around $20 total.

Since we will be messing with the video output, it’s important that we’re able to remote into the RetroPie to make configuration adjustments or revert changes.  In my opinion the easiest way to do this is by accessing /boot/config.txt through SSH.  If SSH is not enabled on your Raspberry Pi you can enable it by using one of the methods here. You can also edit config.txt directly on the SD card.

Now that we have a rollback strategy in place, let’s set everything up.  

  1. Connect the HDMI/VGA adapter to the HDMI port on the Pi. 
  2. Connect the VGA to BNC breakout cable to the HDMI/VGA adapter. 
  3. On the back of the PVM connect the BNC “T” adapter to the Sync input. Then connect on either side of the “T” connector the black and white/gray VGA wires that correspond to the horizontal and vertical sync signals in order to create a composite sync.
  4. Connect the remaining VGA wires to the back of the PVM.  Cable colors Red, Green, and Blue should conveniently match the R, G, B inputs on the PVM. 
Raspberry Pi to Sony PVM wiring diagram

We’re halfway done.  The hardware side of things should be complete; however, we still need to configure the Raspberry Pi to output a video mode and resolution compatible with the PVM.  In a nutshell the PVM is expecting a 640×480 interlaced signal running at 60hz.  If we reference the VIDEO OPTIONS IN CONFIG.TXT from the Raspberry Pi documentation website we see that we can force the Pi to output this signal by making the following change.  Uncomment lines hdmi_group and hdmi_mode.  Leave hdmi_group set to 1, and change hdmi_mode to 6 which corresponds to a 480i signal @ 60hz. 

# uncomment to force a specific HDMI mode (this will force VGA) 
hdmi_group=1
hdmi_mode=6

We need to reboot the Pi in order for these changes to take effect, but at this point we should be seeing a picture on the PVM, albeit it still probably needs some tweaking.  Below are the changes I made to my config.txt to make the Pi fit the PVM screen properly; however, your mileage may vary, so adjust accordingly. 

# uncomment this if your display has a black border of unused pixels visible # and your display can output without 
overscan disable_overscan=0  

# uncomment the following to adjust overscan. Use positive numbers if console 
# goes off screen, and negative if there is too much border 
overscan_left=64 
overscan_right=32 
overscan_top=32 
overscan_bottom=32

The final frustration I dealt with was forcing the audio to go through the 3.5mm jack and not through HDMI. I made the following changes to config.txt to allow for this.

# Uncomment some or all of these to enable the optional hardware interfaces 
dtparam=i2c_arm=off 
dtparam=i2s=off 
dtparam=spi=off

# Enable audio (loads snd_bcm2835) 
dtparam=audio=on 
hdmi_ignore_edid_audio=1 
hdmi_force_edid_audio=0

A copy of my config.txt file can be found on my gitlab; however, it may become incompatible with future revisions of the Raspberry Pi, and should be used more as a cross-reference. 

Now that the picture is fitting the screen correctly, there are a couple of other things we need to consider.

1) The GUI interfaces for these programs were built with high resolution in mind.  This was especially evident in Kodi, so I changed the theme to an older classic XBMC theme.

2) When playing games the HDMI to VGA adapter may introduce noticeable lag when playing certain games.  I haven’t tried to measure this; however, I wouldn’t be surprised if some platformers, shooters, or fighting games feel like they have “spongey” controls. 

Closing thoughts.  An alternative to this is an adapter board that uses the GPIO pins of the Pi to produce a VGA signal.  I have tried both, and although I haven’t made any official measurements,  I suspect this adapter has less lag time, but at the expense of a reduced color depth.  Since I use this setup primarily for movies,  I opted for keeping the HDMI adapter setup.  If I can acquire another Raspberry Pi 3, I should have all the equipment to run a “shoot-out” between the two adapter methodologies and measure their lag.