PSoC Creator supports __DATE__ and __TIME__ preprocessor macros. You can use them to obtain the compilation date and time.
Thank you GeonaM_26!
Sure enough, this works:
DBG_PRINTF("\n%s %s", __DATE__, __TIME__);
I went to find the address of these string constants and this works too.
DBG_PRINTF("%p\n", (void*) __DATE__); //Prints address of string constant
DBG_PRINTF("%p\n", (void*) __TIME__);
I used the memory viewer and they were there in flash.
Another question: Where are these string constants documented?
They don't seem to be defined anywhere. I wonder what else I am missing.
That is so cool. I had no idea. Live and learn.