# How do I2C modules select between more than 2 slave addresses?

I am using the TMP112 I2C temperature sensor and noticed that you can choose between 4 slave addresses by connecting the A0 pin to V+, GND, SCL, or SDA.

How does the sensor tell between SCL, SDA, and V+?

It makes sense that V+ and GND can set the LSB of the slave address, but I am curious as to how the other two connections work.

Here's the link to the datasheet: http://www.ti.com/lit/ds/symlink/tmp112.pdf

I am using this sensor in an undergraduate senior project and am just curious about how this works. The answer won't affect my use of the sensor; I am just curious.

Thanks

Side note: this is my first question on StackExchange so any feedback on improving my questions is appreciated.

• I can see only two possible addresses in the datasheet. Selectable by connecting to either Vcc or GND. Where have you seen four? Jun 1 '16 at 21:52
• @EugeneSh. - FYI, see section 7.3.2.2 on page 12 of the datasheet. It claims that the A0 pin can be connected to the 4 choices given by the OP, to select different I2C addresses. That's different to section 5 on page 3, were it only lists the 2 options which you mention. [Section 8.2.1 on page 25 also lists the 4 address options.] Jun 1 '16 at 21:57
• Hm. Interesting. Doesn't make sense, though... Jun 1 '16 at 22:01
• Well, I guess it could configure itself on startup by sending some special sequence on these pins. Or doing it on runtime by comparing A0 with SCL and SDA Jun 1 '16 at 22:07