Problem with testing ADC0804

Discussion in 'The Projects Forum' started by multiben, Jun 22, 2011.

  1. multiben

    Thread Starter New Member

    Jun 2, 2011
    10
    0
    Hello,
    I am having difficulty setting up a test circuit for the ADC0804LCN analog to digital converter. I have read the data sheet about 100 times and am trying to set up a test to show a simple digital conversion using 8 LEDs as described in the datasheet.

    The problem I am experiencing is that when I apply a voltage to Vin, all of the LEDs light up simultaneously. Even a voltage of 0v still lights the LEDs very faintly. As I increase the voltage to Vin (max 5v) the LEDs all increase in brightness rather than just have some on and some off as I expected.

    Can anyone suggest some ways to trouble shoot this? Is there a mistake that I am likely making (I'm pretty new to this so I assume there is)?
    Thanks,
    Ben
     
  2. bertus

    Administrator

    Apr 5, 2008
    15,647
    2,346
    Hello,

    I presume you are using this circuit:

    [​IMG]

    What voltahe are you measuring on pin 9.
    This should be about half the powersupply voltage.

    Bertus
     
  3. multiben

    Thread Starter New Member

    Jun 2, 2011
    10
    0
    Hello yes that is the exact circuit.

    The supply voltage at pin 20 is 5V and I am supplying almost exactly 2.5V to pin 9. However when I actually connect the wire to pin 9 the voltage at pin 9 drops to about 0.9V - I presume because I am using a potentiometer to supply the 2.5V? I fiddled with the pot to make it read 2.5V at pin 9, but I still get exactly the same result. All the LEDs change in unison.
    Cheers,
    Ben
     
  4. bertus

    Administrator

    Apr 5, 2008
    15,647
    2,346
    Helllo,

    Did you read the theory for the test circuit at fig 17 ?

    [​IMG]

    The switch is used to force a reading.
    The input signal is at pin 6.

    Bertus
     
  5. multiben

    Thread Starter New Member

    Jun 2, 2011
    10
    0
    Hello,
    Yes I read it and when I press the switch to momentarily ground WR and INTR the LEDs all become brighter while the switch is pressed and then return to the same state once it is released.

    What could cause all the digital outputs to be operating like this? Obviously I'm missing something - I just can't figure out what.
     
  6. bertus

    Administrator

    Apr 5, 2008
    15,647
    2,346
    Hello,

    How and where is the input signal connected?
    Is the input signal a DC voltage?
    When it is AC the leds will probably change states and seem to light all.

    Bertus
     
  7. multiben

    Thread Starter New Member

    Jun 2, 2011
    10
    0
    Hi,
    The input signal is coming from a 12V DC power adapter through a 7805 voltage regulator through a 5k potentiometer. The output of the pot is then connected to pin6 of the chip. I've measured this signal on an oscilloscope and it is definitely DC.
    Cheers,
    Ben
     
  8. multiben

    Thread Starter New Member

    Jun 2, 2011
    10
    0
    Oh my god. I'm such an idiot.

    On my bread board I have a ZIF socket where I plug in my chip. And I had connected the ZIF to the breadboard with all the pins offset by one. So what I thought was pin 2 was actually pin 1 and so on. No wonder I was getting bizarre results. I've been puzzling over this for days now and it wasn't until I rebuilt the circuit on a different bread board with no ZIF socket that i realised my mistake.
     
  9. bertus

    Administrator

    Apr 5, 2008
    15,647
    2,346
    Hello,

    Good to hear you found your "mis-fitting".
    Is the circuit working now.

    Bertus
     
  10. multiben

    Thread Starter New Member

    Jun 2, 2011
    10
    0
    Yes thankyou for all your help. The circuit is now operating exactly as expected.
    Cheers,
    Ben
     
Loading...