Famicom AV Mod Situation in 2019

Discuss hardware-related topics, such as development cartridges, CopyNES, PowerPak, EPROMs, or whatever.

Moderators: B00daW, Moderators

User avatar
Ultron
Posts: 21
Joined: Tue Feb 26, 2019 6:36 pm

Re: Famicom AV Mod Situation in 2019

Post by Ultron » Mon May 13, 2019 2:07 pm

On the top loader NES-101, I was able to clean up the +5V signal by replacing almost all electrolytic caps with polymer electrolytic capacitors (I replaced the ones that mattered in this situation - Power). I replaced the main filter cap and the cap near the cartridge slot. I also added a 47uF in place of C35 (which was just a decoupling capacitor located way too far away from the PPU Pin 40 to do anything). This reduced the noise on Pin 40 of the PPU, but DID NOT change the noise on the video output. The noise on the Pin 40 was reduced from ~60mV pk-pk to ~20mV pk-pk. I picked the 47uF cap due to its impedance curve. Pin 40 now looks much like the measurement I took on the AV Famicom.

Before (same pic as in one of my posts above):
5V-Before.png
After:
5V-Clean.png
Board:
Poly Caps.png


I also tested PPU revisions by swapping in my -H from the AV Famicom into the NES-101. Noise was still there. In fact, the -G from the NES-101 I installed in the AV Famicom produced clean video output. Which concludes that the PCB layout is the issue, not the PPU revision.

User avatar
Ben Boldt
Posts: 420
Joined: Tue Mar 22, 2016 8:27 pm
Location: Minnesota, USA

Re: Famicom AV Mod Situation in 2019

Post by Ben Boldt » Mon May 13, 2019 7:51 pm

I agree that it sounds like a layout thing. What could it be about the layout that causes the problem? From my experience in noisy environments, I have found that there is always a possible kludge once the problem is understood. Sometimes the kludge comes first before we understand it! That's kind of what I have been looking for as I poke around. Sticking resistors and caps at different places, adding sockets, yanking/swapping chips, etc. Something is bound to have an interesting effect.

We know that the jailbars are stationary and synchronized to when the PPU accesses memory. That is a really big important fact. What path does it take to make its way out to the video signal? In terms of EMI, is it conducted (through wires) or radiated (through the air)?

You and I have both shown that better decoupling caps greatly improves the situation. Is there still something on the power rails somehow? Ground loops? Inductance of the PPUAD traces? I am at a loss.
Ultron wrote:This reduced the noise on Pin 40 of the PPU, but DID NOT change the noise on the video output.
This is a very interesting observation. It points to the jailbars being picked up IN or AFTER the video amp, which could include the television set itself. Does the NES-101 have a metal shield like the AV famicom?

User avatar
Ultron
Posts: 21
Joined: Tue Feb 26, 2019 6:36 pm

Re: Famicom AV Mod Situation in 2019

Post by Ultron » Mon May 13, 2019 8:55 pm

Ben Boldt wrote:I agree that it sounds like a layout thing. What could it be about the layout that causes the problem? From my experience in noisy environments, I have found that there is always a possible kludge once the problem is understood. Sometimes the kludge comes first before we understand it! That's kind of what I have been looking for as I poke around. Sticking resistors and caps at different places, adding sockets, yanking/swapping chips, etc. Something is bound to have an interesting effect.

We know that the jailbars are stationary and synchronized to when the PPU accesses memory. That is a really big important fact. What path does it take to make its way out to the video signal? In terms of EMI, is it conducted (through wires) or radiated (through the air)?

You and I have both shown that better decoupling caps greatly improves the situation. Is there still something on the power rails somehow? Ground loops? Inductance of the PPUAD traces? I am at a loss.
I believe it's the way the ground plane is laid out. The PPU does heavy switching on it's output pins. The large changes in current due to the switching need a large ground plane to help dissipate these spikes. I don't think the ground plane in the area of the PPU is large enough. I believe this to be the problem in both the Famicom and NES-101.

Another thing is, in circuit design, you learn to keep analog and digital ground paths separate from each other, and only tie them together at the power source (or power connection). Since the PPU is doing double duty by reading in pixel data and producing a video signal, and only has one GND pin, you would point to this. But, the "jailbar" noise is much less on a toaster NES (it is there, I have measured the video signal), and non existent on the AV Famicom, which both use the same PPU. So, it's safe to say the PPU itself isn't the source of the problem. What would happen if you removed the PNP transistor for buffering and tied it's collector (which should be tied to "analog" ground) to the regulator ground pin, or a different section of the ground plane? I wonder if this would help.

I think the real fix would be an adapter board, with the PPU mounted on it, some decoupling MLCC caps, and a nice large ground plane. The board could be mounted where the PPU normally sits, with the EXT and GND pins on the main PCB tied to the ground plane on the adapter board. The question would be how to fit it into the Famicom case.
This is a very interesting observation. It points to the jailbars being picked up IN or AFTER the video amp, which could include the television set itself. Does the NES-101 have a metal shield like the AV famicom?
Yes it does, but those metal shields wouldn't help in this case. All my tests were with them removed, and the AV Famicom still comes clean.

User avatar
Ultron
Posts: 21
Joined: Tue Feb 26, 2019 6:36 pm

Re: Famicom AV Mod Situation in 2019

Post by Ultron » Mon May 13, 2019 9:00 pm

Just to show you the noise on the GND pin of the PPU on the NES-101 (using the heat sink as a reference):
PPU GND Noise.png
Meanwhile, the CPU GND pin is clean as a whistle:
CPU GND Noise.png
You can see the ~676 kHz noise on the GND pin, which is every 8th pixel, the same noise seen on the video.

User avatar
Ben Boldt
Posts: 420
Joined: Tue Mar 22, 2016 8:27 pm
Location: Minnesota, USA

Re: Famicom AV Mod Situation in 2019

Post by Ben Boldt » Mon May 13, 2019 9:17 pm

Wow, I think you are really onto something with that. This high frequency stuff can be sneaky though, depending how you were probing it, you may have formed a loop large enough to pick up radiated stuff. But it really does prove a point.

When I wrapped one of my PPUs in copper foil, I soldered all GND pins directly to the foil and put ceramic bypass caps directly from the 5V pins to the copper foil as well. This forms a very low impedance local ground plane. I did all of the soldering on the top of the chip, so it does not interfere with any of the pins going into the socket. None of that seemed to have any visual effect but I did not measure the composite signal at the time that I did that. When I swapped the shiny copper PPU to the bare one from my front loader, again it is visually the same on the screen. Sorry for not taking measurements lately.

To your point, I didn't connect my copper foil to any sturdier ground anywhere. I wonder if something good might happen if we connected some thick wire between various GNDs and 5Vs. Some SNES video improvement guides suggest adding some wire like this.

User avatar
Ultron
Posts: 21
Joined: Tue Feb 26, 2019 6:36 pm

Re: Famicom AV Mod Situation in 2019

Post by Ultron » Tue May 14, 2019 1:49 pm

Ben Boldt wrote:Wow, I think you are really onto something with that. This high frequency stuff can be sneaky though, depending how you were probing it, you may have formed a loop large enough to pick up radiated stuff. But it really does prove a point.

When I wrapped one of my PPUs in copper foil, I soldered all GND pins directly to the foil and put ceramic bypass caps directly from the 5V pins to the copper foil as well. This forms a very low impedance local ground plane. I did all of the soldering on the top of the chip, so it does not interfere with any of the pins going into the socket. None of that seemed to have any visual effect but I did not measure the composite signal at the time that I did that. When I swapped the shiny copper PPU to the bare one from my front loader, again it is visually the same on the screen. Sorry for not taking measurements lately.

To your point, I didn't connect my copper foil to any sturdier ground anywhere. I wonder if something good might happen if we connected some thick wire between various GNDs and 5Vs. Some SNES video improvement guides suggest adding some wire like this.
Yes, I agree with picking up noise with "how you probe it". Most of my measurements were done with a ground spring on the o-scope probe, which is the best way to do it. The GND measurements obviously were not done that way, but you would figure that the noise would show up on both grounds if the probe was picking up interference.

I'm not sure if the copper foil would do the trick. Maybe it is too thin?

I did try adding a ~22 gauge wire between pin 20 and a different spot on the ground plane. This seemed to make a little difference, but not as much as I would have hoped.

I think I'm giving up on the NES-101 for now, and will move on to the Famicom to see what I can do.

User avatar
Ben Boldt
Posts: 420
Joined: Tue Mar 22, 2016 8:27 pm
Location: Minnesota, USA

Re: Famicom AV Mod Situation in 2019

Post by Ben Boldt » Tue May 14, 2019 10:28 pm

Ultron wrote:The GND measurements obviously were not done that way, but you would figure that the noise would show up on both grounds if the probe was picking up interference.
You can test that if you connect the probe tip directly to probe GND and nothing else, and hold it approximately where you were probing before. Whatever doesn't show up this way was your true difference in GNDs.
Ultron wrote:I'm not sure if the copper foil would do the trick. Maybe it is too thin?
Good point. This is some pretty thin stuff I used. I cut it easily with a scissors and X-acto knife.
Ultron wrote:I did try adding a ~22 gauge wire between pin 20 and a different spot on the ground plane. This seemed to make a little difference, but not as much as I would have hoped.
Was this a visible difference on the screen, or was it a difference on your scope?

User avatar
Ben Boldt
Posts: 420
Joined: Tue Mar 22, 2016 8:27 pm
Location: Minnesota, USA

Re: Famicom AV Mod Situation in 2019

Post by Ben Boldt » Thu May 23, 2019 1:45 pm

Ugh, I don't know how I did this but I got my CY7C128A chip last night to find that it is not even the right number of pins! Here I was thinking I could just plug the thing in and it would work. Silly me. We kind of disproved the RAM chip anyway but just thought I would post an update on that...

Edit:
Heyyyyyy! The datasheet shows a 24-pin chip and this is 28-pin! LOL I wonder what the heck is going on here.

Edit 2: The picture of the item is 24-pin. Hmm...

Image

User avatar
Ben Boldt
Posts: 420
Joined: Tue Mar 22, 2016 8:27 pm
Location: Minnesota, USA

Re: Famicom AV Mod Situation in 2019

Post by Ben Boldt » Mon Jun 24, 2019 9:23 am

Conrad7K wrote:I think tantalum might not be the best choice here, they work their magic best on voltage rails and things that always stay positive.
For the bypass cap (i.e, the one directly from 5V to GND), I found that using a tantalum produces the best results, and there is nothing that should ever make that cap go negative, so I really do recommend tantalum for that cap.

With the large series cap, I found that using a tantalum isn't really any better than using an electrolytic. From what I understand, this cap never goes backwards either though. Think about it like this: the signal before this cap ranges from 0V to +1V. After the cap, the signal ranges from -0.5V to +0.5V. So, at all times, the cap basically has a constant DC -0.5V across it, then the whole cap floats along with the signal, not really seeing the signal internally. Since it is holding a flat -0.5V, you put it in backwards and it should always be happy. To your point, I would recommend electrolytic for this one, especially for unknowns like when you plug and unplug the video jack, etc, but I think in general a tantalum would actually still be OK.

Anomunus
Posts: 4
Joined: Thu Sep 26, 2019 1:34 am

Re: Famicom AV Mod Situation in 2019

Post by Anomunus » Thu Sep 26, 2019 1:42 am

Hello, I want to attempt the AV mod on my Famicom as described in this latest method that you guys have figured out. Just some questions about the tantalum capacitor part:

1. Where did you solder it, the top or the bottom of the motherboard? I didn't see it in the picture that was in this post, so just wondering where I'm supposed to add the capacitor (I have barely worked with soldering anything and I didn't learn any more electrical stuff outside of high school physics, so I'm pretty new to some of this)
2. Does the uF number of that capacitor matter (between 4.7 and 47 as previously experimented with)? Like, is it better to have it higher?

Otherwise, this looks like a really good mod, I really appreciate that it is non-destructive and pretty easily reversible (other than needing to remove and re-purpose the transistor) :D progress in 2019 is awesome

User avatar
Ben Boldt
Posts: 420
Joined: Tue Mar 22, 2016 8:27 pm
Location: Minnesota, USA

Re: Famicom AV Mod Situation in 2019

Post by Ben Boldt » Thu Sep 26, 2019 9:10 pm

Anomunus wrote:Hello, I want to attempt the AV mod on my Famicom as described in this latest method that you guys have figured out. Just some questions about the tantalum capacitor part:

1. Where did you solder it, the top or the bottom of the motherboard? I didn't see it in the picture that was in this post, so just wondering where I'm supposed to add the capacitor (I have barely worked with soldering anything and I didn't learn any more electrical stuff outside of high school physics, so I'm pretty new to some of this)
In this photo (https://forums.nesdev.com/download/file ... &mode=view), it is the yellow Tic Tac-shaped component.
Anomunus wrote:2. Does the uF number of that capacitor matter (between 4.7 and 47 as previously experimented with)? Like, is it better to have it higher?
I found that higher is not better. I noticed the quality got slightly worse with less than 4.7uF and also slightly worse with greater than 47uF. In general, larger capacitors are better at lower frequencies, and smaller capacitors are better at higher frequencies. I wouldn't say that we proved it, I certainly didn't get a PHD in that stuff but it seems reasonable that the range 4.7-47uF is tuned for whatever frequency(ies) are involved here. You would want to use any one of these common values:

4.7uF (475)
6.8uF (685)
10uF (106)
15uf (156)
22uF (226)
33uF (336)
47uF (476)

If you want me to tell you a specific value, go for 22uF 16V. But really I could tell no difference between any of those I listed above, so if you can find one from the list on an old motherboard or hard drive or LCD or something, it will be just as good. Special note: unlike electrolytics, the stripe means (+) on tantalums. It is very important not to get it backwards.

User avatar
Fisher
Posts: 989
Joined: Sat Jul 04, 2015 9:58 am
Location: -29.794229 -55.795374

Re: Famicom AV Mod Situation in 2019

Post by Fisher » Fri Sep 27, 2019 6:52 am

Do these rules also apply to clones or they're completelly different beasts?

lidnariq
Posts: 8786
Joined: Sun Apr 13, 2008 11:12 am
Location: Seattle

Re: Famicom AV Mod Situation in 2019

Post by lidnariq » Fri Sep 27, 2019 9:48 am

PPU clones probably have the same reason for the problems Ben Boldt and Ultron outlined here. The decapped UA6538 is very similar layout-wise to the real 2C02.

Famiclone PCBs will probably have different layout than the top-loader, so might need additional fortification of the power supply to the PPU beyond just a capacitor.

User avatar
Fisher
Posts: 989
Joined: Sat Jul 04, 2015 9:58 am
Location: -29.794229 -55.795374

Re: Famicom AV Mod Situation in 2019

Post by Fisher » Fri Sep 27, 2019 6:44 pm

Good to know.
I have a clone wich have a "stereo headphone" output.
It's nice and had a bunch of problems that I could fix, but now it has 2 horizontal lines that passes on screen.
Looks like it's a power supply problem, because they vanish if I remove the audio module.
It uses an LM317 instead of a 7805.

I'll open a new thread to discuss this as soon as I can get some more information in digital form about it's circuit.

lidnariq
Posts: 8786
Joined: Sun Apr 13, 2008 11:12 am
Location: Seattle

Re: Famicom AV Mod Situation in 2019

Post by lidnariq » Fri Sep 27, 2019 11:18 pm

Two horizontal lines? That's almost certainly a power supply filter issue, and you probably just need to replace the capacitors in there.

What Ben Boldt and Ultron were investigating was a pattern of vertical lines, like what Ben Boldt showed here.

Post Reply