arrange callback in read_dir for future use

Custom callback is called for every file or directory listed on device. This will be used for file download.