• Ready for review
  • UART Serial Port & IrDA

    This describes the serial-driver for the XScale-processor UARTs (universal asynchronous receiver/transmitter) of the Trizeps-module.

    Registry Keys

    The Serial-key is used for the FFUART, Serial2 for the BTUART and Serial3/Irda for the STUART of the XScale-processor. The STUART can be configured to interface with an infrared transceiver.

    [HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Serial]

    [HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Serial]

    [HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Serial2]

    [HKEY_LOCAL_MACHINE\Drivers\BuiltIn\Serial3]

    Key

    Type

    Description

    UseFlowCtrl

    DWORD

    How and if the control-lines of the UART are used. See UseFlowCtrl

    RxFifoHighWater

    DWORD

    This value is copied to FCR-register, and sets the FIFO-thresholds.

    ModRWPrios

    DWORD

    Read-thread priority. Value between 0 and 255.

    Priority256

    DWORD

    Thread priorities of the driver. (0..255).

    DeviceArrayIndex

    DWORD

    Specifies which UART interface. 0: FFUART, 2: BTUART, 3:STUART, 4:IrDA.

    Index

    DWORD

    Specifies which index is to be used for this COM-driver (COM1:,COM2:,..)

    [HKEY_LOCAL_MACHINE\Drivers\BuiltIn\IrDA]

    [HKEY_LOCAL_MACHINE\Drivers\BuiltIn\IrDA]

    DeviceArrayIndex

    DWORD

    Specifies which UART interface. 0: FFUART, 2: BTUART, 3:STUART, 4:IrDA.

    Index

    DWORD

    Specifies which index is to be used for this COM-driver (COM1:,COM2:,..)

    IrDAMode

    DWORD

    IrDA-Mode. See IrDA-Mode

    UseFlowCtrl

    How and if the control-lines of the UART are used. If a signal is not used by the serial-driver, it may be used as GPIO or other function by your application or driver.
    The first serial port (COM1,FFUART) has all flow-control-lines.
    The second port ( COM2, BTUART) only has CTS and RTS.
    The third serial port (COM3 or IrDA, STUART) has no flow-control-lines.

    Flags that can be set:

    • USE_DTR ( 0x0001)

    • USE_RTS ( 0x0002)

    • USE_CTS ( 0x0004)

    • USE_DCD ( 0x0008)

    • USE_DSR ( 0x0010)

    • USE_RI ( 0x0020)

    • RTS_INV ( 0x0040); invert RTS logic value.

    • DTR_INV ( 0x0080); invert DTR logic value.

    • USE_RTS_RS485 ( 0x0100); use RTS as signal to control an external RS485 transceiver.

    • USE_CTS_RS485_EN ( 0x400); Use CTS signal to enable RS485 transceiver.

    • BUGFIX_DONT_ABORT ( 0x1000); may be needed as workaround for C#.

    IrDA-Mode

    Sets IrDA-specific configuration:

    • Switch to GPIO on TX-Idle. (BugFix) ( 0x20)

    • RX-polarity: 0=positive-pulses are zeros, 1=negative-pulses are zeros.

    • TX-polarity: 0=positive-pulses are zeros, 1=negative-pulses are zeros.

    • XMode: 0=transmit-pulse-width is 3/16 of a bit-time wide, 1=transmit-pulse-width is 1.6us.

    See Also

    Connect a UART/RS232/IrDA to a Trizeps