~ubuntu-branches/ubuntu/utopic/libfprint/utopic

« back to all changes in this revision

Viewing changes to libfprint/drivers/aes2550.h

  • Committer: Package Import Robot
  • Author(s): Didier Raboud
  • Date: 2013-05-18 16:35:39 UTC
  • mfrom: (4.1.4 experimental)
  • Revision ID: package-import@ubuntu.com-20130518163539-qvwsan4edkdtry6f
Tags: 1:0.5.0-5
* Upload to unstable with two more backports from upstream:
  - imgdev: fix cancelling of enrollment from stage_completed callback
  - upeke2: Add support for 147e:2020 ID

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/*
 
2
 * AuthenTec AES2550/AES2810 driver for libfprint
 
3
 * Copyright (C) 2012 Vasily Khoruzhick
 
4
 *
 
5
 * This library is free software; you can redistribute it and/or
 
6
 * modify it under the terms of the GNU Lesser General Public
 
7
 * License as published by the Free Software Foundation; either
 
8
 * version 2.1 of the License, or (at your option) any later version.
 
9
 *
 
10
 * This library is distributed in the hope that it will be useful,
 
11
 * but WITHOUT ANY WARRANTY; without even the implied warranty of
 
12
 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
 
13
 * Lesser General Public License for more details.
 
14
 *
 
15
 * You should have received a copy of the GNU Lesser General Public
 
16
 * License along with this library; if not, write to the Free Software
 
17
 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA
 
18
 */
 
19
 
 
20
#ifndef __AES2550_H
 
21
#define __AES2550_H
 
22
 
 
23
/* Registers bits */
 
24
 
 
25
#define AES2550_REG80_MASTER_RESET              (1 << 0)
 
26
#define AES2550_REG80_FORCE_FINGER_PRESENT      (1 << 1)
 
27
#define AES2550_REG80_LPO_START                 (1 << 2)
 
28
#define AES2550_REG80_HGC_ENABLE                (1 << 3)
 
29
#define AES2550_REG80_SENSOR_MODE_OFS           (4)
 
30
#define AES2550_REG80_AUTO_RESTART_FD           (1 << 6)
 
31
#define AES2550_REG80_EXT_REG_ENABLE            (1 << 7)
 
32
 
 
33
#define AES2550_REG81_CONT_SCAN                 (1 << 0)
 
34
#define AES2550_REG81_READ_REG                  (1 << 1)
 
35
#define AES2550_REG81_NSHOT                     (1 << 2)
 
36
#define AES2550_REG81_RUN_FD                    (1 << 3)
 
37
#define AES2550_REG81_READ_ID                   (1 << 4)
 
38
#define AES2550_REG81_RUN_CAL                   (1 << 5)
 
39
#define AES2550_REG81_RUN_TIMER                 (1 << 6)
 
40
#define AES2550_REG81_RUN_BIST                  (1 << 7)
 
41
 
 
42
#define AES2550_REG83_FINGER_PRESENT            (1 << 7)
 
43
 
 
44
#define AES2550_REG85_FLUSH_PER_FRAME           (1 << 7)
 
45
 
 
46
#define AES2550_REG8F_EDATA_DISABLE             (1 << 1)
 
47
#define AES2550_REG8F_AUTH_DISABLE              (1 << 2)
 
48
#define AES2550_REG8F_EHISTO_DISABLE            (1 << 3)
 
49
#define AES2550_REG8F_HISTO64                   (1 << 4)
 
50
#define AES2550_REG8F_SINGLE_REG_ENABLE         (1 << 6)
 
51
 
 
52
#define AES2550_REG95_COL_SCANNED_OFS           (0)
 
53
#define AES2550_REG95_EPIX_AVG_OFS              (4)
 
54
 
 
55
#define AES2550_REGA8_DIG_BIT_DATA_OFS          (0)
 
56
#define AES2550_REGA8_DIG_BIT_EN                (1 << 4)
 
57
#define AES2550_REGA8_FIXED_BIT_DATA            (1 << 5)
 
58
#define AES2550_REGA8_INVERT_BIT_DATA           (1 << 6)
 
59
 
 
60
#define AES2550_REGAD_LPFD_AVG_OFS              (0)
 
61
#define AES2550_REGAD_DETECT_FGROFF             (1 << 4)
 
62
#define AES2550_REGAD_ADVRANGE_2V               (1 << 6)
 
63
 
 
64
#define AES2550_REGB1_ATE_CONT_IMAGE            (1 << 1)
 
65
#define AES2550_REGB1_ANALOG_RESET              (1 << 2)
 
66
#define AES2550_REGB1_ANALOG_PD                 (1 << 3)
 
67
#define AES2550_REGB1_TEST_EMBD_WORD            (1 << 4)
 
68
#define AES2550_REGB1_ORIG_EMBD_WORD            (1 << 5)
 
69
#define AES2550_REGB1_RESET_UHSM                (1 << 6)
 
70
#define AES2550_REGB1_RESET_SENSOR              (1 << 7)
 
71
 
 
72
#define AES2550_REGBD_LPO_IN_15_8_OFS           (0)
 
73
#define AES2550_REGBE_LPO_IN_7_0_OFS            (0)
 
74
 
 
75
#define AES2550_REGBF_RSR_LEVEL_DISABLED        (0 << 0)
 
76
#define AES2550_REGBF_RSR_LEVEL_LEADING_RSR     (1 << 0)
 
77
#define AES2550_REGBF_RSR_LEVEL_SIMPLE_RSR      (2 << 0)
 
78
#define AES2550_REGBF_RSR_LEVEL_SUPER_RSR       (3 << 0)
 
79
#define AES2550_REGBF_RSR_DIR_DOWN_MOTION       (0 << 2)
 
80
#define AES2550_REGBF_RSR_DIR_UP_MOTION         (1 << 2)
 
81
#define AES2550_REGBF_RSR_DIR_UPDOWN_MOTION     (2 << 2)
 
82
#define AES2550_REGBF_NOISE_FLOOR_MODE          (1 << 4)
 
83
#define AES2550_REGBF_QUADRATURE_MODE           (1 << 5)
 
84
 
 
85
#define AES2550_REGCF_INTERFERENCE_CHK_EN       (1 << 0)
 
86
#define AES2550_REGCF_INTERFERENCE_AVG_EN       (1 << 1)
 
87
#define AES2550_REGCF_INTERFERENCE_AVG_OFFS     (4)
 
88
 
 
89
#define AES2550_REGDC_BP_NUM_REF_SWEEP_OFS      (0)
 
90
#define AES2550_REGDC_DEBUG_CTRL2_OFS           (3)
 
91
 
 
92
#define AES2550_REGDD_DEBUG_CTRL1_OFS           (0)
 
93
 
 
94
/* Commands */
 
95
 
 
96
enum aes2550_cmds {
 
97
        AES2550_CMD_SET_IDLE_MODE = 0x00,
 
98
        AES2550_CMD_RUN_FD = 0x01,
 
99
        AES2550_CMD_GET_ENROLL_IMG = 0x02,
 
100
        AES2550_CMD_CALIBRATE = 0x06,
 
101
        AES2550_CMD_READ_CALIBRATION_DATA = 0x10,
 
102
        AES2550_CMD_HEARTBEAT = 0x70,
 
103
};
 
104
 
 
105
/* Messages */
 
106
 
 
107
#define AES2550_STRIP_SIZE              (0x31e + 3)
 
108
#define AES2550_HEARTBEAT_SIZE          (4 + 3)
 
109
#define AES2550_EDATA_MAGIC             0xe0
 
110
#define AES2550_HEARTBEAT_MAGIC         0xdb
 
111
 
 
112
#define AES2550_EP_IN_BUF_SIZE          8192
 
113
 
 
114
#endif