Questions tagged [sd]

The tag has no usage guidance.

Filter by
Sorted by
Tagged with
9
votes
1answer
2k views

Why is our refresh rate consistently decreasing in logging on SD card?

The current code is used to gather the state of 12 infrared beams and log them to an SD card using the real time clock to mark the time. The code uses a switch to turn the device on and off and an LED ...
2
votes
0answers
39 views

Returning to parent directory with the SD library

I have a File variable called dir and i'm building a simple file explorer for my device. Is there a way to get a reference to dir's parent directory?
0
votes
0answers
54 views

Can I record us (microseconds) with AnalogBinLogger example in SdFat's library?

I am using the AnalogBinLogger from the SdFat example library. I am using it to record 8 analog channels at 5kHz! which is amazing (thank you SdFat). Is it possible to include a separate column to ...
2
votes
2answers
235 views

Best buffering practice for continuous SD card writing

In a simplified example, I have a microcontroller functioning as a data acquisition device - sensor data is received over UART, and then saved to an SD card. This received data is in the form of a 12 ...
0
votes
1answer
43 views

SD seems too slow for SMTP

I have asked this question on the arduino forum as well. I have used SMTP before using client.print (and client.println) but I am now trying to move as much text as I can from RAM to SD (and so I need ...
1
vote
0answers
51 views

Problem with using SD and Adafruit_SSD1306 libraries at the same time

I am searched over the internet and found out a few similar questions, but non of them were helpfull, so I decided to open a new quetion. I tried both SD and Adafruit_SSD1306 libraries and they both ...
0
votes
1answer
65 views

Barcode not logged in SD card UART

After trying for a good month.. looking like a Newbie I have not managed to log the result of barcode scanner , using rtc SD module and a waveshare scanner connected via UART to ports 2 and 3 from the ...
1
vote
0answers
64 views

Impossibility to open a file for modification in ESP32

Consider the following code: #include "SD.h" #include "Fs.h" void setup() { Serial.begin(115200); while (!Serial) { ; // wait for serial port to connect. Needed for native USB port only } ...
1
vote
0answers
143 views

Edit JSON File on SD Card

I am currently Working on a project, where I save values in a JSON File on an SD Card. The JSON looks something like this: { "ID1":{[[starttime, endtime], [starttime, endtime], [....
0
votes
0answers
62 views

Failed to display string on oled (SPI) from SD module

i am working on a project in which data from sd card is displayed on the oled screen both using SPI communication, but it is not displaying anything. i commented out the sd part and then oled works ...
0
votes
2answers
304 views

STM32 and SDFat - Can't create file in directory in SD

I'm using the SdFat.h library on a STM32 and I can successfully create a file in the root directory using SD.open("test.txt", FILE_WRITE); but my code fails to create SD.open("DATA/data_test.txt", ...
-1
votes
1answer
71 views

SD card with arduino UNO

I am trying to use a micro SD card in order to store data sent from an arduino UNO. My setup consists of: Arduino UNO (5V logic), powered directly from USB cable Digilent Full-sized SD Card Slot ...
0
votes
1answer
300 views

SD Library function doesnt work while using second SPI port with ESP32

i work on a group project with an ESP32. We have a lcd display and a sd card connected via the two SPI ports of the ESP32. The card gets initialized with no problem using this code: bool ...
1
vote
2answers
54 views

Can I read from a memory card with three pins?

I have a project where I have three pins to use and I just realized it would be better to use a memory card than replacing the code each time. I'm building a Arduino with a push button. Press the ...
1
vote
0answers
633 views

reference to 'File' is ambiguous. Why am I getting this error?

The program is supposed to take photo and store the picture into the SD card with the timestamp. My Program Code: #include <SdFat.h> #include <Adafruit_VC0706.h> #include <SPI.h> #...
-1
votes
1answer
85 views

SD card reader and lcd display

I have sd card reader and lcd display. I want to display bitmap with u8g2 library. My bitmap looks like: 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0xff, 0x3f, 0x00, 0x00,...
1
vote
0answers
93 views

Arduino malfunction tmrpcm while used digitalRead

I am programming Arduino UNO for this functionality: with use of SD card reader module and SIM900 GSM/GPRS shield I am trying to: 1. Pick up incomming call, play message from SD file and after the ...
1
vote
0answers
66 views

Getting wrong value from sd card

I stored "28328630" in sd card but at output i getting wrong value. on serial "5566" getting this value. #include "HX711.h" #include <Wire.h> #include <LiquidCrystal_I2C.h> #...
0
votes
1answer
240 views

SD card creating “extra” file?

So, maybe I'm too tired to see the obvious issue here, but my SD card script is causing a "blank" file to be created, then a secondary file to be correctly created. I'm trying to store data logs, and ...
1
vote
0answers
1k views

How to read correctly binary data on sd card from a structure?

I am currently struggling to apply Majenkos solution to read binary data from an sd card. I am writing data as floats from a 3-axis accelerometer via a struct this way: struct data { float acc_x; ...
1
vote
0answers
111 views

LCD on top of SD datalogger flickers help!

I have a problem with my 16,2 with buttons lcd shield.(LCD Keypad Shield). It is connected on top of an SD dataloger. I came to the conclusion that every time the sd shield logs data and completes the ...
1
vote
3answers
4k views

Arduino SD Card open file modes append / overwrite

Running Arduine IDE SD DataLogger Example, my data gets appended to a txt file. File dataFile = SD.open("datalog.txt", FILE_WRITE); if (dataFile) { dataFile.println(dataString); dataFile.close(); ...
0
votes
1answer
353 views

Fast data logging

I want to store noise data (basically from A0) from an Arduino Uno to an SD card with faster writing speed, preferably by using 512 data together and the write it at once. What should be the code?
0
votes
1answer
841 views

DFPlayer for Writing to SD Card

Can you use the DFPlayer to write to the SD card? Link for DFPlayer: https://www.dfrobot.com/wiki/index.php/DFPlayer_Mini_SKU:DFR0299 Here's the goal of my project. I have a button that, when pressed,...
0
votes
1answer
158 views

Where are the implementations of the SdFat BlockDriver methods?

This is most probably more of a C++ question than an Arduino question; but since this is an Arduino library, I am asking here. I am using the SdFat library for my project. The library defines a ...
0
votes
1answer
160 views

Trouble with reading Bitmaps from SD-Card

I'm having problems with reading a bitmap file with the SD library. I wrote a small header that reads uncompressed 24-bit bitmap files. It works fine when I try it on Windows 10 MingW with fread() ...
-1
votes
1answer
645 views

Attempting to read random string from SD card

I was wondering if anyone knew how to read in a random string from a file named "PhraseList.csv" or "PhraseList.xlsx" (whatever is easier)? There is a list of 10k. #include <SD.h> #include <...
0
votes
0answers
74 views

SD card module not responding [duplicate]

I am trying to read an SD card info by Arduino and an SD card module. But the SD card is not responding. I connected the wires carefully several times but it is not working. I am using this module : ...
0
votes
2answers
543 views

arduino usb host shield and sd card [closed]

when I use the sd card on the mega or the arduino uno it works. Everything is fine. However, when I use it in combination with the USB shield host it doesn't work. I know the usb shield host works ...
0
votes
2answers
674 views

How does one **get** attributes for SD files?

To be able to set the date and time of the files on my SD card I followed this answer: https://arduino.stackexchange.com/a/39127/49678 Now I am wondering How do I read the values out in the ...
0
votes
4answers
3k views

Use 5V SD-Adapter on 3.3V System

I want to use a Catalex Micro SD Card Adapter in Combination with my Arduino MKR GSM 1400. The problem is, that the Arduino uses 3.3V to operate but the SD Adapter needs 5V (or at least 4.5V) to ...
1
vote
1answer
530 views

PMS5003 Serial Output Data to SD Issues

I'm trying to save the output of an air quality sensor to a SD card, but I'm having a few issues. The sensor I'm using is a Plantower PMS5003 which puts out its data via serial. I've heavily tweaked ...
0
votes
1answer
99 views

Datalogger with interruputs

I'm trying to do a data logger. Writes into SD card has to stop when millis()=1000. Maybe I have a problem between millis() and my interrupt, because datalogger doesn't stop after millis()=1000. I'm ...
0
votes
1answer
360 views

Arduino UNO And SD Card Custom csPin

I've connected SD card module to Arduino UNO. I want to use PIN 10 for PWM DC motor control and because of that, I've connected CS pin directly to another pin (A3). SD card is working properly, but ...
3
votes
1answer
320 views

Long freezes at the beginning of sd card transfer

I am creating an accelerometer data logger that writes data to sd card. After some sort of "warm-up" everything works perfectly for at least ~15 minutes (which is what I have tested so far). However, ...
0
votes
1answer
5k views

Saving a .txt file to SD Card and Reading each content data to txt file then save it to a variable

I am new to arduino I am trying to create an arduino project that Saving a .txt file to SD Card and Reading the txt file then save it to a variable data type "Long" named 'savednum'. I had ...
0
votes
2answers
780 views

Adding music to loop

Im newbie. I just wanted to ask how can i put my tmrpcm.play into loop. Im trying to put it in a loop but the problem is it didn't play. I also try adding a method and call the method into the loop ...
1
vote
1answer
79 views

Strange behavior on bitwise operation

i am trying to write a simple program that writes the outputs of an accelerometer (which comes down to 3 analog inputs) onto an SD-Card. I got the hole thing working fine (sending the values as ...
0
votes
1answer
2k views

Delete line from text file

In order to make an algorithm work, I'd like to delete the first line of a text file. I'm having a hard time finding an example for that though. I was thinking that there should be the possibility to ...
2
votes
0answers
84 views

SD card doesn't work properly

I have this SD-card module. I have formatted the SD with this tool. My problem is that the Arduino Uno can't initialize the SD. I tried with this script: // include the SD library: #include <SPI.h&...
0
votes
3answers
5k views

Is there a way to play .mp3 files from an SD card on Arduino?

Is there a way to have mp3 files on an SD card in the SD card shield for the Arduino and play an mp3 file on that SD card with a buzzer? If possible also with something like: playmp3(thismp3.mp3); ...
-1
votes
1answer
900 views

Problem with SPI comms using NodeMCU v 3, Nano and SD

Recently I bought a NodeMCU 8266 v 3 (Lolin) and it works fine. I set up a Catalex SD card module (with a built-in 5-3.3V regulator) and all was good. Then I set the Lolin with an Arduino Uno and or a ...
0
votes
2answers
1k views

Rfid reader and SD card shield won't work together

I recently encountered a problem that's been bugging me for days. I want to make a project using a RFID reader and log data on an SD card with an Arduino Nano, but apparently no matter what I do, I ...
1
vote
2answers
2k views

Problem opening multiple text files simultaneously/in-order using <SD.h>

I am looking to log analog sensor data using 3 pins, A1, A2, A3. My project requires continuous mapping of data, and hence an SD card shield was necessary. However, I need to log the incoming data ...
2
votes
0answers
604 views

Error while creating file on sd card

I want to create a file and read it form sd card by arduino. I have used sd card module. I have used this following code. In serial monitor it says "SD card is ready to use." But it can't read or ...
0
votes
1answer
59 views

Open Parent Class as Child Class (SD Fat Library)

I'm currently using the SDFat library and am passing a global FatFile I if have a function that requires an SdFile type and I know that a given instance of FatFile is a valid SdFile what is the best ...
4
votes
2answers
643 views

How can I work with two devices that use the SPI protocol?

I'm working with a project in which I need to use an SD card module and an RFID antenna simultaneously. The devices that I'm using are the MFRC522 and the CATALEX SD Card Adapter. Both have SPI ...
0
votes
1answer
1k views

read CID of SD card with SD.h library

I would like to be able to read the serial numbers of SD cards using the SD.h library. Only reading the values is enough, I am not looking to modify the CID. This should be possible but I do not have ...
1
vote
1answer
164 views

Connect Arduino to an external microSD card reader [closed]

I have a camera with a microSd card reader that is the only output type. I want to read the microSd when the camera makes a photo. How can I read it with an Arduino? Duplicating the reader connections ...
0
votes
1answer
2k views

Write char array containing new line to SD card

How do I a buffer (char array) containing new line character to SD card using SdFat? I tried: File myFile = SD.open("test.txt", FILE_WRITE) myFile.write(buffer, BUFLEN) but I get this instead: ...