1 GB image


17 posts
by plasticrabbit » Mon Jan 07, 2013 8:19 pm
hiya, this is my first post after getting the pi for xmas off my mrs. been having lots of fun playing with risc os, as my school 1992-97 used pretty much exclusively acorn computers risc os has bought back lots of memories.

i have been trying to resize the risc os partition in order to put it onto a 1gb sd card. found what looks to me like the basic type batch file thingy that will do it. looks like this -

chan=OPENUP("RISCOSpi")
EXT#chan=<new size in bytes>
CLOSE#chan

it tells me that the chan is closed and it can't do it. now, i was wandering if i used another sd card, put risc os on that then attempted to re-size my original image mounted as a 2nd drive in an adapter it might let me do it?

i know i could just go ahead and do it but my only other 2 gig sd card lives in the dreamcast and i don't want to back all the stuff off that up on the off chance it'll work.

ooor, has anybody else made a 1gig risc os image? i read on 1 site that createing the origonal image was 'complicated' but as risc os plus the proigrams i've installed only take up 300odd mb of data a 1 gig card would be just fine.

cheers!
Bad command or file name.
User avatar
Posts: 9
Joined: Mon Jan 07, 2013 8:05 pm
Location: Birmingham
by skywalker » Mon Jan 07, 2013 8:59 pm
I'm currently wasting a 16Gb SD card for RISC OS (!), so am also keen to find a utility or script that could extend the RISC OS volume/partition up to a larger size, though I'm far from using up the available capacity in the distributed image at the moment.
Posts: 28
Joined: Tue Nov 06, 2012 4:55 am
Location: Vancouver, Canada
by nr. » Tue Jan 08, 2013 10:04 am
skywalker wrote:I'm currently wasting a 16Gb SD card for RISC OS (!), so am also keen to find a utility or script that could extend the RISC OS volume/partition up to a larger size, though I'm far from using up the available capacity in the distributed image at the moment.


From what I see, you can't. You need to format the extra space as a FAT partition, and then use FAT32FS v1.41 to mount and manage it from within RISC OS. This works well, except that FAT32FS doesn't give you an entry in the icon bar to control things with, but that doesn't stop you from using it.

To mount the partition:
Code: Select all
fat32fs:mount -fp2 :16 { > null: }


To dismount it:
Code: Select all
fat32fs:dismount -p2 :16 { > null: }


You can either just type those from a command line, or create obey files.
--
nr.
Posts: 138
Joined: Wed Oct 03, 2012 8:51 am
Location: The Fens
by DavidS » Tue Jan 08, 2013 1:08 pm
I think it may be possible to expand the image. I will be testing this later today.

I think that you can create a new small (32 to 64 MB) FAT32 boot partition at the end of the SD card after copying the contents of the current boot partition to a ram disk and dismounting and deleting the old partition, then copy the files back to the new boot partition, then copy all of the contents of the RISC OS Filecore partition to the RAM Disk and dismount and reformat the RISC OS File core partition to be SizeOfSD-64MB.

You will no longer be able to access the contents of the Boot Partition through the FileCore partition, as they will no longer be mapped to the sectors of the FAT32 files, though you can still use Fat32FS to access the Boot partition.
ARM Assembly Language: For those that want: Simple, Powerful, Easy to learn, and Easy to debug.
User avatar
Posts: 1251
Joined: Thu Dec 15, 2011 6:39 am
Location: USA
by DavidS » Tue Jan 08, 2013 9:15 pm
Ok have tried this And it did not work out.

!HForm did not cooperate with me. Is there some kind of problem with using !HForm on an SD card? Does any one else have any suggestions?
ARM Assembly Language: For those that want: Simple, Powerful, Easy to learn, and Easy to debug.
User avatar
Posts: 1251
Joined: Thu Dec 15, 2011 6:39 am
Location: USA
by plasticrabbit » Tue Jan 08, 2013 9:38 pm
i've been wandering if the linux program gparted can handle riscos style partitions? if it's a yes then it will be pretty simple to re size the partition.

gonna give that a try now. brb.
Bad command or file name.
User avatar
Posts: 9
Joined: Mon Jan 07, 2013 8:05 pm
Location: Birmingham
by plasticrabbit » Tue Jan 08, 2013 9:44 pm
nope, can see the riscos partition but sees it as unknown type so is unable to re size.

anybody know of a similar program that DOES know how to play with riscos partitions?
Bad command or file name.
User avatar
Posts: 9
Joined: Mon Jan 07, 2013 8:05 pm
Location: Birmingham
by DavidS » Tue Jan 08, 2013 11:36 pm
plasticrabbit wrote:nope, can see the riscos partition but sees it as unknown type so is unable to re size.

anybody know of a similar program that DOES know how to play with riscos partitions?

I would say if we could get the Disk utilities in RISC OS to work with an SD card then problem solved.
ARM Assembly Language: For those that want: Simple, Powerful, Easy to learn, and Easy to debug.
User avatar
Posts: 1251
Joined: Thu Dec 15, 2011 6:39 am
Location: USA
by Burngate » Wed Jan 09, 2013 10:44 am
plasticrabbit wrote:nope, can see the riscos partition but sees it as unknown type so is unable to re size.

anybody know of a similar program that DOES know how to play with riscos partitions?

As I understand it, that "unknown type" partition is merely there to protect the RISC OS data.
If you were to use a windows style partition tool to add another partition, and that "unknown type" one wasn't there, it would put it straight over the ADFS data, wiping it out.
With that in place, the windows tool adds the next partition after it, leaving the RISC OS data pristine

Quite how the gurus managed to put the fat32 partition where it needs to be for the Pi to boot, and also format the card with ADFS, and then tie the two together, I don't know, but it really was clever!
Brain surgery is easier than psychoanalysis
User avatar
Posts: 2667
Joined: Thu Sep 29, 2011 4:34 pm
Location: Berkshire UK
by plasticrabbit » Wed Jan 09, 2013 11:03 am
its a linux tool that handles around 20 different file systems fat/ext/ntfs/hpfs/etc etc. unknown type just means it's a file system the program doesn't know how to manipulate.
Bad command or file name.
User avatar
Posts: 9
Joined: Mon Jan 07, 2013 8:05 pm
Location: Birmingham
by sawdust » Wed Jan 09, 2013 1:00 pm
RISCOS doesn't know about the partition table used by other OS's at the moment. So even if you edited it, the size of your RISCOS partition wouldn't change.

The safest thing to do for now, is to use any free space on your card as a fat32 partition and use Fat32FS to access it.

Sawdust.
Posts: 40
Joined: Fri Jul 27, 2012 7:09 am
by DavidS » Fri Jan 18, 2013 4:25 pm
To both issues in this thread. I have one install of RISC OS setup to boot from USB stick, with this I just use a 128MB SD-Card and it works well, the only thing on the SD is the FAT32 boot partition so there is plenty of free space. with only about 5MB used (I have some BareMetal test kernels on it also).
ARM Assembly Language: For those that want: Simple, Powerful, Easy to learn, and Easy to debug.
User avatar
Posts: 1251
Joined: Thu Dec 15, 2011 6:39 am
Location: USA
by DavidS » Sun Jan 20, 2013 1:02 am
[quote=""][/quote]
I have some time this evening so I am going to attempt to make a 1024MB (1GB) image and a 512MB image. Unfortunately I do not have anywhere to upload it to.

Once I have the two Images Tested, I will be asking if some one could provide FTP upload access to some repository that is already known to the RPi community (as this will be from my RPi under RISC OS) so that I may upload these two images (and maybe even a third 256MB image)? They will be zipped so should not be any bigger than the current SD image download for RISC OS.
ARM Assembly Language: For those that want: Simple, Powerful, Easy to learn, and Easy to debug.
User avatar
Posts: 1251
Joined: Thu Dec 15, 2011 6:39 am
Location: USA
by DavidS » Sun Jan 20, 2013 4:02 am
Sorry, not going to be able to finnish it this evening.
Does any one know how to map a file to absolute blocks? Like the Loader Image file in the main !Boot program on the SDCard?

I have been beating up against this for a couple hours now, I want people to be able to modify the contents of the boot partition in a easy maner, though this means that I need to map an FAT32Fs Image file to the physical location of the FAT32 partition.
ARM Assembly Language: For those that want: Simple, Powerful, Easy to learn, and Easy to debug.
User avatar
Posts: 1251
Joined: Thu Dec 15, 2011 6:39 am
Location: USA
by buteman » Sun Jan 20, 2013 6:58 pm
Would it be possible to use dd from linux to copy the RISC OS to a file then use it to write it to the smaller SD card?
Posts: 44
Joined: Tue Jul 03, 2012 9:06 am
by DavidS » Sun Jan 20, 2013 7:22 pm
@buteman:
No, the image is formatted for 1.8GB, the file core structure on disk would have to be modified to do that, making it a lot easier to just create the smaller images.

With a File core ADFS E+ file system the FS metatadata (Bad blocks, free bitmap, directory entries, etc, etc.) is spread evenaly acrossed the disk, and most of the important information is close to the center of the data area. I am not going to go into to much detail at this time, though I think that is enough to get the just of it.
ARM Assembly Language: For those that want: Simple, Powerful, Easy to learn, and Easy to debug.
User avatar
Posts: 1251
Joined: Thu Dec 15, 2011 6:39 am
Location: USA
by svrsig » Fri Apr 12, 2013 8:02 pm
I'm currently wasting a 16Gb SD card for RISC OS (!), so am also keen to find a utility or script that could extend the RISC OS volume/partition up to a larger size


If you take the RC8 SD card image (which is designed for a 2Gbyte SD card) and do the following then you will have an additional drive filling the remaining capacity of the SD card.

Using Ubuntu version 10 and its disk utilities, add a FAT partition above the two partitions on the SD card, filling the remaining space and with a name that has no spaces in it.

Download https://sites.google.com/site/jeffreyadoggett/the latest fat32fs (version 1.42) and replace the earlier version in the directory !Boot.Choices.Boot.PreDesk.fat32fs with the downloaded module and its !Run file.

Add an obey file to !Boot.Choices.Boot.Tasks called 'OpenFAT' containing:
fat32fs:dismount :16 { > null: }
fat32fs:mount -fp2 :16 { > null: }
addtinydir fat32fs::16

Now you will have another drive Fat32fs::<name>.$
Posts: 116
Joined: Thu Nov 03, 2011 9:45 am