PMC-Sierra, Inc.
PM4541T1XC-EVBD
TELECOM STANDARD PRODUCT
PMC-920314
ISSUE 2
T1XC EVALUATION DAUGHTERBOARD
UNTIL
SCDR C@ DROP ; ( remove key pressed )
( from uP input reg
)
( Define word to write XPLS D/A code value )
: XWR
XPLS 2+ C!
( DATA ADDR --- )
( SELECT CODE REG )
XPLS 3 + C! ; ( WRITE CODE VALUE)
( Define word to READ XPLS D/A code value )
: XRD
( ADDR --- )
( SELECT CODE REG )
( READ CODE VALUE)
XPLS 2+ C!
XPLS 3 + C@
U. ." " ;
( Write complete template values to XPLS
)
( Usage: Value1 Value2 ... Value8 WRTEMPL )
: WRTEMPL ( C1 C2 C3 C4 C5 C6 C7 C8 --- )
8 0 DO 7 I - XWR LOOP ;
( Read all template values from XPLS
( Usage: RDTEMPL
( uP response: Value1 Value2 ... Value8
( [in HEX]
)
)
)
)
: RDTEMPL ( --- )
8 0 DO I XRD LOOP ;
To use these functions, use the following syntax (the interpreter response is shown
in italics):
FRMR STATUS RD = FF HEX
( Read T1XC #1 FRMR reg #2 contents
)
OK
XBAS 10 WR OK
0 )
( Write 10 hex to T1XC #1 XBAS reg
This document is not intended to give a full tutorial in FORTH, which is better
covered in the many FORTH books available. The FORTH kernel on the 68HC11
on the EVMB is based upon the FORTH-83 standard and should be upward
compatible from FORTH-79. For a complete, detailed FORTH tutorial, refer to the
manuals listed in the references.
30