Using a transistor for opening and closing connection to ground - Page 1
Forum section: electronics / projects

author: sean87
author_rank: Regular Contributor
timestamp: August 06, 2016, 05:36:29 pm
content: I have to design a PCB with 24MAX9611ICs. Since this IC has a fixed I2C address (2 address pins, A0 and A1 with any combination of GND, VCC, VCC/2 and VCC/3) it is only possible to assign 16 unique addresses.In my case, I need to have 2 groups of 12 chips, named CH1 and CH2. and since the microcontroller of choice only has 1 I2C interface, I need to somehow multiplex through them.The easiest solution I can think of is just switch the power between CH1 and CH2 and read their registers alternatively (as the design does not require that all chips to be queried at same time).I want to have the decoupling capacitors to be connected to VCC plane (so they are always charged) and using I/O pins of the uC, turn each channel on/off by switching a transistor so that their ground pins to be connected to the ground plane of the PCB.So here are my questions:1- I have the schematic for the case where the VCC can be switched into the VCC pins of the chips, but I am looking for a way to use the transistor to switch the ground connection instead.2- What kind/type of transistor should I use? I believe the combined current draw for 12 of these chips is about 1A (this is just a rough guess, I could not find the current draw while ON in the datasheet!)

author: Ian.M
author_rank: Super Contributor
timestamp: August 06, 2016, 06:16:15 pm
content: That doesn't seem like a smart idea if the MAX9611 RS pins are above Vcc and even if they aren't it may dump current onto the I2C bus.Why not use an I2C multiplexer, e.gPCA9540Bto split the bus into two sections so you can reuse addresses?

author: Monkeh
author_rank: Super Contributor
timestamp: August 06, 2016, 06:16:57 pm
content: There are chips for this which are a somewhat neater solution, which doesn't involve messing with the ground of analog devices:http://www.nxp.com/products/interface-and-connectivity/interface-and-system-management/i2c-bus-portfolio/i2c-multiplexers-switches/2-channel-ic-bus-multiplexer:PCA9540BQuote from: sean87 on August 06, 2016, 05:36:29 pm<50mA for all 12.

author: wraper
author_rank: Unknown
timestamp: August 06, 2016, 06:31:40 pm
content: Won't work. Don't forget about ESD protection diodes on IC pins. If you disconnect any of the power pins, power will be supplied through the protection diodes or zeners from the other pins (I2C in this case). So what will happen, unpowered IC's will load I2C bus and nothing will work at all. Also you will exceed absolute maximum ratings, which are tied with those likely ESD zeners. On the other hand positive rail disconnection probably will work in this case, because in this patricular IC it seems that zeners to GND pin are used, not two diodes clamping to each power rail. So power from the pins can be sinked only to GND, but not to Vcc.

author: wraper
author_rank: Unknown
timestamp: August 06, 2016, 06:38:11 pm
content: IMO just use analog switch/multiplexer IC(s) on SDA if don't want to use specialized ICs.

author: wraper
author_rank: Unknown
timestamp: August 06, 2016, 06:44:16 pm
content: Quote from: sean87 on August 06, 2016, 05:36:29 pm20 mA typ, 31 mA max. for all 12.

author: Kilrah
author_rank: Unknown
timestamp: August 06, 2016, 06:49:13 pm
content: The datasheet doesn't state whether the address pins are read and latched at powerup or if they're continually active... if the latter, you could probably wire some of the address pins to microcontroller pins to help with selecting/deselecting a group.

author: Kleinstein
author_rank: Super Contributor
timestamp: August 06, 2016, 07:12:34 pm
content: A MUX or special I2C buffer is likely the better idea. There is also the option to implement a second I2C bus in software - it depends on the µC and resources available. An I2C master in software is not that complicated.

author: bson
author_rank: Unknown
timestamp: August 06, 2016, 09:59:43 pm
content: You should be able to multiplex the two buses using four MOSFETs like 2N7002. Or see if you can find a suitable dual/quad package that reduces the parts count and board space. If you find a suitable dual complementary pair you can control them with a single GPIO instead of two.

author: sean87
author_rank: Regular Contributor
timestamp: August 06, 2016, 11:10:34 pm
content: Thanks guys you are all great! (Specially the facepalm forissing Icc in the datasheet)