Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
753 views
in Technique[技术] by (71.8m points)

linux - Is it possible to make a computer behave as a bluetooth HID device?

Is it possible to make a computer behave as a bluetooth HID device? That is, given a local machine with a standard USB keyboard plugged into it, other devices could discover this machine and use it as a bluetooth keyboard.

I'd like to create a linux or OS X application (or use an existing one, though I've found none) which can behave as described above, but I'm not sure where to start, or if it's even possible.

So:

  • Is what I'm describing possible?
  • Are there any existing applications that do what I describe?
  • If no application already exists (I'm assuming not), are there bluetooth libraries or bindings that will help? (I'm pretty comfortable using most of today's popular languages, so I'd prefer a library most directly suited to the task, so long as it's available in linux or OS X.)
  • Failing any of the above, the bluetooth spec looks pretty dense. Are there specific guides or other starting points applicable to the problem at hand that I can read?

I realize that such an application would most likely need to steal the normal keyboard input, possibly providing some KVM-like hotkey for switching between providing input to the host operating system and sending the input over bluetooth to the connected device, but I'm considering that problem to be outside the scope of this question.

See Question&Answers more detail:os

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

It is definitely possible on Linux. Some time ago I found this project:

http://nohands.sourceforge.net/index.html

They emulate a full-blown headset with audio and keyboard controls on the Linux bluetooth stack. If they can emulate something like that, you would probably be able to emulate something simpler like a keyboard.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

...