Skip to content

Rucfs is a Read-only Un-Compressed File System that offers a small and compact structure to store the data. Designed for embedded microcontroller systems.

License

Notifications You must be signed in to change notification settings

TheSnowfield/rucfs

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Rucfs

Rucfs /ˈrɑːkˈɛfˈɛs/ is a Read-only Un-Compressed File System.
It provides a simple and compact structure to store data up to 4GB.

It supports regular files, nested directories, and symbolic links.
Very suit for embedded systems that pursues size and low memory. such as STM32, ESP.. etc.

badge badge

Advantages

For example, this is the Rucfs diagram of STM32F4x chips. diagram

Prepare your Rucfs image

Make sure you have installed python 3.

# Usage: mkfs.rucfs.py <directory> <output>
$ tools/mkfs.rucfs.py ./dir_to_pack/ rucfs.img

Use Rucfs on the chip

// load a rucfs image
rucfs_ctx_t ctx;
if(!rucfs_ok(rucfs_load(image, &ctx))) {
  printf("[****] Rucfs failed to load.");
  return 1;
}

// open the file
rucfs_file_t *file;
if(!rucfs_ok(rucfs_fopen(&ctx, "/hello/world.jpg", &file))) {
  printf("[****] No such file or directory.");
  return 2;
}

// the description of the file
char     *name  = file->name;
uint8_t  *data  = file->data;
uint32_t length = file->length;
printf("[ OK ] File loaded. Length %d", length);

// close the file
rucfs_fclose(file);

TODOs

  • Big Endian
  • Read/Write HAL
  • Benchmark and Tests
  • mkfs.rucfs
  • Readme diagram

License

Licensed under MIT with ❤.

Thanks

About

Rucfs is a Read-only Un-Compressed File System that offers a small and compact structure to store the data. Designed for embedded microcontroller systems.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published