2012-01-03 12:29 AM
Hi everybody,
i work with the evalboard STM3220G with the USB example from the USB host-device lib. I try to write additional data in the create/existing file, but I'm not successful. Can anyone say me, what i must chance to solve that problem?2012-01-03 02:20 AM
hi stephan,
if you want to write additional data the created file, you want to take care of certain things. in the file ''usbh_usr.c'' line no. 623, //------------------------------------------ /* Write buffer to file */ file_write(&file, 50, textFileBuffer); //---------------------------------------- Here you have to change the file size from 50 to your desired value. Also you have to add the required data inside the textFileBuffer.2012-01-03 02:46 AM
Thx for your reply pila,
but maybe you understand me wrong, i don't want to write the data at once. I want to make something like a data logging. I have to open the existing file and add some new data.2012-01-03 03:19 AM
ok..got it.
presently such option is not there in the example. But I think it can be implemented by playing a bit with file system. you can use the function ''file_setpos'' from file.c in EFSL. Let me know if it helps????2012-01-03 03:46 AM
I can't find either such a file nor this function....
Maybe we er talking about two different examples?? I download the USB Host and Device library (UM1021) from the ST-page.2012-01-03 04:20 AM
You are dealing with USB host example or device example??
2012-01-03 04:27 AM
Host example for MSC
2012-01-03 10:34 PM
OK.. So EFSL is not there in your example. FAT_FS is there.
Lemme chk then wht options are there to append a file in FAT_FS. There should be some in ff.c.2012-01-05 02:50 AM
Thx for your hint pila,
i try to modify it, but it's my first USB-project an di'm a bit confused... Can u give me some details??2012-01-05 09:15 PM
Can u plz let me know what exactly you modified???