beautypg.com

FUJITSU F2MC-8L F202RA User Manual

Page 354

background image

338

CHAPTER 14 8-BIT SERIAL I/O

MOV

SMR,#01001100B ; Clears the interrupt request flag, allows the interrupt

request output, sets shift clock input (SCK), prohibits

serial data output (SO), selects the external shift clock,

and sets LSB first.

MOV

SSEL,#00000001B ; Selects the 8-bit serial I/O.

SETB

SST

; Allows serial I/O transfer.

SETI

; Enables interrupts.

:

;--------------------Interrupt processing routine-----------------------------------------------------------

WARI

CLRB

SIOF

; Clears the interrupt request flag.

PUSHW

A

XCHW

A,T

PUSHW

A

MOV

A,SDR

; Reads transfer data.

SETB

SST

; Allows serial I/O transfer.

:

User processing

:

POPW

A

XCHW

A,T

POPW

A

RETI

ENDS

; --------------------------------------------------------------------------------------------------------------------

END

This manual is related to the following products: