BBC Master screen interference PiTube direct

for bbc micro/electron hardware, peripherals & programming issues (NOT emulators!)
pbw72
Posts: 24
Joined: Tue Mar 14, 2017 8:38 pm
Contact:

BBC Master screen interference PiTube direct

Post by pbw72 » Fri Dec 08, 2017 4:54 pm

Hi everyone,

Hoping someone may be able to give me some ideas about an issue i am having with my Beeb Master.

I have the Pitube direct installed internally, along with datacentre + cf card and connect to tv using rgb scart.

After a long delay and taking time to get my Beeb up to full speed i have been playing with the various co-pros via the pitube. After getting my very grateful hands on a CF copy of GEM (thanks RobC) i have this up and running.......however when its booting and finally boots up i seem to be getting lots of interference on the white parts of the screen! The outer grey part is fine??

The odd thing is if i press and hold break it all goes clear and looks great....but of course i am now exiting the program!

I have attached screen shots of both screens (interference and clear) but cannot fathom what the issue is. I have tried the Z80 co-pro with no issues, the version of GEM is 2.0 and the copro version is 80286 960k.

There are no issues with anything else, playing games etc so im pretty sure my scart cable is fine?

Any help would be most welcome, after trying for so long to get this running, now i have its all a bit fuzzy :roll:
Attachments
B7C4FE82-BE03-48D2-93E1-5BB54F00A429.jpeg
B94A5D63-F62C-499F-975A-98FAFE00E1B8.jpeg

User avatar
hoglet
Posts: 7219
Joined: Sat Oct 13, 2012 6:21 pm
Location: Bristol
Contact:

Re: BBC Master screen interference PiTube direct

Post by hoglet » Fri Dec 08, 2017 5:01 pm

This looks like a data corruption issue, as the GEM screen data is written back to the host using OSWORD.

What version of PiTubeDirect are you running?

The best way to tell this is to switch to the 65C02 Co Pro (Co Pro 0), and then enter:

Code: Select all

OLD
LIST
and post a photo of what you get.

Dave

dp11
Posts: 802
Joined: Sun Aug 12, 2012 8:47 pm
Contact:

Re: BBC Master screen interference PiTube direct

Post by dp11 » Fri Dec 08, 2017 5:18 pm

My best guess is the psu caps are failing or the psu is overloaded.

Can you post a photo of the inside of your beeb.

User avatar
BigEd
Posts: 1891
Joined: Sun Jan 24, 2010 10:24 am
Location: West
Contact:

Re: BBC Master screen interference PiTube direct

Post by BigEd » Fri Dec 08, 2017 6:09 pm

hoglet wrote:...
What version of PiTubeDirect are you running?

The best way to tell this is to switch to the 65C02 Co Pro (Co Pro 0), and then enter:

Code: Select all

OLD
LIST
and post a photo of what you get.
Can I recommend

Code: Select all

OLD
LIST ,9
(LIST comma 9) instead?

pbw72
Posts: 24
Joined: Tue Mar 14, 2017 8:38 pm
Contact:

Re: BBC Master screen interference PiTube direct

Post by pbw72 » Fri Dec 08, 2017 10:44 pm

Hi guys, many thanks for the responses. I’m away for a couple of days now so cant get to the beeb :(

As soon as the missus lets me have a few minutes i will get on it!

Again thanks guys, i will be back soon

pbw72
Posts: 24
Joined: Tue Mar 14, 2017 8:38 pm
Contact:

Re: BBC Master screen interference PiTube direct

Post by pbw72 » Sat Dec 09, 2017 3:16 pm

Hi guys, just remembered i have a picture of the insides on my ipad, as you can see its bit busy!

I had the psu caps done a while ago by Mark at retroclinic so they should be ok.

Once i get back i will get some answers for the questions you posed.
Attachments
D369D27F-03FA-4C20-8200-E53FBDF2A557.jpeg
547C8FF8-6C03-47CB-B905-EA8A22347D4E.jpeg

dp11
Posts: 802
Joined: Sun Aug 12, 2012 8:47 pm
Contact:

Re: BBC Master screen interference PiTube direct

Post by dp11 » Sat Dec 09, 2017 3:29 pm

Just to be sure, I'm talking about the caps on the low voltage side of the PSU not the mains Caps.

pbw72
Posts: 24
Joined: Tue Mar 14, 2017 8:38 pm
Contact:

Re: BBC Master screen interference PiTube direct

Post by pbw72 » Mon Dec 11, 2017 1:59 pm

Ok, got a few minutes with the Beeb! The photo shows the pitube details, so not sure of there is a newer version that may be the answer?

I have also tried playing the exec version of elite for the first time (yes!) but did notice some small ‘spots’ on some parts of the graphics on the start up screen akin to the interference I have experienced on the GEM.

I tried the regular version which played fine, so I am looking towards the pitube as the culprit? Or could it be as suggested earlier that the psu is overloaded? I would suspect that when the tube is running that this puts more ‘stress’ on the beeb?

Not the most proficient at the technical aspects, so any further help is most welcome
Attachments
0F027608-E148-4E38-9FAB-43BB4437B769.jpeg

User avatar
hoglet
Posts: 7219
Joined: Sat Oct 13, 2012 6:21 pm
Location: Bristol
Contact:

Re: BBC Master screen interference PiTube direct

Post by hoglet » Mon Dec 11, 2017 2:01 pm

Please try updating to Diamondback RC2:
https://github.com/hoglet67/PiTubeDirect/releases

There was a bug in Cobra that might be causing this:
"Fixed a GPU issue that delayed the tube cycle following a nTube glitch causing random failures"
https://github.com/hoglet67/PiTubeDirec ... 7ddc7ee1e0

Dave

pbw72
Posts: 24
Joined: Tue Mar 14, 2017 8:38 pm
Contact:

Re: BBC Master screen interference PiTube direct

Post by pbw72 » Mon Dec 11, 2017 2:09 pm

Ok, thanks for the quick reply Dave, i will get on this tonight and report back........better get back to work now!

Many thanks

Paul

pbw72
Posts: 24
Joined: Tue Mar 14, 2017 8:38 pm
Contact:

Re: BBC Master screen interference PiTube direct

Post by pbw72 » Tue Dec 12, 2017 12:52 pm

Ok, downloaded the diamondback update and.......it still does the same :(

I notice that the interference occurs when the beeb(or tube) is ‘working’ I.e loading data etc. When I boot up the dos and the digital research screen appears there is some interference while it is loading.

Then it waits for me to press enter to boot from hard disc and the screen is fine, when I press enter and dos starts to load the interference is back?!

I have tried connecting to the tv with composite and uhf just in case there was an issue with my scart cable but I got the same result.

There was a suggestion earlier about the psu being overloaded and/or low voltage caps failing, is this something that occurs? Has anyone experienced a similar thing?

Many thanks

User avatar
marcusjambler
Posts: 361
Joined: Mon May 22, 2017 11:20 am
Location: Bradford
Contact:

Re: BBC Master screen interference PiTube direct

Post by marcusjambler » Wed Dec 13, 2017 10:19 am

Hi All

Just to add my 2p... I've tried the internal kjell level shifter with both Pizero and Pi3 using a fresh Diamondback-RC2 on both my masters.
They both exhibit the same screen interference as described, and shown, by Paul earlier in this thread.

The interference is coincident with increased bus noise on the Beeb speaker.
Its also visible in Elite and on running the 'test ball' code.

Marcus

pbw72
Posts: 24
Joined: Tue Mar 14, 2017 8:38 pm
Contact:

Re: BBC Master screen interference PiTube direct

Post by pbw72 » Wed Dec 13, 2017 11:46 am

Hi Marcus, well thats a relief in that someone else has the same issue (thought it was just me!).

It would be interesting to know if anyone else has the same problems but maybe with an external version of the pi? It would help narrow down what the cause is perhaps?

I would swap to external if this helps but i do like the internal set up. I hope there is a solution as this is a great piece of kit and makes the beeb much more versatile (and cheaper) to use with a copro.

Paul

User avatar
marcusjambler
Posts: 361
Joined: Mon May 22, 2017 11:20 am
Location: Bradford
Contact:

Re: BBC Master screen interference PiTube direct

Post by marcusjambler » Wed Dec 13, 2017 12:45 pm

Hi Paul

I have both internal and external kjell boards.
The external one works fine on both Masters and my NulaBeeb.

Marcus

User avatar
BigEd
Posts: 1891
Joined: Sun Jan 24, 2010 10:24 am
Location: West
Contact:

Re: BBC Master screen interference PiTube direct

Post by BigEd » Wed Dec 13, 2017 12:55 pm

I don't think this is data corruption, if the screen is OK when BREAK is held down. I think I'm with Dominic, that it could be power supply related.

Is it possible with Kjell's internal adapter to cut the power from Master to Pi and to power the Pi separately?

Or, is it possible for someone with this problem to add some capacitors to the level shifter board? (Are there any already? Might they have failed or have bad solder joints?)

dp11
Posts: 802
Joined: Sun Aug 12, 2012 8:47 pm
Contact:

Re: BBC Master screen interference PiTube direct

Post by dp11 » Wed Dec 13, 2017 1:08 pm

As the noise is audible, I suspect we need some low frequency decoupling. The on board level shifter caps will only be good at high frequency. I suspect added something between 100uf and 1000uF might help. It might also be a sign the 5v caps in the PSU are starting to fail.

User avatar
BigEd
Posts: 1891
Joined: Sun Jan 24, 2010 10:24 am
Location: West
Contact:

Re: BBC Master screen interference PiTube direct

Post by BigEd » Wed Dec 13, 2017 1:20 pm

I'm wondering about contention - with the internal adapter, the Pi is on the main 6502 bus. If it's driving the bus at a bad time, would the video ULA pick up the Pi data mixed with the RAM's video data?

dp11
Posts: 802
Joined: Sun Aug 12, 2012 8:47 pm
Contact:

Re: BBC Master screen interference PiTube direct

Post by dp11 » Wed Dec 13, 2017 1:29 pm

That could be possible as the master data bus only wants the data bus driven for half a cycle. PiTubeDirect is likely to drive the databus for more than half a cycle. Still puzzled by the audible noise unless there is a low of current flowing on the data bus.

User avatar
marcusjambler
Posts: 361
Joined: Mon May 22, 2017 11:20 am
Location: Bradford
Contact:

Re: BBC Master screen interference PiTube direct

Post by marcusjambler » Wed Dec 13, 2017 1:30 pm

Is it possible with Kjell's internal adapter to cut the power from Master to Pi and to power the Pi separately?
Yes, there is a jumper on the board to isolate the Pi power

User avatar
BigEd
Posts: 1891
Joined: Sun Jan 24, 2010 10:24 am
Location: West
Contact:

Re: BBC Master screen interference PiTube direct

Post by BigEd » Wed Dec 13, 2017 2:01 pm

Might be worth trying independent power, for those who see the video trouble.

I'd not take the audio breakthrough as too big a clue, as I hear audio noise too on machines which run fine. I think the sound amplifier is very good at amplifying noise!

User avatar
marcusjambler
Posts: 361
Joined: Mon May 22, 2017 11:20 am
Location: Bradford
Contact:

Re: BBC Master screen interference PiTube direct

Post by marcusjambler » Wed Dec 13, 2017 3:12 pm

Might be worth trying independent power, for those who see the video trouble.
Yes indeed I'll give it a test on both masters

pbw72
Posts: 24
Joined: Tue Mar 14, 2017 8:38 pm
Contact:

Re: BBC Master screen interference PiTube direct

Post by pbw72 » Wed Dec 13, 2017 3:20 pm

Ok, so power seems to be the possible culprit? As noted above, the Pi could be powered separately, how would this be done for the internal version?

Would it be possible for some step by step guidelines as to how this would be achieved? I am not overly technical but quite good with a soldering iron!

I am keen to see if this alternate power idea works. As suggested, I would also perhaps want to change the 5v capacitors on the main psu as well just to cover all bases, are there any diagrams available to see where these are located?

Thanks to all the contributions so far

Paul

User avatar
paulv
Posts: 3618
Joined: Tue Jan 25, 2011 6:37 pm
Location: Leicestershire
Contact:

Re: BBC Master screen interference PiTube direct

Post by paulv » Wed Dec 13, 2017 3:35 pm

Replacing the original PSU with a Meanwell supply may give you the extra power and stability you need...

http://www.waitingforfriday.com/?p=794

Paul

User avatar
hoglet
Posts: 7219
Joined: Sat Oct 13, 2012 6:21 pm
Location: Bristol
Contact:

Re: BBC Master screen interference PiTube direct

Post by hoglet » Wed Dec 13, 2017 3:35 pm

I'm wondering if it is brief periods of bus contention, making their effects known through the power supply rails?

When the x86 Co Pro is idling in Gem, most of the time the host is executing this idle loop:

Code: Select all

2837 : AD E2 FE : LDA FEE2       : 4 : A=7F X=28 Y=80 SP=?? N=0 V=0 D=0 I=0 Z=0 C=1
283A : 10 04    : BPL 2840       : 3 : A=7F X=28 Y=80 SP=?? N=0 V=0 D=0 I=0 Z=0 C=1
2840 : AD E0 FE : LDA FEE0       : 4 : A=4F X=28 Y=80 SP=?? N=0 V=0 D=0 I=0 Z=0 C=1
2843 : 10 F2    : BPL 2837       : 3 : A=4F X=28 Y=80 SP=?? N=0 V=0 D=0 I=0 Z=0 C=1
The visible line in Beeb screen modes is always 40us wide, which is 80 cycles of the 2MHz clock. Each LDA/BPL takes 7 cycles. So if it's bus contention every LDA, then you could expect to see 80 / 7 = 11.4 bursts of interference per line.

If you look very carefully at the screen shot posted earlier, then that's exactly what you see.

One thing you could try is editing cmdline.txt on the Pi's SD Card, and increase the value of tube_delay from 0 to 10, then 15, then 20 and see if this has any effect on the interference. Beyond 20 the Pi will probably not be recognised. It's possible this will make the interference worse, but that would be a clue.

Dave

User avatar
marcusjambler
Posts: 361
Joined: Mon May 22, 2017 11:20 am
Location: Bradford
Contact:

Re: BBC Master screen interference PiTube direct

Post by marcusjambler » Wed Dec 13, 2017 3:57 pm

One thing you could try is editing cmdline.txt on the Pi's SD Card, and increase the value of tube_delay from 0 to 10, then 15, then 20 and see if this has any effect on the interference. Beyond 20 the Pi will probably not be recognised. It's possible this will make the interference worse, but that would be a clue.
I'll set this up and get back with some results/pics

User avatar
marcusjambler
Posts: 361
Joined: Mon May 22, 2017 11:20 am
Location: Bradford
Contact:

Re: BBC Master screen interference PiTube direct

Post by marcusjambler » Wed Dec 13, 2017 5:57 pm

This is with Pizero Diamondback RC2 tube_delay=20 in a master with internal datacentre and Retroclinic DualOS...

The Pizero is on a kjell level shifter and powered by phone charger
Attachments
IMG_0429a.jpg
IMG_0421a.jpg

dp11
Posts: 802
Joined: Sun Aug 12, 2012 8:47 pm
Contact:

Re: BBC Master screen interference PiTube direct

Post by dp11 » Wed Dec 13, 2017 7:04 pm

Would you mind testing different tube delays and see if there is any difference? I'll try and look at the code over the weekend.

User avatar
hoglet
Posts: 7219
Joined: Sat Oct 13, 2012 6:21 pm
Location: Bristol
Contact:

Re: BBC Master screen interference PiTube direct

Post by hoglet » Wed Dec 13, 2017 7:35 pm

dp11 wrote: I'll try and look at the code over the weekend.
Here's what I think might be happening....

On the Master, the internal tube interface connects to data bus CD[7:0] which connects directly to the 65SC12, the 4464 DRAMs and the Video processor. The DRAM is shared between the 65SC12 CPU and the Video Processor (i.e. when Phi2 is low, DRAM is read by the video processor, and when Phi2 is high, the is read/written by the CPU).

The problem is the internal level shifter will probably drive the bus for both halves of the bus cycle. I say probably, because it depends on how signal INTUBE is generated in the Master. But I suspect that's generated just by decoding the address bus. So every tube read will basically be clobbering the read of screen data.

The Model B and the Master external tube don't suffer the same problem because there is a buffer that isolates the Tube from the DRAM->Video data bus.

I don't think there's much that can be done in software on the Pi to fix this, because the control signals of the data bus level shifter are not controlled by the Pi. The only way to fix this (if I'm correct in my assertions here) would be to gate the enable signal of the data bus level shifter with Phi2, so it only drives the bus when Phi2 is high.

There's still several things that don't quite make sense though...
- Why does this only happen on the x86 Co Pro? Maybe it's just more noticeable with a white screen .
- Why doesn't everyone using the Kjell's internal level shifter suffer from the same problem? Maybe they do, but haven't noticed.
- Why does increasing tube_delay make this worse?

Ed, do you have an internal level shifter in your Master?

Dave

User avatar
BigEd
Posts: 1891
Joined: Sun Jan 24, 2010 10:24 am
Location: West
Contact:

Re: BBC Master screen interference PiTube direct

Post by BigEd » Wed Dec 13, 2017 7:46 pm

(No, sorry, I don't have an internal level shifter. I suppose we could rig up some cabling to use an external level shifter on the internal interface?)

pbw72
Posts: 24
Joined: Tue Mar 14, 2017 8:38 pm
Contact:

Re: BBC Master screen interference PiTube direct

Post by pbw72 » Wed Dec 13, 2017 9:09 pm

I have also noticed this on the tube enhanced version of elite but its very, very slight (Marcus mentioned this also).

So perhaps its not just isolated to the 80x but its just more noticeable on this particular copro?

Post Reply