delay(50);
}
In the code above, we defined the Vref as 3.0V which is decided by the I2C ADC module. This reference
voltage is more accurate than one generated by microcontroller. And you can make that more accurate by
measuring the voltage between VA and GND and use that value to replace 3.00 in the code above.
Now you can upload the code. Please click
here
if you do not know how to upload.
Afterwards, open the serial monitor and read the values:
Note: The address of Grove - I2C ADC is changeable which means you can redefine its address. That requires
some hardware modification on the board. If you are thinking about using more than one I2C ADC at the
same time, follow the instruction in the Reference part below to do so. The maximum of I2C ADC used
simultaneously is 9, but there are only 4 I2C sockets on
Grove - Base Shield
V1.3, so if you want to use more
than 4 I2C ADC, take a
Grove - I2C Hub
to create more I2C sockets.
8
Need help?
Do you have a question about the Grove-I2C ADC and is the answer not in the manual?