Atlas 544099, 447299 manual Sum, Bit

Page 9

Atlas #544099 and #447399 DCC Decoders

9

Converting the Binary Values of Individual Bits within a Configuration Variable into an Equivalent Decimal Value for the Entire CV

Reasons for Setting and Clearing the Individual Bits of a Configuration Variable

In order to make a DCC decoder perform in the manner that you wish it to perform, one must sometimes set or clear individual bits of a CV. To program a DCC decoder using a DCC system that allows only the writing of decimal values into CVs (such as the Atlas Master Commander), it is first necessary to convert the values of all the individual bits of that CV that are to be set to the binary value 1 into their equivalent decimal values. It is then necessary to add together all of these equivalent decimal values.

Procedure for Converting Individual CV Bit Values into a Decimal Equivalent Value for the CV

The following table illustrates how to calculate the decimal value that must be written into a CV in order to set and/or clear a specified set of individual bits within that CV.

Each bit of a CV that is to be set to the binary

Bit

Decimal

Decimal

value “1” can be represented by the equivalent

Number

Equivalent

Values for

decimal number shown in the second column of

 

 

CV

this table. To determine the equivalent decimal

 

 

Calculation

value to be written into the CV, first write down

0

1

 

in column 3 of this table the decimal equivalent

 

 

 

1

2

 

values of all the bits of the CV that are to be set

 

to a binary 1. Write nothing in column 3 for

2

4

 

each bit of the CV that is to be cleared, i.e., set

3

8

 

to a binary 0. Then add up all the numbers that

 

 

 

4

16

 

you have written down in column 3. The sum

 

that you get is the equivalent decimal value that

5

32

 

you need to write into the CV.

6

64

 

 

7

128

 

 

 

SUM:

 

Atlas Model Railroad Co., Inc.

Image 9
Contents Atlas #544099 and #447399 DCC Decoders Preparing to Install an Atlas #544099 or #447299 DCC Decoder Step by Step Installation Programming Atlas #544099 and #447299 DCC Decoders Reg Description Range Default Value Short locomotive address Configuration Variables Decoder Configuration, Byte Reg Description Range Default Value Version Number Manufacturers Identification1 Extended Address High ByteHeadlight mode Description Range Default ValueUsage on conventional DC layouts Extended AddressingAmount of Headlight Dimming Bit SUMBit Decimal Example Calculating the Default Value for CV29Troubleshooting Decoder Programming Problems For Technical Assistance Dcc@atlasrr.com Atlas Limited One-Year DCC Decoder Warranty