Questions tagged [fat]

File Allocation Architecture (file system)

Originally designed for floppy discs, with its original o bit version, this robust and simple legacy file system was quickly addapted to larger media, resulting in three major variants: FAT12, FAT16 and FAT32. The numbers represent the number of bits on the file allocation tables of those versions.

For more detailed information, consult Wikipedia.

35 questions
9
votes
3 answers

FSInit() - "CE_BAD_PARTITION"

I am using a PIC18F26K80 and an XC8 compiler. I am trying to initialise an SD card and create a file. I have simply formatted the SD card on Windows to have a "FAT32" file system and an "Allocation unit size" of 512 bytes. The capacity of the SD…
user2344158
  • 175
  • 3
  • 11
4
votes
2 answers

SD Card formatting in FAT 32 file system

I am using NXP Micro for interfacing microSD card with FAT32 file system. for implementation I am using drivers located at below…
Mandar Sansare
  • 133
  • 1
  • 9
4
votes
1 answer

SPI / SD Card communication issues

I am working with a PIC18F67K22 and am seeing some bizarre things in the SPI data stream. I am trying to interact with a FAT32 partition using FatFs and a custom built diskio.c file. I am able to recognize the FAT32 partition, but when attempting to…
kingcoyote
  • 298
  • 1
  • 9
4
votes
0 answers

SD Card Buffer in FreeRTOS

One of my tasks in a project is responsible for gathering information about values measured from sensors and write information in a .txt file on an SD card. What would be the best way to do this? Right now, I create a task with 25000 size of stack…
user54506
3
votes
2 answers

STM32 - SD CARD USING FATFS

I am trying to read and write to a class 10 - 2GB SD card from STM32 with the help of FATFS R0.11, but f_mount() function is returning FR_NO_FILESYSTEM error code. I have tested the same code on a class 4 - 2GB and class 10 - 16GB SD card, and it…
Pudi
  • 111
  • 1
  • 2
  • 9
3
votes
2 answers

Read big file from sd card with fatfs

I'm using the STM32F4DISCOVERY board and I am trying to read a file from a micro SD card, and treat the data. I'm using the following functions int main(void) { int i = 0; HAL_Init(); /* Configure the system clock */ …
3
votes
1 answer

Writing and Reading Hex Values to a Text file using FatFs

Currently i am working on STM32F479 Eval board. I have to collect data from sensor nodes and store it in a text file using FatFs. My sensor values are in Hexadecimal values. I am using STM32F4Cube HAL Library which includes FatFs. I am using…
Jahir Hussain
  • 31
  • 1
  • 5
3
votes
2 answers

Read SD card without a file system

I design a DAQ to collect data from different sensors. The data are written on an SD card by a microcontroller, dsPIC33FJ256GP710A. The data are stored without a file system for speed reasons. Now I need to read the data acquired, store it on the SD…
2
votes
2 answers

FatFs f_write not working in LPC1788 Timer ISR

I’m using LPC1788 MCU with KeilV5 compiler. I Have a Timer ISR in which I read a value form specific ADC channel and write it into a SD-Card using FATFS library. Here is my Timer ISR code: void TIMER1_IRQHandler(void){ if…
Nima
  • 166
  • 11
2
votes
2 answers

Using FatFS on internal flash of STM32f303 microcontroller

I want to use FatFS library using STM32F303 internal flash memory. I created user_diskio.c file and described necessary functions USER_write, USER_read and USER_ioctl for reading and writing data to/from internal flash if…
user2809652
  • 71
  • 2
  • 8
2
votes
1 answer

SD card suddenly stops responding to CMD0 (RESET/SPI)

A device I had been testing for over two months suddenly started giving FR_DISK_ERR (I'm using Elm Chan's FAT-FS) [Link]. When I tried debugging, the command (CMD0) which must be clocked in to set the SD card into SPI mode (as described in the SD…
clamentjohn
  • 386
  • 3
  • 15
2
votes
1 answer

FatFs: Why am I not able to properly read sector 0?

Background: I am using an nRF52832 Development Kit with this microSD card in this breakout board. The card is powered at 3 V (I've tested running off the dev kit regulator and an external power supply). I am using 22 ohm series resistors on the…
jpwr
  • 301
  • 1
  • 10
2
votes
1 answer

Adapt fatFS library to PIC32

I'm developing an application with PIC32MX, that record 3 WAV sounds and store theme into SD. Unfortunately the speed that I have reach is 155 kB/s and is insufficient for my application. Then I have to move fatFS, that use multi sector write speed…
1
vote
0 answers

fat fs f_findfirst question

So, trying to use the f_findfirst() function in fat_fs by elmChaN. Using R0.11a. I have everything configured for long file names. The one kicker is that after f_findfirst has ran the first character in longFileName[0] is '\0' (as in NULL…
DDECE88
  • 21
  • 1
1
vote
1 answer

STM32F103C8 + W25Q64 USB Mass Storage Device

I have problems creating an MSC device. I made the following functions: #define STORAGE_BLK_NBR 0x4000 #define STORAGE_BLK_SIZ 0x200 int8_t STORAGE_Read_FS(uint8_t lun, uint8_t *buf, uint32_t blk_addr, uint16_t blk_len) { …
in_text
  • 9
  • 2
1
2 3