Argox PA-20 Programming Guide Manuale Utente Pagina 32

  • Scaricare
  • Aggiungi ai miei manuali
  • Stampa
  • Pagina
    / 130
  • Indice
  • SEGNALIBRI
  • Valutato. / 5. Basato su recensioni clienti
Vedere la pagina 31
PT-20 Programming Guide
30
Calender
DayOfWeek
Purpose
Get the day of the week information.
Syntax
int DayOfWeek(void);
Example call
day=DayOfWeek( );
Includes
#include “SDK.h ”
Description
The DayOfWeek function returns the day of week information based on
current date.
Returns
The DayOfWeek function returns an integer indicating the day of week
information. A value of 1 to 6 represents Monday to Saturday accordingly.
And a value of 7 indicates Sunday.
get_time
Purpose
Get current date and time
Syntax
int get_time(char *cur_time);
Example call
char system_time[16];
get_time(system_time);
Includes
#include “SDK.h ”
Description
The get_time function reads current date and time from the calendar
chip and copies them to a character array specified in the argument
cur_time. The character array cur_time allocated must have a
minimum of 15 bytes to accommodate the date, time, and the string
terminator. The format of the system date and time is listed below.
"YYYYMMDDhhmmss"
YYYY
year, 4 digits
MM
month, 2 digits
DD
day, 2 digits
hh
hour, 2 digits
mm
minute, 2 digits
ss
second, 2 digits
Returns
Normally the get_time function always returns an integer value of 0. If the
calendar chip malfunctions, the get_time function will then return 1 to
indicate error.
set_time
Purpose
Set new date and time to the calendar chip.
Vedere la pagina 31
1 2 ... 27 28 29 30 31 32 33 34 35 36 37 ... 129 130

Commenti su questo manuale

Nessun commento