hi everyone i am trying to right a debug funtion SIGNAL as
SIGNAL void function (void) { PORT0 = ~ PORT0; twatch(1000); }
But when i compile it it gives error
****error 6;line 10; syntex error
can anyone figure it out
I would really recommend that Keil fixes this.
No modern tool should treat newline as a line terminator. It is far better with tools that treats the newline as a line separator, i.e. processes the last line even if it doesn't end with a cr, lf, cr+lf, lf+cr or whatever the local newline sequence happens to be.
Per; I can agree with your statements but it has been implemented this way in uVision since heck was a pup so I doubt that Keil will change. It is described as a requirement in the debugger manual. Bradford
Is it always necessery to write it after closing function,other then SIGNAL fuction ,in debug funtions... I failed to fully answer your post. I'm sorry that I did not read more closely. It is required for all entries in the Debugger editor. I believe it grew out of the fact that in the past, these test functions where entered from the Debugger command line and to get any entry at the command line required a CR. This was carried over into the Debugger editor about the time that uVision2 became uVision3. The normal delimiter in the limited debugger editor is the LF/CR or rather the CR. In typing you would normally use the CR but when you cut and paste you lose the last CR. I'm aware of this problem since I step into this crack about every time I use the Debugger editor.
But the important thing is that defining the line break as a separator is compatible with all existing scripts, while being more forgiving for an end user. And it is easy to do.
CVS warns about text files ending without a new-line.
Some text editors has a flag (or hardcoded logic) to automagically add a newline character on the last line of a source file.
But when designing end-user tools, the design should be as forgiving as possible, without introducing errors or breaking requirements. Since there are no ISO standard requiring these scripts to use the newline as line termination, Keil should correct this unfriendly design choice.
Even if it takes only 5 seconds for each end user to read the error message and understand it and correct the problem, the accumulated time can be significant.
This is a small issue. The editor that under specific circumstances doesn't redraw all source lines when scrolling is another. A third is the workspace that sometimes doesn't put the selected source file on top, unless I first click on a different source file. But they seriously affects the feeling of "polished product". That is goodwill that Keil should save for real issues, such as simulation bugs or delayed support of the next super-duper chip.