user30152: I am working on a project on nano and want to use analog pins for 4x4 matrix keypad input. My connections are for keypad are as follows:

Digital pins are D10-D13 and Analog pins are A0-A3. 
A0->14, 
A1->15, 
A2->16, 
A3->17 

Code is:
#include <Keypad.h> // includes the keypad library
const byte ROWS = 4; // four rows
const byte COLS = 4; // four columns
char keys[ROWS][COLS] = {
 {'1','2','3','A'},
 {'4','5','6','B'},
 {'7','8','9','C'},
 {'*','0','#','D'}
};

byte rowPins[ROWS] = {10,11,12,13}; // connect to the row pinouts of the keypad
byte colPins[COLS] = {14,15,16,17}; // connect to the column pinouts of the keypad
Keypad keypad = Keypad( makeKeymap(keys), rowPins, colPins, ROWS, COLS );

Can I use analog pins as I defined for keypad? Is "Keypad.h" library compatible with Arduino Nano v3.0?

user30198: You can use the analog pins. I prefer {A0, A1, A2, A3} in the code instead of {14, 15, 16, 17}. That makes it easier to check if you connected the wires to the right pins.
Don't use pin 13 for an input with the Arduino Nano. An LED is connected to that pin. You can use that pin as an output for something else.

30152: <p>I am working on a project on nano and want to use analog pins for 4x4 matrix keypad input. My connections are for keypad are as follows:</p>

<ul>
<li>Digital pins are D10-D13 and Analog pins are A0-A3. </li>
<li>A0->14, </li>
<li>A1->15, </li>
<li>A2->16, </li>
<li>A3->17 </li>
</ul>

<p>Code is:</p>

<pre class="lang-cpp prettyprint-override"><code>#include &lt;Keypad.h&gt; // includes the keypad library
const byte ROWS = 4; // four rows
const byte COLS = 4; // four columns
char keys[ROWS][COLS] = {
 {'1','2','3','A'},
 {'4','5','6','B'},
 {'7','8','9','C'},
 {'*','0','#','D'}
};

byte rowPins[ROWS] = {10,11,12,13}; // connect to the row pinouts of the keypad
byte colPins[COLS] = {14,15,16,17}; // connect to the column pinouts of the keypad
Keypad keypad = Keypad( makeKeymap(keys), rowPins, colPins, ROWS, COLS );
</code></pre>

<p>Can I use analog pins as I defined for keypad? Is "Keypad.h" library compatible with Arduino Nano v3.0?</p>
 30198: <p>You can use the analog pins. I prefer {A0, A1, A2, A3} in the code instead of {14, 15, 16, 17}. That makes it easier to check if you connected the wires to the right pins.</p>

<p>Don't use pin 13 for an input with the Arduino Nano. An LED is connected to that pin. You can use that pin as an output for something else.</p>
