Loading a ROM into SW Ram - basics

discuss both original and modern hardware for the bbc micro/electron
rph
Posts: 65
Joined: Wed Jun 05, 2019 4:46 pm
Contact:

Loading a ROM into SW Ram - basics

Post by rph »

Hi
I'm new to this but am getting very lost. I've been reading posts and researching but can't seem to get any closer.
I've run the *SWRTEST and all fine.

After many hours of searching and looking I think I might actually be understanding it more.
I think I'm just needing to find out how to get a ROM such as the below loaded into SW RAM from my Gotek. Do I have to somehow get it onto a .dsd on the gotek?

ROMs Disk 1
http://mdfs.net/Mirror/Image/JGH/
Or is there some way to load a ROM into SW Ram from my Gotek. Such as the ones above?

Any help appreciated as I fear I'm getting very muddled.
User avatar
jms2
Posts: 2767
Joined: Mon Jan 08, 2007 6:38 am
Location: Derby, UK
Contact:

Re: Loading a ROM into SW Ram - basics

Post by jms2 »

The problem breaks down into two stages:
1. Getting the file onto a disc image (eg, a .ssd file) that you can load into your Gotek.
2. Loading the file from the disc image into sideways ram.

For step 1, you need a disc image editor which will allow you to create a new blank disc image and copy the file onto it. Search on here for "beeb image" - it was written by someone on here and is the best tool for the job. Other tools are available online as well. By the way, I'm assuming you are using Windows (I don't know about the tools for Linux but they definitely exist!).

For step 2, you have the problem that you cannot simply *LOAD files into sideways ram. If you have a Master you can use the built in *SRLOAD command. On a Model B, you will need to find a disc image with SRLOAD on it. There is one on the MDFS site, I think it is called SRAM utilities.

Using Beeb image you need to create a disk which contains any roms that you wish to try, together with the SRLOAD program.

Then the syntax is

*SRLOAD ROMIMAGE 8000 4

Where ROMIMAGE is the filename and 4 is the slot that you want to load into.

If you have a BBC it would be a good idea to put *ROMS onto the disc as well. This shows what is loaded into all 16 slots and so is very useful.
rph
Posts: 65
Joined: Wed Jun 05, 2019 4:46 pm
Contact:

Re: Loading a ROM into SW Ram - basics

Post by rph »

Hi
Thanks, I've only got a mac at home. So not sure if I'll be able to!
To test I was using the .ssd from:
http://mdfs.net/Mirror/Image/JGH/

I seemed to be able to run it to my beeb using *SRLOAD name 8000 15, but could no get any further to actually run it, or see if it worked. Any idea how I'd do this?

R
User avatar
KenLowe
Posts: 1625
Joined: Mon Oct 18, 2004 5:35 pm
Location: UK
Contact:

Re: Loading a ROM into SW Ram - basics

Post by KenLowe »

Alternatively, you can use the EELOAD utility by Martin Barr to load a ROM image into a SWR bank. I've included a copy of this, along with BasicEd in the attached. Copy this ssd file over to your Gotek USB stick. To install the ROM, at the > prompt, type:

*EELOAD BASICED x

Where x is the SWRAM bank you want to install the ROM into. The number is hexadecimal, so use 0 thru F for banks 0 thru 15.

Edit: Once installed, reset your machine with Ctrl-Break, and then *BE to run the program.
Attachments
SWRUtil.ssd
(200 KiB) Downloaded 51 times
rph
Posts: 65
Joined: Wed Jun 05, 2019 4:46 pm
Contact:

Re: Loading a ROM into SW Ram - basics

Post by rph »

You absolute star! This works a treat.
How did you get the ROM onto the .SSD? I have access to a Windows PC at school and the IT support might even install a package if I ask nicely. I'm assuming there is no mac alternative?

Thanks again.
Ralph
User avatar
hoglet
Posts: 9800
Joined: Sat Oct 13, 2012 7:21 pm
Location: Bristol
Contact:

Re: Loading a ROM into SW Ram - basics

Post by hoglet »

You might want to consider John Welch's DFS Explorer which runs on the MAC:
https://www.g7jjf.com/mac_dfs_explorer.htm

It's shareware and costs £5.00 to get a version that will let you save.

But for free you can download it and test whether it works on what ever version of MACOS you are using.

(BTW, I use the windows version of this, not the MAC version)

Dave
rph
Posts: 65
Joined: Wed Jun 05, 2019 4:46 pm
Contact:

Re: Loading a ROM into SW Ram - basics

Post by rph »

Hi
Now trying to do it myself I'm only getting so far....
I've been able to install beebem on the mac and copy over (import files from disk) the ROM to a blank .dsd. When I try to load up using
*SRLOAD BASICED 8000 15
I get:
illegal address
Doing the same with the previous downloaded file it runs fine.

ALT i also the downloaded EELOAD .ssd file, removed the BASICED rom in beebem, the added it again. When I then tried to run it the screen turned into a mess of multicoloured lines (beeb version of BSOD?).

If it's just a case of beebem not being up to the job and me having to pay £5 for the MAC DFS explorer I shall do (though will will need to wait till pay day!)

Thanks
Ralph
User avatar
jgharston
Posts: 4254
Joined: Thu Sep 24, 2009 12:22 pm
Location: Whitby/Sheffield
Contact:

Re: Loading a ROM into SW Ram - basics

Post by jgharston »

rph wrote:
Sat Oct 26, 2019 9:50 am
I seemed to be able to run it to my beeb using *SRLOAD name 8000 15, but could no get any further to actually run it, or see if it worked. Any idea how I'd do this?
You then need to press Ctrl-Break to let the operating system recognise and initialise it. Depending on what system you're using and what ROM you're loading, you can sometimes also use an I option in the SRLOAD command to insert it into the MOS's ROM table, viz:

*SRLOAD name 8000 15 I

This will only work with ROMs where the only thing they need is to be physically present. It won't work with ROMs that actually do need to go through the Ctrl-Break initialisation to work, receiving the Ctrl-Break service calls, etc.

Code: Select all

$ bbcbasic
PDP11 BBC BASIC IV Version 0.32
(C) Copyright J.G.Harston 1989,2005-2020
>_
User avatar
jgharston
Posts: 4254
Joined: Thu Sep 24, 2009 12:22 pm
Location: Whitby/Sheffield
Contact:

Re: Loading a ROM into SW Ram - basics

Post by jgharston »

rph wrote:
Sat Oct 26, 2019 1:14 pm
I've been able to install beebem on the mac and copy over (import files from disk) the ROM to a blank .dsd. When I try to load up using
*SRLOAD BASICED 8000 15
I get:
illegal address
Some SRLOAD commands use decimal for the ROM number, some use hex (some will allow either). Try *SRLOAD BASICED 8000 F

Code: Select all

$ bbcbasic
PDP11 BBC BASIC IV Version 0.32
(C) Copyright J.G.Harston 1989,2005-2020
>_
rph
Posts: 65
Joined: Wed Jun 05, 2019 4:46 pm
Contact:

Re: Loading a ROM into SW Ram - basics

Post by rph »

Hi
I had tried the HEX but no luck.

I was just confused by how the version I put together via beebem had the exact 2 files on as the download (which I was able to load and then run fine) but the beebem version had the illegal address come up.
I'm assuming that means it hadn't loaded.
Ta
R
User avatar
KenLowe
Posts: 1625
Joined: Mon Oct 18, 2004 5:35 pm
Location: UK
Contact:

Re: Loading a ROM into SW Ram - basics

Post by KenLowe »

rph wrote:
Sat Oct 26, 2019 10:43 am
How did you get the ROM onto the .SSD?
I already had the ROM installed on my beeb, so I used *SRSAVE to write it to ssd.
rph wrote:
Sat Oct 26, 2019 1:14 pm
Now trying to do it myself I'm only getting so far....
I've been able to install beebem on the mac and copy over (import files from disk) the ROM to a blank .dsd. When I try to load up using
*SRLOAD BASICED 8000 15
I get:
illegal address
Doing the same with the previous downloaded file it runs fine.
I've just downloaded ROMS1.ssd image from mdfs.net, and mounted that in BeebEm (windows), then imported the latest basiced.rom from github to that ssd. I've then copied that ssd over to my gotek USB, and run the SRLOAD utility from the ssd to install BasicEd into one of my RAM banks. All worked without any issues.

Out of interest, what other ROMS have you got installed in your Beeb? Do you have another ROM that has a slightly different version of the SRLOAD command?

What message do you get if you type *SRLOAD without any parameters?
Last edited by KenLowe on Sat Oct 26, 2019 5:31 pm, edited 3 times in total.
User avatar
Wheel_nut
Posts: 506
Joined: Wed May 01, 2019 1:46 pm
Location: West of Scotland
Contact:

Re: Loading a ROM into SW Ram - basics

Post by Wheel_nut »

The *SRLOAD function is for the Master IIRC. There is an equivalent command *RLOAD for the Beeb and it is included in either Disc 5 or Disc 100 of the STH image, depending on which Image you have.

The syntax is *RLOAD filename F <Q> where F is the Sideways RAM Bank in Hex and Q is optional, loading QUICK but corrupts Main Memory.
#1 BBC Model B Issue 7 + 1770 DFS + Dual TEAC Floppy
#2 BBC Model B Issue 7 + 8271 DFS + Dual Floppy + Speech
#3 BBC Model B Issue 7 + 8271 DFS + Cumana Single Floppy + PiTubeDirect on KenLowe's Tube Level Shifter
User avatar
KenLowe
Posts: 1625
Joined: Mon Oct 18, 2004 5:35 pm
Location: UK
Contact:

Re: Loading a ROM into SW Ram - basics

Post by KenLowe »

Wheel_nut wrote:
Sat Oct 26, 2019 4:34 pm
The *SRLOAD function is for the Master IIRC.
SRAM utilities (which include *SRLOAD and *SRSAVE) are included with the Acorn 1770 DFS which can be installed in a suitable beeb.
User avatar
sweh
Posts: 2345
Joined: Sat Mar 10, 2012 12:05 pm
Location: New York, New York
Contact:

Re: Loading a ROM into SW Ram - basics

Post by sweh »

hoglet wrote:
Sat Oct 26, 2019 11:44 am
You might want to consider John Welch's DFS Explorer which runs on the MAC:
https://www.g7jjf.com/mac_dfs_explorer.htm
For SSD management, my MMB Utils should also work on a Mac, since it's just perl: https://sweh.spuddy.org/Beeb/mmb_utils.html

Then you can add files from the command line; eg "beeb putfile my.ssd file1 file2 file3"
Rgds
Stephen
rph
Posts: 65
Joined: Wed Jun 05, 2019 4:46 pm
Contact:

Re: Loading a ROM into SW Ram - basics

Post by rph »

Well I take your file SWRUtil and in beebem remove both files using *DESTROY **
I then import the BASICED rom.
I eject the disc.

Running it on my gotek using
*SRLOAD BASICED 8000 15
or using F in place of 15

Once again get the:
Illegal address

come up.

Running BASICED from your file in your SWUtil .ssd it runs fine, no problem using *SRLOAD BASICED 8000 15 .

Beebem - Also when I tried Export to file literally nothing happens at all.

I'm baffled, just hate not knowing WHY something isn't working.

*.H
SRAM 1.05
It's a few months old beeb from Mark at retroclinic, so very nice piece of kit.

Cheers
R
User avatar
KenLowe
Posts: 1625
Joined: Mon Oct 18, 2004 5:35 pm
Location: UK
Contact:

Re: Loading a ROM into SW Ram - basics

Post by KenLowe »

Are you sure that bank 15 is a valid RAM bank? What message do you get if you type *SRLOAD without any parameters?
rph
Posts: 65
Joined: Wed Jun 05, 2019 4:46 pm
Contact:

Re: Loading a ROM into SW Ram - basics

Post by rph »

Illegal address

Odd as no issue with other .ssd loading into 15.
User avatar
KenLowe
Posts: 1625
Joined: Mon Oct 18, 2004 5:35 pm
Location: UK
Contact:

Re: Loading a ROM into SW Ram - basics

Post by KenLowe »

Ok. I can get the same error on BeebEm with 1770 DFS and DFS 2.26.

Edit: And now I can't :-?
User avatar
jgharston
Posts: 4254
Joined: Thu Sep 24, 2009 12:22 pm
Location: Whitby/Sheffield
Contact:

Re: Loading a ROM into SW Ram - basics

Post by jgharston »

Wheel_nut wrote:
Sat Oct 26, 2019 4:34 pm
The *SRLOAD function is for the Master IIRC.
The *SRLOAD command is for /any/ computer, it is built in on the Master, and included in the 1770 DFS ROM, and otherwise is available in other SRAM Utils support ROMs or on disks.
Are you sure that bank 15 is a valid RAM bank?
The SRLOAD command on the JGH SRAM Utils disk should give 'Not SRAM' if trying to load to ROM (or write-protected RAM).
Running it on my gotek using
*SRLOAD BASICED 8000 15
or using F in place of 15
Once again get the:
Illegal address
On the off chance, try doing *SRLOAD BASICED 15 or *SRLOAD BASICED F. It could be a version of a SRLOAD command that only takes a ROM number as a parameter, and doesn't allow the address to be specified.

Code: Select all

$ bbcbasic
PDP11 BBC BASIC IV Version 0.32
(C) Copyright J.G.Harston 1989,2005-2020
>_
User avatar
BeebMaster
Posts: 3856
Joined: Sun Aug 02, 2009 5:59 pm
Location: Lost in the BeebVault!
Contact:

Re: Loading a ROM into SW Ram - basics

Post by BeebMaster »

I think we need to trace how this Illegal address error comes about, because although I can see it listed within the 1770 DFS ROM, I can't do anything which generates this error. Most incorrectly formed SRLOAD commands give a Bad command error, sometimes an Illegal parameter error, but I can't get it to give me Illegal address.

That's on a Master 128 with DFS 2.24/SRAM 1.04.
Image
User avatar
KenLowe
Posts: 1625
Joined: Mon Oct 18, 2004 5:35 pm
Location: UK
Contact:

Re: Loading a ROM into SW Ram - basics

Post by KenLowe »

BeebMaster wrote:
Sat Oct 26, 2019 9:00 pm
I think we need to trace how this Illegal address error comes about, because although I can see it listed within the 1770 DFS ROM, I can't do anything which generates this error. Most incorrectly formed SRLOAD commands give a Bad command error, sometimes an Illegal parameter error, but I can't get it to give me Illegal address.

That's on a Master 128 with DFS 2.24/SRAM 1.04.
I can get the illegal address error if I exclude the sram address. ie: *SRLOAD filename x

On a beeb with DFS 2.26 / SRAM 1.05.
Attachments
Illegal Address.png
User avatar
BeebMaster
Posts: 3856
Joined: Sun Aug 02, 2009 5:59 pm
Location: Lost in the BeebVault!
Contact:

Re: Loading a ROM into SW Ram - basics

Post by BeebMaster »

I don't have a 1770 Model B to test, but with that on M128 I get "Illegal parameter".

I can now get Illegal address, but only by using SRDATA or SRROM on a bank that isn't Sideways RAM (ie. 4-7 on the Master).

But there appears to be a bug, because after an SRLOAD command the behaviour of SRDATA and SRROM changes. SRDATA then gives a RAM occupied error, and SRROM is accepted.
Image
User avatar
BeebMaster
Posts: 3856
Joined: Sun Aug 02, 2009 5:59 pm
Location: Lost in the BeebVault!
Contact:

Re: Loading a ROM into SW Ram - basics

Post by BeebMaster »

I can't quite see how, but this must be a functional difference between a B and a Master because with DFS 2.25/SRAM 1.05 loaded into SRAM (!!!!) and ROM 9 unplugged, I still get Illegal parameter.
Image
User avatar
KenLowe
Posts: 1625
Joined: Mon Oct 18, 2004 5:35 pm
Location: UK
Contact:

Re: Loading a ROM into SW Ram - basics

Post by KenLowe »

Yeah. I get the same 'Illegal parameter' with Master 128 emulation on BeebEm. I've loaded DFS 2.28 / SRAM 1.06.
rph
Posts: 65
Joined: Wed Jun 05, 2019 4:46 pm
Contact:

Re: Loading a ROM into SW Ram - basics

Post by rph »

Same thing!
User avatar
jgharston
Posts: 4254
Joined: Thu Sep 24, 2009 12:22 pm
Location: Whitby/Sheffield
Contact:

Re: Loading a ROM into SW Ram - basics

Post by jgharston »

A faint bell is ringing at the back of my mind. Some SRLOAD commands make assumptions about what is in what sideways bank and invalidate certain <rom> numbers. For instance, I think the SRAM Utils in the 1770 DFS ROM assume that it only ever possible to have SRAM in 0,1,8,9 or something.

Try going through all 16 possible ROM slots:
*SRLOAD file 8000 0
*SRLOAD file 8000 1
*SRLOAD file 8000 2
*SRLOAD file 8000 3
etc up to
*SRLOAD file 8000 E (or 14)
*SRLOAD file 8000 F (or 15)

and see what the results are.

Code: Select all

$ bbcbasic
PDP11 BBC BASIC IV Version 0.32
(C) Copyright J.G.Harston 1989,2005-2020
>_
User avatar
jgharston
Posts: 4254
Joined: Thu Sep 24, 2009 12:22 pm
Location: Whitby/Sheffield
Contact:

Re: Loading a ROM into SW Ram - basics

Post by jgharston »

jgharston wrote:
Sun Oct 27, 2019 12:10 am
A faint bell is ringing at the back of my mind. Some SRLOAD commands make assumptions about what is in what sideways bank and invalidate certain <rom> numbers. For instance, I think the SRAM Utils in the 1770 DFS ROM assume that it only ever possible to have SRAM in 0,1,8,9 or something.
Yep, checking the source, the SRAM Utils in the DFS 2.24 ROM will only allow loading to banks 4,5,6,7. Any other bank will give an error, so *SRLOAD file 8000 15 is faulted. You need to use an alternative SRLOAD command, such as the one on the JGH ROM Utils disk, and use */SRLOAD file 8000 15.

Code: Select all

$ bbcbasic
PDP11 BBC BASIC IV Version 0.32
(C) Copyright J.G.Harston 1989,2005-2020
>_
rph
Posts: 65
Joined: Wed Jun 05, 2019 4:46 pm
Contact:

Re: Loading a ROM into SW Ram - basics

Post by rph »

Thanks though don't understand why I can load it to bank 15 fine with one .SSD file but not the identical one I made via beebem.

People who got the error, were you adding the ROM to the SSD using beebem? Or were you still getting the illegal error using other software?
User avatar
hoglet
Posts: 9800
Joined: Sat Oct 13, 2012 7:21 pm
Location: Bristol
Contact:

Re: Loading a ROM into SW Ram - basics

Post by hoglet »

rph wrote:
Mon Oct 28, 2019 8:09 am
Thanks though don't understand why I can load it to bank 15 fine with one .SSD file but not the identical one I made via beebem.

People who got the error, were you adding the ROM to the SSD using beebem? Or were you still getting the illegal error using other software?
If you attach both .ssd files to this thread I can take a look and tell you what went wrong with your version.

Dave
User avatar
MartinB
Posts: 5358
Joined: Mon Mar 31, 2008 10:04 pm
Location: Obscurity
Contact:

Re: Loading a ROM into SW Ram - basics

Post by MartinB »

If you try both ssd's with the EELOAD utility that Ken Lowe recommended earlier in the thread (and I think you tried?), you will get a checksum after loading a given rom image and this will tell you definitively if there are differences between the alternatively sourced versions of the images.
Post Reply

Return to “8-bit acorn hardware”