I want to write the log into text file and save to device memory, since when the app will be crashed than i can tell the client to email the same file