I2C to RS485 converter - Page 1
Forum section: electronics / beginners

author: Vindhyachal.takniki
author_rank: Frequent Contributor
timestamp: April 11, 2017, 05:40:20 am
content: 1. I need a I2C to RS485 converter. Preferred is hardware based solution so that no MCU programming is required & low power since system is battery powered.2. I2c specs are attached to be matched. If 400khz is fast, then I can limit 100Khz.3. I was loking for MAX1307 and SC16IS750IBS.looks like they can fit the solution.4. Any other suggestions or better solution? Provided low power & dont want to add code/MCU support in it, looking for hardware based solution.5. Only single I2C device will be connected. No more than that. i2C pins are pulled by 10K to 3.3Vdc

author: Vindhyachal.takniki
author_rank: Frequent Contributor
timestamp: April 11, 2017, 05:42:15 am
content: specs

author: tszaboo
author_rank: Super Contributor
timestamp: April 11, 2017, 09:55:59 am
content: MAX13071075ksps, 12-Bit, Parallel-Output ADCs with ±10V, ±5V and 0–5V Analog Input Ranges

author: Vindhyachal.takniki
author_rank: Frequent Contributor
timestamp: April 11, 2017, 12:57:43 pm
content: Ohhh.It was Max3107.One one side I have Texas Instrument's bq34z100-g1.Need to increase the communication wire length & read it on MCU on host side using RS485. SO I was thinking of using some bridge converter.

author: Vindhyachal.takniki
author_rank: Frequent Contributor
timestamp: April 12, 2017, 03:22:26 am
content: Hi,A)Circuit:1. I am using TI's bq34z100-g1 in device. It has I2c communication. Usually we connect an external MCU(I2c master), to read the bq34z100-g1 registers. Standard it has three pins SCL, SDA & GND(GND & BAT- same thing).2. But in battery applications, we have another negative terminal called pack-. Bat- & Pack- are separated by inline sense resistor, charge & discharge mosfets, to protect the battery in case of any battery related error.3. In outer battery pack case, we have four terminals: Pack+ , Pack- , SCl & SDA. Pack+ is battery positive voltage.4. In normal operation, both fets are on, so bat- & pack- forms a path via a sense resistor. But in case of error, one of two or both fets are off, in that case connection between bat- & pack- breaks. & so does communication.B)Goal:1. To convert communication from I2c to such an interface, where this ground issue does not come in between. Communication happens without gnd line requirement.2. Since circuit is to be used in electronisc vehicle, so I want communication with higher level of noise immunity.3. Additional optional is, conversion from i2c to required interface, should be such no programming in interface conversion is required. Should be hardware asic based.4. If third is not possible, then I can do MCU programming is required. But it will involve code time & other times like testing. So not an preferred option.5. Since entire is battery powered, so lowest power consumption possible is preferrable.C)What interface I selected:1. Based on these I have selected RS485 communication.2. I am open to suggestion or any other better interface solution.D)What RS485 solution I have come up with:1. Since I2C is bidirectional interface, so I have to select full duplex RS485.2. I am thinking of using NXP's SC18IM700 & TI's SN65HVD70.3. SN65HVD70 is Full-Duplex RS-485.4. SC18IM700 is Master I2C-bus controller with UART interface.5. SO bq34z100-g1 will be connected through SC18IM700. Then SC18IM700 will be connected to SN65HVD70 for full-duplex RS485.6. On host side, I will have another SN65HVD70 & a uart based MCU for reading through registers of bq34z100-g1.E) How does it solves the purpose:1. No gnd related issue now. Even if bat- & pack- gets disconnected, I don't have problem of communication.2. Since communication is RS485, so noise immunity will be there.3. Power consumption of SC18IM700 is high is in 5mA in idle mode. It has sleep option, But cannot use it, since to wake up it needs its pin to be pulled down, which is not possible, as in outer case I have only four connections.F)Suggestions/Reviews:1. What are suggestions or reviews on this?2. Any other solution for this?3. Any way I can reduce power consumption?

author: Tantalum
author_rank: Regular Contributor
timestamp: April 12, 2017, 09:03:39 am
content: You can also use I2C with differential signals (like RS485) at high speed, so no need for conversion (except if you really need UART on the device side of course).->PCA9615

author: Vindhyachal.takniki
author_rank: Frequent Contributor
timestamp: April 12, 2017, 11:47:49 am
content: Hi,1. Attached is the circuit diagram which I am talking about.It has a complete battery unit, from where 4 outputs are coming.Pack+ & pack- are for power. SCL/SDA are for data read.2. Bq34z100-g1 is powered from battery inside & there is another circuit inside this entire pack, which controls charge & discharge fets.3. Bq34z100-g1 Vss connection is with Bat-, while battery pack return is through pack-.3. Now problem which I am thinking will come is, as long as there is no error, both fets are on, communication will be ok, as there will be only sense resistor between BAt- & Pack-.But when one or both fets are off, there will be a communication break.4. I cannot bring out bat- terminal from the pack. Thats why I am thinking of some way that I can read through it even if any/both mosfets off.Also want communication to be immune to noise.5. Two ways communication can happen, external host is powered from pack+ only or have seprate supply.6. What could be solution in this.I am also looking reading datasheet of NXP's PCA9615 at the moment if it fits the application.7. External four wire connector, I can choose, how many connections there. Can increase from 4. No issues there. Task is to solve these:a) communication dont break even if fets gets offb) noise immune for vehicle applicationc) low power

author: ebclr
author_rank: Super Contributor
timestamp: April 13, 2017, 04:45:48 am
content: A transceiver will not solve your problemI2C is a synchronous protocol. where SCL sends the clock and SDA the dataRS485 is based on standard serial asynchronous communications, with a special differential driver.You have several possibilities none with only transceivers1) Use RS422 instead and send SDA in one pair and SCL in another pair ( 4 wires )2) Convert the synchronous I2C to asynchrony serial protocol using a processor, who will also control addressing and flow directionhttp://www.ti.com/lit/an/slva704/slva704.pdf