SparkFun Forums 

Where electronics enthusiasts find answers.

Have questions about a SparkFun product or board? This is the place to be.
By dlotton
#155593
I'm having a problem using the CanaKit USB Relay board with Win7 64-bit.

I've written a python class to control this board and it works great under Linux and WinXP. However, under Win7 64-bit it appears to occasionally drop characters.

Under Win7, when I compare the string sent to the board to the string that is echoed back, there are occasionally characters missing from the echoed string, and of course, the board does not perform the function that was requested.

I'm running a Linux (Xubuntu 12.04) virtual machine under VMWare on my Win7 64-bit host computer. Running the Python code on the Linux VM works flawlessly. Running the Python code on the Win7 64-bit host computer gives the above described behavior. Running the Python code on another computer with WinXP (32-bit) works flawlessly.

Since all of the hardware (PC and relay board) in the Linux and Win7 examples is exactly the same, I feel comfortable in saying the hardware is functioning properly.

I've tried inserting inter-character delays, and inter-command delays (up to 2 seconds) to no avail.

This board uses the built-in windows usbser.sys CDC driver with a manufacturer supplied INF file. The driver is installed, the device is detected and enumerated and communicates, but as described above, appears to drop characters sporadically.

I submitted this issue to CanaKit via their web form, but have received no reply from them.

Any thoughts?
By dlotton
#155756
Finally received a reply from Canakit.

For the benefit of others, here is a portion of the reply...
Code: Select all
We have seen this behavior in very very fews instances, and unfortunately we have not been able to figure out the root cause of the problem.   We believe it to be some sort of an internal Windows driver issue with some specific USB Controller chips maybe.  

Note that we don’t really supply a driver, and the “INF” windows file simply identifies the hardware as a generic USB CDC device (aka Virtual COM port).  Your results are very interesting to us because you are running it within a VM on the host machine and you indicate it works inside the VM but not on the host, which make us believe even more it’s some sort of an internal driver issue.  We are trying to figure out if there is a “work around” we can implement within the firmware of the board itself to compensate for what happens, but unfortunately as we don’t know what actually causes it, we have had a hard time coming up with any kind of patch on our side to compensate for it.
I will post back here as I learn more from CanaKit.
By dlotton
#176983
I never got another reply from them. Apparently, they aren't going to address the issue.

I started using these instead...

https://www.sparkfun.com/products/9526 (currently out of stock)

It is more expensive, but works great and you can write your own code to run on it if you want with the free Arduino development tools. Or just use it as-is as a USB relay box.