hid

Debugging BLE HID device

谁说我不能喝 提交于 2019-12-13 03:19:39
问题 I'm trying to make an Android application for Android Things running on raspberry pi that takes USB joystick inputs (including DJI Mavic controller) and passes it over BLE HID as a gamepad. Windows, Oculus Quest and Mac all recognize it as a gamepad, but when I try to connect to it, they connect and disconnect right away. I'm not sure why Is there any tool on any OS that logs the BLE HID pairing process to find out what went wrong? https://github.com/darvin/USBMavicBLEHIDAndroidThing/blob

How do I get the Vendor and Product strings in case of a HID device on Windows?

☆樱花仙子☆ 提交于 2019-12-13 02:07:10
问题 I need to get information about the idProduct and idVendor of a plugged in HID device on my Windows machine. How do I get the USB_DEVICE_DESCRIPTOR for a given HID device? I searched the internet, but I only found examples of devices being queried using the WinUSB library and getting the USB_DEVICE_DESCRIPTOR. My understanding that I cannot use WinUSB for plugged in HID device. What do I need to use for a HID device then? 回答1: If you're using HidLibrary, you can get a device like this:

Can I access USB HID device via a Chrome App?

陌路散爱 提交于 2019-12-12 08:54:53
问题 I have a simple little dongle I want to debug by sending/receiving basic USB messages. It enumerates as an HID device (like an additional mouse), but am worried that I won't have access to it. I forgot the hardware and can't test with it for a couple days. Is it a futile effort to continue building a chrome extension to test it? Chrome App, USB documentation: https://developer.chrome.com/apps/app_usb Getting-started example: https://github.com/GoogleChrome/chrome-app-samples/tree/master/usb

Rename a USB HID device under Windows

血红的双手。 提交于 2019-12-12 02:58:48
问题 I wrote a firmware to a USB device that uses the generic HID class for communicating with the host PC. When connecting the device to the PC, it shows the hard-coded string I put in the firmware, but after the driver installation is over (using the generic Windows driver), the device's name is changed to a generic "USB Input Device". How can I rename the device back? 回答1: You can't do that. The device manager shows the string that is registered at installation by the device driver - in your

“Access is denied” in interrupt Write in JNA implementation of USB HID communication

我们两清 提交于 2019-12-12 02:54:58
问题 Using the library in this link http://www.blog.kslemb.com/doku.php/en/projects/globx/java_hid I have been modfied this code to send data on a HID device using interrupt transfer. public byte SetInReport(byte[] buffer, int buffersize) { if (HIDHandle.equals(WinBase.INVALID_HANDLE_VALUE)) { return HID_DEVICE_NOT_OPENED; } IntByReference bWritten = new IntByReference(); boolean Status = Kernel32.INSTANCE.WriteFile(HIDHandle, buffer, buffersize, bWritten, null); if (Status == false) { debug(

Delphi HID in Delphi7 and Delphi XE2

爷,独闯天下 提交于 2019-12-11 16:06:45
问题 I made a small program in Delphi 7 to show some details of all attached HID devices. I only used system files like SetupAPI , Moduleloader and HID.pas . This works perfect. When I take the same code and compile it in Delphi XE2 or (2010 for that matter), it fails to produce the required output. Probably this has something to do with pointer casting or so, but I cannot find the root cause. Can anyone help. This is my code: unit Unit1; interface uses Windows, Messages, SysUtils, Variants,

What is a correct usbHidReportDescriptor for Android?

心已入冬 提交于 2019-12-11 14:59:11
问题 I am implementing a USB touchscreen interface, which needs to work on Android. From https://github.com/denilsonsa/atmega8-magnetometer-usb-mouse/blob/master/firmware/main.c#L159 I first tried: // Mouse 0x05, 0x01, // USAGE_PAGE (Generic Desktop) 0x09, 0x02, // USAGE (Mouse) 0xa1, 0x01, // COLLECTION (Application) 0x85, 0x02, // REPORT_ID (2) 0x09, 0x01, // USAGE (Pointer) 0xa1, 0x00, // COLLECTION (Physical) // X, Y movement 0x09, 0x30, // USAGE (X) 0x09, 0x31, // USAGE (Y) 0x26, 0xff, 0x7f,

how to send data to usb hid via chome app/javascript

泄露秘密 提交于 2019-12-11 12:31:31
问题 I succefully connected to mydevice (ps 3 pad) via usb and easily can intercept data depending on which button i press. But pad also can vibrate and has leds and i'd like to operate them as well so here as the questions: though google manuals are really poor i tried to establish connection to device on my own: var message = new Uint8Array(58); message[0] = 1; console.log(message.buffer); chrome.hid.send(connectionId, reportId, message.buffer, function() { console.log('accomplished') }

How do I org.bluetooth.characteristic.report_map for more than one type of report?

六眼飞鱼酱① 提交于 2019-12-11 08:04:54
问题 Alright, I'm building a keyboard with an integrated touch-screen used as a mouse, I'm sending the data generated over BLE via HID OVER GATT. This works fine for org.bluetooth.characteristic.boot_keyboard_input_report & org.bluetooth.characteristic.boot_mouse_input_report, but I'm not very certain how to configure the report_map and what I need to send according to these declarations. The Main question is really, because there is no hybrid type of Usage, I need to use two Usage. But do I need

Device::HID read barcode scanner convert binary to Ascii

浪尽此生 提交于 2019-12-11 07:09:11
问题 I try to read barcode form scanner. I had got data from scanner and the format is binary. How do I conert binary to Ascii string? The barcode type is code 39. A1234 => [Barcode SCANNRT] => [perl] => binary => ?? A1234 ??? use Device::HID; use Data::Hexdumper qw(hexdump); my $dev = Device::HID->new(vendor => 0x04b4, product => 0x0100) or die "No such device !\n"; $dev->timeout = 0.1; # seconds (=100 ms) my $buf; my $len=128; while(defined(my $in = $dev->read_data($buf, $len))){ if ($in == 0) {