Manual
Table Of Contents
- AN118: Interfacing the CS5521/22/23/24/28 to the 80C51
- TABLE OF CONTENTS
- 1. INTRODUCTION
- 2. ADC DIGITAL INTERFACE
- 3. SOFTWARE DESCRIPTION
- 4. MAXIMUM SCLK RATE
- 5. DEVELOPMENT TOOL DESCRIPTION
- 6. CONCLUSION
- 7. APPENDIX: 80C51 MICROCONTROLLER CODE

AN118
AN118REV2 29
;****************************************************************
;* Routine - RXSER
;* Input - none
;* Output - Byte received is placed in R7
;* Description - This subroutine receives 1 byte from converter
;* via UART. It uses the RS-232 serial protocol to transmit
;* one byte from a PC/UART system to the 8051.
;****************************************************************
; The function prototype is: char RXSER(void);
$DEBUG
USING 0 ; Use register bank 0
TCOD SEGMENT CODE ; Define ROUT as a segment of code
PUBLIC RXSER ; Make subroutine global
RSEG TCOD ; Make code relocatable
RXSER:
JNB SCON.0,$ ; Poll RI
MOV R7,SBUF ; Place received byte in R7
CLR SCON.0 ; Reset RI bit
RET
END