添加链接
link管理
链接快照平台
  • 输入网页链接,自动生成快照
  • 标签化管理网页链接
相关文章推荐
逆袭的拖把  ·  Failed to parse field ...·  4 月前    · 
健壮的冲锋衣  ·  更新日志 - ...·  6 月前    · 
逆袭的墨镜  ·  perl 调用perl 脚本 - ...·  1 年前    · 
睿智的柠檬  ·  导航设计丝带·  1 年前    · 
威武的钥匙扣  ·  Amazon RDS for ...·  1 年前    · 

Hello,

I am planning to use the Custom HID device from CUBEIDE on an STM32F103 (I do not want to use CDC). I would like to use this in order to transfer simple packets of 20 bytes to and from the PC in a reasonable speed. I already set up some keyboard, mouse and gamepad collections wich work fine. But how do I interface with the custom device on Windows? I need the device not to need any specific drivers. I need to interface with this in python and java. Are the any guides on how to do this?

The second question is how to identify my device prior to sending data to see if it is physically connected. Can I use a string descriptor to identifie it in my PC application?

Thanks

Kind regards

For the old good Win32 API, read this :

Handling HID Reports Topics - Windows drivers | Microsoft Docs

Python and Java have various libraries, please google.

> how to identify my device prior to sending data to see if it is physically connected.

A simple example with Win32 C API is here .

Once you have the device handle, you can call HidD_GetManufacturerString , HidD_GetProductString , HidD_GetSerialNumberString and so on.

For more modern languages you can ask on the Microsoft forums or Stack Overflow (or again, google).

-- pa

STM32cube ide Hangs opening document in Software Packs Component Selector in STM32CubeIDE (MCUs) Trying to read I2C ADC device MCP3021 with HAL I2C library in STM32CubeMX (MCUs) STM32 device cannot be recognised without STM32CubeProgrammer in STM32CubeProgrammer (MCUs) STM32H753I-Eval2 in DFU mode in STM32CubeProgrammer (MCUs)