Introducing the Jaf Sandwich



Well, here's a turn up for the books. I'm sure I'm not the only person who felt pretty darn certain that the RCA Phono Jack on the old Commodore 64 RF Modulator was a relic; past its time, and its usefulness consigned to bygone days. But then Reinhard Grafl (aka C0pperdragon) comes along with another amazing idea and my preconceptions about that jack are stomped into grey rubble on the floor.

So, if you have absolutely no idea what I'm talking about, let's remedy that. Before proceeding though, please be aware this whole saga is stupidly convolted. And it's not all my fault. 

Your first stop should be to C0pperdragon's Tindie Store. There you will see a product called the "VIC-II-dizer". In brief, this is a PCB which sits between the C64 and the VIC-II chip. It listens to the communications between the two, and generates an output signal dubbed "LumaCode". So far so good.

C0pperdragon's VIC-II-dizer

The relevant (and really clever bit) is how this LumaCode is fed out of the C64. Rather than requiring the user go through the arduous task of de-soldering the RF Modulator and install something else, the VIC-II-dizer comes with two cables terminated in crocodile clips. One of these simply clips to ground, and the other clips to the RCA Phono Jack, re-using this already-existing-but-until-now-defunct output. Simple.

(It's not really simple - it works like this: "rather than outputting an RGB or YUV signal which would require some sort of muti way connector or cable out of the computer, the board [the VIC-II-dizer] generates a four level mono video signal at two or three times the pixel rate of the original computer. Four levels means each pixel encodes 2 bits of information so for the C64 which has four bits per pixel, two mono pixels are required for each original c64 pixel." Quote from this Stardot forum.)

Outside of the C64, a cable then needs to be attached to the now reused RCA Jack and on to a box of tricks which can translate the LumaCode into an HDMI signal. This box of tricks is called "RGBtoHDMI" and is a hat (i.e. it plugs into) a Raspberry Pi Zero. The variant I'm using for now can be found at that link. This will output a pixel perfect HDMI signal on to your modern TV (without sound, but that's a whole separate issue).

Ok, so it's a whole new way of getting an HDMI signal out of the Commodore 64. And it's a way that greatly interests me. Even more interesting is that behind the scenes, the developer of the VIC-II Kawari, Randy Rossi, is examining and testing ways to try to incorporate the generation of LumaCode in the Kawari Mini (full conversation here and extensive instructions here) which dispenses with the need for the VIC-II-dizer board. Now, Randy was able to get this to work, but it is not easy and is nowhere near as simple as using a VIC-II-dizer with a regular VIC-II chip. For this to have any chance of working with my idea, I'll have to employ some thought. We'll pick up that part of the story in the next blog.

So, with all of that out-of-the-way, let's get to the point of this article:

Regular readers will be well aware that the Commodore 64 I use pretty much all the time is my SixtyClone, completely built by me, from almost all new parts. This did not come with an RF Modulator, instead, I designed my own: the JaF64 (which you can read all about over nine excruciatingly verbose parts). It never occurred to me then that the RCA Jack could have a modern use, so it was never incorporated into my new design.

To cut a long story right down to the meat and bones: I want to redesign my JaF64 to incorporate an RCA Jack for future use with the VIC-II-dizer (and, potentially, maybe, a LumaCode adapted Kawari). This means my redesign needs to do 4 different things:

  1. Accept the existing video input signals and output normal composite and S-Video signals as it currently does.
  2. Support a Lumacode signal from a VIC-II-dizer and output this through an RCA (phono) Jack. This will catagorically be a different approach from point 3.
  3. Support a Lumacode signal from the Kawari Mini and output this through an RCA (phono) Jack. This will catagorically be a different approach from point 2.
  4. Fit on the 250466 mainboard and C64C case without any modification.

Let's set a few points in stone from the outset:

  • I am not going to change the way the JaF64 connects to the C64 motherboard. It's modular, it's rock solid. It's flippin perfect.
  • The JaF64 will need a redesign to accommodate the planned changes but I'll limit this to essential changes only.
  • The addition of the RCA Jack will be via a new PCB which plugs into the redesigned JaF64. And I'll explain why in some depth later
  • No holes will be drilled in the case. Any changes must fit with the existing design.
  • I will undertake this in stages only adding potential support for the Kawari Lumacode if I can get the VIC-II-dizer Lumacode working.

With that said, let me explain my thinking:

The first problem to overcome is adding an RCA (phono) Jack to my current design AND getting this jack to align with the existing hole in the case. If I can't do that, everything else is moot.

The existing hole in the case to accommodate the RCA Jack is 12mm in diameter. The jack itself is 8.3mm in diameter, thus if positioned correctly at the centre of the hole there should be a 1.87mm gap between the outside of the jack, and the inside of the hole all around. Therefore, we don't have a great deal of wriggle room to deal with misalignment.

Edit from the future. Some measurements below are incorrect. I assumed something because I'm an idiot. Specifically, I calculated everything on the assumption that the combined height of male and female pin headers was 10mm. It is not. It is actually closer to 10.82mm which consequently, when my margin of error is already very small, throws everything off. I will have to deal with this in the future.

Theoretically, the top surface of the JaF64 sits 11.6mm above the mainboard. If an RCA Jack were simply mounted onto the JaF64, the centre line of the Jack would be a further 8mm higher than that - a total of 19.6mm above the mainboard. The original RF Modulator places the centre of the jack 12.7mm above the C64 mainboard. Thus we cannot simply mount the jack on the JaF64 as this would be 6.9mm too high.

By the use of standard pin headers however, it's easy to mount a new PCB 10mm above the JaF64. If we mount the RCA Jack onto the bottom of that new PCB, then I calculate the centre line of the Jack will only be 0.9mm from the centre line of the case hole. That might work.

What I am proposing then is to adjust the JaF64 to allow a new PCB be mounted on top. The new PCB will have the RCA Jack mounted to its base. This will drop to approximately the correct location for the hole. The JaF64 will have to have a hole cut in it to allow the RCA Jack to drop through. And the new PCB will have to have two holes cut in it to allow screwdriver access to the mounting screws on the JaF64.

Don't worry if you can't picture any of that - digital renders are below. Meantime, here's a rough sketch of what I have in mind - nothing is to scale by-the-way, but the measurements shown are theoretically accurate.


Measurements shown are sourced from a combination of the C64 Service Manual, the RCA Jack datasheet and my own measurements of my existing setup. Oh, and this sketch neglects to place the RCA Jack actually in the hole - it's too far to the right - but as it was only to sketch out the vertical placement that wasn't a consideration.

Enough with the theory though. Next step in progressing this is to shuffle some components around and cut a dirty big hole in the JaF64 to allow the RCA Jack to drop through. The placement of this cut has been guided by the C64 Service Manual which places the centre of the RCA Jack on the horizontal 26.9mm from the centre of the modulator mounting hole, which is in the same place as the left solder-tang in the image below, scanned from the Service Manual.


The datasheet for my chosen RCA Jack provides all the following dimensions, in mm:


As you can see it is 10mm wide. The body is 10mm long and the RCA Jack barrel is an additional 9.5mm long. I want the outside edge of the barrel to extend through the hole in the case so that it is flush with the outside of the case, but no further; the distance between the edge of the JaF64 and the outside of the hole is 3.5mm, so that leaves 6mm of barrel and the 10mm body length (16mm in total) to accommodate on the board. Accordingly, and adding some wriggle room, I need to cut a 12mm by 18mm hole in the JaF64, the centre line of which should be 26.9mm from the centre of the nearby mounting screw. This datasheet, incidentally, does not contain any footprint dimensions which is just fuckin dumb but I can sort of extrapolate the required size and spacing of mounting holes from the info provided. Irritating though.

I will need to move existing components to accommodate this. I will also need to make space for two rows of pin headers to allow the new PCB to be mounted on top, illustrated here:

Top and bottom renders of the lower board of the JaF Sandwich

As for the new PCB, that really couldn't be much simpler. Its overall dimensions will be identical to the JaF64. All it needs to accommodate are the RCA Jack, some form of connector to allow the LumaCode signal to get to the jack, and two rows of female pin headers to allow it to plug into the JaF64. These headers incidentally will be used in future to carry a signal, but in this iteration they're merely to allow simple mounting; I will ensure they're electrically connected to ground though. What we will end up with then are two PCBs joined together and it would be a crying shame if I didn't call this design the "JaF Sandwich".

Top and bottom renders of the upper board of the JaF Sandwich

And finally a 3d rendering of the two halves to clearly demonstrate exactly what I'm trying to articulate. Hopefully you get the idea by now.


With the redesign in the bag I needed to sit on it for a few days and give myself time to double check my measurements and connections, just to make sure I've not done anything stupid.

I will, at this stage, fully admit I'm not 100% confident the dimensions shown above will properly line up the RCA Jack with the corresponding hole in the case; as I've said, in theory it should fit with just a 0.9mm misalignment but past experience has taught me that my on-paper measurements versus actual measurements on disparate parts aren't always mm perfect, despite my best efforts, and there is very distinct, almost certain probability the end result will be somewhat further askew than anticipated. But we'll deal with it.

For the reason outlined above this first order will be made using the cheapest combination of options at PCBWay. With a minimum order of 5 top boards and 5 bottom boards, that works out at $36.65 including the cheapest, slowest, shipping option. The cost of components (not including headers as I have plenty of them in stock) for a single build comes in at £9.15, giving a total unit cost (at todays exchange rate) for this first run as £15.42 per sandwich. Not terrible for a test run. My intention is to build one unit and test fit everything before anything else.

I placed my order on Sun, 12 Nov 2023, at 20:14. I received notification that the boards had shipped on Fri, 17 Nov, at 14:30.

Popular Posts