Arduino and a PCF8591 AD/DA Converter example

The PCF8591 is a single-chip, single‑supply low‑power 8‑bit CMOS data acquisition device with four analog inputs, one analog output and a serial I²C‑bus interface. Three address pins A0, A1 and A2 are used for programming the hardware address, allowing the use of up to eight devices connected to the I²C‑bus without additional hardware. Address, control and data to and from the device are transferred serially via the two-line bidirectional I²C‑bus.

The functions of the device include analog input multiplexing, on-chip track and hold function, 8-bit analog‑to‑digital conversion and an 8‑bit digital‑to‑analog conversion. The maximum conversion rate is given by the maximum speed of the I²C-bus.


  • Single power supply
  • Operating supply voltage 2.5 V to 6.0 V
  • Low standby current
  • Serial input/output via I²C-bus
  • I²C address selection by 3 hardware address pins
  • Max sampling rate given by I²C-bus speed
  • 4 analog inputs configurable as single ended or differential inputs
  • Auto-incremented channel selection
  • Analog voltage range from VSS to VDD
  • On-chip track and hold circuit
  • 8-bit successive approximation A/D conversion
  • Multiplying DAC with one analog output.

This is the module that I used in this example, there are a couple of variants that work as well


I have not been able to find a schematic of the CJMCu-8591 module, the following is the connections that I made to make the code work. I simply connected the analog inputs to gnd and vcc, you could connect these to a pot for testing as well



[codesyntax lang=”cpp”]

#include "Wire.h"

#define PCF8591 (0x90 >> 1)
byte adcvalue0, adcvalue1, adcvalue2, adcvalue3;
void setup()
void loop()
 Wire.requestFrom(PCF8591, 5);;;;;;
 Serial.print(" ,");
 Serial.print(" ,");
 Serial.print(" ,");



Open the serial monitor and should you see something like this which is what you would expect since the Analog inputs are connected to 5v and Gnd in this example

255 ,0 ,255 ,0
255 ,0 ,255 ,0
255 ,0 ,255 ,0
255 ,0 ,255 ,0
255 ,0 ,255 ,0
255 ,0 ,255 ,0
255 ,0 ,255 ,0



PCF8591 AD/DA Converter Module Analog To Digital Conversion+Cable

This div height required for enabling the sticky sidebar
Ad Clicks : Ad Views : Ad Clicks : Ad Views : Ad Clicks : Ad Views :