Windows 10 USB CDC Serial

Developing a Cross-Platform app to work with an embedded device. App targets Windows Vista, 7, 8, 10, & Mac OSX. App works fine under all target OSes except Windows 10.

Updated to Windows 10 and communication over serial is very problematic. Communications from Xojo’s Serial object appear to reach the device fine, but communications from device to Xojo are not. Communications from device seem to be buffered somehow, the initial communication always fails to arrive, but if I forcefully send a second it will reach Xojo just fine.

Once communication between Xojo and device are established things appear more consistent but Xojo seems to receive duplicates of certain transmissions.

I’ve tested communications using Python / Terminal instead of Xojo and everything is fine, problem definitely appears to be in Xojo.

Has anyone else experienced anything like this?

Are using a Serial to USB converter?

No, Serial comes directly from Microcontroller with Serial USB capability to a simple inf / driver that links to Windows provided Usbser.sys. Windows 10 includes a rewrite of Usbser.sys and would automatically link to the new one based on Device Class Compatability IDs, but the installed inf should overwrite those settings (and appears to when using Python).

Just not sure if the Xojo Serial implementation has taken Windows 10 serial changes into account.

The socket class is troublesome in 10 as well. Sometimes LastErrorCode causes a hard crash in Xojo applications. :-/ we had issues using serial during the technical preview so we tried the socket class only to find more troubles. 10 has definitely caused some problems.

Thanks for the reply Matthew. Sucks, but glad to know I’m not the only one and that I’m not going crazy or anything. (I was really hoping Windows 10 would be a straight forward upgrade… sigh / Microsoft).

Found a sort-of solution:

I did find if you right-click a compiled program and change the program compatibility the problem does rectify… although there is no distributable compatibility setting which I am aware of, besides modifying the user’s registry (which is possible with some setup packagers) or having the user set compatibility mode for the application before running, themselves.

Bumping this thread as I have the same problem. Serial does not work on Xojo and W10 but just fine from the same system using Arduinos serial monitor. Everything still works well in W7.

Any clues? Is somebody working on the problem?

Has anyone made case out of this?
I really want to rank it high.

I have to come back to this again and ask for clues! Please let me know if you have some input on the matter. I have a commercial product out in the form of a small instrument powered by a arduino based control board that communicates with my Xojo software via USB/serial. It works on mac, it works on W7 bot it does NOT work with W10. If I use some other software to talk to the instrument on W10 like for example the Serial monitor in the Arduino IDE everything works fine.

My conclusion is that the Serial control is not correctly implemented in Xojo for W10.
Could someone (preferably from Xojo) comment on this?

Sure… Have you filed a Feedback bug report so we can look at it?

Thank you for your reply Greg. I will compile a simple project that shows my point. I will post here when it is submitted.

I have now added a bug report with no 41631.
Thanks for looking at this Greg.

[quote=204732:@Ben Artes]…Communications from Xojo’s Serial object appear to reach the device fine, but communications from device to Xojo are not. Communications from device seem to be buffered somehow, the initial communication always fails to arrive, but if I forcefully send a second it will reach Xojo just fine.

Once communication between Xojo and device are established things appear more consistent…[/quote]

I also see the symptom of not getting data back immediately, but after I start seeing data it carries on OK.

I haven’t noticed this ( yet ).

I’ve added some notes to your feedback.

I am sorry to see that no-one at Xojo has had time to review the bug report for this yet. Is there anything else we can do to speed this up Greg O’Lone? Our customers wish to upgrade to W10 but they can’t until this problem is resolved and we can’t sell to customers running W10. Please review bug report 41631.

Maybe i can help but i’d like to know your kind of microcontroller and serial settings (baud, bits, stop and parity).
Also an encoding your using perhaps.

This case has been needs review for a month now. It has been the highest ranking case needing review since a few days after it was opened. I know this is not a new sentiment, but I can’t help but feel that if an issue like this appeared on Mac it would have received more attention from Xojo.

@Thom Leiding
Does this happen with earlier versions of XOJO as well? I have serial apps working fine with 2014 (in WIN10). I did try your test program on 2014 (by wrapping the RX to TX on the serial output) and it appeared to work.

@Chris Carter
If past history is any indication of future actions, I am not sure why would that surprise you. But beware, you are almost guarantee to get flamed for comments like that.

@Derk Jochems
I am communication with an 32U4, in the form of an Arduino Leonardo (and a compatible), via USB (virtual COM port). Settings are 115200 baud, 8 bits, NP, 1 sb. I am not specifying any encoding.

@LangueR
I haven’t tried with 2014. Got rid of the old versions. I will try to get hold of it and try.

I just ran across this post, and it’s a relief to know a bug report/case (41631) is submitted–I’ve been having the exact issue for the past couple of months.

I’m developing an application to work with the LRS T7470 pager transmitter (http://pager.net/products/cell-phone-paging-transmitter-t7460-freedom/), and encountering the same issue as Chris Carter described: the DataAvailable event does not fire until a second command is sent, and only part of the first command’s response is received until (yet) another command is sent.

When communicating with the device via putty, no problems–I find this issue using Xojo2015r4 on Windows 10 on a device using “usbser.sys”.

The LRS T7470 has an integrated USB-to-Serial adapter. Using the serial-based LRS TX-7470-C232 (http://pager.net/products/interface-transmitter-t74c232/) with an external USB-to-Serial FTDI chipset (ftser2k.sys, serenum.sys, ftcserco.dll, and ftserui2.dll) works flawlessly with the same Xojo2015r4 on Windows 10.

I might see if LRS has an alternative driver (to usbser.sys) for the T7470 on Windows 10, however, I agree—the issue exists with Xojo, Windows 10, and usbser.sys.

Please let me know if any further information is needed to help pinpoint and resolve this problem in Xojo—I hope to get this fixed soon.

Any updates on this issue? I recently ran into this issue with an old Realbasic application. I was getting ready to install my (old) version of Xojo to see if that would help when I found this thread.

Thanks,