Inputs always high

I suspect I may have static zapped my Arduino Uno board. I am working on turning my Arduino into a timer that can time down to .001 seconds. I am using digital pin 2 as an interrupt that watches my 1000hz master clock. Digital pin 3 is an input that watches for the Start pushbutton to be pressed. Digital pins 4 thru 9 drive a pair of LCD displays. I'm using digital pins 10, 11, 12, and 13 as inputs that watch for Stop signals.

  1. Had my sketch working, just debugging it
  2. suddenly had 4 inputs - digital pins 10, 11, 12, and 13 always read high
  3. wrote a short diagnostic that to specifically test those pins and display the results
  4. the diagnostic proves those pins are always high (even when I solder a ground to the pins)
  5. I thought I had blown the ATMega328 chip so I replaced that chip
  6. those four pins are still always reading a high input while all the other pins function normally

Is there some other chip I need to replace? Or maybe some resistors I've blown? What else could be making only those four pins always read high even when I have a ground soldered to the pins?

If I put a voltmeter on those pins the voltage measured varies between 0v and .1 volts - so those pins do [u]not[/u] actually have a high on them.

Without posting your sketch and a drawing of your wiring it's pretty hard for anyone to help.


True but my guess is that he has blown the input pins.

What is generating the stop signals to these pins?

What is connected to the pins is not important because even when that circuit is disconnected and I solder a wire from any of the pins (10 thru 13) to ground - so it’s a hard wired LOW signal, those pins still read as HIGH.

Since I have already replaced the ATMega328 chip … what else is there that could make these pins read as high?

in other words … if I write a program that says:

int val = 0;
val = digitalRead(10);
print(val); //this shows the status on the LCD display

The display will show that the pin is reading as HIGH. But when I put a voltmeter on pin 10 it reads 0 volts, so it’s NOT actually high. And since I have replaced the ATMega328 chip there MUST be something else that is causing the false reading … what could that be?

I could post the actual code but that would take years for me to explain all the nuances of how it works. Please suffice it to say that one moment it was working and fine but suddenly those four inputs stopped working and now no matter what I do those inputs do not read correctly, while digital inputs 2 and 3 (they are connected to pushbuttons) are still working perfectly, and pins 4 thru 9 are driving the LCD displays correctly.

I have been over the code with a fine-toothed comb and the same code that reads pins 2 & 3 correctly reads a false HIGH on pins 10 thru 13.

Well you replaced the 328 chip. Was it subjected to the same wiring condition as the prior one before you disconnected all wiring to those chips and grounded the pins? That is, could external wiring problems have damaged both chips? A wiring drawing still would be a nice thing to look over.

As far as not posting your code that's your choice of course. The fact remains you may have an error that you just don't see, it happens to most of us at times. Your simple example code isn't a complete sketch but if you did write such a simple program that displays the problem then post that test code.

So it's up to you. The problem as you frame it has no solution or cause, so what else can you expect from us?


Unconnected pins read high or low, because they act like antennas but when you load then, for example with the multimeter they will read low because of the interference that the voltmeter introduces.

Senso: Unconnected pins read high or low, because they act like antennas but when you load then, for example with the multimeter they will read low because of the interference that the voltmeter introduces.

But he stated that he wired the pins to ground and they still read HIGH, so floating input pin symptom doesn't apply.


The code I'm using to test the inputs is as follows:

void TestInputs() { testit: TextString[0] = _0; TextString[1] = _0; TextString[2] = _0; TextString[3] = _0; TextString[4] = _0; TextString[5] = _0; TextString[6] = _0; TextString[7] = _0; TextString[8] = _0; TextString[9] = _0; TextString[10] = _0; TextString[11] = _0; TextString[12] = _0;

if (digitalRead(L1in == HIGH)){TextString[1] = _1;} if (digitalRead(L2in == HIGH)){TextString[2] = _1;} if (digitalRead(L3in == HIGH)){TextString[3] = _1;} if (digitalRead(L4in == HIGH)){TextString[4] = _1;}

PrnText(Display1); goto testit;


Where L1in is a constant = 10 L2in = 11 L3in = 12 L4in = 13

Based on the condition of those pins I set the text of the string I'm sending to the display, and then it loops to test them again.

But ya know what ... looking over those lines ... I'm wondering if I got my parentheses placed wrong....

Where "if (digitalRead(L1in == HIGH)){TextString[1] = _1;}"

SHOULD read "if (digitalRead(L1in) == HIGH){TextString[1] = _1;}"

HA! I just tested it and I was right! Man! It's sometimes Sooooo frustrating when something like that just kicks your butt, and when you finally find it you slap your forehead and say "DOH!" (ala Homer Simpson)

I've been beating my brains out on this for over two weeks!!!

Well guys, thanks for being my sounding board. The discussion helped me take a fresh look at it and find my mistake.

Nice way to spend all your ram in a blink of an eye.... Just do some digital read, sum '0' to it and send it via serial.print, it is as easy as it can be. Something like:

void setup(){

void loop(){
Serial.print("Pin 10: ");
Serial.print("Pin 11: ");
Serial.print("Pin 12: ");
Serial.print("Pin 13: ");

As easy as it gets! What a hummmm hell is that _1's and _0's? Smells more like code always buggy than pins always high.

And yes, your parenthises are wrong, you are doing the comparation of 10==HIGH, that will return false I think, so what argument will the digitalRead receive? Who knows..

Just to clarify .... The LCD displays don't use ASCII codes to display characters. They use hexidecimal values instead ... so the _0 is a pre-defined hexidecimal constant. That makes it far easier for me the programmer to display a 0 (zero) by sending "_0" than by sending a hex value of 0x07. And since I have about 40 of those constants defined I can remember that _E sends the letter "E" to the display versus a 0xF1.

Anyway, I have it working again, now that I got my parentheses in the right place.

(I was SURE that I had blown those pins, but didn't know what to make of it when I replaced the chip and they were still not working)

I'm just glad it did not mean buying a new Arduino.

you are doing the comparation of 10==HIGH, that will return false I think, so what argument will the digitalRead receive? Who knows..

zero. false is zero, true is non-zero in C.

Depend in which flag that is set and what flags does the branch that the compiler chooses looks for.