Hi  am pavithra.

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Hi  am pavithra.

1,195 Views
pavithras
Contributor I

i am   working on mqx version 4.0.0.can we use all file functions in mqx. I am getting problem while using  fputs  function. It is working properly on linux platform  but not in mqx it is writing some junk data in to file .and  if I use fprintf or f write one extra space is coming between each character please get me the solution

Original Attachment has been moved to: ADC0.TXT.txt.zip

Labels (1)
0 Kudos
Reply
1 Reply

1,026 Views
RadekS
NXP Employee
NXP Employee

That is strange. I tested it at MQX4.0.2.2 and it works correctly.

I didn’t discover any issue in case of fputs() function and I didn’t found any change of this function in documentation.

I used mfs_usb example add here short code:

MQX_FILE_PTR in_fd=NULL;

in_fd = fopen("c:TE123", "w+");

fputs("123This is c programming.123", in_fd);

fputs("123This is a system programming language.123", in_fd);

fclose(in_fd);

content of TE123 file was: “123This is c programming.123123This is a system programming language.123”

Could you please share here your code that we could try figure out what is wrong?

I hope it helps you.

Have a great day,
RadekS

-----------------------------------------------------------------------------------------------------------------------
Note: If this post answers your question, please click the Correct Answer button. Thank you!
-----------------------------------------------------------------------------------------------------------------------

0 Kudos
Reply