I am using a serial println loop inside if loop similar as:
if (x == 1){
serial.prinln(1)
}
else if (y==1){
serial.prinln(2)
}
....
But I am getting output only sending '2'. the loop never goes out of the else loop.
How to achieve this so that bit '1' also sent through serial?
@debasishnath Installation and Troubleshooting is for Problems with the Arduino IDE itself NOT your project. It says so in the description of the section.
Therefore I have moved your post here. Please be more careful where you post in future.
Are you having difficulty understanding the word all.
It means all the code you are using. The code in its entirety. Every single line of code that you have in your program that you uploaded to your Arduino.