Email: Password: Remember Me | Create Account (Free)

Back to Subject List

Old thread has been locked -- no new posts accepted in this thread
???
06/02/09 10:06
Read: times


 
#165747 - PCF8591 - Self Test
Hello all,

I am wrote a program which
* writes a byte to input of PCF8591. The analog output is connected to the AIN2 (channel 2) of the same.
* Then the digital output after A to D conversion is read back through I2C bus.
* The values Written to and Read from the DAC/ADC are displayed on LCD for verification.

The aim of the program is to perform a test of the IC connected to P89V664 and display the test result("test fail" or "test pass") on the lcd, to ensure proper (hardware ) setup.


When a '0' is written to DAC a decimal '37' is read from the ADC. For any change in DAC input the ADC value read changes proportionately. I calculated the DAC and ADC outputs as given in the datasheets but the values don't match. [Vagnd = Vdgnd = 0V, Vref = 4.096V].

I want to know:
* What should I do to test the IC.
* Is any better way to perform a self test on the IC?

I am working with P89V664 controller and SDCC compiler. The I2C protocol is implemented by bit banging.

I'd greatly appreciate any comments and suggestions.
Thanks in advance

No replies in thread

Back to Subject List