控制USB接口的电源? [英] Control USB port's power?

查看:181
本文介绍了控制USB接口的电源?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

是否有人知道如何在一定USB端口控制USB引脚?我认为这是肯定可以用汇编但对于C ++或C#?

Does anybody know how to control USB pins on a certain USB port? I think it is definately possible in assembler but what about C++ or C#?

我希望能够使用USB电池作为LED的电源或类似的东西。于是程序将其启动并关闭其电源使其闪烁。

I want to be able to use USB battery as a power supply for an LED or something like that. So then a program would power it on and power it off making it flash.

我知道这听起​​来毫无意义,但我需要做的东西真棒。

I know it sounds pointless but I need to do it for something awesome.

我也知道, 。可能需要自定义驱动程序

I also know that it might require a custom driver.

HTTP: //www.riccibitti.com/pc_therm/USB_A_pinout.jpg

推荐答案

USB是不平凡的,所以我想你必须使用它的一些问题(MIS)。你会/多/更好(恕我直言)与标准的串行端口,它已被用于这样的东西了好半天,用大量的可用的例子。如果没有可用的串行端口目标机器上,则可以使用USB - >串行接口电缆。

USB is not trivial, so I guess you'll have some problems (mis)using it. You would be /much/ better off (IMHO) with standard serial ports, which have been used for stuff like that for ages, with plenty of examples available. If you don't have serial port available on your target machine, you can use USB->Serial interface cable.

话虽这么说,你可能要采取看看@:
http://sourceforge.net/projects/libusbdotnet/

That being said, you'll probably want to take a look @: http://sourceforge.net/projects/libusbdotnet/

LP,
德扬

LP, Dejan

这篇关于控制USB接口的电源?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆