home bbs files messages ]

Forums before death by AOL, social media and spammers... "We can't have nice things"

   comp.sys.apple2      Discussion about Apple II micros      56,720 messages   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]

   Message 55,645 of 56,720   
   Joshua Bell to justliketom...@gmail.com   
   Re: MLI call to eject 3.5" disk?   
   26 Jul 22 08:52:05   
   
   From: inexorabletash@gmail.com   
      
   On Tuesday, July 26, 2022 at 8:41:15 AM UTC-7, justliketom...@gmail.com wrote:   
   > On Tuesday, July 26, 2022 at 10:56:17 AM UTC-4, Tom Thumb wrote:    
   > > Anyone know how to eject a 3.5” disk programmatically? I have a drive   
   where the eject motor functions; Prosel will eject a disk from it after   
   formatting but the button won’t activate the motor. The switch tests good so   
   I don’t know where the    
   disconnect is.    
   > >    
   > > Trivial, I know, but anyone know how or where to find such info. I have   
   the proofs technical reference as well as the //e tech reference but I’m not   
   finding it.   
   > I found some info for 3.5 Unidisk in the IIgs firmware reference.    
      
   Yep, that's where to look.   
      
   TL;DR: Issue a SmartPort Control ($04) command with the control code $04 in   
   the parameter block.   
      
   Caveats:    
      
   * Don't issue this against devices that are not a UniDisk 3.5. For example, it   
   will cause the FloppyEmu (a modern smartport storage device) to crash. So if   
   you're writing a general purpose utility, issue a Status ($00) call with   
   status code $03 to return    
   a Device Information Block (DIB) from the device, and verify that the device   
   type code is $01 (3.5" Disk)   
      
   * If you already know the slot and unit number (e.g. your controller is in   
   Slot 5 and you have only one device plugged in), then you can determine the   
   SmartPort dispatch address per the documentation in the Firmware Reference,   
   and assume the device SP    
   unit number is 1 - you're all set to make the eject call. But if you're   
   writing a general purpose utility under ProDOS, given device mirroring in   
   ProDOS 2.x, determining the actual slot and SP unit number is non-trivial if   
   given a volume name or a slot/   
   drive combination.    
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   

[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]


(c) 1994,  bbs@darkrealms.ca