View Full Version : Control of "Safely Remove hardware"
scrybe
June 13th, 2004, 12:39 PM
I have been trying on and off for the last couple months to find a way to control the mounting and unmounting of a Firewire Hard Drive in windows. I have been through WMI and VB, and even a little C++ and have been unable to find something that can act like me clicking on "safely remofe hardware" and selecting the Firewire drive.
Anyone here think they can get girder to do it?
I'm trying to get my LaCie BiggerDisk (Yeah I know drool!) to unmount from my HTPC and mount to my Desktop when I need to do some re-encoding.
Any Ideas?
Promixis
June 13th, 2004, 03:22 PM
I would have though with WMI or the like that you could unmount the device...
What system calls did you try from c?
scrybe
June 13th, 2004, 07:11 PM
I tried the C so long ago that I don't remember what all I tried. I REALLY suck when it comes to C though. The last program bigger than hello world I wrote was in '91. My favorite reference from this whole excursion comes from the docs for Win32_DiskDrive:
Methods
The Win32_DiskDrive class defines the following methods.
Method Description
Reset Not implemented.
SetPowerState Not implemented.
Right now I am trying to avoid any more programming than I have to as I am a systems admin not a programmer and I don't really want to have to wrap my head around things like IRP_MN_QUERY_REMOVE_DEVICE. eek! I am just BOGGLING that microsoft has not made the safely remove hardware accessable through a script.
Promixis
June 14th, 2004, 06:32 PM
See
http://groups.google.com/groups?hl=en&lr=&ie=UTF-8&threadm=c5353aa9.0301170315.7612a614%40posting.goo gle.com&rnum=3&prev=/groups%3Fq%3Ddeletevolumemountpoint%26num%3D100%26 hl%3Den%26lr%3D%26ie%3DUTF-8%26sa%3DN%26tab%3Dwg
Promixis
June 14th, 2004, 07:19 PM
and
http://support.microsoft.com/default.aspx?scid=http://support.microsoft.com:80/support/kb/articles/Q165/7/21.asp&NoWebContent=1
scrybe
June 15th, 2004, 04:38 AM
Looks like I'm stuck with C huh. Well I'll try to get around to compiling that code chunk and see how it works for a firewire drive. Might be a bit as my billable utilization average for the last 3 months is north of 65 hours a week.
Promixis
June 15th, 2004, 06:25 AM
If the above code works, I will include in it in the Lua System Functions plugin so you can call it from Girder directly. Let me know.
Powered by vBulletin® Version 4.1.8 Copyright © 2012 vBulletin Solutions, Inc. All rights reserved.