What is new with Serial in Windows 10


Authored by George Roussos [MSFT]

The Serial Communication protocol is everywhere; it is broadly available, easy to learn, and low cost.   It is used across many different transports: typically over USB, in cases over Bluetooth and even over TCP/IP.   Many people are familiar with COM ports and programs that read data from and/or write data to them.  Today we find Serial Communications in both 30 year old hardware like natural gas meters and new products like many 3D Printers or those in the prototyping stage based upon Arduino boards.  

We listened to customer feedback on Serial while planning Windows 10 and acted upon two high level points:

  1. Improve Serial over USB driver support from Windows.
  2. Provide a Windows Runtime API for communication with Serial devices.

This blog entry focuses on enhancements for USB connected Serial devices in Windows 10, and how customers can provide additional feedback on them which we can efficiently act upon.

1.   Improved Serial over USB driver support in Windows 10

Earlier versions of Windows contained a driver for USB connected serial devices: usbser.sys. However the driver did not include a compatible ID match in an INF. The driver had to be included using modem INFs which was not standard.

In Windows 10, we added inbox support for USB CDC Abstract Control Model (ACM) compliant hardware. Usbser.sys is now installed as a compatible ID match for USB CDC compliant hardware, without requiring a 3rd party driver or inclusion via modem INFs.

Now devices that report these compatible IDs: 

  • USB\Class_02&SubClass_02&Prot_01
  • USB\Class_02&SubClass_02

… including popular prototyping boards like Arduinos – just work with our built-in driver.  

Also usbser.sys has been completely re-written in WDF, improving its overall reliability as well incorporating new features for power management i.e. USB Selective Suspend.  See USB Serial driver on MSDN for details.

2.   A Windows Runtime API for communication with Serial devices

Windows 10 includes the Windows.Devices.SerialCommunication universal API designed for these three scenarios:

  1. USB Peripherals like Arduinos – including as a USB Accessory on new Phones and Tablets
  2. Peripherally connected USB to RS-232 Adapters
  3. UARTs inside embedded  systems like MinnowBoard Max or Raspberry Pi v2 running Windows IoT SKU

This API does not include support for accessing UARTs/COM ports inside Phones/Tablets/PCs; Windows 10 focused on above 3 scenarios.

//Build/ 2015 USB Accessories including SerialCommunications session introduces this API and walks thru the design and usage of it.

Windows 10 SDK includes two Universal SDK samples illustrating this API:

  1. CustomSerialDeviceAccess SDK Sample
  2. New SerialArduino SDK Sample from above //build talk is now available including C# and Arduino sketch source code.

How to Provide Feedback

We listen and act upon customer feedback; all of above are all results of prior feedback.   If you have encountered a problem with functionality described in this blog entry, or want additional functionality, please see below.

Our team listens to two feedback channels to provide feedback:  Forums and the Feedback App (see Feedback App post for additional information) are available to everyone.   Please follow below guidance on where to provide your feedback and what to include to help us efficiently act upon your feedback.

Forums

Please create a new post on the Windows Insider Program forum under the ‘Devices and Drivers’ Topic.

Feedback App

Please file a bug under:
Category:  Hardware, Devices, and Drivers
Sub-Category:  USB devices and connectivity

What information to include

To help us efficiently act upon any bugs for feedback you have, please include relevant information below.

Problems with built-in USBSer.sys
USBSerial driver for USB CDC compliant devices

  • Feedback or Bugs:  Please include ‘USBSer’ in bug title
  • Bugs, please add: 
    • Crisp steps to reproduce the issue
    • Hardware IDs and Compatible IDs for target device  (below)
    • If problem involves data transfer, please include Traces as described under Tracing below.

Problems with Windows.Devices.SerialCommunication Universal API

  • Feedback or Bugs: Please include ‘Windows.Devices.SerialCommunication’ in bug title
  • Bugs, please add:
    • a sample code fragment that illustrates the problem
    • All App manifest device capabilities declarations,  like

 <DeviceCapability Name="serialcommunication">

<Device Id="any">

<Function Type="name:serialPort" />

</Device>

</DeviceCapability>

 <DeviceCapability Name="serialcommunication">

<Device Id="any">

<Function Type="name:serialPort" />

</Device>

</DeviceCapability>

How to capture Hardware IDs

  1. Attach your Arduino, open Device Manager, select the board, select Properties, then Details tab
  2. Select Hardware IDs from Property dropdown
  3. Select the values, right click and “copy” them – and paste into the bug.
  4. Select Compatible IDs from Property dropdown
  5. Select the values, right click and “copy” them – and paste into the bug.

Example: Arduino Uno R3

Hardware IDs
USB\VID_2341&PID_0043&REV_0001
USB\VID_2341&PID_0043

Compatible IDs
USB\Class_02&SubClass_02&Prot_01
USB\Class_02&SubClass_02
USB\Class_02

Tracing

Please enter the copy and paste below commands into an Administrative command window, reproduce the problem, and attach the resultant trace files into a bug:

Before Repro

logman create trace -n Serial_WPP -o %SystemRoot%\Tracing\Serial_WPP.etl -nb 128 640 -bs 128

logman update trace -n Serial_WPP -p {7F82DC23-235A-4CCA-868C-59531F258662} 0x7FFFFFFF 0xFF

logman update trace -n Serial_WPP -p {8FBF685A-DCE5-44C2-B126-5E90176993A7} 0x7FFFFFFF 0xFF

logman update trace -n Serial_WPP -p {0ae46f43-b144-4056-9195-470054009d6c} 0x7FFFFFFF 0xFF

logman start -n Serial_WPP

<Reproduce the problem at this point (do not copy and paste this)>

AfterRepro

logman stop -n Serial_WPP

logman delete -n Serial_WPP

md %systemroot%\Tracing\Logs

move /Y %SystemRoot%\Tracing\Serial_WPP_000001.etl %SystemRoot%\Tracing\Logs\Serial_WPP.etl 


Comments (9)

  1. chauncey says:

    I have a new hp computer with windows 10, I have an older printer/cutter with need for a lpt1 port hook up
    what can I do to make this work

  2. Daniel says:

    I recently upgraded to windows 10, and I’m having what seems to be dropped frames on my 3D printer (Arduino board with Ramps Shield).
    The printer will stutter, in doing so start printing offset (layer shift). Nothing I do seems to improve the problem, and it didn’t occur when I was running Windows 8.1.

  3. Curren says:

    Hi. I have been using an arduino with windows 7 and everything worked 100%. Now with windows 10, the USB to serial communications does not work. I think the hexadecimal’s that is sent from the arduino to PC does not get recognized/ picked up? I have browsed the internet and saw comments like, “install generic modem driver”… Not sure how to fix it. Please help.

  4. Verlan Troutt says:

    Not sure if this is where I need to enter this but, My company, a Telecommunication company has 1000+ pieces of equipment that we can only backup utilizing a DOS 16 bit program. with computer changes they have decided to go to windows 10 64 bit in 2017 and I am looking for a way to still communicate with the equipment. I have tested windows 10 64 on a new laptop using a USB- Serial adapter. I installed a dos emulator and then install the dos program for backups. The program runs but it can not communicate through the adapter to the equipment. I have checked that the com port 1 shows installed for the adapter.
    Any suggests will be appreciated.

    1. Aschgrau says:

      Try flushing your port first, worked for me.

  5. Aschgrau says:

    When I connect my RS-232 based device to usb my WIndows 10 can see it, but cannot communicate. In order to work with it I need to force flush before anything else.

  6. Bill says:

    I have an HP computer with windows 10 and intend to control a cnc machine with Tinyg/chillipeppr using web base Json server, however when loading Json a message appears”there are no serial ports listed”. question: how can this problem be solved?

  7. atif nizar says:

    window 10 serial no
    s657850606870
    I need this window product key.

Skip to main content