Jump to content
 

Technical question about the two-byte address range


F2Andy
 Share

Recommended Posts

The documentation I have found says that with two-byte addresses, the range of addresses available is 1 to 10,239 (though some implementations might reduce that). The first two bits of the address byte have to be 1 to indicate this is a two-0byte address, which leaves 14 bits for the address itself, that gives you 16,383 addresses. However, The first eight bits cannot be all 1, as that is the null address, so that reduces the range by 256. That leaves 5,888 addresses unaccounted for.

 

Can anyone explain this? Have I misunderstood something?

 

I do appreciate this is just part of the magic that happens behind the scenes, and there is no reason I need to know this; I am just interested.

Link to post
Share on other sites

  • RMweb Gold

If the least signifcant byte cannot be 255 it can presumably still be 254 so that only 'costs' one address.  10,239 is an 11 bit address prefixed by 100.

 

10011111111

 

So :

1100000000001

to 

1110011111111

 

Still not using the full range though.

Edited by AndrueC
Link to post
Share on other sites

The answer is in the Extended Packet Format Spec S-9.2.1 where it explains the addressing. Any address above 10000000 is followed by another byte to form a two-byte address, hence:

 

Addresses 11000000-11100111 (192-231)(inclusive): Multi Function Decoders with 14 bit addresses

 

So 14-bit (or extended or 4 byte or whatever you want to call them) addresses range from (stripping the top two bits, adding the second byte and switching to hex) 0x2000 - 0x27FF,  or 0 - 10,239. Some systems impose a limit of 0 - 9999 (hence refereed to as 4-digit).

 

Link to post
Share on other sites

Thanks for the responses. Building on comments here, I found this web page, which seems to be a more up-to-date version of S-9.2.1 than in on the NMRA site.

https://sites.google.com/site/markgurries/dcc-welcome-page/advanced-topics/decoder-addressing/decoding-dcc-addresses

 

The answer appears to be:

 

Quote

 

5) Addresses 11101000-11111110 (232-254)(inclusive):

Reserved for Future Use

 

 

Link to post
Share on other sites

For DCC standards, its probably better now to be reading the "RailCommunity" documentation, rather than NMRA.  RailCommunity operates in German.   It seems that RailCommunity set things, then, after a while, NMRA adopts a translation.    The MERG site has translations of some of the RailCommunity documentation. 

 

- Nigel

  • Like 1
Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...