Well, “clicking” isn’t a very precise description of what is happening, so there is a multitude of possible reasons for it, however, one of the most common is that the SD card is simply too slow. SD cards are made for high average speed, but what ProffieOS actually needs is reasonable speed for every block. As SD cards age, more read errors occur, these read errors can almost always be corrected, so no data is lost, but the error correction can end up taking extra time when reading.
When this happens too much, or the delay is too large, underflow occurs, and when those are detected, they are printed out in the serial monitor. One thing that can contribute to overflows is that every time ProffieOS has to open a new file, it has to read several blocks to find it. The more blocks it has to read, the bigger the chance of an underflow.
An SD card block has 512 bytes in it. A FAT32 directory entry requires 32 bytes. That means that you can only fit 16 directory entries in a single block. FAT32 directories are basically just files that contain directory entries, so searching a directory for a file means opening the file and reading until you find it. So, if you’re looking for a file called “font1/clash/clash00.wav”, then you first have to open up the root directory, read until you find the “font1” entry, then open up that directory, read until you find “clash” and then open up that entry and read until you find “clash00.wav”, and then you have to open up that entry to actually read data, so at least 4 reads.
If “font1” is the 17th entry in the root directory, then it’s 5 reads. If “clash” is the 17th entry in the “font1” directory, then that also adds a read.
One thing that makes all of this worse is long filenames. FAT32 only has room for 11 (8+3) characters per directory entry, and when you use filenames that doesn’t fit, it some special magic that uses multiple directory entries to store the name.
When you delete a file or directory on a FAT32 filesystem, directory files are not shrunk, instead the directory entry that had that file/folder is marked as deleted and it’s re-used next time you create a new file or directory. So if “font1” is the 17th entry in the root directory, it will still be the 17th entry even if you delete all the other files and folders in the root directory.
When there are no “free” directory entries (created by deleting something) then new directory entries are added at the end. This generally means that if you add the fonts to the SD card first, you can add as many files as you want after that, and it won’t affect the performance at all. Another way to minimize performance impact is to create a single directory in the root, and then stick anything that ProffieOS doesn’t need in that directory. Regardless of how much stuff you put in that directory, it will still only be one directory entry.