Author Topic: Amstrad Diagnostics ROM  (Read 2222 times)

0 Members and 1 Guest are viewing this topic.

Offline llopis

  • Supporter
  • CPC6128
  • *
  • Posts: 284
  • Country: es
    • Noel's Retro Lab
  • Liked: 157
  • Likes Given: 133
Amstrad Diagnostics ROM
« on: 18:35, 24 February 21 »
Hi everybody,

I decided to create a diagnostics ROM for Amstrad CPC (and Plus down the line I suppose). A lot of it was done by combining and enhancing exiting code other people wrote and were kind enough to release (including Gerald with his famous "quick and dirty test"). You can find it here: https://github.com/llopis/amstrad-diagnostics

Right now it does a few things:
  • Lower 64KB RAM test.
  • Upper 64KB RAM test.
  • [Dandanator build only] Check the low system ROM is valid.
  • Check that upper system ROMs are valid.
  • Detect CRTC model.
One of the enhancement over the "quick and dirty" RAM test is that it explains which bits are failing by labeling them. No more forgetting if the LSB is in the top or the bottom!  :D


There's a lot that can be improved, but it's a start. If anybody has any suggestions or even straight contributions, please let me know.

Offline Audronic

  • 6128 Plus
  • ******
  • Posts: 1.388
  • Country: au
  • I know RST3 . I now know a little More.
  • Liked: 307
  • Likes Given: 710
Re: Amstrad Diagnostics ROM
« Reply #1 on: 07:55, 25 February 21 »

@llopis

Ok Is this the correct screen for a Known good working 6128 with Parados 1.2 rom (Internal)
Thanks for the Diag V0.1
Keep Safe
Ray



« Last Edit: 07:59, 25 February 21 by Audronic »
Procrastinators Unite,
If it Ain't Broke PLEASE Don't Fix it.
I keep telling you I am Not Pedantic.
As I Live " Down Under " I Take my Gravity Tablets and Wear my Magnetic Boots to Keep me from Falling off.

Offline Sid_

  • CPC664
  • ***
  • Posts: 117
  • Country: fr
  • Liked: 101
  • Likes Given: 225
Re: Amstrad Diagnostics ROM
« Reply #2 on: 09:03, 25 February 21 »
This diag rom may be installed on the c4cpc ?

Offline Duke

  • Supporter
  • 6128 Plus
  • *
  • Posts: 1.235
  • Country: dk
    • spinpoint.org
  • Liked: 1443
  • Likes Given: 1138
Re: Amstrad Diagnostics ROM
« Reply #3 on: 09:09, 25 February 21 »
If anybody has any suggestions or even straight contributions, please let me know.
Maybe include ram C1/C3 page mapping check. Feel free to use any parts of this https://github.com/M4Duke/z80/blob/master/RAM512KB.s

Offline llopis

  • Supporter
  • CPC6128
  • *
  • Posts: 284
  • Country: es
    • Noel's Retro Lab
  • Liked: 157
  • Likes Given: 133
Re: Amstrad Diagnostics ROM
« Reply #4 on: 09:35, 25 February 21 »
Ok Is this the correct screen for a Known good working 6128 with Parados 1.2 rom (Internal)
Ha! Technically yes, but I should change it. The purpose of the ROM check is just to make sure the standard ROMs are not corrupted. Right now I walk 0 through 15 and compare them against the CRC of a few known ROMs. So I should check 0 and 7 just to start and maybe get the CRCs for a few more popular ROMs like Parados.


I actually always use standard ROMs, but which ones out there are worth checking against? Parados, SymbiOS? What else?


Actually looking at that it's weird that all of them return the same CRC. Does Parados map the same 16KB in every bank or something? Otherwise something fishy is happening there.

Offline llopis

  • Supporter
  • CPC6128
  • *
  • Posts: 284
  • Country: es
    • Noel's Retro Lab
  • Liked: 157
  • Likes Given: 133
Re: Amstrad Diagnostics ROM
« Reply #5 on: 09:37, 25 February 21 »
This diag rom may be installed on the c4cpc ?
No idea! I haven't even tested it on a Plus. It will for sure complain about unknown ROMs, but it's possible that the rest of things will work.
I'll look into getting C4CPC support when I test it on the Plus.

Offline llopis

  • Supporter
  • CPC6128
  • *
  • Posts: 284
  • Country: es
    • Noel's Retro Lab
  • Liked: 157
  • Likes Given: 133
Re: Amstrad Diagnostics ROM
« Reply #6 on: 09:38, 25 February 21 »
Maybe include ram C1/C3 page mapping check. Feel free to use any parts of this https://github.com/M4Duke/z80/blob/master/RAM512KB.s
Yes, I've already gotten a request to check C3 specifically. I'll do that and also check all available RAM, so that code will come in handy I think. Thank you!

Offline Audronic

  • 6128 Plus
  • ******
  • Posts: 1.388
  • Country: au
  • I know RST3 . I now know a little More.
  • Liked: 307
  • Likes Given: 710
Re: Amstrad Diagnostics ROM
« Reply #7 on: 09:56, 25 February 21 »
Hi Noel


Photos from CPC6128 Standard rom


The id of rom 7 Varies ? 8179  - 2162 at restart (Power up ) I Varies each power up.


Keep safe


Ray


 
« Last Edit: 09:59, 25 February 21 by Audronic »
Procrastinators Unite,
If it Ain't Broke PLEASE Don't Fix it.
I keep telling you I am Not Pedantic.
As I Live " Down Under " I Take my Gravity Tablets and Wear my Magnetic Boots to Keep me from Falling off.

Offline llopis

  • Supporter
  • CPC6128
  • *
  • Posts: 284
  • Country: es
    • Noel's Retro Lab
  • Liked: 157
  • Likes Given: 133
Re: Amstrad Diagnostics ROM
« Reply #8 on: 10:36, 25 February 21 »
Hi Noel

Photos from CPC6128 Standard rom


The id of rom 7 Varies ? 8179  - 2162 at restart (Power up ) I Varies each power up.


Keep safe


Ray
Interesting. I see your startup screen is branded Awa. Is that something you did with the links, or was it like that originally? I wonder if your ROMs are very slightly different than the standard English ROMs.
I don't see anything about different Awa ROMs here: http://www.cpcwiki.eu/index.php/ROM_List


The fact that it's repeating Unknown is normal because it's not able to ID your 0 upper ROM (BASIC) and then as it keeps trying new ROMs in other slots the same one comes up. Which even tells me that your BASIC ROM doesn't have the &80 ID byte that it's supposed to have, because if it did it would skip it in the checks.


Edit: I didn't answer the varying number next to ROM 7 (AMSDOS supposedly). Unless there's a bug, that's supposed to be a CRC16 of the ROM contents. So the fact that it varies is REALLY weird. Especially seeing how the machine is working.
« Last Edit: 10:58, 25 February 21 by llopis »

Offline Audronic

  • 6128 Plus
  • ******
  • Posts: 1.388
  • Country: au
  • I know RST3 . I now know a little More.
  • Liked: 307
  • Likes Given: 710
Re: Amstrad Diagnostics ROM
« Reply #9 on: 11:06, 25 February 21 »

[size=78%]Hi Noel[/size]


Interesting. I see your startup screen is branded Awa. Is that something you did with the links, or was it like that originally? I wonder if your ROMs are very slightly different than the standard English ROMs.
I don't see anything about different Awa ROMs here: http://www.cpcwiki.eu/index.php/ROM_List


[size=78%]The fact that it's repeating Unknown is normal because it's not able to ID your 0 upper ROM (BASIC) and then as it keeps trying new ROMs in other slots the same one comes up. Which even tells me that your BASIC ROM doesn't have the &80 ID byte that it's supposed to have, because if it did it would skip it in the checks.[/size]

Edit: I didn't answer the varying number next to ROM 7 (AMSDOS supposedly). Unless there's a bug, that's supposed to be a CRC16 of the ROM contents. So the fact that it varies is REALLY weird. Especially seeing how the machine is working.
\


The links on the mother board are set in Australia for AWAThe Rom is Still the Factory rom (second set of Photos)
I reset the machine 2 ways 1) by the reset button on the lower Rom board, 2) Turned power on.
The number just keeps changing


I hope that helps


Keep Safe


Ray
« Last Edit: 11:08, 25 February 21 by Audronic »
Procrastinators Unite,
If it Ain't Broke PLEASE Don't Fix it.
I keep telling you I am Not Pedantic.
As I Live " Down Under " I Take my Gravity Tablets and Wear my Magnetic Boots to Keep me from Falling off.

Offline llopis

  • Supporter
  • CPC6128
  • *
  • Posts: 284
  • Country: es
    • Noel's Retro Lab
  • Liked: 157
  • Likes Given: 133
Re: Amstrad Diagnostics ROM
« Reply #10 on: 11:30, 25 February 21 »
Which ROM board are you using to test the diagnostics ROM? Not like that's likely to be the culprit, but just in case.


Is there any chance you could dump your 0 and 7 ROMs? I'm sure there has to be a BASIC program to do it somewhere, or I can write one for you really quickly. I'd love to do a diff against the English BASIC 1.1 and AMSDOS ROMs and see where it differs.


Dang, I just had this brilliant insight thinking that somehow the diagnostics ROM was mapped to bank 0 (in addition to the lower ROM), but I just checked its CRC and it's not the one you're getting!


As for the changing one... I'm baffled. It's as if it's a "fake" ROM that includes a current clock time or something like that. It's the only explanation I can think of. Do you ever get the same number if you try twice in a row, or is it different every time? (that would support the clock theory).

Offline Audronic

  • 6128 Plus
  • ******
  • Posts: 1.388
  • Country: au
  • I know RST3 . I now know a little More.
  • Liked: 307
  • Likes Given: 710
Re: Amstrad Diagnostics ROM
« Reply #11 on: 14:30, 25 February 21 »
The roms in the cpc6128 are standard roms
40015 and 40025

The Rom board that I am using is the Bryce LowerRom Board

Yes the Number changes each time


Ray
Procrastinators Unite,
If it Ain't Broke PLEASE Don't Fix it.
I keep telling you I am Not Pedantic.
As I Live " Down Under " I Take my Gravity Tablets and Wear my Magnetic Boots to Keep me from Falling off.

Offline llopis

  • Supporter
  • CPC6128
  • *
  • Posts: 284
  • Country: es
    • Noel's Retro Lab
  • Liked: 157
  • Likes Given: 133
Re: Amstrad Diagnostics ROM
« Reply #12 on: 19:15, 27 February 21 »
The roms in the cpc6128 are standard roms
40015 and 40025

The Rom board that I am using is the Bryce LowerRom Board

Yes the Number changes each time


Ray
Hi Ray,
If you get a chance, could you dump those ROMs and send them to me? I created a quick program to do that: https://github.com/llopis/amstrad-diagnostics/tree/main/ROMDump


On a related note, anybody knows who is maintaining the page of Amstrad ROMs in the Wiki? http://www.cpcwiki.eu/index.php/ROM_List I have come across some weird official ROMs that aren't there and it would be nice to make it more comprehensive.

Offline Bryce

  • The Hardware Guy.
  • Supporter
  • 6128 Plus
  • *
  • Posts: 12.166
  • Country: wf
  • It's not broken, it just hasn't been fixed yet.
    • index.php?action=treasury
  • Liked: 4501
  • Likes Given: 474
Re: Amstrad Diagnostics ROM
« Reply #13 on: 20:44, 27 February 21 »
Hi Ray,
If you get a chance, could you dump those ROMs and send them to me? I created a quick program to do that: https://github.com/llopis/amstrad-diagnostics/tree/main/ROMDump


On a related note, anybody knows who is maintaining the page of Amstrad ROMs in the Wiki? http://www.cpcwiki.eu/index.php/ROM_List I have come across some weird official ROMs that aren't there and it would be nice to make it more comprehensive.

The CPCWiki is a... Wiki. Anyone can maintain or add content to any page they want. What "weird official ROMs" do you have?

Bryce.

Offline llopis

  • Supporter
  • CPC6128
  • *
  • Posts: 284
  • Country: es
    • Noel's Retro Lab
  • Liked: 157
  • Likes Given: 133
Re: Amstrad Diagnostics ROM
« Reply #14 on: 22:47, 27 February 21 »
The CPCWiki is a... Wiki. Anyone can maintain or add content to any page they want. What "weird official ROMs" do you have?
Ah, got it! I thought it was more curated than that. Happy to add any different ROMs I find then.


Apparently the Spanish 464 Schneider has a different ROM. Not sure what the difference is yet, but the CRC doesn't match. I'm hoping to get a dump tomorrow and confirm that.


It's also possible that Ray's Awa-branded 6128 has a different ROM too. Probably just a few bytes off, but it would be interesting to preserve them.

Offline rpalmer

  • 6128 Plus
  • ******
  • Posts: 564
  • Country: au
  • Liked: 383
  • Likes Given: 18
Re: Amstrad Diagnostics ROM
« Reply #15 on: 23:06, 27 February 21 »
There various different lower ROMs to handle the different keyboard layouts.
1. The default UK English/Australian QWERTY layout.
2. The French with the AZERTY layout.3. The German layout with accented keys.4. The Spanish layout with different accented keys to the German layout.
I think that is most if not all.
As for BASIC ROMs there are several notably 1.0 and 1.1. There are several other with patches for fixes to routines and speed up of others.
The sign on message is based on the link setting on the motherboard which are used as an index into a table of possible sign on messages types.

Offline llopis

  • Supporter
  • CPC6128
  • *
  • Posts: 284
  • Country: es
    • Noel's Retro Lab
  • Liked: 157
  • Likes Given: 133
Re: Amstrad Diagnostics ROM
« Reply #16 on: 23:54, 27 February 21 »
There various different lower ROMs to handle the different keyboard layouts.
1. The default UK English/Australian QWERTY layout.
2. The French with the AZERTY layout.3. The German layout with accented keys.4. The Spanish layout with different accented keys to the German layout.
I think that is most if not all.
As for BASIC ROMs there are several notably 1.0 and 1.1. There are several other with patches for fixes to routines and speed up of others.
The sign on message is based on the link setting on the motherboard which are used as an index into a table of possible sign on messages types.


Right, I know that. But I'm already detecting the English/Spanish/French variations (no German yet) https://github.com/llopis/amstrad-diagnostics/blob/main/src/ROMTable.asm and that Schneider one in that 464 isn't one of them.
I also know the branding comes from the links, which makes the Awa ROM difference very curious.

Offline Audronic

  • 6128 Plus
  • ******
  • Posts: 1.388
  • Country: au
  • I know RST3 . I now know a little More.
  • Liked: 307
  • Likes Given: 710
Re: Amstrad Diagnostics ROM
« Reply #17 on: 00:07, 28 February 21 »
Hi Noel


Ok I have the CPC 6128 at the ready


which rom numbers do you want me to dump ?


Thanks


Ray



Procrastinators Unite,
If it Ain't Broke PLEASE Don't Fix it.
I keep telling you I am Not Pedantic.
As I Live " Down Under " I Take my Gravity Tablets and Wear my Magnetic Boots to Keep me from Falling off.

Offline Audronic

  • 6128 Plus
  • ******
  • Posts: 1.388
  • Country: au
  • I know RST3 . I now know a little More.
  • Liked: 307
  • Likes Given: 710
Re: Amstrad Diagnostics ROM
« Reply #18 on: 00:24, 28 February 21 »
Hi Noel


Ok I can Dump LOW OK
If I try to Dump  7 The CPC6128 Crashes ?
I have included the dump of LOW only

I have also tried it on another cpc6128 this also crashes on ROM 7

Keep Safe


Ray
« Last Edit: 00:54, 28 February 21 by Audronic »
Procrastinators Unite,
If it Ain't Broke PLEASE Don't Fix it.
I keep telling you I am Not Pedantic.
As I Live " Down Under " I Take my Gravity Tablets and Wear my Magnetic Boots to Keep me from Falling off.

Offline pelrun

  • Supporter
  • 6128 Plus
  • *
  • Posts: 718
  • Country: au
    • index.php?action=treasury
  • Liked: 386
  • Likes Given: 253
Re: Amstrad Diagnostics ROM
« Reply #19 on: 05:19, 28 February 21 »
Awa is absolutely in the standard English ROMs, although it was only really used in the early days of the Australian market before Amstrad established their own sales office here.
My circa-86 6128 was originally Awa, but after I blew the AY from static discharge it went off for repair and came back as Amstrad (I guess they just swapped the mainboard out.) I've since changed the links back to Awa :)

Offline Bryce

  • The Hardware Guy.
  • Supporter
  • 6128 Plus
  • *
  • Posts: 12.166
  • Country: wf
  • It's not broken, it just hasn't been fixed yet.
    • index.php?action=treasury
  • Liked: 4501
  • Likes Given: 474
Re: Amstrad Diagnostics ROM
« Reply #20 on: 12:08, 28 February 21 »
I thought we had all variations dumped and available here: http://www.cpcwiki.eu/index.php/ROM_List

Bryce.

Offline llopis

  • Supporter
  • CPC6128
  • *
  • Posts: 284
  • Country: es
    • Noel's Retro Lab
  • Liked: 157
  • Likes Given: 133
Re: Amstrad Diagnostics ROM
« Reply #21 on: 13:27, 28 February 21 »
Ok I can Dump LOW OK
If I try to Dump  7 The CPC6128 Crashes ?
I have included the dump of LOW only
Hi Ray,
Thanks! The crash was a bug on my part (not restoring ROM state) so that's fixed. But from the other dumps was enough: Your ROMs are indeed standard English ROMs.
So I wonder why the diagnostics ROM is reporting weird CRCs. I don't have that ROM extender, so I can't try it, but I wonder if it's mapping that ROM in the lower ROM and all the upper ROM slots? That's pretty weird.
I will make a version of the diagnostics ROM to load it in upper ROM anyway for people who want to use it from an M4 or something like that.


I thought we had all variations dumped and available here: http://www.cpcwiki.eu/index.php/ROM_List
I thought so too, but as I said, there is a special ROM that Schneider added to the Spanish 464s (they pretty much scratched Amstrad and wrote Schneider). I don't know if we want it or not since technically it's not exactly Amstrad. But if we do, I'm happy to add it to the page.

Offline robcfg

  • Supporter
  • 6128 Plus
  • *
  • Posts: 2.391
  • Country: se
  • 8-Bit Technomancer
    • index.php?action=treasury
  • Liked: 1081
  • Likes Given: 2620
Re: Amstrad Diagnostics ROM
« Reply #22 on: 14:44, 28 February 21 »
Well, we cover a lot of peripherals that were not made by Amstrad, and Schneider was the german distributor of Amstrad, so I think it fits pretty well here.


Even if that weren't the case, I'd rather have it here than lost, so please add it.

Offline llopis

  • Supporter
  • CPC6128
  • *
  • Posts: 284
  • Country: es
    • Noel's Retro Lab
  • Liked: 157
  • Likes Given: 133
Re: Amstrad Diagnostics ROM
« Reply #23 on: 20:33, 28 February 21 »
Ok I can Dump LOW OK
By the way, I just released an upper ROM version for those with ROM boards that can't map the low ROM (or if it's more convenient). I suspect that version will report your existing ROMs correctly. I still can't figure out why that one caused the CRCs to be off.

Offline Audronic

  • 6128 Plus
  • ******
  • Posts: 1.388
  • Country: au
  • I know RST3 . I now know a little More.
  • Liked: 307
  • Likes Given: 710
Re: Amstrad Diagnostics ROM
« Reply #24 on: 00:47, 01 March 21 »
Hi Noel


for completeness I have used the Version 2 romdump and was able to dump 0 and 7
I include a copy for your reference.


Thanks
Keep Safe


Ray
Procrastinators Unite,
If it Ain't Broke PLEASE Don't Fix it.
I keep telling you I am Not Pedantic.
As I Live " Down Under " I Take my Gravity Tablets and Wear my Magnetic Boots to Keep me from Falling off.