« first day (1908 days earlier)   

5:02 PM
In the code, how is the difference between analog and digital pin initialization known?
I mean, I will be using digital pins 14, 15, etc; but already have this:
pinMode(14, INPUT); // analog input
pinMode(15, INPUT);
 
5:29 PM
in hardware there is no difference
setting to input just means dissabling the transistors that would pull it high or low
 
5:44 PM
I do not think that is what I'm asking about.
 
when you actually read it's either digitalread or analog read
 
Let's say I'm using the analog pins 14 and 15 as analog inputs. I am also using the digital pins 14 and 15 as digital outputs
 
they are the same pins with at the same voltage level
 
Pin A14 is connected to the other side??
Or are all the analog pins initialized as their equivalent digital pin? For example, A14 = 68?
So I should do this instead: pinMode(68, INPUT); // analog input
 
 
2 hours later…
8:19 PM
No?
 

« first day (1908 days earlier)