

The Adafruit Feather M0 Adalogger (Part ID: 2796) is a compact and versatile microcontroller board designed for low-power applications. It features an ARM Cortex-M0 processor and includes an onboard SD card slot for data logging, making it ideal for projects that require data storage and portability. The board is part of Adafruit's Feather ecosystem, which emphasizes small form factors and compatibility with a wide range of FeatherWing add-ons.








The Adafruit Feather M0 Adalogger is packed with features that make it suitable for a variety of applications. Below are its key technical details:
The Adafruit Feather M0 Adalogger has a total of 20 GPIO pins, each with specific functions. Below is a detailed pinout:
| Pin | Label | Function |
|---|---|---|
| 1 | A0 - A5 | Analog inputs (12-bit ADC), can also be used as digital I/O |
| 2 | D0 - D13 | Digital I/O pins, some with PWM capability |
| 3 | SDA, SCL | I2C communication pins |
| 4 | MOSI, MISO, SCK | SPI communication pins |
| 5 | RX, TX | UART communication pins for serial data |
| 6 | 3V3, GND | Power pins (3.3V output and ground) |
| 7 | BAT | Battery voltage monitoring pin |
| 8 | EN | Enable pin to turn the board on/off |
| 9 | USB | USB power input and data communication |
| 10 | LIPO | LiPo battery connector for portable power |
The Adafruit Feather M0 Adalogger is easy to use and integrates seamlessly with the Arduino IDE. Below are the steps to get started and important considerations for using the board effectively.
Powering the Board:
Programming the Board:
Connecting Peripherals:
Data Logging Example:
#include <SPI.h>
#include <SD.h>
#include <DHT.h>
// Define SD card chip select pin
#define SD_CS 4
// Define DHT sensor pin and type
#define DHTPIN 2
#define DHTTYPE DHT22
DHT dht(DHTPIN, DHTTYPE);
File dataFile;
void setup() {
Serial.begin(9600);
while (!Serial) {
// Wait for Serial Monitor to open
}
// Initialize DHT sensor
dht.begin();
// Initialize SD card
if (!SD.begin(SD_CS)) {
Serial.println("SD card initialization failed!");
return;
}
Serial.println("SD card initialized.");
}
void loop() {
// Read temperature and humidity
float temp = dht.readTemperature();
float humidity = dht.readHumidity();
// Check if readings are valid
if (isnan(temp) || isnan(humidity)) {
Serial.println("Failed to read from DHT sensor!");
return;
}
// Open file for writing
dataFile = SD.open("datalog.txt", FILE_WRITE);
if (dataFile) {
// Write data to file
dataFile.print("Temperature: ");
dataFile.print(temp);
dataFile.print(" *C, Humidity: ");
dataFile.print(humidity);
dataFile.println(" %");
dataFile.close(); // Close file
Serial.println("Data logged.");
} else {
Serial.println("Error opening datalog.txt!");
}
delay(2000); // Wait 2 seconds before next reading
}
Board Not Recognized by Arduino IDE:
SD Card Initialization Fails:
Sensor Readings Are NaN:
Board Not Powering On:
Q: Can I use the Feather M0 Adalogger with 5V sensors?
A: The Feather M0 operates at 3.3V logic levels. Use a level shifter to interface with 5V sensors.
Q: What is the maximum SD card size supported?
A: The board supports microSD cards up to 32GB formatted in FAT16 or FAT32.
Q: Can I use the board without a battery?
A: Yes, the board can be powered via USB without a battery. However, a battery is required for portable applications.
Q: How do I reset the board?
A: Press the reset button on the board to restart the microcontroller.
This concludes the documentation for the Adafruit Feather M0 Adalogger. For additional support, visit the Adafruit Learning System.