Hi all, i need to read data from a text file and write in keil µvision program. How to open file, read, write and close file works in µvision programs. Thanking you,
I'm not sure, if it's useful, but in my µVision there is in the File menu an option Open to read and an option Save for writing Textfiles. ;-)
"in my µVision there is in the File menu an option Open to read and an option Save for writing Textfiles." That would open a file in an editor window, and save the text from an editor window to a file. Hence my initial questions: What do you want uVision to do with the data that it reads? What data from uVision do you wnat to write to the file?
in µvision there is no transmitt mode, but we r developing a project in that we make a transmitt mode, so for that user has to set receivers address in VC GUI, so we are saving this seleted data in a .txt file, so now we need that µvision program has to read the data in .txt file. how can i do this. thanking you
"in µvision there is no transmitt mode, but we r developing a project in that we make a transmitt mode" So this is for the uVision Simulator, then?
Hi its not a µvision simulator, i dont have much idea in µvision programming,i want how to read and write data from .txt file , if u have any idea please tell me.thanking you
"its not a µvision simulator" No - I don't mean something that simulates uVision. uVision includes a simulator that allows you to run embedded code on the PC without an actual embedded processor or target hardware. Are you making something to use with embedded code that is running in the Simulator in uVision? "i dont have much idea in µvision programming" That is clear! That is why I suggested that you get your embedded guy(s) to continue this discussion! It is very difficult to understand what you actually want to do, as everything is being obscured by the lack of understanding of what uVision is and does.
"but we r developing a project in that we make a transmitt mode" What will be transmitted? From where? By what? What is your "transmitter" code - on what target platform will it run?
uVision can read and write files with OPEN/SAVE from the file menu. In AGSI-DLLs you can do everything too. But this works only inside the simulator. Good luck.
"uVision can read and write files with OPEN/SAVE from the file menu." Yes - but, as already noted, that just opens the file in an editor window.
Do you want to compile this file? If so have your GUI create a C file (or header) with the correct data, then save it to the uP folder. "What we have here is a failure to Comunicate"
"have your GUI create a C file (or header) with the correct data" Yes - I have already suggested that twice! "What we have here is a failure to Comunicate" Absolutely! There appear to be 3 issues here: 1. The OP, by his own admission, is not an embedded developer, and knows nothing about embedded development; 2. The OP, by his own admission, knows nothing about uVision - what it is, what it does nor how to use it; 3. We are trying to discuss all this in a foreign language! None of this is a criticism of the OP - it just makes communication almost impossible! This is why I've suggested a couple of times that he gets his embedded developer(s) to describe what's going on - then they might be able to describe the real requirement, and we might be able to come up with a spec for the GUI that a VC developer could understand. As it stands, I'm still not convinced that the OP understands the difference between uVision & what it does on the PC, and the actual embedded application running on the target hardware - I'm not sure that he really wants compile-time configuration, rather than a run-time user interface... Maybe your fresh set of ears can understand him better than mine?
Hi , sorry that i opened another thread, i wanted to say that i need to use Read, and write .txt,.xml files in C51 programs. Thanking you.
"i need to use Read, and write .txt,.xml files in C51 programs." Are we still talking about files created by your PC-based GUI? Remember: C51 programs run on 8051 processors in embedded hardware - they do not run on PCs! Therefore, before doing any file operations in a C51 program, you will have to implement a file system on the embedded target hardware! Part of implementing the file system will be to provide the necessary functions to read & write files. Once you have implemented your file system on your embedded target hardware, you will also have to figure out a way to get the files generated on your PC by your GUI from the PC and onto your embedded target hardware. I don't think you really want to do that, do you??! You still haven't said why you can't have your GUI generate a 'C' source file...