单片机
返回首页

ARM平台设备WinCE下UART配置

2021-06-22 来源:eefocus

UART串口作为最为常用的工业设备接口之一被广泛且大量的应用,本文就基于Toradex ARM平台设备为例介绍WinCE下UART配置。


我们采用Colibri ARM核心板产品搭配Colibri开发板来进行测试,OS为Toradex官方发布的最新版WinCE,其中Colibri系列默认定义了三个串口,UART A, UART B和UART C,其中UART A用作调试串口使用,下面就分别针对不同SoC产品进行说明。


1).基于NXP i.MX6Solo/DualLite的Colibri i.MX6产品


系统默认定义COM 1 – UART A (调试串口,全功能);COM 2 – UART B (支持Flow control);COM 3 – UART C;另外还支持额外的两个串口UART D和UART E,默认没有使能;所有串口默认均为DTE模式。


./使能UART D方法,请在注册表中添加下面内容并保存


[HKEY_LOCAL_MACHINEDriversBuiltInCOM4]


'Order'=dword:00000002


'IoLen'=dword:000000d4


'IoBase'=dword:021f0000


'Index'=dword:00000004


'DeviceArrayIndex'=dword:00000003


'Prefix'='COM'


'Dll'='csp_serial.dll'


[HKEY_LOCAL_MACHINEDriversBuiltInCOM4Unimodem]


'DevConfig'=hex:10,00,00,00,05,00,00,00,10,01,00,00,00,4B,00,00,00,00,08,00,00,00,00,00,00


'DeviceType'=dword:00000000


'Tsp'='Unimodem.dll'


'FriendlyName'='COM4 UNIMODEM'


[HKEY_LOCAL_MACHINEDriversBuiltInCOM4Pinout_Default]


'colibripin_165'='altfn=3'


'colibripin_167'='altfn=3'


./使能UART E方法,请在注册表中添加下面内容并保存


[HKEY_LOCAL_MACHINEDriversBuiltInCOM5]


'Order'=dword:00000002


'IoLen'=dword:000000d4


'IoBase'=dword:021f4000


'Index'=dword:00000005


'DeviceArrayIndex'=dword:00000004


'Prefix'='COM'


'Dll'='csp_serial.dll'


[HKEY_LOCAL_MACHINEDriversBuiltInCOM5Unimodem]


'DevConfig'=hex:10,00,00,00,05,00,00,00,10,01,00,00,00,4B,00,00,00,00,08,00,00,00,00,00,00


'DeviceType'=dword:00000000


'Tsp'='Unimodem.dll'


'FriendlyName'='COM5 UNIMODEM'


[HKEY_LOCAL_MACHINEDriversBuiltInCOM5Pinout_Default]


'colibripin_169'='altfn=3'


'colibripin_171'='altfn=3'


2).基于NXP Vybrid的Colibri VF50/VF61产品


系统默认定义COM 1 – UART A (调试串口,全功能控制引脚需使用GPIO);COM 2 – UART B (支持Flow control);COM 3 – UART C;另外还支持额外的两个串口UART D和UART E,默认没有使能。


./使能UART D方法,请在注册表中添加下面内容并保存


[HKEY_LOCAL_MACHINEDriversBuiltInUARTD]


'DeviceArrayIndex'=dword:00000003


'Index'=dword:00000004


'Prefix'='COM'


'Dll'='vybrid_serial.dll'


'Order'=dword:00000001


'TXPIN'=dword:00000017


'TXAF'=dword:00000006


'RXPIN'=dword:0000001f


'RXAF'=dword:00000006


./使能UART E方法,由于管脚和Colibir默认定义的SDHC接口冲突,因此需先关闭SDHC功能,请在注册表中修改下面内容并保存


[HKEY_LOCAL_MACHINEDriversBuiltInESDHC]


'Dll'='_esdhc.dll'


[HKEY_LOCAL_MACHINEDriversBuiltInUARTE]


'DeviceArrayIndex'=dword:00000004


'Index'=dword:00000005


'Prefix'='COM'


'Dll'='vybrid_serial.dll'


'Order'=dword:00000001


'TXPIN'=dword:00000033


'TXAF'=dword:00000004


'RXPIN'=dword:00000035


'RXAF'=dword:00000004


3).基于nVidia Tegra的Colibri T20/T30产品


系统默认定义COM 1 – UART A (UART 1,调试串口,全功能串口);COM 2 – UART B (UART 4,支持Flow control);COM 3 – IrDA (WinCE6)或UART C (WEC7)(UART2);另外还支持额外的两个串口UART 3和UART 5,默认没有使能。


./ WinCE6下COM 3设置为普通串口方法,注册表如下修改


-----------------------------


[HKLMDriversBuiltInSerial3]


' IrConnected'=dword:00000000


[HKLMCommIRSIR]


'ImagePath '='_irsir.dll '


./ UART3 Pin脚定义


SODIMM Pin 115 (GMI_A2) – UART3 TxD


SODIMM Pin 117(GMI_A3) – UART3 RxD


./使能UART 3方法,请在注册表中添加下面内容并保存


-----------------------------


[HKEY_LOCAL_MACHINEDriversBuiltInSerial4]


'DeviceArrayIndex'=dword:00000083


'Prefix'='COM'


'Dll'='libnvuart.dll'


'Order'=dword:00000004


'Index'=dword:00000004


'IClass'=hex(7):7b,00,41,00,33,00,32,00,39,00,34,00,32,00,42,00,37,00,2d,00,39,00,32,00,30,


00,43,00,2d,00,34,00,38,00,36,00,62,00,2d,00,42,00,30,00,45,00,36,00,2d,00,


39,00,32,00,41,00,37,00,30,00,32,00,41,00,39,00,39,00,42,00,33,00,35,00,7d,


00,00,00,00,00


[HKEY_LOCAL_MACHINEDriversBuiltInSerial4Unimodem]


'Tsp'='Unimodem.dll'


'DeviceType'=dword:00000000


'FriendlyName'='Serial on COM4:'


'DevConfig'=hex:10,00,00,00,05,00,00,00,10,01,00,00,00,4b,00,00,00,00,08,00,00,00,00,00,00


./UART5 Pin脚定义


SODIMM Pin 192 – UART5 TxD


SODIMM Pin 49 – UART5 RxD


./使能UART 5方法,由于管脚和Colibir默认定义的SDIO接口冲突,因此需先关闭SDIO功能,请在注册表中修改下面内容并保存


[HKEY_LOCAL_MACHINEDriversBuiltInSDIO]


'Dll'='_libnvsdio.dll'


[HKEY_LOCAL_MACHINEDriversBuiltInSerial5]


'DeviceArrayIndex'=dword:00000084


'Prefix'='COM'


'Dll'='libnvuart.dll'


'Order'=dword:00000004


'Index'=dword:00000005


'IClass'=hex(7):7b,00,41,00,33,00,32,00,39,00,34,00,32,00,42,00,37,00,2d,00,39,00,32,00,30,


00,43,00,2d,00,34,00,38,00,36,00,62,00,2d,00,42,00,30,00,45,00,36,00,2d,00,


39,00,32,00,41,00,37,00,30,00,32,00,41,00,39,00,39,00,42,00,33,00,35,00,7d,


00,00,00,00,00


[HKEY_LOCAL_MACHINEDriversBuiltInSerial5Unimodem]


'Tsp'='Unimodem.dll'


'DeviceType'=dword:00000000


'FriendlyName'='Serial on COM5:'


'DevConfig'=hex:10,00,00,00,05,00,00,00,10,01,00,00,00,4b,00,00,00,00,08,00,00,00,00,00,00


进入单片机查看更多内容>>
相关视频
  • RISC-V嵌入式系统开发

  • SOC系统级芯片设计实验

  • 云龙51单片机实训视频教程(王云,字幕版)

  • 2022 Digi-Key KOL 系列: 你见过1GHz主频的单片机吗?Teensy 4.1开发板介绍

  • TI 新一代 C2000™ 微控制器:全方位助力伺服及马达驱动应用

  • MSP430电容触摸技术 - 防水Demo演示

精选电路图
  • 家用电源无载自动断电装置的设计与制作

  • 用数字电路CD4069制作的万能遥控轻触开关

  • 使用ESP8266从NTP服务器获取时间并在OLED显示器上显示

  • 开关电源的基本组成及工作原理

  • 用NE555制作定时器

  • 带有短路保护系统的5V直流稳压电源电路图

    相关电子头条文章