fbpixel
Tags: ,

The Arduino NANO board is a smaller version of the Arduino UNO with similar functionality. Ideal for rapid prototyping and building embedded projects.

arduino-nano Arduino NANO microcontroller overview

Microcontroller features

The Arduino NANO microcontroller uses the ATmega328 microprocessor. This processor operates at a clock frequency of 16 MHz, and has 2 kB RAM, 1 kB EEPROM and 32 kB Flash memory (for programming and data storage).

  • CPU ATmega328
  • Voltage : 5V
  • Flash : 32 kB
  • RAM : 2 kB
  • EEPROM : 1 kB
  • Clock speed : 16MHz
  • WiFi : No
  • Bluetooth : No
  • SD : No
arduino-nano-overview Arduino NANO microcontroller overview

Power supply

The Arduino NANO microcontroller operates over a voltage range of 7-12V, thanks to its on-board voltage regulator. The microprocessor operates at 5V. In normal operation, the microcontroller consumes up to 19mA (if no power is supplied) and can accept a maximum current of 40mA on each of its IO pins.

Pinout

  • Analog I/O : 8 (A0, A1, A2, A3, A4, A5, A6, A7)
  • Digital I/O : 8 (0, 1, 2, 4, 7, 8, 12, 13)
  • PWM pins: 6 (3, 5, 6, 9, 10, 11)
  • Communication Serial: 14 (0, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13)
  • I2C communication : 1 ((‘A4’, ‘A5’))
  • SPI communication: 1 ((10, 13, 12, 11))
  • Interrupt : 1 (2)
arduino-nano-pinout Arduino NANO microcontroller overview

Basic code and pin identification

To use the input/output pins in the code, simply use the labels present on the board, i.e. A0-A7 and 0-13. Pins A0, A1, A2, A3, A4 and A5 can also be replaced by 14, 15, 16, 17, 18 and 19 respectively. For your information, analog pins can also be used as digital I/Os.

const int analogPin=A0; // broches A0-A7
const int digitalInPin=2; // broches 0-13 et 14-19
const int digitalOutPin=4; // broches 0-13 et 14-19
const int pwmPin=3; // broches 3 5 6 9 10 11

int analogVal=0;
int digitalState=LOW;
int pwmVal=250;

void setup() {
  Serial.begin(9600); //broches 0(Rx) et 1(Tx)
  
  pinMode(analogPin,INPUT_PULLUP); // broches 0-13 et A0-A7, Argument OUTPUT, INPUT, INPUT_PULLUP
  pinMode(digitalInPin,INPUT);
  pinMode(digitalOutPin,OUTPUT);
  pinMode(pwmPin,OUTPUT);
}

void loop() {
 analogVal=analogRead(analogPin); // broches A0-A7, return int
 digitalState=digitalRead(digitalInPin); // broches 0-13 et 14-19, return boolean
 digitalWrite(digitalOutPin,HIGH); //broches 0-13 et 14-19, valeur LOW(0) ou HIGH(1)
 analogWrite(pwmPin,pwmVal);// broches 3 5 6 9 10 11, valeur 0-255
}

Summary of features

Microcontrôleur 
Nom:Arduino NANO
Marque:Arduino
Caractéristiques 
CPU:ATmega328
Tension d’alimentation :7-12V
Tension logic:5V
E/S digitales:14
Entrées analogiques:8
Flash:32kB
SRAM:2kB
EEPROM:1kB
Fréquence d’horloge:16 MHz
Wifi:No
Bluetooth:No
SD card:No
Touch:No
UART/SPI/I2C/I2S:Yes/Yes/Yes/No

How to get started