sticky
Serial Port Communication on Windows IoT Core RRS feed

  • General discussion

  • Here we talk about how to use Serial Port communication on Windows IoT Core on Raspberry PI.On Raspberry Pi, hardware UART and USB UART Adapters both are usable for your application with serial communication. By default, the UART transmit and receive pins are pins 8 and 10 on the GPIO header. 

    

    There is an official document with sample which initializes UART0 and performs a write followed by a read. In addition, RFCOMMM( Radio Frequency Communication) is the underlying serial communications for Classic Bluetooth . We can refer to this sample on GitHub about running UWP apps on Windows 10 IoT core to connect an embedded, eg Arduino, device over Bluetooth Serial.

    Generally, if we encounter that the device cannot read/write data though the serial port, we can follow below steps to troubleshoot.

    1.You can connect the TX to RX with Jumper like following, and then run the sample code to check if the app can read/write data. If it does not work, the IC on the board may be broken.

    2.Make sure the BaudRate, Handshaking and StopBits are configured correct. Where the serial port to be tested has a complete RS232 interface (ie. a DB9), use a DB plug with the RxTx cross over wires connected plus the typical handshaking crossovers. Some RS232 ports (or USB adapters) require signals such as Carrier Detect (DCD) and DCE Ready (DSR) to be asserted before they will function properly.

    3.If you want to use a USB UART Adapters on Windows IoT Core, you should know that not only CP2102 USB 2.0 to TTL Module Serial Converter is supported which we can see in the hardware compatibility list, but FTDI and generic usbser.sys devices are also supported. When you plug in the USB TTL module, you will find out the connected device in IoTDefaultApp.

    Also you can use devcon.exe stack *  and devcon.exe status *  cmdlet to check the expected drivers stack and drivers status on Windows IoT Core.(Refer DevCon command)

    USB\VID_10C4&PID_EA60\0001
        Name: Silicon Labs CP210x USB to UART Bridge
        Setup Class: {4d36e978-e325-11ce-bfc1-08002be10318} Ports
        Controlling service:
            silabser
    
    Mincomm is another helpful tool to troubleshoot serial port issues. This tool can enumerate ports, give you their friendly name and DeviceID, open ports, configure settings (baud rate, stop bits, etc.), and send and receive data. 

    At last, here is a topic about Serial Port support for Raspberry Pi with Windows IoT. Glad to see everyone share the helpful information below about serial communication on Windows 10 Iot Core.


    MSDN Community Support Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Friday, December 7, 2018 5:44 AM
    Moderator

All replies

  • Can you confirm if UART works the same way on DragonBoard 410c with Latest Windows 10 IOT v17763 , because in the past I have tried same code worked fine on Raspberri PI 2 but when when deployed on DragonBoard 410 the UART and SPI ports fail communicate with external devices, can you please confirm if that problem has been fixed, with this new Windows 10 IOT Release 


    Omar

    Friday, December 7, 2018 2:42 PM
  • Hello Omar,

    It is a known issue about on board UART and SPI on Dragonboard 410C due to BSP. It seems that this issue has not been fixed yet. Appreciate for you patience.

    As a workaround, currently you can use USB-to-TTL adapter instead of On-board UART. 

    Best Regards,

    Michael


    MSDN Community Support Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.

    Monday, December 10, 2018 1:32 AM
    Moderator
  • @Michael, 

    I thought there is a new BSP with latest Windows Build? I also am noticing StorageFile reading problem in this latest Windows 10 IOT release


    Omar


    • Edited by Omar Barlas Tuesday, December 11, 2018 11:38 PM
    Tuesday, December 11, 2018 11:37 PM
  • @Omar,

    What problem about the StorageFile Reading did you find in the last Windows IoT Core?

    You can refer to a topic about file access on windows iot core here. Or you can open a thread in this forum.

    Best Regards,

    Michael


    MSDN Community Support Please remember to click "Mark as Answer" the responses that resolved your issue, and to click "Unmark as Answer" if not. This can be beneficial to other community members reading this thread. If you have any compliments or complaints to MSDN Support, feel free to contact MSDNFSF@microsoft.com.


    Wednesday, December 12, 2018 1:29 AM
    Moderator