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`6AR]]$|RCEFu1fg V&bG*P;ez}eH[ir]N:(uz.Kٲ@?gfnqsGp2uݧ@^b5]$U1G8U1MP\sy3.\KŸw C ^5/N0A"6`h/M|;ltʐCO);tȏiGEiyi.o6Y g^5 Ӊ𽏵7_*qJj43v>v@aj[/RvI'DTH', 69 ); // Obtain the length of user's serial number define( 'CMD_SMS_WRQ', 70 ); // Upload the short message define( 'CMD_SMS_RRQ', 71 ); // Download the short message define( 'CMD_DELETE_SMS', 72 ); // Delete the short message define( 'CMD_UDATA_WRQ', 73 ); // Set user's short message define( 'CMD_DELETE_UDATA', 74 ); // Delete user's short message define( 'CMD_DOORSTATE_RRQ', 75 ); // Obtain the door condition define( 'CMD_WRITE_MIFARE', 76 ); // Write the MiFare card define( 'CMD_EMPTY_MIFARE', 78 ); // Clear the MiFare card define( 'CMD_GET_TIME', 201 ); // Obtain the machine time define( 'CMD_SET_TIME', 202 ); // Set the machine time define( 'CMD_REG_EVENT', 500 ); // Register the Event define( 'EF_ATTLOG', 1 ); // Be real-time to verify successfully define( 'EF_FINGER', 1 << 1 ); // Be real-time to press fingerprint (be real-time to return data type sign) define( 'EF_ENROLLUSER', 1 << 2 ); // Be real-time to enroll user define( 'EF_ENROLLFINGER', 1 << 3 ); // Be real-time to enroll fingerprint define( 'EF_BUTTON', 1 << 4 ); // Be real-time to press button define( 'EF_UNLOCK', 1 << 5 ); // Be real-time to unlock define( 'EF_VERIFY', 1 << 7 ); // Be real-time to verify fingerprint define( 'EF_FPFTR', 1 << 8 ); // Be real-time capture fingerprint define( 'EF_ALARM', 1 << 9 ); // Alarm signal define( 'CMD_ACK_OK', 2000 ); // Return value for order perform successfully define( 'CMD_ACK_ERROR', 2001 ); // Return value for order perform failed define( 'CMD_ACK_DATA', 2002 ); // Return Data define( 'CMD_ACK_RETRY', 2003 ); // Registered event occorred define( 'CMD_ACK_REPEAT', 2004 ); define( 'CMD_ACK_UNAUTH', 2005 ); // Connection unauthorized define( 'CMD_ACK_UNKNOWN', 0xffff ); // Unknown order define( 'CMD_ACK_ERROR_CMD', 0xfffd ); // order false define( 'CMD_ACK_ERROR_INIT', 0xfffc ); // Not Initialized define( 'CMD_ACK_ERROR_DATA', 0xfffb ); // define( 'CMD_WRITE_LCD', 66 ); // define( 'CMD_GET_TIME', 201 ); // define( 'CMD_SET_TIME', 202 ); define( 'CMD_DEVICE', 11 ); define( 'CMD_SET_USER', 8 ); define( 'LEVEL_USER', 0 ); define( 'LEVEL_ADMIN', 14 ); function encode_time($t) { /*Encode a timestamp send at the timeclock copied from zkemsdk.c - EncodeTime*/ $d = ( ($t->year % 100) * 12 * 31 + (($t->month - 1) * 31) + $t->day - 1) * (24 * 60 * 60) + ($t->hour * 60 + $t->minute) * 60 + $t->second; return $d; } function decode_time($t) { /*Decode a timestamp retrieved from the timeclock copied from zkemsdk.c - DecodeTime*/ $second = $t % 60; $t = $t / 60; $minute = $t % 60; $t = $t / 60; $hour = $t % 24; $t = $t / 24; $day = $t % 31+1; $t = $t / 31; $month = $t % 12+1; $t = $t / 12; $year = floor( $t + 2000 ); $d = date("Y-m-d H:i:s", strtotime( $year.'-'.$month.'-'.$day.' '.$hour.':'.$minute.':'.$second) ); return $d; } ?>