CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

Date & Time Stamp

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
newpic



Joined: 09 Aug 2005
Posts: 32

View user's profile Send private message

Date & Time Stamp
PostPosted: Tue Aug 09, 2005 2:19 pm     Reply with quote

How to have date and time stamp to work?
I use it exactly on the CCS manual on page 36 & 57 and it does not work.

Anybody knows how to use it?

Here is my code:

Code:

#include<16F877.h>


void main()
{

    while(1)
    {
       printf("The date is time is:  ");
       printf(_DATE_);
       printf(_TIME_);
    }
}

     


compile error as follow:

Quote:
Executing: "C:\Program Files\PICC\Ccsc.exe" "adc.c" +FM +DF +LN +T -A +M +Z +Y=9 +EA
>>> Warning 203 "C:\PICC\PCM\adc.c" Line 31(1,1): Condition always TRUE
*** Error 12 "C:\PICC\PCM\adc.c" Line 43(9,15): Undefined identifier _TIME_
1 Errors, 1 Warnings.
Halting build on first failure as requested.
BUILD FAILED: Tue Aug 09 15:51:35 2005
Ttelmah
Guest







PostPosted: Tue Aug 09, 2005 2:35 pm     Reply with quote

Two underbar characters each side of the declarations, not one.

Best Wishes
languer



Joined: 09 Jan 2004
Posts: 144
Location: USA

View user's profile Send private message

PostPosted: Wed Aug 10, 2005 12:14 am     Reply with quote

Check the following links, they give some pretty clever ideas.

Embedding build numbers

Handy Firmware Revision trick

Smile
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group