PCF8591 hardware interface (circuit diagram and pin diagram)

Publisher:HarmoniousSoulLatest update time:2017-11-16 Source: eefocusKeywords:PCF8591 Reading articles on mobile phones Scan QR code
Read articles on your mobile phone anytime, anywhere

PCF8591 is a single-power, low-power 8-bit CMOS data acquisition device with 4 analog inputs, 1 analog output and a serial I2C bus interface for communicating with a microcontroller. Similar to the 24C02 mentioned earlier, the three address pins A0, A1, and A2 are used to program the hardware address, allowing up to 8 devices to be connected to the I2C bus without the need for additional chip select circuits. The device address, control, and data are all transmitted through the I2C bus. Let's first look at the schematic diagram of the PCF8591, as shown in Figure 17-3.

Figure 17-3 PCF8591 schematic diagram

Pins 1, 2, 3, and 4 are 4 analog inputs, pins 5, 6, and 7 are the hardware addresses of the I2C bus, pin 8 is the digital ground GND, and pins 9 and 10 are the SDA and SCL of the I2C bus. Pin 12 is the clock selection pin. If it is connected to a high level, it means that the external clock input is used, and if it is connected to a low level, the internal clock is used. Our circuit uses the internal clock, so pin 12 is directly connected to GND, and pin 11 is left floating. Pin 13 is the analog ground AGND. In actual development, if there is a more complex analog circuit, the AGND part must be specially handled in the layout and wiring, and there are many ways to connect it to GND. You can understand it here first. There is no complex analog circuit on our board, so we connect AGND and GND together. Pin 14 is the reference source, pin 15 is the analog output of the DAC, and pin 16 is the power supply VCC.

The ADC of PCF8591 is a successive approximation type, and its conversion rate is medium-speed, but its speed bottleneck is in I2C communication. Since I2C communication speed is slow, the final conversion speed of PCF8591 directly depends on the I2C communication rate. Due to the limitation of I2C speed, PCF8591 is a low-speed AD and DA integration, mainly used in some occasions where the conversion speed requirement is not high and the cost is expected to be low, such as battery-powered equipment, measuring the battery supply voltage, and when the voltage is lower than a certain value, an alarm prompts to replace the battery and similar occasions.

There are two ways to provide Vref reference voltage. One is to use the principle of simplicity and connect it directly to VCC. However, since VCC will be affected by the power consumption of the entire circuit, it is not an accurate 5 V, and the actual measurement is mostly around 4.8 V. Secondly, it will fluctuate with the change of the load of the entire system, so it can only be used in simple occasions where the accuracy requirement is not high. The second method is to use a special reference voltage device, such as TL431, which can provide a very accurate 2.5 V voltage reference. This is the method we usually use. As shown in Figure 17-4.

Figure 17-4 PCF8591 reference and external interface schematic

In the figure, J17 is a double-row pin. You can choose to short-circuit with a jumper cap or use a Dupont line to connect other external circuits according to your needs. Both are acceptable. At this point, we directly short-circuit pins 3 and 4 of J17 with a jumper cap, so now the reference source of Vref is 2.5 V. If 5 and 6, 7 and 8, 9 and 10, 11 and 12 are short-circuited with jumper caps, then our AIN0 actually measures the voltage divider value of the potentiometer, AIN1 and AIN2 measure the value of GND, and AIN3 measures the value of +5 V. It should be noted here that although AIN3 measures the value of +5 V, for AD, as long as the input signal exceeds the Vref reference source, it always gets the maximum value, that is, 255, which means that it cannot actually measure voltage signals that exceed its Vref. It should be noted that the voltage value of all input signals cannot exceed VCC, that is, +5 V, otherwise the ADC chip may be damaged.


Keywords:PCF8591 Reference address:PCF8591 hardware interface (circuit diagram and pin diagram)

Previous article:Temperature sensor DS18B20
Next article:PCF8591 Applications

Latest Microcontroller Articles
  • Download from the Internet--ARM Getting Started Notes
    A brief introduction: From today on, the ARM notebook of the rookie is open, and it can be regarded as a place to store these notes. Why publish it? Maybe you are interested in it. In fact, the reason for these notes is ...
  • Learn ARM development(22)
    Turning off and on interrupts Interrupts are an efficient dialogue mechanism, but sometimes you don't want to interrupt the program while it is running. For example, when you are printing something, the program suddenly interrupts and another ...
  • Learn ARM development(21)
    First, declare the task pointer, because it will be used later. Task pointer volatile TASK_TCB* volatile g_pCurrentTask = NULL;volatile TASK_TCB* vol ...
  • Learn ARM development(20)
    With the previous Tick interrupt, the basic task switching conditions are ready. However, this "easterly" is also difficult to understand. Only through continuous practice can we understand it. ...
  • Learn ARM development(19)
    After many days of hard work, I finally got the interrupt working. But in order to allow RTOS to use timer interrupts, what kind of interrupts can be implemented in S3C44B0? There are two methods in S3C44B0. ...
  • Learn ARM development(14)
  • Learn ARM development(15)
  • Learn ARM development(16)
  • Learn ARM development(17)
Change More Related Popular Components

EEWorld
subscription
account

EEWorld
service
account

Automotive
development
circle

About Us Customer Service Contact Information Datasheet Sitemap LatestNews


Room 1530, 15th Floor, Building B, No.18 Zhongguancun Street, Haidian District, Beijing, Postal Code: 100190 China Telephone: 008610 8235 0740

Copyright © 2005-2024 EEWORLD.com.cn, Inc. All rights reserved 京ICP证060456号 京ICP备10001474号-1 电信业务审批[2006]字第258号函 京公网安备 11010802033920号