User program examples
PCD7.D250
Page 8-26
SAIA-Burgess Electronics Ltd.
(D25-08-E.DOC)
26/770 E1
Entering numerical parameters
;+----------------------------------------------------------------------+
;¦
¦
;¦
User program example 8.5 for the industrial terminal PCD7.D250
¦
;¦
==============================================================
¦
;¦
Input of numerical parameters
¦
;¦
¦
;¦
File:
DEMO.SRC
¦
;¦
Version:
1.0
¦
;¦
¦
;¦
Creation:
21.01.93
U.Jäggi
¦
;¦
Modified:
08.02.00
C. Bruegger
¦
;¦
¦
;+----------------------------------------------------------------------+
RBSY_F
EQU
O 32
; Receiver Busy
PUBL
RBSY_F
XBSY_F
EQU
O 38
; Text Busy
PUBL
XBSY_F
SIGN
EQU
O 48
; Sign input
IN_BUSY
EQU
O 49
; Input busy
PUBL
IN_BUSY
DIGIT
EQU
R 0
; Number of digits
X_POS
EQU
R 1
; X-position
Y_POS
EQU
R 2
; Y-position
DECIMAL
EQU
R 3
; Number of decimal places
DOC
R 500
DIAG_R
EQU
R 999
; Diagnostic register
DOC
R 1000
DOC
C 100
MAIN
EQU
TEXT 0
; Main menue
IN_TXT_R
EQU
TEXT 1
; Input text register
IN_TXT_C
EQU
TEXT 2
; Input text counter
DISP
EQU
TEXT 10
ASSIGN
EQU
TEXT 999
; Assignation of the serial interfac
CHAN_N
EQU
1
; Number of serial channel
PUBL
CHAN_N
DOC
COB 0
DOC
XOB 16
INPUT
EQU
FB 0
; Functionblock input
PUBL
INPUT
TEXT
ASSIGN
"UART:9600,8,E,1;"
"MODE:MC0;"
"DIAG:",RBSY_F.T,",",DIAG_R.T,""
TEXT
DISP
"<27><64><77><49>"
; Display mode:4 x 20
TEXT
MAIN
"<12>"
; Clear display
"<27><84>"
; Cursor off
"==PARAMETER
INPUT=="
"--------------------"
"MODIFY REGISTER [F1]"
"MODIFY COUNTER
[F2]"
TEXT
IN_TXT_R
"<12>"
"R-Value : $%00.3d$R0500<10><13>"
"ACCEPT VALUE
[CR]"
"MODIFY VALUE
[F1]"
"MAIN MENU
[F2]"
TEXT
IN_TXT_C
"<12>"
"C-Value : $C0100<10><13>"
"ACCEPT VALUE
[CR]"
"MODIFY VALUE
[F1]"
"MAIN MENU
[F2]"