473,626 Members | 3,392 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

.NET support for USB devices?

These days, many devices connect to the computer using USB interface.
For example, my MP3 player and printer is connected through USB. I
searched for 'USB' in the Object Browser but there was virtually no
result. I could find only System.IO.Port and it didn't seem to related
to USB. I want to get notifed when a USB mass storage device is
connected. Is there any .NET support for this kind of operations or
should I look for those tricky Windows APIs?

Jan 12 '06 #1
2 2028
To be more specific, I don't need those low-level I/O operations. All I
want to do is,

1. To get notified when a USB mass storage gets connected and
disconnected.
Which works as a removable disk on Windows.

2. To detect the type of that USB mass storage.
Many different kinds of devices work as USB mass storage, such as
camaras, mp3 players. So I need to figure out whether it is a camara,
mp3 or so on.

I can copy files using normal .NET IO methods.
Sin Jeong-hun wrote:
These days, many devices connect to the computer using USB interface.
For example, my MP3 player and printer is connected through USB. I
searched for 'USB' in the Object Browser but there was virtually no
result. I could find only System.IO.Port and it didn't seem to related
to USB. I want to get notifed when a USB mass storage device is
connected. Is there any .NET support for this kind of operations or
should I look for those tricky Windows APIs?


Jan 12 '06 #2
Hi,

AFAIK, there are no built in classes for accessing USB devices (But there is
a new SerialPort class).

These might help:
http://msdn.microsoft.com/coding4fun...u/default.aspx
http://msmvps.com/blogs/coad/archive/2005/03.aspx

--
HTH,
Rakesh Rajan
MVP, MCSD
http://www.rakeshrajan.com/
"Sin Jeong-hun" wrote:
To be more specific, I don't need those low-level I/O operations. All I
want to do is,

1. To get notified when a USB mass storage gets connected and
disconnected.
Which works as a removable disk on Windows.

2. To detect the type of that USB mass storage.
Many different kinds of devices work as USB mass storage, such as
camaras, mp3 players. So I need to figure out whether it is a camara,
mp3 or so on.

I can copy files using normal .NET IO methods.
Sin Jeong-hun wrote:
These days, many devices connect to the computer using USB interface.
For example, my MP3 player and printer is connected through USB. I
searched for 'USB' in the Object Browser but there was virtually no
result. I could find only System.IO.Port and it didn't seem to related
to USB. I want to get notifed when a USB mass storage device is
connected. Is there any .NET support for this kind of operations or
should I look for those tricky Windows APIs?


Jan 12 '06 #3

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

0
6240
by: A. Fuentes | last post by:
Fellow Oracle Netters: I have the following problem: Enviroment: Oracle9i/AIX5.2/Veritas vxvm I am trying to create an Oracle database using RAW devices UNDER the Veritas vxvm.(Veritas Volume Manager). Brief Antecedents:
21
4178
by: kaeli | last post by:
Hey all, Does anyone know if all the newer browsers support XHTML? My main target is IE6/NN6+(firefox/mozilla/etc), but I'd like to know if Safari, Opera, Konqueror, and other browsers also support it. Anyone know of any major compatibility problems with XHTML? How do older browsers, such as Netscape 4, react to the doctype? TIA
18
474
by: Bud Cookson | last post by:
We are in the process of developing the requirements for a new medical device and the question has been raised about what development tool/language should be used. The application(s) will be primarily user interface on a Windows CE on a Single Board Computer. We see the choices as: 1. embedded C++ 2. embedded VB 3. VB.Net 4. C#.Net There is the potential for a combination of these but out preference is to do a majority of the...
42
4675
by: Jim Smith | last post by:
Note the cross-posting - but no flame wars please. This question was prompted by a thread on the a postgres mailing list during which someone (Gregory Williamson) claimed <quote> raw devices, at least on Solaris, are about 10 times as fast as cooked file systems for Informix. <quote>
46
2091
by: H.A. Sujith | last post by:
Why doesn't the standard library provide (at least basic) networking facilities using TCP/IP ?
22
23346
by: Matthew Louden | last post by:
I want to know why C# doesnt support multiple inheritance? But why we can inherit multiple interfaces instead? I know this is the rule, but I dont understand why. Can anyone give me some concrete examples?
0
1849
by: gewe | last post by:
I am using the following code to enumerate devices on the local computer: ManagementObjectSearcher searcher = new ManagementObjectSearcher("SELECT * from Win32_PnPEntity"); ManagementObjectCollection devices = searcher.Get(); foreach (ManagementObject device in devices) Console.WriteLine(device.Properties.Value.ToString());
3
2027
by: stacy | last post by:
I am developing an application that must look out over TCP on an ethernet connection to locate our proprietary devices. The Web application and the devices are communicating over ethernet with TCP using known IP addresses at present. We would like to design a method to discover devices in the system without knowing their IP addresses. Is there a recommended protocol for this type of problem or do most develop their own protocol? Any...
2
1854
by: Johnson | last post by:
While I have done a substantial amount of ASP.NET programming, I have only dabbled with AJAX (update panels and a 3rd party JSON setup - jayrock - that directly updates the DOM). In any case, I'm considering offering Web pages both to browsers that support AJAX and to those that do not support AJAX. Questions: 1. In general, should I look to offer two versions of each page - one for AJAX clients and the other for "non AJAX-supporting"...
0
8701
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed. This is as boiled down as I can make it. Here is my compilation command: g++-12 -std=c++20 -Wnarrowing bit_field.cpp Here is the code in...
0
8637
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that captivates audiences and drives business growth. The Art of Business Website Design Your website is...
1
8364
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
0
8502
tracyyun
by: tracyyun | last post by:
Dear forum friends, With the development of smart home technology, a variety of wireless communication protocols have appeared on the market, such as Zigbee, Z-Wave, Wi-Fi, Bluetooth, etc. Each protocol has its own unique characteristics and advantages, but as a user who is planning to build a smart home system, I am a bit confused by the choice of these technologies. I'm particularly interested in Zigbee because I've heard it does some...
0
7192
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own.... Now, this would greatly impact the work of software developers. The idea...
0
5571
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert into image. Globals.ThisAddIn.Application.ActiveDocument.Select();...
0
4090
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in the same network. But I'm wondering if it's possible to do the same thing, with 2 Pfsense firewalls...
0
4196
by: adsilva | last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
1
1807
muto222
by: muto222 | last post by:
How can i add a mobile payment intergratation into php mysql website.

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.