Hi all,
probably I'm ignoring some basic problem but could anyone please help
with this?:
I have a comparator with no histeresys (LM311) connected to Atmega328's Pin 4 (ARDUINO digital pin 2). This pin is also indicated as PCINT18/INT0 or PD2.
The comparator has to compare a very weak digital signal that varies between -0,3V and -0,9V and output must be TTL (so then I can drive it to attack AtMega's digital pins) - this function is doing well, I tested.
Ok, so the output of the comparator is TTL (0 to 5V - I checked that) and gives me the right values, but when I connect to Pin 4 the signal drops to a level that is no more recognized as TTL, because ATMega reads 0 from that pin all the time.
The drop is normal but I expected that it was a very short one. So...is the pin consuming more current than normal? Does it present a low impedance? (I programmed the Arduino digital pin 2 to INPUT).
Any one can give me any suggestion about the error I'm doing here? I have no clues, but I'm not an expert on ATMega either
...
Is there anything special about this PORT (I tested every pins of the D port) that can't be used as a TTL input?
Thanks for your help.