Cirkit Designer LogoCirkit DesignerYour all-in-one circuit design IDE Launch Cirkit Designer App

How to Use SparkFun Qwiic OpenLog: Examples, Pinouts, and Specs

Image of SparkFun Qwiic OpenLogDesign with SparkFun Qwiic OpenLog in Cirkit Designer

Introduction

The SparkFun Qwiic OpenLog is an open-source data logger that is part of SparkFun's Qwiic connect system. It is designed for simplicity and ease of use, allowing users to log data from various sources without the need for soldering or complex wiring. The Qwiic OpenLog is ideal for applications such as sensor data logging, serial communication recording, or capturing any serial data for analysis and debugging purposes.

Explore Projects Built with SparkFun Qwiic OpenLog

Use Cirkit Designer to design, explore, and prototype these projects online. Some projects support real-time simulation. Click "Open Project" to start designing instantly!
Image of ESP32-Based Battery-Powered Weather Station with LoRa and GPS: A project utilizing SparkFun Qwiic OpenLog in a practical application
ESP32-Based Battery-Powered Weather Station with LoRa and GPS

This circuit is a data logging and communication system powered by a Li-ion battery, featuring an ESP32 microcontroller. It includes sensors (BME280 and MPU-6050) for environmental and motion data, a GPS module for location tracking, and a LoRa radio for long-range communication. The system logs data to a SparkFun OpenLog and is managed by a TP4056 battery charger with power regulation components.

Open Project in Cirkit Designer
Image of ESP32-Based GPS Tracker with Data Logging: A project utilizing SparkFun Qwiic OpenLog in a practical application
ESP32-Based GPS Tracker with Data Logging

This circuit features an ESP32 Wroom Dev Kit microcontroller interfaced with a SparkFun OpenLog data logger and a GPS NEO 6M module. The ESP32 is configured to communicate with the OpenLog via serial connection (GPIO 18 and GPIO 19) and with the GPS module via another serial connection (GPIO 16 and GPIO 17). The purpose of this circuit is likely to log GPS data received from the GPS module onto the OpenLog for storage or later retrieval.

Open Project in Cirkit Designer

Technical Specifications

Key Technical Details

Pin Configuration and Descriptions

Pin Number Pin Name Description
1 GND Ground connection
2 3.3V Power supply input (3.3V)
3 SDA I2C data line
4 SCL I2C clock line
5 RXI UART Receive Input
6 TXO UART Transmit Output

Usage Instructions

Integrating with a Circuit

To use the SparkFun Qwiic OpenLog in a circuit:

  1. Connect the Qwiic OpenLog to a Qwiic-enabled board using a Qwiic cable.
  2. Insert a formatted microSD card into the OpenLog.
  3. Power the system with a 3.3V supply.

Best Practices

Example Code for Arduino UNO

#include <Wire.h>
#include <SparkFun_Qwiic_OpenLog_Arduino_Library.h> // Click here to get the library: http://librarymanager/All#SparkFun_Qwiic_OpenLog

OpenLog myLog;

void setup() {
  Wire.begin();

  Serial.begin(9600);
  Serial.println("Qwiic OpenLog Test");

  if (myLog.begin() == false) {
    Serial.println("Qwiic OpenLog did not respond. Freezing...");
    while (1);
  }
  Serial.println("Qwiic OpenLog online!");

  myLog.append("log.txt", "Hello, world!"); // Append "Hello, world!" to log.txt
}

void loop() {
  // Code to collect data and log it
}

Ensure that the SparkFun Qwiic OpenLog Arduino Library is installed before uploading this code to your Arduino UNO.

Troubleshooting and FAQs

Common Issues

Solutions and Tips

FAQs

Q: What is the maximum size of the microSD card that can be used with the OpenLog?

A: The OpenLog supports microSD cards up to 32GB in size.

Q: Can I use the OpenLog without a Qwiic-enabled board?

A: Yes, you can directly connect to the TXO and RXI pins for UART communication, but you'll need to provide your own 3.3V power supply.

Q: How do I change the baud rate of the OpenLog?

A: You can change the baud rate by sending commands to the OpenLog through a serial connection. Refer to the OpenLog command set for detailed instructions.

This documentation provides an overview of the SparkFun Qwiic OpenLog, its technical specifications, usage instructions, example code for Arduino UNO, and troubleshooting tips. For more detailed information, refer to the official SparkFun Qwiic OpenLog datasheet and user manual.