SW500009 Microchip Technology, SW500009 Datasheet - Page 179

HI-TECH FOR DSPIC/PIC24

SW500009

Manufacturer Part Number
SW500009
Description
HI-TECH FOR DSPIC/PIC24
Manufacturer
Microchip Technology
Type
Compilerr
Series
PIC24 & DsPICr
Datasheet

Specifications of SW500009

Supported Families
PIC24
Core Architecture
PIC, DsPIC
Software Edition
Standard
Kit Contents
Software And Docs
Tool Type
Compiler
Mcu Supported Families
PIC24 MCUs And DsPIC DSCs
Lead Free Status / RoHS Status
Not applicable / RoHS Compliant
For Use With/related Products
DSPIC3X/PIC24
Lead Free Status / Rohs Status
Lead free / RoHS Compliant
Other names
025
778-1003
778-1003
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));
165

Related parts for SW500009