[Mono-list] USB hardware detection using Mono on Linux

Adam Tauno Williams awilliam at whitemice.org
Tue Aug 18 06:49:25 EDT 2009

On Tue, 2009-08-18 at 12:06 +0200, Danny Haak wrote:
> Hi all,
> I am currently writing a piece of software that needs to detect which
> USB devices are attached to the computer. Event-based notifications of
> attaching and detaching hardware while the software is running is nice,
> but not required.
> I first used DeviceKit-Sharp (by Ben Gamari), but when observing a bug
> and asking the DeviceKit mailing-list, Kay Sievers answered: "The
> DeviceKit daemon is dead and will not run, or be installed on any usual
> system. You need to use libudev, or the GUdev to retrieve this
> information." This is a pity, because DeviceKit was working nicely,
> despite the bug in the daemon.
> I can't find any Mono-bindings for libudev, and diving deeper in the
> documentation, libudev seems quite low-level and talking to HAL. Looking
> for HAL abstractions, I discovered that HAL will be obsolete as well in
> the near future. This leaves me completely confused about 'the way to
> go' for hardware detection in Mono on Linux. Is there anybody who can
> suggest a (sort of) future-proof approach to this?

I believe you can attach to the system D-BUS and you will receive HAL
events.   <http://www.ndesk.org/DBus_Documentation>
OpenGroupware developer: awilliam at whitemice.org
OpenGroupare & Cyrus IMAPd documenation @

More information about the Mono-list mailing list