1. Welcome to Tacoma World!

    You are currently viewing as a guest! To get full-access, you need to register for a FREE account.

    As a registered member, you’ll be able to:
    • Participate in all Tacoma discussion topics
    • Communicate privately with other Tacoma owners from around the world
    • Post your own photos in our Members Gallery
    • Access all special features of the site

starting/stopping usb ports

Discussion in 'Technical Chat' started by HerNameIsLucy, Jan 22, 2009.

  1. Jan 22, 2009 at 7:57 AM
    #1
    HerNameIsLucy

    HerNameIsLucy [OP] I miss Lucy. :-(

    Joined:
    Jul 31, 2008
    Member:
    #8256
    Messages:
    3,042
    Gender:
    Male
    First Name:
    John
    Equador. Don't know why.
    Vehicle:
    RIP Lucy.
    She's gone but not forgotten.
    Anyone know if there is a command that can be used in a .bat file that will stop and restart a specific USB port? Or a specific USB device?

    My system has a weather station, scanner, and a X10 USB device that converts video input from a RCA jack to USB.

    The weather station and the X10 device butt heads on startup, the only way I can get them to play nice is to set the X10 service startup to manual, open the weather station, start the X10 service and then physically unplug and re-plug in the X10 device.

    The X10 device sets itself up as a COM port, Com4. The mappings are a bit odd, it doesn't use a specific address (EG 2F8) but it does use an interrupt (17). The weather station is on COM1 (2F8 INT4). So they SHOULDN'T butt heads, but they do.

    Would be nice to do all the service starting / stopping (that part I know) AND bounce the USB port in one batch file.
     
  2. Jan 22, 2009 at 11:45 AM
    #2
    JDCPA

    JDCPA Well-Known Member

    Joined:
    Nov 15, 2008
    Member:
    #10777
    Messages:
    933
    Gender:
    Male
    First Name:
    Jim
    SW FL
    Vehicle:
    09 5 Lug Access Cab SR5
    Curt Hitch and etrailer.com wiring harness.
    Can you reassign the COM port to a different address? That would probably be the easiest thing to do.
     
  3. Jan 22, 2009 at 11:52 AM
    #3
    HerNameIsLucy

    HerNameIsLucy [OP] I miss Lucy. :-(

    Joined:
    Jul 31, 2008
    Member:
    #8256
    Messages:
    3,042
    Gender:
    Male
    First Name:
    John
    Equador. Don't know why.
    Vehicle:
    RIP Lucy.
    She's gone but not forgotten.
    Both the scanner and the weather station software will only work on COM1 or COM2. I tricked the weather station to work on COM6 by editing it's .ini file, used a serial to USB adapter. Now the software fires up fine but it won't read the station. Figuring the station uses some sort of "counting" feature, something that opens/closes two terminals on the serial port like UPS monitoring does. So it has to be on a physical port.

    Was thinking a few minutes ago, I could put in a Belkin USB card, plug just the X10 camera adapter into it, and figure out what service it uses, write a start / stop command into a batch file. Something to try later today.
     
  4. Jan 22, 2009 at 12:12 PM
    #4
    JDCPA

    JDCPA Well-Known Member

    Joined:
    Nov 15, 2008
    Member:
    #10777
    Messages:
    933
    Gender:
    Male
    First Name:
    Jim
    SW FL
    Vehicle:
    09 5 Lug Access Cab SR5
    Curt Hitch and etrailer.com wiring harness.
    Go through your Control Panel into the System section and look under the Hardware tab. You should be able to assign the COM port to a different interrupt which should clear the conflict. You will still be using the COM port, it will just be talking to the CPU through a different interrupt.
     
  5. Jan 22, 2009 at 12:48 PM
    #5
    HerNameIsLucy

    HerNameIsLucy [OP] I miss Lucy. :-(

    Joined:
    Jul 31, 2008
    Member:
    #8256
    Messages:
    3,042
    Gender:
    Male
    First Name:
    John
    Equador. Don't know why.
    Vehicle:
    RIP Lucy.
    She's gone but not forgotten.
    You can't on the X10 USB video adapter. Takes what it wants. No ini file to edit. Right now it's on 17 (which we know is a software based interrupt - that might be causing the problem).

    Answer for now is for me to set the X10 service startup to manual on machine boot so the weather station works. Then start the X10 service with a NET START command. Then pull the USB connector for the video adapter out, plug it back in. It finds the camera and all of a sudden it works.

    Or quit busting my balls on this and get a cheap video capture board with a RCA input on it....

    But I don't like to lose these battles!
     
  6. Jan 22, 2009 at 1:50 PM
    #6
    JDCPA

    JDCPA Well-Known Member

    Joined:
    Nov 15, 2008
    Member:
    #10777
    Messages:
    933
    Gender:
    Male
    First Name:
    Jim
    SW FL
    Vehicle:
    09 5 Lug Access Cab SR5
    Curt Hitch and etrailer.com wiring harness.
    I went back and re-read your original post. I thought you were using the COM port on the computer which can be reassigned. Sounds like the conflict is just at startup. Is it possible to have them start up in a different sequence? That way the interrupt 17 might be cleared by the time the second device wants it.
     
  7. Jan 22, 2009 at 1:54 PM
    #7
    HerNameIsLucy

    HerNameIsLucy [OP] I miss Lucy. :-(

    Joined:
    Jul 31, 2008
    Member:
    #8256
    Messages:
    3,042
    Gender:
    Male
    First Name:
    John
    Equador. Don't know why.
    Vehicle:
    RIP Lucy.
    She's gone but not forgotten.
    Unfortunately the X10 device is run by a service, and the weather software is an application, so the service starts first.

    If I allow the X10 service to start on boot the weather software won't find it's port (COM 1). So I start the X10 service manually with a .bat file with NET START. No problem there. What I don't get is why I have to unplug / re-plug the X10 adapter to get XP to see the camera. I'm using the latest (if you can call 2001 latest) drivers from XP. There are no options with it, it's just a simple driver.
     
  8. Jan 22, 2009 at 1:57 PM
    #8
    JDCPA

    JDCPA Well-Known Member

    Joined:
    Nov 15, 2008
    Member:
    #10777
    Messages:
    933
    Gender:
    Male
    First Name:
    Jim
    SW FL
    Vehicle:
    09 5 Lug Access Cab SR5
    Curt Hitch and etrailer.com wiring harness.
    Why can't you reassign COM1? Isn't that hardware? That would leave Interrupt 17 available for your software COM4.
     
  9. Jan 22, 2009 at 2:02 PM
    #9
    HerNameIsLucy

    HerNameIsLucy [OP] I miss Lucy. :-(

    Joined:
    Jul 31, 2008
    Member:
    #8256
    Messages:
    3,042
    Gender:
    Male
    First Name:
    John
    Equador. Don't know why.
    Vehicle:
    RIP Lucy.
    She's gone but not forgotten.
    'cause the weather station will only recognize 2F8 INT4 or 3F8 INT3.

    I'm gonna hit ebay and get a cheap video input card. Solves it all.

    Thanks for the help though!
     
To Top