Sometimes we need to store/access data from external storage devices in our mobile apps. But before storing or accessing data we can check whether the storage device (SD card) is present or not. Using titanium, easily we can verify that.
//Ti.Filesystem.isExternalStoragePresent();
//Returns boolean value
//Check external storage
if(Ti.Filesystem.isExternalStoragePresent()){
//Do the read/write operation on file from sd card.