I have been struggling with this problem for a couple of days now and I have had no luck finding an explanation for what I am doing wrong. I seem to be missing a very key and, probably simple, piece of information. Here is my situation:
I have 2 ATMega328 MCUs on a bread board. They are both using the same power supply circuit. Unit One is outputting a signal on one of it's pins just by setting the pin high and low. This signal changes state every 5 seconds. Unit Two is suppose to receive the signal and display a message on an LCD display telling me the state of the output pin on Unit One. All the code is working correctly. Unit One is sending the signal and I can see it on my oscilloscope just as I would expect. Unit Two tells me that the pin is high when I connect it's input pin to the voltage rail and it tells me the pin is low when I disconnect it. The problem is that when I connect the output from Unit One to the Input of Unit Two, the signal on the oscilloscope goes flat at 0 volts. What am I missing?
Here is a list of things I have tried:
- Adding and removing a pull down resistor to the line - No effect (my design includes the use of the pull down resistor)
- Removing the pull down resistor and enabling the pull up resistor on unit 2's input pin - Effect: the voltage on the line is always high connecting Unit Two's input to ground works to send the signal low and disconnecting it sends the signal high. The signal from Unit one is still not visible on the oscilloscope.
- Adding a diode - The signal does not exist on the output of the diode a very small signal exists on the input side (I think this is due to forward biasing but I am not sure if that is the correct term).
- Adding an NPN transistor, connecting the output of Unit One to the base, VCC to the collector, and the input of unit 2 to the emitter. Effect - The signal is very small (less than 100 mV) and very noisy. Removing the connection from the emitter to Unit Two shows me the full signal.
- Massive amounts of Googling.
It is as if when I send the signal to Unit Two, the MCU sends the signal to ground and doesn't read it at all. However, this can't be the case as when I connect the same pin to VCC, the pin is read as high and there is a 5V constant signal on my oscilloscope. There is something flawed in the way I am looking at this. Please educate me.
Thanks in advance,