Reading Values With Sign Bits, Dl440/450; Broken Transmitter Detection - Automation Direct DL405 User Manual

Analog
Hide thumbs Also See for DL405:
Table of Contents

Advertisement

3–26
F4–04AD 4-Channel Analog Input
Reading Values
With Sign Bits,
DL440/450
5
4
4
430
440
450
Broken
Transmitter
Detection
In 16 Input Mode, the most significant bit (bit 15) is the sign bit for the active channel
of the current scan. Because it is multiplexed (shared) among the four channels,
you may need to separate it into four individual sign bits. The following example
gives a method to do this, giving the resulting sign bits as internal contacts C0 to C3.
SP1
X34
X35
X37
X34
X35
X37
X34
X35
X37
X34
X35
X37
Note: This example uses SP1, which is always on.
You could also use an X, C, etc. permissive con-
tact.
When the 4–20 mA range is selected, the bit next to the most significant bit (bit 14) is
on when the current for the active channel is less than 1.25 mA. You can use the
method in the previous example to generate four independent broken transmitter
bits. Just replace X37 with X36 in the example.
Loads the first 12 bits of the data word into the accumulator.
LDF
X20
The X address depends on the I/O configuration.
K12
It's usually easier to perform math operations in BCD, so it is
BCD
best to convert the data to BCD immediately. You can omit
this instruction if your application does not require it (such as
PID loops).
OUT
Channel 1 data is being sent when X34 and X35 are off. The
V3000
out instruction moves the data from the accumulator to
V3000.
C0
RST
Turn off sign bit (C0) for channel 1. It will remain off for
positive numbers.
C0
When the module's sign bit (X37) is on the data is negative,
SET
C0 turns on.
Channel 2 data is being sent when X34 is on and X35 is off.
OUT
The out instruction moves the data from the accumulator to
V3001
V3001.
C1
RST
Turn off sign bit (C1) for channel 2. It will remain off for
positive numbers.
C1
When the module's sign bit (X37) is on the data is negative,
SET
C1 turns on.
Channel 3 data is being sent when X34 is off and X35 is on.
OUT
The out instruction moves the data from the accumulator to
V3002
V3002.
C2
RST
Turn off sign bit (C2) for channel 3. It will remain off for
positive numbers.
C2
When the module's sign bit (X37) is on the data is negative,
SET
C2 turns on.
Channel 4 data is being sent when X34 and X35 are on. The
OUT
out instruction moves the data from the accumulator to
V3003
V3003.
C3
RST
Turn off sign bit (C3) for channel 4. It will remain off for
positive numbers.
C3
When the module's sign bit (X37) is on the data is negative,
SET
C3 turns on.

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the DL405 and is the answer not in the manual?

Questions and answers

Subscribe to Our Youtube Channel

Table of Contents