Random pixels on BBC Model B

for bbc micro/electron hardware, peripherals & programming issues (NOT emulators!)
User avatar
1024MAK
Posts: 7202
Joined: Mon Apr 18, 2011 4:46 pm
Location: Looking forward to summer in Somerset, UK...
Contact:

Re: Random pixels on BBC Model B

Postby 1024MAK » Sun Dec 31, 2017 2:06 pm

JannievanZyl wrote:Meant, the exact bit pattern that would show the problem. Was hoping all the hints the system throw out would have pointed to a specific bit or range of addresses.

If the problem is a failure with only one DRAM chip, it will affect only a single bit, but typically affect many (if not all) addresses within that chips memory.

If the problem is that of an addressing error (the addressing of RAM in a BBC Micro is rather complex), then either the data is being written to more than one address, or maybe being read from more than one address and two chips are fighting one another's outputs.

As you now have problems with MODE 7 (and it's only 1k bytes of data), you could compare what the CPU reads from this memory area when you have corruption on screen. This will tell you for certain if the problem is a faulty DRAM chip, or a problem with the data being read by the display system/addressing of the DRAM by the display system.

The other thing to keep in mind, is that it is the display system that provides DRAM refresh. It does this by continually reading the DRAM even if the data is not needed for the display (/RAS and /CAS active for the addressed DRAM chip). As it scans through the addresses needed for the display, enough DRAM chip row addresses are scanned (/RAS goes active, but /CAS does not) so that ALL the DRAM chips will refresh the cells in that row. Also, in a DRAM chip, every time a memory cell is read, the stored value is destroyed, so circuitry in the chip has to restore the cell contents. It's possible that there is a fault in one of the DRAM chips where sometimes this data restoration is not working correctly, so as data is read by the display system, the corruption spreads...

So as you can see, identification of the cause from the symptoms is sometimes not so easy... :-(

Mark
For a "Complete BBC Games Archive" visit www.bbcmicro.co.uk NOW!
BeebWiki‬ - for answers to many questions...

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Sun Dec 31, 2017 4:04 pm

1024MAK wrote:
So as you can see, identification of the cause from the symptoms is sometimes not so easy... :-(

Mark

Indeed :D

Still throws me that it's 'red' that seems to trigger the most severe case of pixelitus.

I've ordered new RAM from Mark, as I know I'm going to replace something eventually. It's just the engineer in me that says one should understand exactly what's wrong and then fix that bit. And only that bit. [-X

If I've not figured it out by the end of this year, I'm pulling out the desoldering gun........

User avatar
DutchAcorn
Posts: 1714
Joined: Fri Mar 21, 2014 9:56 am
Location: Maarn, Netherlands
Contact:

Re: Random pixels on BBC Model B

Postby DutchAcorn » Sun Dec 31, 2017 4:06 pm

A pound sign in mode 7 is a nice smoking gun. If you see a pound sign where you should see a space character, it means you see ASCII 96 instead of ASCII 32. So bit 5 is sometimes stuck high (+64). If you get that in mode 7 with S25 north you are seeing it in the screen memory on a BBC B configuration, which is located in CAS1.

So I'd say the most likely culprit is IC58.
Paul

User avatar
1024MAK
Posts: 7202
Joined: Mon Apr 18, 2011 4:46 pm
Location: Looking forward to summer in Somerset, UK...
Contact:

Re: Random pixels on BBC Model B

Postby 1024MAK » Sun Dec 31, 2017 6:27 pm

Yes, but like I said earlier, it's worthwhile getting BASIC (the CPU) to read these MODE7 corrupted codes. Just so that we can see if the problem is the RAM, or the display system, or maybe the address decoding/encoding circuitry...

Mark
For a "Complete BBC Games Archive" visit www.bbcmicro.co.uk NOW!
BeebWiki‬ - for answers to many questions...

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Sun Dec 31, 2017 6:36 pm

Damn...nearly thought I had this,

Wrote a program that will write a single bit to the screen in Mode 1. All 8 bits are given an equal amount of screen space.

You can see the output of the program here.

Capture.JPG


You can see all the 'distortion' happens in the area where Bit 5 was written.

So, it must be Bit 5 in CAS1, right? IC58. Full of bravado, I replace IC58.

And the results stay the same....urg....

But it MUST be *something* to do with Bit 5, surely?

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Sun Dec 31, 2017 6:37 pm

DutchAcorn wrote:A pound sign in mode 7 is a nice smoking gun. If you see a pound sign where you should see a space character, it means you see ASCII 96 instead of ASCII 32. So bit 5 is sometimes stuck high (+64). If you get that in mode 7 with S25 north you are seeing it in the screen memory on a BBC B configuration, which is located in CAS1.

So I'd say the most likely culprit is IC58.


And my testing also pointed to IC58. But when I replaced IC58, no joy. :?

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Sun Dec 31, 2017 6:49 pm

So, my next test was to write 1 bit at a time to the whole block from &4000 to &7FFF.

But it pretty much point to the same thing. The pixels only appear when Bit-5 is written. Any other bit, no distortion appears.

Capture.JPG

User avatar
tricky
Posts: 2299
Joined: Tue Jun 21, 2011 8:25 am
Contact:

Re: Random pixels on BBC Model B

Postby tricky » Sun Dec 31, 2017 6:51 pm

Try writing bit 5 in the first part of the screen, as you had corruption there too, which would be a different chip.
If it is there, follow the path back from both b5s and see what they have in common.
I think it gets a bit crazy with 4MHz address latching, but I could easily be wrong!

User avatar
DutchAcorn
Posts: 1714
Joined: Fri Mar 21, 2014 9:56 am
Location: Maarn, Netherlands
Contact:

Re: Random pixels on BBC Model B

Postby DutchAcorn » Sun Dec 31, 2017 6:52 pm

JannievanZyl wrote:
DutchAcorn wrote:A pound sign in mode 7 is a nice smoking gun. If you see a pound sign where you should see a space character, it means you see ASCII 96 instead of ASCII 32. So bit 5 is sometimes stuck high (+64). If you get that in mode 7 with S25 north you are seeing it in the screen memory on a BBC B configuration, which is located in CAS1.

So I'd say the most likely culprit is IC58.


And my testing also pointed to IC58. But when I replaced IC58, no joy. :?

Darn. :(

And the distortion on your bit 5 tests disappears when using the inverter on S25, right?
Paul

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Sun Dec 31, 2017 7:49 pm

DutchAcorn wrote:
JannievanZyl wrote:
DutchAcorn wrote:A pound sign in mode 7 is a nice smoking gun. If you see a pound sign where you should see a space character, it means you see ASCII 96 instead of ASCII 32. So bit 5 is sometimes stuck high (+64). If you get that in mode 7 with S25 north you are seeing it in the screen memory on a BBC B configuration, which is located in CAS1.

So I'd say the most likely culprit is IC58.


And my testing also pointed to IC58. But when I replaced IC58, no joy. :?

Darn. :(

And the distortion on your bit 5 tests disappears when using the inverter on S25, right?

Yup

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Sun Dec 31, 2017 8:20 pm

OK, you might want to sit down for this......

(I'll admit I've had quite a few glasses of red, but I'm sure my code is correct.)

What I did was to keep bit-5 high and then cycle all the other bits, basically 1,2,4,8,16 with 32 added every time.

With bit-5 constantly high the distortion appears together with any bit turned on in the lower nibble, i.e. bit-0 to bit-3. We kinda expected this.

BUT....

When bit-5 is on with another bit in the higher nibble (bit-4 to bit-7), the distortion does not appear.......

So, writing 33, 34, 36 ,40 creates the problem as well as writing 32 (Bit-5 all by itself).

But 48, 96 and 160 show no issues.

If I interpret this correctly, it means that Bit-5 by itself or with any lower nibble bit creates the problem but with any higher nibble bit is OK. It's like the higher bits *fixes* the problem.

Now I'm first off to go a pour another glass of red! :D

When we get this solved, I'm buying the whole forum a virtual round!

User avatar
1024MAK
Posts: 7202
Joined: Mon Apr 18, 2011 4:46 pm
Location: Looking forward to summer in Somerset, UK...
Contact:

Re: Random pixels on BBC Model B

Postby 1024MAK » Sun Dec 31, 2017 9:27 pm

Yeah, weird!

Meanwhile, try something like this on a MODE 7 screen (remove the CLS commands, help text and maybe the garbage generator).

IMG_6006.JPG
IMG_6004.JPG

Mark
For a "Complete BBC Games Archive" visit www.bbcmicro.co.uk NOW!
BeebWiki‬ - for answers to many questions...

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Sun Dec 31, 2017 10:26 pm

1024MAK wrote:Yeah, weird!

Meanwhile, try something like this on a MODE 7 screen (remove the CLS commands, help text and maybe the garbage generator).

IMG_6006.JPGIMG_6004.JPG
Mark

Will do!

First watching the fireworks over Table Mountain. :D

Happy New Year from Cape Town!! :mrgreen:

crj
Posts: 830
Joined: Thu May 02, 2013 4:58 pm
Contact:

Re: Random pixels on BBC Model B

Postby crj » Mon Jan 01, 2018 4:27 am

JannievanZyl wrote:With bit-5 constantly high the distortion appears together with any bit turned on in the lower nibble, i.e. bit-0 to bit-3. We kinda expected this.

BUT....

When bit-5 is on with another bit in the higher nibble (bit-4 to bit-7), the distortion does not appear.......

Am I the only person beginning to wonder if this is strange enough to be a floating ground somewhere? It might be worth probing potential differences between the ground pins on the various ICs involved and the 0V power supply spades. Or using a reasonably thick bit of wire to give each chip in turn a really solid ground connection and see if that helps.


Have you had the mainboard out of the machine and checked there's nothing obviously awful that's happened to the rear side, by the way?

User avatar
1024MAK
Posts: 7202
Joined: Mon Apr 18, 2011 4:46 pm
Location: Looking forward to summer in Somerset, UK...
Contact:

Re: Random pixels on BBC Model B

Postby 1024MAK » Mon Jan 01, 2018 10:51 am

A dry joint is also a possibility...
Or a poor contact in a socket...

Mark
For a "Complete BBC Games Archive" visit www.bbcmicro.co.uk NOW!
BeebWiki‬ - for answers to many questions...

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Mon Jan 01, 2018 11:21 am

crj wrote:Have you had the mainboard out of the machine and checked there's nothing obviously awful that's happened to the rear side, by the way?


Yup, all looks good. But then dry joints, etc. often do.

I'll climb in with the scope today.

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Mon Jan 01, 2018 11:54 am

BTW, how can one continue a BASIC program after a Break?

User avatar
1024MAK
Posts: 7202
Joined: Mon Apr 18, 2011 4:46 pm
Location: Looking forward to summer in Somerset, UK...
Contact:

Re: Random pixels on BBC Model B

Postby 1024MAK » Mon Jan 01, 2018 11:58 am

OLD

Mark
For a "Complete BBC Games Archive" visit www.bbcmicro.co.uk NOW!
BeebWiki‬ - for answers to many questions...

User avatar
daveejhitchins
Posts: 4028
Joined: Wed Jun 13, 2012 5:23 pm
Location: Newton Aycliffe, County Durham
Contact:

Re: Random pixels on BBC Model B

Postby daveejhitchins » Mon Jan 01, 2018 2:05 pm

1024MAK wrote:OLD

Mark
I know - Don't get personal :evil:

Dave H :lol:
Parts: UM6502CE, GAL22V10D, GAL16V8D, AS6C62256A, TC514400AZ, WD1772, R6522, TMS27C512, AT28C256
Products: ARA II, ABR, ATI, AP6, MGC, AP5 . . .
For a price list, contact me at: Retro Hardware AT dave ej hitchins DOT plus DOT com

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Mon Jan 01, 2018 3:13 pm

OK, the plot thickens. Considerably.

Decided, bugger it and socketed and swapped all the RAM in CAS1 out with a second Model B I've got.

Not only is the problem still there but it's worse/different.

This is just putting it in Mode 1 and leaving it.

Capture.JPG


The RAM I took out works fine in the other machine.

So whatever showed as a Bit-5 issue seems to have spread. Clearly must be something I did in replacing the RAM, manhandling the board, heating / soldering. Maybe different timing.

I'll now focus on the chips around the RAM. Maybe I must first swap out the Video Controller?

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Mon Jan 01, 2018 3:24 pm

Swapping CAS0/1 still resolves the problem, so it must be something that is also affected by swapping the banks, right?

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

Re: Random pixels on BBC Model B

Postby hoglet » Mon Jan 01, 2018 4:01 pm

What's surprising to me is that the system seems to run reliably, apart from the video corruption. Is that true?

Can you tell if the CPU ever sees bad data?

For example, if you get a corruption in Mode 7, then *SAVE the screen, then *DUMP the contents, do you see the corruption?

Another interesting test would be in Mode 7, set PAGE=&4000, then enter a short basic program and see if this ever gets corrupted.

Also, in the mode recent screen shot, is the pattern of corruption static, or constantly changing?

What happens if you then do:

Code: Select all

P%=&2000
[SEI:JMP&2001
CALL&2000

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Mon Jan 01, 2018 4:11 pm

OK, found it. One of the '245's. IC14.

When I replaced the LS245 with a HC245, it resolved the 'pixel' problem, but the machine became unstable. For example, it would randomly hang and would never complete loading a program from tape.

So I took a LS245 from the other machine and now it all seems fine.

It was already socketed, so I (falsely) assumed it was probably replaced recently and thus should be OK.

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Mon Jan 01, 2018 4:13 pm

Thanks for all the super help and support in this thread.

That virtual round is for sure on me!! :D

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

Re: Random pixels on BBC Model B

Postby hoglet » Mon Jan 01, 2018 4:14 pm

=D> =D> =D> =D> =D> =D> =D>

User avatar
tricky
Posts: 2299
Joined: Tue Jun 21, 2011 8:25 am
Contact:

Re: Random pixels on BBC Model B

Postby tricky » Mon Jan 01, 2018 4:31 pm

Glad it is sorted.

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Mon Jan 01, 2018 4:33 pm

See, no "pixels"!! :D :D

Capture.JPG

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Mon Jan 01, 2018 4:39 pm

tricky wrote:Glad it is sorted.

Thanks for all the help!

Mark (retroclinic) is sending me some goodies to add to the systems, so soon I'll be (semi-)literate on these machines.

I really enjoy fixing them, you learn a huge amount actually working on them.

Next job now is to fix the PSU on a Z80 Torch dual-floppy unit I have here.

I still have a faulty Electron to get working and then I must tackle about 8 or so Acorn RISC systems waiting for me. Then the 'Acorn' family is complete.

User avatar
1024MAK
Posts: 7202
Joined: Mon Apr 18, 2011 4:46 pm
Location: Looking forward to summer in Somerset, UK...
Contact:

Re: Random pixels on BBC Model B

Postby 1024MAK » Mon Jan 01, 2018 11:56 pm

Just so you know, the 74LS245 in position IC14 is a known cause of what appears to be RAM problems, but your problem at first did not appear to be a typical symptom of a faulty 74LS245....!

Anyway, I glad that you have fixed it :D

Mark
For a "Complete BBC Games Archive" visit www.bbcmicro.co.uk NOW!
BeebWiki‬ - for answers to many questions...

JannievanZyl
Posts: 145
Joined: Sat Feb 11, 2017 8:56 pm
Location: Cape Town, South Africa
Contact:

Re: Random pixels on BBC Model B

Postby JannievanZyl » Tue Jan 02, 2018 1:57 pm

1024MAK wrote:Just so you know, the 74LS245 in position IC14 is a known cause of what appears to be RAM problems, but your problem at first did not appear to be a typical symptom of a faulty 74LS245....!

Anyway, I glad that you have fixed it :D

Mark


100%!

I read it in a few places as well but, as you say, the whole bit-5 thing threw me as well.

Also, this specific one was already on a socket, so I assume it's been replaced before.