EasyManuals Logo

Siemens CPU 948 User Manual

Siemens CPU 948
548 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Page #249 background imageLoading...
Page #249 background image
Programming example for "read system time"
FB 14 is programmed for the "read system time" function. The current values
should be stored in data block DB 11 (data word DW 0 to DW 3).
STEP 5 program:
FB14
NAME :CLKRD
:MBR EEC00 Load start address of the DB list
: in BR
:LRW +11 Load start address of DB 11 in memory
: (paragraph address) in ACCU 1
:L KB 0
:!=F Check that OB 11 is loaded
:JC =NIVO Jump to error handling
: if DB start address = 0
:TAK
:SLD 4 Absolute address of DB 11 (DW 0)
:MAB Load contents of ACCU 1 into BR register
:L KB 2 Load function no. ’2’ in ACCU-1-L
:JU OB 121 Read system time
:BEU
:
NIVO : Error handling
:
:BE
Data block DB 11 contains the following information after OB 121 is called
(example):
0: KH = 2994; 29 sec., 940 millisec.
1: KH = 9555; 24 hour format, 15 hours, 55 minutes
2: KH = 1010; 10 days, weekday ’1’(Tuesday), 0
3: KH = 9308; 93 years, 8 months
4:
It is Tuesday the 10th of August 1993, 15 hours, 57 minutes, 29 seconds and
940 milliseconds (9 tenths and 4 hundredths of a second).
OB 121: Set/Read System Time
CPU 948 Programming Guide
C79000-G8576-C848-04
6 - 11

Table of Contents

Questions and Answers:

Question and Answer IconNeed help?

Do you have a question about the Siemens CPU 948 and is the answer not in the manual?

Siemens CPU 948 Specifications

General IconGeneral
BrandSiemens
ModelCPU 948
CategoryController
LanguageEnglish

Related product manuals