+ Reply to Thread
Results 1 to 6 of 6

Thread: Is it possible to detect an usb device when the device is plugged in??

  1. #1
    Learning Programmer yonghan is an unknown quantity at this point
    Join Date
    May 2008
    Posts
    96

    Is it possible to detect an usb device when the device is plugged in??

    I want to ask,is it possible to detect a device that are connected to the usb port?And directly link to the software that we've made?Thanks a lot

  2. #2
    Newbie excavator is on a distinguished road
    Join Date
    Apr 2008
    Location
    behind my desk
    Posts
    16

    Re: Is it possible to detect an usb device when the device is plugged in??

    it is possible. try using Win32_ControllerDevice, Win32_USBHub, Win32_Controller class from WMI Classes. there may be other alternatives that more suitable for your app, but you need to be more specific (eg: is the device a storage device? or custom made hardware, etc). HTH

  3. #3
    Learning Programmer yonghan is an unknown quantity at this point
    Join Date
    May 2008
    Posts
    96

    Re: Is it possible to detect an usb device when the device is plugged in??

    To read a pole display/customer display so the application i made can directly connect with it..Thanks a lot.

  4. #4
    Xav
    Xav is offline
    Code Slinger Xav has much to be proud of Xav has much to be proud of Xav has much to be proud of Xav has much to be proud of Xav has much to be proud of Xav has much to be proud of Xav has much to be proud of Xav has much to be proud of Xav has much to be proud of Xav's Avatar
    Join Date
    Mar 2008
    Location
    The North Pole
    Posts
    13,210
    Blog Entries
    13

    Re: Is it possible to detect an usb device when the device is plugged in??

    In a few cases the hardware came with software, which in turn may have an API for you to automate.

    Quote Originally Posted by Jordan View Post
    Good members, like yourself, stick around and post for ages to come!
    Mr. Xav | Blog | Forums

  5. #5
    Newbie excavator is on a distinguished road
    Join Date
    Apr 2008
    Location
    behind my desk
    Posts
    16

    Re: Is it possible to detect an usb device when the device is plugged in??

    Other alternatives are,you could check if the usb device is emulating serial port / network. if it is emulating serial port then you can use System.IO.Ports.SerialPort class. if the device capable of TCP/IP communication then you can use System.Net.Sockets.Socket class. other than that you can use Windows API.

    Most customer display device i know emulate serial port (COM5/COM6) perhaps yours too.

  6. #6
    Xav
    Xav is offline
    Code Slinger Xav has much to be proud of Xav has much to be proud of Xav has much to be proud of Xav has much to be proud of Xav has much to be proud of Xav has much to be proud of Xav has much to be proud of Xav has much to be proud of Xav has much to be proud of Xav's Avatar
    Join Date
    Mar 2008
    Location
    The North Pole
    Posts
    13,210
    Blog Entries
    13

    Re: Is it possible to detect an usb device when the device is plugged in??

    Check the software that came with the device, or try the website. When you install the software, sometimes it installs the API with it.

    Quote Originally Posted by Jordan View Post
    Good members, like yourself, stick around and post for ages to come!
    Mr. Xav | Blog | Forums

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

     

Similar Threads

  1. Microsoft Device Emulator?
    By Lop in forum General Programming
    Replies: 2
    Last Post: 04-24-2007, 04:19 PM

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts