-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathbinformat
64 lines (49 loc) · 1.13 KB
/
binformat
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
512k eeprom.
32,000-2 cards
1k eeprom
64-2 cards
first 32 bytes of eeprom. [byte] unless otherwise specified. [#:] # bits.
card params.
[site start][site len][id start][id len]
[par type][par bit][par start][par end]
[par2 type][par2 bit][par2 start][par2 end]
open hours and config.
[ignore par][ignore site][ignore id][rsvd]
[rsvd]
[open door entry 1-2 (same format as hours info)]
[open door entry 3-4 (same format as hours info)]
id info 8 bytes.
[magic 'r'][ site 2 bytes ][ id 5 bytes]
hours info 8 bytes. 4 ranges. 4 bits hour 2 bits minute. granularity of 30 min.
entry is 2 bytes.
[4:day][6:s][6:e][4:day][6:s][6:e]
[4:day][6:s][6:e][4:day][6:s][6:e]
day bytes.
0000 no record.
1111 no record
0001 weekday
0010 weekend
0011 mon
0100 tues
0101 wed
0110 thurs
0111 fri
1000 sat
1001 sun
1010 every day
5 bits hour
00000 0:00
00001 1:00
00010 2:00
00011 3:00
...
11000 24:00
1 bit minute
0 :00
1 :30
example: 010010 5:00pm
full record (16 bits 2 bytes)
0001 (weekday) 010001 (8:30am) 010010 (5:00pm)
0010 (weekend) 000000 (12am) 11000(11:59pm)
00010100 01010010 00100000 00110000
00000000 00000000 00000000 00000000