Loading...
Searching...
No Matches
arduino_board_analog.h File Reference

Arduino analog pin map. More...

Detailed Description

Arduino analog pin map.

Note
The contents of this file are mostly generated using the python snippets documented. Do not edit these parts by hand, but rather adjust the python snippets and regenerate.
Author
Marian Buschsieweke maria.nosp@m.n.bu.nosp@m.schsi.nosp@m.ewek.nosp@m.e@ovg.nosp@m.u.de

Definition in file arduino_board_analog.h.

#include "periph/adc.h"
#include "arduino_iomap.h"
+ Include dependency graph for arduino_board_analog.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

#define ARDUINO_ANALOG_PIN_LAST   /* board specific number */
 Number of the last analog pin.
 
static const adc_t arduino_analog_map []
 Look-up table for the Arduino's analog pins.
 

Macro Definition Documentation

◆ ARDUINO_ANALOG_PIN_LAST

#define ARDUINO_ANALOG_PIN_LAST   /* board specific number */

Number of the last analog pin.

E.g. 5 if A5 is the analog pin with the highest number.

Definition at line 39 of file arduino_board_analog.h.

Variable Documentation

◆ arduino_analog_map

const adc_t arduino_analog_map[]
static

Look-up table for the Arduino's analog pins.

Generate using

format = """#ifdef ARDUINO_A{0:}
ARDUINO_A{0:},
#elif ARDUINO_ANALOG_PIN_LAST > {0:}
ADC_UNDEF,
#endif"""
for i in range(16):
print(format.format(i))
void print(const char *s, size_t n)
Print string to stdout.

The Arduino MEGA 2560 has A0 to A15, so 16 Analog inputs is the largest as of now.

Definition at line 73 of file arduino_board_analog.h.