Thread overview | |||||||
---|---|---|---|---|---|---|---|
|
November 08, 2020 Looking for an HID binding for D | ||||
---|---|---|---|---|
| ||||
https://github.com/libusb/hidapi > A Simple library for communicating with USB and Bluetooth HID devices on Linux, Mac and Windows. Anyone ever used it in D or done a D binding? I'm in need of a binding. |
November 08, 2020 Re: Looking for an HID binding for D | ||||
---|---|---|---|---|
| ||||
Posted in reply to aberba | On Sunday, 8 November 2020 at 20:47:10 UTC, aberba wrote: > https://github.com/libusb/hidapi > >> A Simple library for communicating with USB and Bluetooth HID devices on Linux, Mac and Windows. > > Anyone ever used it in D or done a D binding? I'm in need of a binding. There you go. https://gist.github.com/UplinkCoder/c61dc8516d06c67c280e087a82b28815 Running dstep and deleting the useless macros was enough. |
November 09, 2020 Re: Looking for an HID binding for D | ||||
---|---|---|---|---|
| ||||
Posted in reply to Stefan Koch | On Sunday, 8 November 2020 at 21:58:54 UTC, Stefan Koch wrote:
> On Sunday, 8 November 2020 at 20:47:10 UTC, aberba wrote:
>> https://github.com/libusb/hidapi
>>
>>> A Simple library for communicating with USB and Bluetooth HID devices on Linux, Mac and Windows.
>>
>> Anyone ever used it in D or done a D binding? I'm in need of a binding.
>
> There you go.
>
> https://gist.github.com/UplinkCoder/c61dc8516d06c67c280e087a82b28815
>
> Running dstep and deleting the useless macros was enough.
Thanks, Stefan, never took a close look at step. Looks like a pretty nice translation tool.
What do you think about doing a Conf session on the steps to take an average C code and turn it into D using DStep?
|
November 09, 2020 Re: Looking for an HID binding for D | ||||
---|---|---|---|---|
| ||||
Posted in reply to aberba | On Monday, 9 November 2020 at 00:21:12 UTC, aberba wrote:
> On Sunday, 8 November 2020 at 21:58:54 UTC, Stefan Koch wrote:
>> On Sunday, 8 November 2020 at 20:47:10 UTC, aberba wrote:
>>> https://github.com/libusb/hidapi
>>>
>>>> A Simple library for communicating with USB and Bluetooth HID devices on Linux, Mac and Windows.
>>>
>>> Anyone ever used it in D or done a D binding? I'm in need of a binding.
>>
>> There you go.
>>
>> https://gist.github.com/UplinkCoder/c61dc8516d06c67c280e087a82b28815
>>
>> Running dstep and deleting the useless macros was enough.
>
> Thanks, Stefan, never took a close look at step. Looks like a pretty nice translation tool.
> What do you think about doing a Conf session on the steps to take an average C code and turn it into D using DStep?
Dstep translates the headers. Not the implementation.
My Conference talk is about template overhead, therefore I won't go into dstep.
|
November 09, 2020 Re: Looking for an HID binding for D | ||||
---|---|---|---|---|
| ||||
Posted in reply to aberba | On Sunday, 8 November 2020 at 20:47:10 UTC, aberba wrote: > https://github.com/libusb/hidapi > >> A Simple library for communicating with USB and Bluetooth HID devices on Linux, Mac and Windows. > > Anyone ever used it in D or done a D binding? I'm in need of a binding. I have used https://github.com/FFY00/hidapi-d once. It worked but it was a long time ago. I clearly remember that the only problem I had encountered was with the obscure proprietary API of the hardware, not the library. |
Copyright © 1999-2021 by the D Language Foundation