The maximum size for a FAT32 directory is 65536 32bit entries. A file will require at least 2 entries depending on the length of the filename. Long filenames are stored in 16bit UNICODE characters and only thirteen characters are stored per directory entry.
Large directories should be avoided for performance reasons. For example, adding a file requires all existing entries to be scanned to avoid duplicates.
The FAT32 specification can be downloaded here:
http://msdn.microsoft.com/en-us/windows/hardware/gg463080.aspx