Appendix C: Reading and Writing to Bit-Mapped S Registers
Registers S13, S14, S*2, S*5, S*6, and S*7 are “bit-mapped registers”, that is, each stores informa-
tion about up to eight binary (.e., on\off) conditions. Each condition is mapped to a bit position with the
following binary value:
BIT 0 = 1 (binary 00000001)
BIT 1 = 2 (binary 00000010)
BIT 2 = 4 (binary 00000100)
BIT 3 = 8 (binary 00001000)
BIT 4 = 16 (binary 00010000)
BIT 5 = 32 (binary 00100000)
BIT 6 = 64 (binary 01000000)
BIT 7 = 128 (binary 10000000)
Reading S Registers
When you request the current setting of one of these registers with the command ?, the T-311 re-
sponds with a number between 0 and 255. This represents the sum of the binary values of all bits set
to 1 in that register, expressed as a decimal number.
For example, Register S13 maps the data word format using bits 2 - 5. If you requested the current
setting of S13 with the command ATS13?, and if the default data word format were in effect (i.e., par-
ity off, 7 data bits), the T-311 would respond with 8 (indicating that bit 3 is set to 1 and all other bits
are 0 or ignored).
If parity were set to on (Bit 2 = 1 =(4)), even parity (Bit 3 = 1 = (8)), the T-311 would respond with 12,
the sum of bits 2 and 3 (.e., 4 + 8).
The simplest way to decode these S register values is by a continuous subtraction process. That is:
•
If the T-311 response to a query is a number between 128 and 255, then bit 7 = 1. Subtract 128
(the binary value of Bit 7) from the number. If the response is 200, for example, 200-128 = 72.
•
If the remainder is a number between 64 and 127, then bit 6 = 1. Subtract 64 from the remainder.
Using the same example, subtract 72-64=8. The remainder of 8 indicates that Bit 3 is set to 1. Bits
0, 1, 2, 4, and 5 are 0.
Writing to S13 and S14 Registers
To change the contents of register S13, add the decimal value of the bit position to change a bit to 1
or subtract the decimal value of the bit position to change a bit to 0.
For example, to turn parity on (change bit 2 to 1), add 4 + 8 = 12 and enter the command:
ATS13=12<CR>
Register S14 can be remapped in the manner, or changed using the AT commands indicated on page
35.
Reference Manual
Appendix C: Reading and Writing to Bit-Mapped S Registers
40-400-00045, Rev.
B
Page 51
Содержание T-311
Страница 1: ...Telephone Access Unit T 311 Product Manual 40 400 00045 Rev B ...
Страница 8: ...This page intentionally left blank T 311 Page vi ...
Страница 10: ...T 311 Page 2 Figure 1 T 311 Telephone Access Unit ...
Страница 17: ...Reference Manual Chapter 4 Dialing Instructions 40 400 00045 Rev B Page 9 Figure 3 System Connections ...
Страница 20: ...T 311 Page 12 Figure 5 Universal Mounting Bracket Optional Figure 6 Universal Mounting Shelf Optional ...
Страница 58: ...T 311 Page 50 Figure 7 T 311 Block Diagram ...