HubertD / candle_dll

Windows DLL to access candleLight devices via WinUSB
15 stars 16 forks source link

Added VS2013 test program, improved performance #1

Open mbehensky opened 6 years ago

mbehensky commented 6 years ago

Hi, Hubert-

I'm trying to get my cantact board to work better under Windows. The standard serial port emulation firmware was only able to receive a few hundred packets per second in Wndows, so I tried your excellent candlelight firmware. This was easily able to receive all the packets on my 45% loaded 250kbps canbus under Linux.

I tried your candle_dll for windows support. After modifying it to compile under visual studio and writing a test program I was able to receive 1k packets per second, which wasn't quite fast enough (my bus had around 1.2k packets per second). It seems like on at least some motherboards under WinUsb you are limited to one packet per full speed usb frame unless the packet is equal to the max packet size of the pipe.

I created a modified version of the firmware that optionally pads packets to 32 bytes (I gave you a pull request for that as well). The combination works much better. For more details, check out WinUSBNotes.txt in the top level directory, and Usage.txt in the candle_test directory.

I didn't try and get everything to compile with your makefile. It looks like maybe you were using the gnu tools with mingw or something. If you give me some details on how to set that development environment up I can try and get that to work with the test program.

HubertD commented 6 years ago

Thank you so much for your effort and contribution. You are right, the DLL was built for use with Qt & MinGW. It might take some time, but I will take a look and try to integrate.