Some classes and macros to enable quick single line trace and watch facilities. Three macros DBUG_INIT, TRACE & WATCH are used to implement all functions. DBUG_INIT is used to allocate the maximum number of watch items that are to be displayed at any time. The remainder of the VT100 emulation screen will be dedicated to the scrolling trace function. The use of macros means that they will be ignored by the compiler when the debug declaration is removed. To assist in formatting the string output I have implemented a caret field that is interpreted as a screen attribute eg ^R reverse video on ^r reverse video off. Look at the VT100 class for further details. This was completed for a rush project about 10 minutes ago so expect a few issues to become apparent.

Dependencies:   mbed

Committer:
ChrisHatfield
Date:
Mon Jan 04 23:25:20 2010 +0000
Revision:
0:0c4137d26c2e

        

Who changed what in which revision?

UserRevisionLine numberNew contents of line
ChrisHatfield 0:0c4137d26c2e 1 #include "Config.h"
ChrisHatfield 0:0c4137d26c2e 2
ChrisHatfield 0:0c4137d26c2e 3 long RemoteFunction(const long Arg)
ChrisHatfield 0:0c4137d26c2e 4 {
ChrisHatfield 0:0c4137d26c2e 5 TRACE("Remote Function Arg %6ld\n\r", Arg);
ChrisHatfield 0:0c4137d26c2e 6 long lReturn(Arg ^ 0x55AAAA & 0xFFFFFF);
ChrisHatfield 0:0c4137d26c2e 7 WATCH("Remote Funtion Return %8ld", lReturn);
ChrisHatfield 0:0c4137d26c2e 8 return lReturn;
ChrisHatfield 0:0c4137d26c2e 9 }