2 ## This file is part of the libsigrokdecode project.
4 ## Copyright (C) 2015 Uwe Hermann <uwe@hermann-uwe.de>
6 ## This program is free software; you can redistribute it and/or modify
7 ## it under the terms of the GNU General Public License as published by
8 ## the Free Software Foundation; either version 2 of the License, or
9 ## (at your option) any later version.
11 ## This program is distributed in the hope that it will be useful,
12 ## but WITHOUT ANY WARRANTY; without even the implied warranty of
13 ## MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 ## GNU General Public License for more details.
16 ## You should have received a copy of the GNU General Public License
17 ## along with this program; if not, write to the Free Software
18 ## Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
21 # Dict which maps command IDs to their names and descriptions.
23 0x06: ('WREN', 'Write enable'),
24 0x04: ('WRDI', 'Write disable'),
25 0x9f: ('RDID', 'Read identification'),
26 0x05: ('RDSR', 'Read status register'),
27 0x01: ('WRSR', 'Write status register'),
28 0x03: ('READ', 'Read data'),
29 0x0b: ('FAST/READ', 'Fast read data'),
30 0xbb: ('2READ', '2x I/O read'),
31 0x20: ('SE', 'Sector erase'),
32 0xd8: ('BE', 'Block erase'),
33 0x60: ('CE', 'Chip erase'),
34 0xc7: ('CE2', 'Chip erase'), # Alternative command ID
35 0x02: ('PP', 'Page program'),
36 0xad: ('CP', 'Continuously program mode'),
37 0xb9: ('DP', 'Deep power down'),
38 0xab: ('RDP/RES', 'Release from deep powerdown / Read electronic ID'),
39 0x90: ('REMS', 'Read electronic manufacturer & device ID'),
40 0xef: ('REMS2', 'Read ID for 2x I/O mode'),
41 0xb1: ('ENSO', 'Enter secured OTP'),
42 0xc1: ('EXSO', 'Exit secured OTP'),
43 0x2b: ('RDSCUR', 'Read security register'),
44 0x2f: ('WRSCUR', 'Write security register'),
45 0x70: ('ESRY', 'Enable SO to output RY/BY#'),
46 0x80: ('DSRY', 'Disable SO to output RY/BY#'),
57 'macronix_mx25l1605d': {
59 'model': 'MX25L1605D',
65 'sector_size': 4 * 1024,
66 'block_size': 64 * 1024,
68 'macronix_mx25l3205d': {
70 'model': 'MX25L3205D',
76 'sector_size': 4 * 1024,
77 'block_size': 64 * 1024,
79 'macronix_mx25l6405d': {
81 'model': 'MX25L6405D',
87 'sector_size': 4 * 1024,
88 'block_size': 64 * 1024,