JeffAllenNJ Posted June 23, 2014 Posted June 23, 2014 I have a Firewire device tightly fit in a cabinet that I needed to "reboot" once in a while. It is a pain to always grab the firewire cable, pull it out, wait 5 seconds, and then plug it back in a few times a day. Are there any AutoIT solutions so that I can programmatically shut down power to the Firewire port, wait 5 seconds and then restore it?
Moderators JLogan3o13 Posted June 23, 2014 Moderators Posted June 23, 2014 The only way I have done so is with the DevCon utility. However, depending on the device, a "hard stop" of simply disabling the port may not be a good idea. http://msdn.microsoft.com/en-us/library/windows/hardware/ff544707(v=vs.85).aspx "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum!
JeffAllenNJ Posted June 23, 2014 Author Posted June 23, 2014 I might need a little hand holding here. Can you elaborate "DEVCON for dummies" when you get a chance?
iamtheky Posted June 23, 2014 Posted June 23, 2014 http://support.microsoft.com/kb/311272 devcon disable *MSLOOPDisables all devices that have a hardware ID that ends in "MSLOOP" (including "*MSLOOP"). ,-. .--. ________ .-. .-. ,---. ,-. .-. .-. .-. |(| / /\ \ |\ /| |__ __||| | | || .-' | |/ / \ \_/ )/ (_) / /__\ \ |(\ / | )| | | `-' | | `-. | | / __ \ (_) | | | __ | (_)\/ | (_) | | .-. | | .-' | | \ |__| ) ( | | | | |)| | \ / | | | | | |)| | `--. | |) \ | | `-' |_| (_) | |\/| | `-' /( (_)/( __.' |((_)-' /(_| '-' '-' (__) (__) (_) (__)
Moderators JLogan3o13 Posted July 1, 2014 Moderators Posted July 1, 2014 Look here for a list of commands: http://msdn.microsoft.com/en-us/library/windows/hardware/ff544766(v=vs.85).aspx It would be something akin to... ShellExecuteWait("devcon.exe", "/m:\\computer /r <command> <args>") ; Or RunWait("devcon.exe /m:\\computer /r <command> <args>") The help file can help you with the params for either ShellExecuteWait or RunWait "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum!
JeffAllenNJ Posted July 8, 2014 Author Posted July 8, 2014 duh sorry ... I knew that! anyway, when I try "devcon disable *MSLOOP", devcon says "no devices disabled" and when I try "devcon enable *MSLOOP", it says "no devices enabled".
Moderators JLogan3o13 Posted July 8, 2014 Moderators Posted July 8, 2014 What about if you run it just from a command line? "Profanity is the last vestige of the feeble mind. For the man who cannot express himself forcibly through intellect must do so through shock and awe" - Spencer W. Kimball How to get your question answered on this forum!
JeffAllenNJ Posted July 29, 2014 Author Posted July 29, 2014 I am running it from the command line. Once it works, I can incorporate it into AutoIt. Unfortunately *MSLOOP does not work for any devcon command
computergroove Posted July 29, 2014 Posted July 29, 2014 I needed to use DevCon once in Windows XP and I could never get it to work. Get Scite to add a popup when you use a 3rd party UDF -> http://www.autoitscript.com/autoit3/scite/docs/SciTE4AutoIt3/user-calltip-manager.html
JeffAllenNJ Posted August 1, 2014 Author Posted August 1, 2014 (edited) Well, until someone shows that they have successfully used devcon to disable, enable, and restart devices, it is safe to assume that devcon does not work. I finally found that *MSLOOP is really just some sort of example and has nothing to do with firewire. My firewire port shows up in device manager as IEEE_* but that doesn't work with devcon either. With a devcon list classes command I see that firewire was actually class 1394. When I show devices in that class, I get the device id. When I show that device id, is shows the driver is running. When I try to disable that device id, devcon cannot. Yes, I am running CMD as admin. C:>devcon listclass 1394 Listing 1 device(s) for setup class "1394" (IEEE 1394 Bus host controllers). PCI\VEN_1106&DEV_3044&SUBSYS_30441106&REV_46\5&36BEC05D&0&0800E4: VIA 1394 OHCI Compliant Host Controller C:>devcon status "@PCI\VEN_1106&DEV_3044&SUBSYS_30441106&REV_46\5&36BEC05D&0&0800E4" PCI\VEN_1106&DEV_3044&SUBSYS_30441106&REV_46\5&36BEC05D&0&0800E4 Name: VIA 1394 OHCI Compliant Host Controller Driver is running. 1 matching device(s) found. C:>devcon disable "@PCI\VEN_1106&DEV_3044&SUBSYS_30441106&REV_46\5&36BEC05D&0&0800E4" PCI\VEN_1106&DEV_3044&SUBSYS_30441106&REV_46\5&36BEC05D&0&0800E4: Disable failed No devices disabled. Edited August 2, 2014 by jaja714
JeffAllenNJ Posted May 19, 2016 Author Posted May 19, 2016 (edited) bump ... after a few years ... I am still seeking a solution for this I'm tired of bumping my head every day unplugging and plugging this thing in! Perhaps someone has new insight into how best to control certain ports on a pc with AutoIt? Edited May 19, 2016 by jaja714
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now