BV4205-ADC

BV4205 IC

The BV4205 is an IC that has 10 channels x 10 bit ADC and is controlled using the I2C interface. The full datasheet is here.

Here is some code submitted by Ian that will control the BV4205 using an Arduino:

  Wire.beginTransmission(0x31);  // join I2C, talk to BV4206 by Addr 31 (7bit) = 62 BV addr (default).
  Wire.send(0x01);   //select channel command
  Wire.send(0x00);   //ch.0
  Wire.endTransmission();

  Wire.beginTransmission(0x31);
  Wire.send(0x02);   //do conversion
  Wire.endTransmission();

  Wire.beginTransmission(0x31);
  Wire.send(0x04);   //result of conversion
  Wire.endTransmission();

  Wire.beginTransmission(0x31);
  Wire.requestFrom(0x31, 2); //get 2-byte
  while(Wire.available() < 1);
  for (int i=0;i<2;i++){
     data[i]=Wire.receive();
  }
  Wire.endTransmission();       // leave I2C bus

  // combine 2 bytes into 1 unsigned int, value 0-1023
  AI_RawBV4205_0 = ((unsigned int)data[0] << 8) | data[1];