[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: disk image emulator on the GS - possible?
On Jul 3, 6:57 am, Toinet <antoine.vig...@laposte.net> wrote:
> On 2 juil, 01:52, "Charlie" <charlieD...@verEYEzon.net> wrote:
>
>
>
>
>
> > "Toinet" <antoine.vig...@laposte.net> wrote in message
>
> >cc928f2a-ebb1-4549-9345-0aa5a2d46bfb@z14g2000yqa.googlegroups.com">news:cc928f2a-ebb1-4549-9345-0aa5a2d46bfb@z14g2000yqa.googlegroups.com...
>
> > > Hi All,
>
> > > I like that post, I worked on such a IIgs thing in January 2009 in
> > > order to mount CBM D64 images.
>
> > > The objective is to double-click a disk image (DSK, PO) and thanks to
> > > the IPC thing in a PIF, load the file into memory, perform the
> > > necessary checks and add it into the list of devices.
>
> > > What is interesting is that the driver is responsible for the
> > > different block reads and writes or inits and that's all, the rest of
> > > the job is performed by the FSTs.
>
> > > I developed that new driver with my source code of the RAM5 (works
> > > with the RAM but is firmware related) and ensoniqRAM (not hardware
> > > related) drivers but I failed as I am still unable to simulate the
> > > disk insertion or ejection which would update the device list, even
> > > with the help of the different GS/OS books.
>
> > > If one understands that notion (how to mount/unmount a device), please
> > > contact me and I will finish that one during my summer vacation,
>
> > > antoine
>
> > Hi Antoine,
>
> > I'm really glad you jumped into this discussion since I feel I was
> > getting in way over my head.
> > It seems you are very close to what the original poster wanted.
>
> > First I have to say that I've never done any device driver programming
> > for the Apple IIgs. Since I don't want anyone to think I would let my
> > ignorance stop me from posting I'll ask if you have tried using the
> > system service call SET_DISKSW which is supposed to notify GS/OS that a
> > disk switched or is in an off-line condition. If I understand the
> > description of the call (page 283 of the device driver reference)
> > drivers can request a change in the disk switched status which is
> > maintained by the device dispatcher. I believe the device dispatcher is
> > responsible for the device list.
>
> > Anyway the description sounds a lot like what you want so I had to ask.
>
> > Charlie
>
> Thanks for your help, I appreciate. SET_DISKSW requires a device
> number which I do not have as I need to let it be set by the device
> dispatcher.
>
> Then, I have had an idea: browse the contents of your Apple II
> Developer CDs and the answer is to be found here: cd1 / System 6.0
> sample code / System 6 pieces / SCSI.Drivers / SCSI Driver Mgmt
>
> The way the Apple SCSI driver works is described hereafter: have a
> default empty Device Independent Block and set it as not HW related.
> That's all.
>
> When a DStatus or DInfo is performed, control is passed to a routine
> (unit_state) which creates DIBs dynamically depending on the
> physical / logical volumes present on the device.
>
> Consider now that we are in the FinderExtension, we have just double-
> clicked the disk image we want to add to the system, we need to tell
> our driver that a new device (then volume if recognized) must come
> online. That can be done of two different ways:
> - call a subcall to the driver and tell it to add the volume and make
> it online (if not already in the devices)
> - perform like IR from M. Deatherage does: InitialLoad2 a new driver,
> set the interesting values and call it
>
> And the volume will come online because of the SET_DISKSW call that
> will be performed!
>
> Oh, I think I will enjoy my summer holidays!
>
> antoine
Cool, we look forward to seeing the results!
As an aside, for a relative newcomer to the IIgs (I got my 1st IIgs in
2006!), are the developer CD's with source code that you mentioned
still available anywhere? I'd love to get my hands on these rather
than trying to reinvent the wheel all the time. :-)
Cheers,
Mike