MAX3111ECNI Maxim Integrated Products, MAX3111ECNI Datasheet - Page 29

no-image

MAX3111ECNI

Manufacturer Part Number
MAX3111ECNI
Description
IC TXRX RS232 SPI INT-CAP 28-DIP
Manufacturer
Maxim Integrated Products
Datasheet

Specifications of MAX3111ECNI

Features
Transceiver
Number Of Channels
1, UART
Protocol
RS232, RS485
Voltage - Supply
3 V ~ 3.6 V
With Irda Encoder/decoder
Yes
With False Start Bit Detection
Yes
With Cmos
Yes
Mounting Type
Through Hole
Package / Case
28-DIP (0.300", 7.62mm)
Lead Free Status / RoHS Status
Contains lead / RoHS non-compliant
Listing 1. Outline for a MAX3110E/MAX3111E Software Driver (continued)
Protected RS-232 Transceivers with Internal Capacitors
SPI/MICROWIRE-Compatible UART and ±15kV ESD-
/* This driver needs a txqueue transmit-data queue and a rxqueue receive-data queue.
** These can be ring buffers or any other kind of first-in, first-out data queue.
*/
EnQueue ( queue , char )
char DeQueue ( queue )
true/false IsQueueEmpty ( queue )
/*
low level.
** This is a PRIVATE routine to be used only within the driver software.
*/
ServiceMAX3110E/MAX3111Eint ( )
{
} /* end of ServiceMAX3110E/MAX3111Eint */
Interrupt service routine called when the MAX3110EMAX3111E's INT pin falls to a
int rxdata;
int txdata;
char c;
/* issue a READ DATA command to discover the cause of the interrupt */
rxdata = MAX3110E/MAX3111E ( 0 );
if ( rxdata & 0x8000 )
{
}
if ( rxdata & 0x4000 )
{
}
______________________________________________________________________________________
c = rxdata & 0x00FF; /* get the received character data */
EnQueue ( rxqueue, c );
if ( IsQueueEmpty ( txqueue ) )
{
}
else /* transmit some data */
{
}
/* mask the transmit-buffer-empty interrupt */
config = config & ~ 0x0800; /* clear the TM bit */
config = config | 0xC000; /* set bits 15 and 14 */
MAX3110E/MAX3111E ( config );
/* issue a WRITE DATA command */
txdata = DeQueue ( txqueue );
c = txdata & 0x00FF; /* get the transmit character */
MAX3110E/MAX3111E ( 0x8000 | c );
/* the R bit = 1 */
/* the T bit = 1 */
29

Related parts for MAX3111ECNI