Hi Bala,
1.) 'rt' instead of 'r+' means for me, that there is some problem with character coding in the downloaded samples, e.g. '+' appeared as 't'.
2.) Maybe more characters can be interpreted false, like in #1.
3.) The BSFN have to be translated without Warnings. Please, post the Warnings, that you received at compilation
4.) Can you describe step by step, how did you created the BSFN or attach your .c and .h files?
>> "Can you give me how you guys created the text file?"
Sometimes we created with NotePad or other simple text editor for 0th test, but generaly the text file was generated by 3th party applications. We had no problem with .txt file, except a minor - with code page, what we resolved (you know, Hungarian language use special characters, e.g. á, é ,í, ó, ő, ú, ü, ű, etc.)
Regards,
Zoltán