Forum Announcement
22/04/2018 - The Online Chat isn't working via the normal link.
You can connect via IRC, or using another web client - https://kiwiirc.com/client/chat.qlforum.co.uk/#qlforum

Gold Card / Super Gold Card ROM patching...

Nagging hardware related question? Post here!
User avatar
Pr0f
Trump Card
Posts: 235
Joined: Thu Oct 12, 2017 9:54 am

Gold Card / Super Gold Card ROM patching...

Postby Pr0f » Fri Dec 15, 2017 1:39 pm

Not sure if this has been asked before, but my search didn't come up with anything specific, so here goes.

The Gold Card and Super Gold Card, copy the current ROM image in the lower 48K and then 'modify or patch' it for use with these cards. Does anyone have any more detailed notes on exactly which areas of the ROM are patched, and how the GC/SGC deals with the many different ROM versions out there, where the patched routines may for instance move location within the ROM?


User avatar
tofro
QL Wafer Drive
Posts: 1339
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: Gold Card / Super Gold Card ROM patching...

Postby tofro » Fri Dec 15, 2017 2:09 pm

The best information on that can be had from the SMSQ/E sources - SMSQ/E does pretty much the same thing on a GC/SGC.

Tobias


User avatar
Pr0f
Trump Card
Posts: 235
Joined: Thu Oct 12, 2017 9:54 am

Re: Gold Card / Super Gold Card ROM patching...

Postby Pr0f » Fri Dec 15, 2017 2:23 pm

I have those downloaded, will have to have a peek at them.

I am guessing that the GC/SGC still respect the trap and vector addresses from the ROM's, otherwise things like the I2C on the Minerva wouldn't work.


User avatar
tofro
QL Wafer Drive
Posts: 1339
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: Gold Card / Super Gold Card ROM patching...

Postby tofro » Fri Dec 15, 2017 3:53 pm

Pr0f wrote:I have those downloaded, will have to have a peek at them.

I am guessing that the GC/SGC still respect the trap and vector addresses from the ROM's, otherwise things like the I2C on the Minerva wouldn't work.


No, they obviously can't - They replace the complete ROM with RAM and use their own interrupt service routines - I think Minerva I2C has received special care in SMSQ/E, though.

Tobias


User avatar
Pr0f
Trump Card
Posts: 235
Joined: Thu Oct 12, 2017 9:54 am

Re: Gold Card / Super Gold Card ROM patching...

Postby Pr0f » Fri Dec 15, 2017 7:15 pm

Strictly speaking the ROM is copied to the RAM and occupies the same address space it would have done in a standard QL, so the vectors could all still be valid...


Derek_Stewart
Aurora
Posts: 974
Joined: Mon Dec 20, 2010 11:40 am
Location: Runcorn, Cheshire, UK

Re: Gold Card / Super Gold Card ROM patching...

Postby Derek_Stewart » Fri Dec 15, 2017 9:41 pm

Hi,

Pr0f wrote:Strictly speaking the ROM is copied to the RAM and occupies the same address space it would have done in a standard QL, so the vectors could all still be valid...


So if you are correct, to get SMSQ/E working on a BBQL with ram expansion, the copy to ram should disabled.

Somehow I think it is not tgat simple.


Regards,

Derek
User avatar
tofro
QL Wafer Drive
Posts: 1339
Joined: Sun Feb 13, 2011 10:53 pm
Location: SW Germany

Re: Gold Card / Super Gold Card ROM patching...

Postby tofro » Fri Dec 15, 2017 9:52 pm

Pr0f wrote:Strictly speaking the ROM is copied to the RAM and occupies the same address space it would have done in a standard QL, so the vectors could all still be valid...


Well, directly after the copy the vectors still point to the same addresses in copied code as in ROM - But we don't want a 100% copy - as soon as you start to patch, this might simply no longer be possible, because routines have to be moved for lack of space etc.

Tobias


User avatar
Pr0f
Trump Card
Posts: 235
Joined: Thu Oct 12, 2017 9:54 am

Re: Gold Card / Super Gold Card ROM patching...

Postby Pr0f » Fri Dec 15, 2017 10:35 pm

Derek_Stewart wrote:Hi,

Pr0f wrote:Strictly speaking the ROM is copied to the RAM and occupies the same address space it would have done in a standard QL, so the vectors could all still be valid...


So if you are correct, to get SMSQ/E working on a BBQL with ram expansion, the copy to ram should disabled.

Somehow I think it is not tgat simple.


Derek - no offence, but the question in the original post was regarding the original QL ROM based OS - I made no mention of SMSQ in my initial post. It's perfectly possible to run QDOS on a GC or SGC I believe. I realise that running SMSQ requires quite a bit more work - but that wasn't my question - sorry.


User avatar
Pr0f
Trump Card
Posts: 235
Joined: Thu Oct 12, 2017 9:54 am

Re: Gold Card / Super Gold Card ROM patching...

Postby Pr0f » Fri Dec 15, 2017 10:36 pm

tofro wrote:
Pr0f wrote:Strictly speaking the ROM is copied to the RAM and occupies the same address space it would have done in a standard QL, so the vectors could all still be valid...


Well, directly after the copy the vectors still point to the same addresses in copied code as in ROM - But we don't want a 100% copy - as soon as you start to patch, this might simply no longer be possible, because routines have to be moved for lack of space etc.

Tobias


Exactly - and it's what modifications take place that I am interested in.


User avatar
Dave
SandySuperQDave
Posts: 1867
Joined: Sat Jan 22, 2011 6:52 am
Location: Austin, TX
Contact:

Re: Gold Card / Super Gold Card ROM patching...

Postby Dave » Fri Dec 15, 2017 10:37 pm

Can't you just make an image of the edited ROM, then compare it against the original? A lot of stuff has to align up still, so it's only going to be simple substitutions of specific locations/vectors etc?



Return to “Hardware”

Who is online

Users browsing this forum: No registered users and 2 guests