Example for Arduino-Write Data in CSV Format
Last revision 2026/01/15
This article provides a step-by-step guide on how to write data in CSV format using Arduino and a Serial Data Logger, complete with hardware requirements, connection diagrams, sample code, and running results to help hobbyists and enthusiasts effectively log data.
Hardware Preparation
- DFR0216 DFRduino UNO R3 x 1
- TEL0148 Fermion: Serial Data Logger x 1
- SD/MicroSD Memory Card x1
- FIT0916-FF DuPont Wires x3
Software Preparation
- Download Arduino IDE: Click to download Arduino IDE
In the config.txt file, set FileFormat to 1
Connection Diagram

Sample Code
#define SPIN 6 //Connect to the module Pin S, trigger to save files at low level
uint16_t i = 0;
void setup(void)
{
Serial.begin(9600);
delay(2000); //To aviod data lost, delay a period of time to wait for the module to start
pinMode(SPIN, OUTPUT);
digitalWrite(SPIN, HIGH);
}
void loop(void)
{
Serial.println(String(i));
i++;
if((i % 10) == 0){
digitalWrite(SPIN, LOW);
delay(500);
digitalWrite(SPIN, HIGH);
}
delay(300);
}
Running Results

Was this article helpful?
