That is my suspicion.If I understand what you are saying, the arduino doesn't see any input from the accelerometer so it thinks that the input is below the low limit that i set in the program?
It is possible that you are fighting this problem.Could that be what is messing with my relay as well? I'm trying to control one relay with three different inputs
Would the analog side of things be able to read in decimal values are does it have to be in binary?
Yes.So if I changed my code from this
To this:Rich (BB code):if(analogRead(xpin)>0B0001011110) { digitalWrite(relaypin, HIGH); }
That should work?Rich (BB code):if(analogRead(xpin)>607) { digitalWrite(relaypin, HIGH);