SW500008 Microchip Technology, SW500008 Datasheet - Page 183

PICC-18 STD

SW500008

Manufacturer Part Number
SW500008
Description
PICC-18 STD
Manufacturer
Microchip Technology
Type
Compilerr
Series
PIC18r
Datasheets

Specifications of SW500008

Supported Families
PIC18
Core Architecture
PIC
Software Edition
Standard
Kit Contents
Software And Docs
Mcu Supported Families
PIC18
Tool Function
Compiler
Tool Type
Compiler
Lead Free Status / RoHS Status
Not applicable / RoHS Compliant
For Use With/related Products
PIC18 Series
Lead Free Status / Rohs Status
Lead free / RoHS Compliant
Other names
015
778-1001
778-1001
Library Functions
ASCTIME
Synopsis
Description
The asctime() function takes the time broken down into the struct tm structure, pointed to by its
argument, and returns a 26 character string describing the current date and time in the format:
example gets the current time, converts it to a struct tm pointer with localtime(), it then converts
this to ASCII and prints it. The time() function will need to be provided by the user (see time() for
details).
Example
See Also
ctime(), gmtime(), localtime(), time()
Sun Sep 16 01:03:52 1973\n\0
Note the newline at the end of the string. The width of each field in the string is fixed. The
#include <time.h>
char * asctime (struct tm * t)
#include <stdio.h>
#include <time.h>
void
main (void)
{
}
time_t clock;
struct tm * tp;
time(&clock);
tp = localtime(&clock);
printf("%s", asctime(tp));
169

Related parts for SW500008