Series 3700A Switch and Control Cards Reference Manual
Section 13: Model 3750 multifunction control card
3700AS-909-01 Rev. A / Preliminary
13-7
To write to the banks
Because the default state of a digital I/O bank is configured as an input, the mode needs to be
changed so that it is ready to accept
write
commands by using the channel.setmode() command:
channel.setmode("1005", channel.MODE_OUTPUT)
To write a single bank of 8 bits associated with channel 5, send the channel.write() command:
channel.write("1005", 9)
Writing the value of 9 causes bits 1 and 4 to go high, while the rest remain low.
To write multiple banks at the same time, use the optional
width
parameter to indicate how many
banks to affect. For example, the following command outputs 1 (hexadecimal 01) to bank 1, 2
(hexadecimal 02) to bank 2, 3 (hexadecimal 03) to bank 3, and 4 (hexadecimal 04) to bank 4.
channel.write("1001", 67305985, 4)
To read and write banks using a scan
Any input bank or totalizer channel that is included in a scan list is read when that channel is
scanned. The value is saved to the buffer specified for the scan. For digital inputs, the width defaults
to 1. For totalizers, the full count is read. For example, to read totalizer 1 on card 2 after scanning all
channels of a slot 1 multiplexer, use the scan.create() command:
scan.create("1001:1060, 2006")
To read more than one bank at a time, the
width
needs to be specified with the scan.add()
command. For example, to read 32 bits of digital input on slot 2 after scanning 60 channels on slot 1:
scan.create("1001:1060")
scan.add("2001", 4)
To write to either a digital output or an analog channel, use the scan.addwrite() command, which
includes a parameter for the data value to be written and an optional width parameter. For example,
to program DAC channel 1 on the slot 2 card to go to +5 V after scanning 60 channels on slot 1:
scan.create("1001:1060")
scan.addwrite("2010", "5")
Power consumption information
You can power off the totalizers if they are not being used, which reduces the power required of the
card. The card has a default static power draw of 3300 mW, which includes powering the totalizer
channels and both analog output channels. If the totalizer channels are powered off, they reduce the
3300 mW draw by 730 mW. This power can then be used for closing relays on other cards within the
bank. See Series 3700A Module Schematics and Connections for more information on power
handling information and examples.
NOTE
The four totalizers are either all powered on or all powered off. Changing the power state of one
affects them all. The command for controlling power is
channel.setpowerstate(channelList,
state)
, where
state
is either "
channel.ON"
or
"channel.OFF"
. See channel.setpowerstate()
for more information.