<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>
Date   : Tue, 18 Jul 2006 15:54:41 +0100
From   : Rob <robert@...>
Subject: Re: Getting .SSD disk images onto a beeb...

At 14:33 18/07/2006, Jules Richardson wrote:


>Well I suppose getting the data across isn't too hard, but I 
>wouldn't have a clue how to write the necessary BASIC at the other end :-)

If you can get the actual SSD/DSD file over into the beeb environment 
somehow (you'd obviously need to have a larger format media to store 
it on, either an ADFS floppy, hard disc, econet fileserver or GoMMC) 
then I don't suppose it would be too hard to knock up a bit of BASIC 
to read it in 256 bytes at a time and just write it directly onto a 
floppy as-is..  Unlike a PC, the beeb has an advantage of being able 
to write DFS format discs without issue..

Actually, assuming the format of the SSD file is as simple as has 
been described, then, off the top of my head, you only need something like:

*DISC
fh%=OPENIN("-NET-image.ssd") : REM you need a Master for temporary filesystem
side%=0
lba%=0: DIM buffer% 256
FOR trk% = 0 to 79
   FOR sec% = 0 to 9 : REM is it 9, so long since I looked..
       PROGosgbpb(fh%,buffer%,256,lba%*256)
       PROCwrite_sector(side%,trk%,sec%,buffer%)
       lba%=lba%+1
   NEXT
NEXT
CLOSE#fh%

The two DEF PROCs required are left as an exercise for the student..

Rob.


-- 
  (\_/)
(='.'=) This is Bunny. Copy and paste bunny into your
(")_(") signature to help him gain world domination. 
<< Previous Message Main Index Next Message >>
<< Previous Message in Thread This Month Next Message in Thread >>