LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 1555|回复: 1

linux 用什么函数可以检测U盘的插入?

[复制链接]
发表于 2011-5-9 13:44:21 | 显示全部楼层 |阅读模式
linux 用什么函数可以检测U盘的插入?
发表于 2011-5-9 14:03:45 | 显示全部楼层
Post by zzxap;2138490
linux 用什么函数可以检测U盘的插入?

Notification when hardware is inserted or removed is provided by the
hotplug mechanism.  Linux provides two hotplug interfaces: /sbin/hotplug and netlink.
基础是上面所述,但应用程序可以通过libdbus接口获得硬件热插拔事件。
可参考我之前的文章:http://linuxsir.cn/bbs/thread319781.html
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表