Recent Posts

Pages: 1 2 [3] 4 5 ... 10
21
USB / Re: Generic HID example work only under .NET Framework 2.0
« Last post by Jan Axelson on December 03, 2019, 12:04:50 pm »
Changing the build worked for me. If you can find where the code is failing we might be able to help.
22
USB / Re: Generic HID example work only under .NET Framework 2.0
« Last post by Frank Neumann on December 03, 2019, 11:32:38 am »
I have already tried, unfortunately the same behavior
23
USB / Re: Generic HID example work only under .NET Framework 2.0
« Last post by Jan Axelson on December 03, 2019, 11:29:21 am »
Try setting Build > Configuration Manager > x86
24
USB / Re: Generic HID example work only under .NET Framework 2.0
« Last post by Jan Axelson on December 03, 2019, 10:36:11 am »
What in the code triggers the exception?

I can run the code under .NET 4.0, haven't tried higher.

Also see:

https://social.msdn.microsoft.com/Forums/lync/en-US/394ce5ba-b2fa-4046-af17-9904c00cd326/moving-to-net-46-caused-an-overflow-exception?forum=csharpgeneral
25
USB / Re: Generic HID example work only under .NET Framework 2.0
« Last post by Frank Neumann on December 03, 2019, 10:10:22 am »
Hi Mrs. Axelson,

if I switch the Targetframework from 2.0 to 4.5 then I get the message:
Quote
Eine Ausnahme (erste Chance) des Typs "System.OverflowException" ist in GenericHid.exe aufgetreten.
An exception (first chance) of the System.OverflowException type has occurred in GenericHid.exe.
And my Hardware can not switched.

Till Framework 3.5 is OK, over 4.0 I get this message.
26
USB / Re: Generic HID example work only under .NET Framework 2.0
« Last post by Jan Axelson on December 03, 2019, 09:54:28 am »
Where is the code failing?
27
USB / Generic HID example work only under .NET Framework 2.0
« Last post by Frank Neumann on December 03, 2019, 07:50:10 am »
For 4 days I try to find out why the code (Generic HID 50) does not work with my Visual Studio settings! :-)

Now today I found out that the sample code of Jan Axelson is based on the framework 2.0, where I set mine to 4.5.

Who can tell me what I need to change in the code so that the example of Jan Axelson also works under the Framework 4.5?

thank you in advance
Frank Neumann
28
USB / Re: Anything better than HIDAPI today?
« Last post by Jan Axelson on December 02, 2019, 01:43:54 pm »
Thanks for sharing this
29
USB / Re: Anything better than HIDAPI today?
« Last post by bpaddock on December 02, 2019, 08:14:55 am »
Due to the original author abandoning HIDAPI the
LibUSB project has forked it and applied the long
lingering patches needed:

https://github.com/libusb/hidapi
30
USB / Re: hakcing the binterval - pitfalls
« Last post by Jan Axelson on November 30, 2019, 05:25:32 pm »
A host can poll as often as it wants. If an interrupt, bulk, or control endpoint isn't ready to send or receive data, it can return NAK.

It's possible, however, that a device won't be tested at rates faster than expected, and if an IN or OUT token arrives too quickly, the endpoint won't be set up in time to return NAK.

As for control transfers, from USB Complete 5th Ed:

In a USB 2.0 control transfer, where stricter timing isnít specified (as in a class specification), in a transfer where the host requests data from the device, a device may delay as long as 500 ms before making the data available to the host.

In a transfer where the host sends data to the device, if the host sends data at the maximum rate the device can accept the data, a USB 2.0 device can take up to 5 seconds to accept all of the data and complete the Status stage. Once begun, the Status stage must complete within 50 ms.

The host and its drivers arenít required to enforce the timing limits, but all devices should comply with the limits to ensure proper operation with any host.


Pages: 1 2 [3] 4 5 ... 10