From 7a74f9709f772a7743a36e9fb30d42607383d41b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?King=20K=C3=A9vin?= Date: Wed, 10 Mar 2021 14:12:31 +0100 Subject: [PATCH] add SWD library --- lib/jep106.inc | 1416 ++++++++++++++++++++++++++++++++++++++++++++++++ lib/swd.c | 324 +++++++++++ lib/swd.h | 197 +++++++ 3 files changed, 1937 insertions(+) create mode 100644 lib/jep106.inc create mode 100644 lib/swd.c create mode 100644 lib/swd.h diff --git a/lib/jep106.inc b/lib/jep106.inc new file mode 100644 index 0000000..76e6137 --- /dev/null +++ b/lib/jep106.inc @@ -0,0 +1,1416 @@ +/* + * Should be autogenerated with update_jep106.pl but latest + * file from JEDEC is only available in PDF form. The PDF + * also breaks the pdftotext flow due to embedded watermarks. + * Created with a mix of scripts and manual editing. + */ +[0][0x01 - 1] = "AMD", +[0][0x02 - 1] = "AMI", +[0][0x03 - 1] = "Fairchild", +[0][0x04 - 1] = "Fujitsu", +[0][0x05 - 1] = "GTE", +[0][0x06 - 1] = "Harris", +[0][0x07 - 1] = "Hitachi", +[0][0x08 - 1] = "Inmos", +[0][0x09 - 1] = "Intel", +[0][0x0a - 1] = "I.T.T.", +[0][0x0b - 1] = "Intersil", +[0][0x0c - 1] = "Monolithic Memories", +[0][0x0d - 1] = "Mostek", +[0][0x0e - 1] = "Freescale (Motorola)", +[0][0x0f - 1] = "National", +[0][0x10 - 1] = "NEC", +[0][0x11 - 1] = "RCA", +[0][0x12 - 1] = "Raytheon", +[0][0x13 - 1] = "Conexant (Rockwell)", +[0][0x14 - 1] = "Seeq", +[0][0x15 - 1] = "NXP (Philips)", +[0][0x16 - 1] = "Synertek", +[0][0x17 - 1] = "Texas Instruments", +[0][0x18 - 1] = "Toshiba", +[0][0x19 - 1] = "Xicor", +[0][0x1a - 1] = "Zilog", +[0][0x1b - 1] = "Eurotechnique", +[0][0x1c - 1] = "Mitsubishi", +[0][0x1d - 1] = "Lucent (AT&T)", +[0][0x1e - 1] = "Exel", +[0][0x1f - 1] = "Atmel", +[0][0x20 - 1] = "STMicroelectronics", +[0][0x21 - 1] = "Lattice Semi.", +[0][0x22 - 1] = "NCR", +[0][0x23 - 1] = "Wafer Scale Integration", +[0][0x24 - 1] = "IBM", +[0][0x25 - 1] = "Tristar", +[0][0x26 - 1] = "Visic", +[0][0x27 - 1] = "Intl. CMOS Technology", +[0][0x28 - 1] = "SSSI", +[0][0x29 - 1] = "MicrochipTechnology", +[0][0x2a - 1] = "Ricoh Ltd", +[0][0x2b - 1] = "VLSI", +[0][0x2c - 1] = "Micron Technology", +[0][0x2d - 1] = "SK Hynix", +[0][0x2e - 1] = "OKI Semiconductor", +[0][0x2f - 1] = "ACTEL", +[0][0x30 - 1] = "Sharp", +[0][0x31 - 1] = "Catalyst", +[0][0x32 - 1] = "Panasonic", +[0][0x33 - 1] = "IDT", +[0][0x34 - 1] = "Cypress", +[0][0x35 - 1] = "DEC", +[0][0x36 - 1] = "LSI Logic", +[0][0x37 - 1] = "Zarlink (Plessey)", +[0][0x38 - 1] = "UTMC", +[0][0x39 - 1] = "Thinking Machine", +[0][0x3a - 1] = "Thomson CSF", +[0][0x3b - 1] = "Integrated CMOS (Vertex)", +[0][0x3c - 1] = "Honeywell", +[0][0x3d - 1] = "Tektronix", +[0][0x3e - 1] = "Oracle Corporation", +[0][0x3f - 1] = "Silicon Storage Technology", +[0][0x40 - 1] = "ProMos/Mosel Vitelic", +[0][0x41 - 1] = "Infineon (Siemens)", +[0][0x42 - 1] = "Macronix", +[0][0x43 - 1] = "Xerox", +[0][0x44 - 1] = "Plus Logic", +[0][0x45 - 1] = "Western Digital Technologies Inc", +[0][0x46 - 1] = "Elan Circuit Tech.", +[0][0x47 - 1] = "European Silicon Str.", +[0][0x48 - 1] = "Apple Computer", +[0][0x49 - 1] = "Xilinx", +[0][0x4a - 1] = "Compaq", +[0][0x4b - 1] = "Protocol Engines", +[0][0x4c - 1] = "SCI", +[0][0x4d - 1] = "Seiko Instruments", +[0][0x4e - 1] = "Samsung", +[0][0x4f - 1] = "I3 Design System", +[0][0x50 - 1] = "Klic", +[0][0x51 - 1] = "Crosspoint Solutions", +[0][0x52 - 1] = "Alliance Semiconductor", +[0][0x53 - 1] = "Tandem", +[0][0x54 - 1] = "Hewlett-Packard", +[0][0x55 - 1] = "Integrated Silicon Solutions", +[0][0x56 - 1] = "Brooktree", +[0][0x57 - 1] = "New Media", +[0][0x58 - 1] = "MHS Electronic", +[0][0x59 - 1] = "Performance Semi.", +[0][0x5a - 1] = "Winbond Electronic", +[0][0x5b - 1] = "Kawasaki Steel", +[0][0x5c - 1] = "Bright Micro", +[0][0x5d - 1] = "TECMAR", +[0][0x5e - 1] = "Exar", +[0][0x5f - 1] = "PCMCIA", +[0][0x60 - 1] = "LG Semi (Goldstar)", +[0][0x61 - 1] = "Northern Telecom", +[0][0x62 - 1] = "Sanyo", +[0][0x63 - 1] = "Array Microsystems", +[0][0x64 - 1] = "Crystal Semiconductor", +[0][0x65 - 1] = "Analog Devices", +[0][0x66 - 1] = "PMC-Sierra", +[0][0x67 - 1] = "Asparix", +[0][0x68 - 1] = "Convex Computer", +[0][0x69 - 1] = "Quality Semiconductor", +[0][0x6a - 1] = "Nimbus Technology", +[0][0x6b - 1] = "Transwitch", +[0][0x6c - 1] = "Micronas (ITT Intermetall)", +[0][0x6d - 1] = "Cannon", +[0][0x6e - 1] = "Altera", +[0][0x6f - 1] = "NEXCOM", +[0][0x70 - 1] = "Qualcomm", +[0][0x71 - 1] = "Sony", +[0][0x72 - 1] = "Cray Research", +[0][0x73 - 1] = "AMS(Austria Micro)", +[0][0x74 - 1] = "Vitesse", +[0][0x75 - 1] = "Aster Electronics", +[0][0x76 - 1] = "Bay Networks (Synoptic)", +[0][0x77 - 1] = "Zentrum/ZMD", +[0][0x78 - 1] = "TRW", +[0][0x79 - 1] = "Thesys", +[0][0x7a - 1] = "Solbourne Computer", +[0][0x7b - 1] = "Allied-Signal", +[0][0x7c - 1] = "Dialog Semiconductor", +[0][0x7d - 1] = "Media Vision", +[0][0x7e - 1] = "Numonyx Corporation", +[1][0x01 - 1] = "Cirrus Logic", +[1][0x02 - 1] = "National Instruments", +[1][0x03 - 1] = "ILC Data Device", +[1][0x04 - 1] = "Alcatel Mietec", +[1][0x05 - 1] = "Micro Linear", +[1][0x06 - 1] = "Univ. of NC", +[1][0x07 - 1] = "JTAG Technologies", +[1][0x08 - 1] = "BAE Systems (Loral)", +[1][0x09 - 1] = "Nchip", +[1][0x0a - 1] = "Galileo Tech", +[1][0x0b - 1] = "Bestlink Systems", +[1][0x0c - 1] = "Graychip", +[1][0x0d - 1] = "GENNUM", +[1][0x0e - 1] = "VideoLogic", +[1][0x0f - 1] = "Robert Bosch", +[1][0x10 - 1] = "Chip Express", +[1][0x11 - 1] = "DATARAM", +[1][0x12 - 1] = "United Microelectronics Corp", +[1][0x13 - 1] = "TCSI", +[1][0x14 - 1] = "Smart Modular", +[1][0x15 - 1] = "Hughes Aircraft", +[1][0x16 - 1] = "Lanstar Semiconductor", +[1][0x17 - 1] = "Qlogic", +[1][0x18 - 1] = "Kingston", +[1][0x19 - 1] = "Music Semi", +[1][0x1a - 1] = "Ericsson Components", +[1][0x1b - 1] = "SpaSE", +[1][0x1c - 1] = "Eon Silicon Devices", +[1][0x1d - 1] = "Integrated Silicon Solution (ISSI)", +[1][0x1e - 1] = "DoD", +[1][0x1f - 1] = "Integ. Memories Tech.", +[1][0x20 - 1] = "Corollary Inc", +[1][0x21 - 1] = "Dallas Semiconductor", +[1][0x22 - 1] = "Omnivision", +[1][0x23 - 1] = "EIV(Switzerland)", +[1][0x24 - 1] = "Novatel Wireless", +[1][0x25 - 1] = "Zarlink (Mitel)", +[1][0x26 - 1] = "Clearpoint", +[1][0x27 - 1] = "Cabletron", +[1][0x28 - 1] = "STEC (Silicon Tech)", +[1][0x29 - 1] = "Vanguard", +[1][0x2a - 1] = "Hagiwara Sys-Com", +[1][0x2b - 1] = "Vantis", +[1][0x2c - 1] = "Celestica", +[1][0x2d - 1] = "Century", +[1][0x2e - 1] = "Hal Computers", +[1][0x2f - 1] = "Rohm Company Ltd", +[1][0x30 - 1] = "Juniper Networks", +[1][0x31 - 1] = "Libit Signal Processing", +[1][0x32 - 1] = "Mushkin Enhanced Memory", +[1][0x33 - 1] = "Tundra Semiconductor", +[1][0x34 - 1] = "Adaptec Inc", +[1][0x35 - 1] = "LightSpeed Semi.", +[1][0x36 - 1] = "ZSP Corp", +[1][0x37 - 1] = "AMIC Technology", +[1][0x38 - 1] = "Adobe Systems", +[1][0x39 - 1] = "Dynachip", +[1][0x3a - 1] = "PNY Technologies Inc", +[1][0x3b - 1] = "Newport Digital", +[1][0x3c - 1] = "MMC Networks", +[1][0x3d - 1] = "T Square", +[1][0x3e - 1] = "Seiko Epson", +[1][0x3f - 1] = "Broadcom", +[1][0x40 - 1] = "Viking Components", +[1][0x41 - 1] = "V3 Semiconductor", +[1][0x42 - 1] = "Flextronics (Orbit Semiconductor)", +[1][0x43 - 1] = "Suwa Electronics", +[1][0x44 - 1] = "Transmeta", +[1][0x45 - 1] = "Micron CMS", +[1][0x46 - 1] = "American Computer & Digital Components Inc", +[1][0x47 - 1] = "Enhance 3000 Inc", +[1][0x48 - 1] = "Tower Semiconductor", +[1][0x49 - 1] = "CPU Design", +[1][0x4a - 1] = "Price Point", +[1][0x4b - 1] = "Maxim Integrated Product", +[1][0x4c - 1] = "Tellabs", +[1][0x4d - 1] = "Centaur Technology", +[1][0x4e - 1] = "Unigen Corporation", +[1][0x4f - 1] = "Transcend Information", +[1][0x50 - 1] = "Memory Card Technology", +[1][0x51 - 1] = "CKD Corporation Ltd", +[1][0x52 - 1] = "Capital Instruments Inc", +[1][0x53 - 1] = "Aica Kogyo Ltd", +[1][0x54 - 1] = "Linvex Technology", +[1][0x55 - 1] = "MSC Vertriebs GmbH", +[1][0x56 - 1] = "AKM Company Ltd", +[1][0x57 - 1] = "Dynamem Inc", +[1][0x58 - 1] = "NERA ASA", +[1][0x59 - 1] = "GSI Technology", +[1][0x5a - 1] = "Dane-Elec (C Memory)", +[1][0x5b - 1] = "Acorn Computers", +[1][0x5c - 1] = "Lara Technology", +[1][0x5d - 1] = "Oak Technology Inc", +[1][0x5e - 1] = "Itec Memory", +[1][0x5f - 1] = "Tanisys Technology", +[1][0x60 - 1] = "Truevision", +[1][0x61 - 1] = "Wintec Industries", +[1][0x62 - 1] = "Super PC Memory", +[1][0x63 - 1] = "MGV Memory", +[1][0x64 - 1] = "Galvantech", +[1][0x65 - 1] = "Gadzoox Networks", +[1][0x66 - 1] = "Multi Dimensional Cons.", +[1][0x67 - 1] = "GateField", +[1][0x68 - 1] = "Integrated Memory System", +[1][0x69 - 1] = "Triscend", +[1][0x6a - 1] = "XaQti", +[1][0x6b - 1] = "Goldenram", +[1][0x6c - 1] = "Clear Logic", +[1][0x6d - 1] = "Cimaron Communications", +[1][0x6e - 1] = "Nippon Steel Semi. Corp", +[1][0x6f - 1] = "Advantage Memory", +[1][0x70 - 1] = "AMCC", +[1][0x71 - 1] = "LeCroy", +[1][0x72 - 1] = "Yamaha Corporation", +[1][0x73 - 1] = "Digital Microwave", +[1][0x74 - 1] = "NetLogic Microsystems", +[1][0x75 - 1] = "MIMOS Semiconductor", +[1][0x76 - 1] = "Advanced Fibre", +[1][0x77 - 1] = "BF Goodrich Data.", +[1][0x78 - 1] = "Epigram", +[1][0x79 - 1] = "Acbel Polytech Inc", +[1][0x7a - 1] = "Apacer Technology", +[1][0x7b - 1] = "Admor Memory", +[1][0x7c - 1] = "FOXCONN", +[1][0x7d - 1] = "Quadratics Superconductor", +[1][0x7e - 1] = "3COM", +[2][0x01 - 1] = "Camintonn Corporation", +[2][0x02 - 1] = "ISOA Incorporated", +[2][0x03 - 1] = "Agate Semiconductor", +[2][0x04 - 1] = "ADMtek Incorporated", +[2][0x05 - 1] = "HYPERTEC", +[2][0x06 - 1] = "Adhoc Technologies", +[2][0x07 - 1] = "MOSAID Technologies", +[2][0x08 - 1] = "Ardent Technologies", +[2][0x09 - 1] = "Switchcore", +[2][0x0a - 1] = "Cisco Systems Inc", +[2][0x0b - 1] = "Allayer Technologies", +[2][0x0c - 1] = "WorkX AG (Wichman)", +[2][0x0d - 1] = "Oasis Semiconductor", +[2][0x0e - 1] = "Novanet Semiconductor", +[2][0x0f - 1] = "E-M Solutions", +[2][0x10 - 1] = "Power General", +[2][0x11 - 1] = "Advanced Hardware Arch.", +[2][0x12 - 1] = "Inova Semiconductors GmbH", +[2][0x13 - 1] = "Telocity", +[2][0x14 - 1] = "Delkin Devices", +[2][0x15 - 1] = "Symagery Microsystems", +[2][0x16 - 1] = "C-Port Corporation", +[2][0x17 - 1] = "SiberCore Technologies", +[2][0x18 - 1] = "Southland Microsystems", +[2][0x19 - 1] = "Malleable Technologies", +[2][0x1a - 1] = "Kendin Communications", +[2][0x1b - 1] = "Great Technology Microcomputer", +[2][0x1c - 1] = "Sanmina Corporation", +[2][0x1d - 1] = "HADCO Corporation", +[2][0x1e - 1] = "Corsair", +[2][0x1f - 1] = "Actrans System Inc", +[2][0x20 - 1] = "ALPHA Technologies", +[2][0x21 - 1] = "Silicon Laboratories Inc (Cygnal)", +[2][0x22 - 1] = "Artesyn Technologies", +[2][0x23 - 1] = "Align Manufacturing", +[2][0x24 - 1] = "Peregrine Semiconductor", +[2][0x25 - 1] = "Chameleon Systems", +[2][0x26 - 1] = "Aplus Flash Technology", +[2][0x27 - 1] = "MIPS Technologies", +[2][0x28 - 1] = "Chrysalis ITS", +[2][0x29 - 1] = "ADTEC Corporation", +[2][0x2a - 1] = "Kentron Technologies", +[2][0x2b - 1] = "Win Technologies", +[2][0x2c - 1] = "Tezzaron Semiconductor", +[2][0x2d - 1] = "Extreme Packet Devices", +[2][0x2e - 1] = "RF Micro Devices", +[2][0x2f - 1] = "Siemens AG", +[2][0x30 - 1] = "Sarnoff Corporation", +[2][0x31 - 1] = "Itautec SA", +[2][0x32 - 1] = "Radiata Inc", +[2][0x33 - 1] = "Benchmark Elect. (AVEX)", +[2][0x34 - 1] = "Legend", +[2][0x35 - 1] = "SpecTek Incorporated", +[2][0x36 - 1] = "Hi/fn", +[2][0x37 - 1] = "Enikia Incorporated", +[2][0x38 - 1] = "SwitchOn Networks", +[2][0x39 - 1] = "AANetcom Incorporated", +[2][0x3a - 1] = "Micro Memory Bank", +[2][0x3b - 1] = "ESS Technology", +[2][0x3c - 1] = "Virata Corporation", +[2][0x3d - 1] = "Excess Bandwidth", +[2][0x3e - 1] = "West Bay Semiconductor", +[2][0x3f - 1] = "DSP Group", +[2][0x40 - 1] = "Newport Communications", +[2][0x41 - 1] = "Chip2Chip Incorporated", +[2][0x42 - 1] = "Phobos Corporation", +[2][0x43 - 1] = "Intellitech Corporation", +[2][0x44 - 1] = "Nordic VLSI ASA", +[2][0x45 - 1] = "Ishoni Networks", +[2][0x46 - 1] = "Silicon Spice", +[2][0x47 - 1] = "Alchemy Semiconductor", +[2][0x48 - 1] = "Agilent Technologies", +[2][0x49 - 1] = "Centillium Communications", +[2][0x4a - 1] = "W.L. Gore", +[2][0x4b - 1] = "HanBit Electronics", +[2][0x4c - 1] = "GlobeSpan", +[2][0x4d - 1] = "Element 14", +[2][0x4e - 1] = "Pycon", +[2][0x4f - 1] = "Saifun Semiconductors", +[2][0x50 - 1] = "Sibyte Incorporated", +[2][0x51 - 1] = "MetaLink Technologies", +[2][0x52 - 1] = "Feiya Technology", +[2][0x53 - 1] = "I & C Technology", +[2][0x54 - 1] = "Shikatronics", +[2][0x55 - 1] = "Elektrobit", +[2][0x56 - 1] = "Megic", +[2][0x57 - 1] = "Com-Tier", +[2][0x58 - 1] = "Malaysia Micro Solutions", +[2][0x59 - 1] = "Hyperchip", +[2][0x5a - 1] = "Gemstone Communications", +[2][0x5b - 1] = "Anadigm (Anadyne)", +[2][0x5c - 1] = "3ParData", +[2][0x5d - 1] = "Mellanox Technologies", +[2][0x5e - 1] = "Tenx Technologies", +[2][0x5f - 1] = "Helix AG", +[2][0x60 - 1] = "Domosys", +[2][0x61 - 1] = "Skyup Technology", +[2][0x62 - 1] = "HiNT Corporation", +[2][0x63 - 1] = "Chiaro", +[2][0x64 - 1] = "MDT Technologies GmbH", +[2][0x65 - 1] = "Exbit Technology A/S", +[2][0x66 - 1] = "Integrated Technology Express", +[2][0x67 - 1] = "AVED Memory", +[2][0x68 - 1] = "Legerity", +[2][0x69 - 1] = "Jasmine Networks", +[2][0x6a - 1] = "Caspian Networks", +[2][0x6b - 1] = "nCUBE", +[2][0x6c - 1] = "Silicon Access Networks", +[2][0x6d - 1] = "FDK Corporation", +[2][0x6e - 1] = "High Bandwidth Access", +[2][0x6f - 1] = "MultiLink Technology", +[2][0x70 - 1] = "BRECIS", +[2][0x71 - 1] = "World Wide Packets", +[2][0x72 - 1] = "APW", +[2][0x73 - 1] = "Chicory Systems", +[2][0x74 - 1] = "Xstream Logic", +[2][0x75 - 1] = "Fast-Chip", +[2][0x76 - 1] = "Zucotto Wireless", +[2][0x77 - 1] = "Realchip", +[2][0x78 - 1] = "Galaxy Power", +[2][0x79 - 1] = "eSilicon", +[2][0x7a - 1] = "Morphics Technology", +[2][0x7b - 1] = "Accelerant Networks", +[2][0x7c - 1] = "Silicon Wave", +[2][0x7d - 1] = "SandCraft", +[2][0x7e - 1] = "Elpida", +[3][0x01 - 1] = "Solectron", +[3][0x02 - 1] = "Optosys Technologies", +[3][0x03 - 1] = "Buffalo (Formerly Melco)", +[3][0x04 - 1] = "TriMedia Technologies", +[3][0x05 - 1] = "Cyan Technologies", +[3][0x06 - 1] = "Global Locate", +[3][0x07 - 1] = "Optillion", +[3][0x08 - 1] = "Terago Communications", +[3][0x09 - 1] = "Ikanos Communications", +[3][0x0a - 1] = "Princeton Technology", +[3][0x0b - 1] = "Nanya Technology", +[3][0x0c - 1] = "Elite Flash Storage", +[3][0x0d - 1] = "Mysticom", +[3][0x0e - 1] = "LightSand Communications", +[3][0x0f - 1] = "ATI Technologies", +[3][0x10 - 1] = "Agere Systems", +[3][0x11 - 1] = "NeoMagic", +[3][0x12 - 1] = "AuroraNetics", +[3][0x13 - 1] = "Golden Empire", +[3][0x14 - 1] = "Mushkin", +[3][0x15 - 1] = "Tioga Technologies", +[3][0x16 - 1] = "Netlist", +[3][0x17 - 1] = "TeraLogic", +[3][0x18 - 1] = "Cicada Semiconductor", +[3][0x19 - 1] = "Centon Electronics", +[3][0x1a - 1] = "Tyco Electronics", +[3][0x1b - 1] = "Magis Works", +[3][0x1c - 1] = "Zettacom", +[3][0x1d - 1] = "Cogency Semiconductor", +[3][0x1e - 1] = "Chipcon AS", +[3][0x1f - 1] = "Aspex Technology", +[3][0x20 - 1] = "F5 Networks", +[3][0x21 - 1] = "Programmable Silicon Solutions", +[3][0x22 - 1] = "ChipWrights", +[3][0x23 - 1] = "Acorn Networks", +[3][0x24 - 1] = "Quicklogic", +[3][0x25 - 1] = "Kingmax Semiconductor", +[3][0x26 - 1] = "BOPS", +[3][0x27 - 1] = "Flasys", +[3][0x28 - 1] = "BitBlitz Communications", +[3][0x29 - 1] = "eMemory Technology", +[3][0x2a - 1] = "Procket Networks", +[3][0x2b - 1] = "Purple Ray", +[3][0x2c - 1] = "Trebia Networks", +[3][0x2d - 1] = "Delta Electronics", +[3][0x2e - 1] = "Onex Communications", +[3][0x2f - 1] = "Ample Communications", +[3][0x30 - 1] = "Memory Experts Intl", +[3][0x31 - 1] = "Astute Networks", +[3][0x32 - 1] = "Azanda Network Devices", +[3][0x33 - 1] = "Dibcom", +[3][0x34 - 1] = "Tekmos", +[3][0x35 - 1] = "API NetWorks", +[3][0x36 - 1] = "Bay Microsystems", +[3][0x37 - 1] = "Firecron Ltd", +[3][0x38 - 1] = "Resonext Communications", +[3][0x39 - 1] = "Tachys Technologies", +[3][0x3a - 1] = "Equator Technology", +[3][0x3b - 1] = "Concept Computer", +[3][0x3c - 1] = "SILCOM", +[3][0x3d - 1] = "3Dlabs", +[3][0x3e - 1] = "c't Magazine", +[3][0x3f - 1] = "Sanera Systems", +[3][0x40 - 1] = "Silicon Packets", +[3][0x41 - 1] = "Viasystems Group", +[3][0x42 - 1] = "Simtek", +[3][0x43 - 1] = "Semicon Devices Singapore", +[3][0x44 - 1] = "Satron Handelsges", +[3][0x45 - 1] = "Improv Systems", +[3][0x46 - 1] = "INDUSYS GmbH", +[3][0x47 - 1] = "Corrent", +[3][0x48 - 1] = "Infrant Technologies", +[3][0x49 - 1] = "Ritek Corp", +[3][0x4a - 1] = "empowerTel Networks", +[3][0x4b - 1] = "Hypertec", +[3][0x4c - 1] = "Cavium Networks", +[3][0x4d - 1] = "PLX Technology", +[3][0x4e - 1] = "Massana Design", +[3][0x4f - 1] = "Intrinsity", +[3][0x50 - 1] = "Valence Semiconductor", +[3][0x51 - 1] = "Terawave Communications", +[3][0x52 - 1] = "IceFyre Semiconductor", +[3][0x53 - 1] = "Primarion", +[3][0x54 - 1] = "Picochip Designs Ltd", +[3][0x55 - 1] = "Silverback Systems", +[3][0x56 - 1] = "Jade Star Technologies", +[3][0x57 - 1] = "Pijnenburg Securealink", +[3][0x58 - 1] = "takeMS - Ultron AG", +[3][0x59 - 1] = "Cambridge Silicon Radio", +[3][0x5a - 1] = "Swissbit", +[3][0x5b - 1] = "Nazomi Communications", +[3][0x5c - 1] = "eWave System", +[3][0x5d - 1] = "Rockwell Collins", +[3][0x5e - 1] = "Picocel Co Ltd (Paion)", +[3][0x5f - 1] = "Alphamosaic Ltd", +[3][0x60 - 1] = "Sandburst", +[3][0x61 - 1] = "SiCon Video", +[3][0x62 - 1] = "NanoAmp Solutions", +[3][0x63 - 1] = "Ericsson Technology", +[3][0x64 - 1] = "PrairieComm", +[3][0x65 - 1] = "Mitac International", +[3][0x66 - 1] = "Layer N Networks", +[3][0x67 - 1] = "MtekVision (Atsana)", +[3][0x68 - 1] = "Allegro Networks", +[3][0x69 - 1] = "Marvell Semiconductors", +[3][0x6a - 1] = "Netergy Microelectronic", +[3][0x6b - 1] = "NVIDIA", +[3][0x6c - 1] = "Internet Machines", +[3][0x6d - 1] = "Memorysolution GmbH", +[3][0x6e - 1] = "Litchfield Communication", +[3][0x6f - 1] = "Accton Technology", +[3][0x70 - 1] = "Teradiant Networks", +[3][0x71 - 1] = "Scaleo Chip", +[3][0x72 - 1] = "Cortina Systems", +[3][0x73 - 1] = "RAM Components", +[3][0x74 - 1] = "Raqia Networks", +[3][0x75 - 1] = "ClearSpeed", +[3][0x76 - 1] = "Matsushita Battery", +[3][0x77 - 1] = "Xelerated", +[3][0x78 - 1] = "SimpleTech", +[3][0x79 - 1] = "Utron Technology", +[3][0x7a - 1] = "Astec International", +[3][0x7b - 1] = "AVM gmbH", +[3][0x7c - 1] = "Redux Communications", +[3][0x7d - 1] = "Dot Hill Systems", +[3][0x7e - 1] = "TeraChip", +[4][0x01 - 1] = "T-RAM Incorporated", +[4][0x02 - 1] = "Innovics Wireless", +[4][0x03 - 1] = "Teknovus", +[4][0x04 - 1] = "KeyEye Communications", +[4][0x05 - 1] = "Runcom Technologies", +[4][0x06 - 1] = "RedSwitch", +[4][0x07 - 1] = "Dotcast", +[4][0x08 - 1] = "Silicon Mountain Memory", +[4][0x09 - 1] = "Signia Technologies", +[4][0x0a - 1] = "Pixim", +[4][0x0b - 1] = "Galazar Networks", +[4][0x0c - 1] = "White Electronic Designs", +[4][0x0d - 1] = "Patriot Scientific", +[4][0x0e - 1] = "Neoaxiom Corporation", +[4][0x0f - 1] = "3Y Power Technology", +[4][0x10 - 1] = "Scaleo Chip", +[4][0x11 - 1] = "Potentia Power Systems", +[4][0x12 - 1] = "C-guys Incorporated", +[4][0x13 - 1] = "Digital Communications Technology Inc", +[4][0x14 - 1] = "Silicon-Based Technology", +[4][0x15 - 1] = "Fulcrum Microsystems", +[4][0x16 - 1] = "Positivo Informatica Ltd", +[4][0x17 - 1] = "XIOtech Corporation", +[4][0x18 - 1] = "PortalPlayer", +[4][0x19 - 1] = "Zhiying Software", +[4][0x1a - 1] = "ParkerVision Inc", +[4][0x1b - 1] = "Phonex Broadband", +[4][0x1c - 1] = "Skyworks Solutions", +[4][0x1d - 1] = "Entropic Communications", +[4][0x1e - 1] = "I'M Intelligent Memory Ltd", +[4][0x1f - 1] = "Zensys A/S", +[4][0x20 - 1] = "Legend Silicon Corp", +[4][0x21 - 1] = "Sci-worx GmbH", +[4][0x22 - 1] = "SMSC (Standard Microsystems)", +[4][0x23 - 1] = "Renesas Electronics", +[4][0x24 - 1] = "Raza Microelectronics", +[4][0x25 - 1] = "Phyworks", +[4][0x26 - 1] = "MediaTek", +[4][0x27 - 1] = "Non-cents Productions", +[4][0x28 - 1] = "US Modular", +[4][0x29 - 1] = "Wintegra Ltd", +[4][0x2a - 1] = "Mathstar", +[4][0x2b - 1] = "StarCore", +[4][0x2c - 1] = "Oplus Technologies", +[4][0x2d - 1] = "Mindspeed", +[4][0x2e - 1] = "Just Young Computer", +[4][0x2f - 1] = "Radia Communications", +[4][0x30 - 1] = "OCZ", +[4][0x31 - 1] = "Emuzed", +[4][0x32 - 1] = "LOGIC Devices", +[4][0x33 - 1] = "Inphi Corporation", +[4][0x34 - 1] = "Quake Technologies", +[4][0x35 - 1] = "Vixel", +[4][0x36 - 1] = "SolusTek", +[4][0x37 - 1] = "Kongsberg Maritime", +[4][0x38 - 1] = "Faraday Technology", +[4][0x39 - 1] = "Altium Ltd", +[4][0x3a - 1] = "Insyte", +[4][0x3b - 1] = "ARM Ltd", +[4][0x3c - 1] = "DigiVision", +[4][0x3d - 1] = "Vativ Technologies", +[4][0x3e - 1] = "Endicott Interconnect Technologies", +[4][0x3f - 1] = "Pericom", +[4][0x40 - 1] = "Bandspeed", +[4][0x41 - 1] = "LeWiz Communications", +[4][0x42 - 1] = "CPU Technology", +[4][0x43 - 1] = "Ramaxel Technology", +[4][0x44 - 1] = "DSP Group", +[4][0x45 - 1] = "Axis Communications", +[4][0x46 - 1] = "Legacy Electronics", +[4][0x47 - 1] = "Chrontel", +[4][0x48 - 1] = "Powerchip Semiconductor", +[4][0x49 - 1] = "MobilEye Technologies", +[4][0x4a - 1] = "Excel Semiconductor", +[4][0x4b - 1] = "A-DATA Technology", +[4][0x4c - 1] = "VirtualDigm", +[4][0x4d - 1] = "G Skill Intl", +[4][0x4e - 1] = "Quanta Computer", +[4][0x4f - 1] = "Yield Microelectronics", +[4][0x50 - 1] = "Afa Technologies", +[4][0x51 - 1] = "KINGBOX Technology Co Ltd", +[4][0x52 - 1] = "Ceva", +[4][0x53 - 1] = "iStor Networks", +[4][0x54 - 1] = "Advance Modules", +[4][0x55 - 1] = "Microsoft", +[4][0x56 - 1] = "Open-Silicon", +[4][0x57 - 1] = "Goal Semiconductor", +[4][0x58 - 1] = "ARC International", +[4][0x59 - 1] = "Simmtec", +[4][0x5a - 1] = "Metanoia", +[4][0x5b - 1] = "Key Stream", +[4][0x5c - 1] = "Lowrance Electronics", +[4][0x5d - 1] = "Adimos", +[4][0x5e - 1] = "SiGe Semiconductor", +[4][0x5f - 1] = "Fodus Communications", +[4][0x60 - 1] = "Credence Systems Corp", +[4][0x61 - 1] = "Genesis Microchip Inc", +[4][0x62 - 1] = "Vihana Inc", +[4][0x63 - 1] = "WIS Technologies", +[4][0x64 - 1] = "GateChange Technologies", +[4][0x65 - 1] = "High Density Devices AS", +[4][0x66 - 1] = "Synopsys", +[4][0x67 - 1] = "Gigaram", +[4][0x68 - 1] = "Enigma Semiconductor Inc", +[4][0x69 - 1] = "Century Micro Inc", +[4][0x6a - 1] = "Icera Semiconductor", +[4][0x6b - 1] = "Mediaworks Integrated Systems", +[4][0x6c - 1] = "O'Neil Product Development", +[4][0x6d - 1] = "Supreme Top Technology Ltd", +[4][0x6e - 1] = "MicroDisplay Corporation", +[4][0x6f - 1] = "Team Group Inc", +[4][0x70 - 1] = "Sinett Corporation", +[4][0x71 - 1] = "Toshiba Corporation", +[4][0x72 - 1] = "Tensilica", +[4][0x73 - 1] = "SiRF Technology", +[4][0x74 - 1] = "Bacoc Inc", +[4][0x75 - 1] = "SMaL Camera Technologies", +[4][0x76 - 1] = "Thomson SC", +[4][0x77 - 1] = "Airgo Networks", +[4][0x78 - 1] = "Wisair Ltd", +[4][0x79 - 1] = "SigmaTel", +[4][0x7a - 1] = "Arkados", +[4][0x7b - 1] = "Compete IT gmbH Co KG", +[4][0x7c - 1] = "Eudar Technology Inc", +[4][0x7d - 1] = "Focus Enhancements", +[4][0x7e - 1] = "Xyratex", +[5][0x01 - 1] = "Specular Networks", +[5][0x02 - 1] = "Patriot Memory (PDP Systems)", +[5][0x03 - 1] = "U-Chip Technology Corp", +[5][0x04 - 1] = "Silicon Optix", +[5][0x05 - 1] = "Greenfield Networks", +[5][0x06 - 1] = "CompuRAM GmbH", +[5][0x07 - 1] = "Stargen Inc", +[5][0x08 - 1] = "NetCell Corporation", +[5][0x09 - 1] = "Excalibrus Technologies Ltd", +[5][0x0a - 1] = "SCM Microsystems", +[5][0x0b - 1] = "Xsigo Systems Inc", +[5][0x0c - 1] = "CHIPS & Systems Inc", +[5][0x0d - 1] = "Tier 1 Multichip Solutions", +[5][0x0e - 1] = "CWRL Labs", +[5][0x0f - 1] = "Teradici", +[5][0x10 - 1] = "Gigaram Inc", +[5][0x11 - 1] = "g2 Microsystems", +[5][0x12 - 1] = "PowerFlash Semiconductor", +[5][0x13 - 1] = "P.A. Semi Inc", +[5][0x14 - 1] = "NovaTech Solutions S.A.", +[5][0x15 - 1] = "c2 Microsystems Inc", +[5][0x16 - 1] = "Level5 Networks", +[5][0x17 - 1] = "COS Memory AG", +[5][0x18 - 1] = "Innovasic Semiconductor", +[5][0x19 - 1] = "02IC Co Ltd", +[5][0x1a - 1] = "Tabula Inc", +[5][0x1b - 1] = "Crucial Technology", +[5][0x1c - 1] = "Chelsio Communications", +[5][0x1d - 1] = "Solarflare Communications", +[5][0x1e - 1] = "Xambala Inc", +[5][0x1f - 1] = "EADS Astrium", +[5][0x20 - 1] = "Terra Semiconductor Inc", +[5][0x21 - 1] = "Imaging Works Inc", +[5][0x22 - 1] = "Astute Networks Inc", +[5][0x23 - 1] = "Tzero", +[5][0x24 - 1] = "Emulex", +[5][0x25 - 1] = "Power-One", +[5][0x26 - 1] = "Pulse~LINK Inc", +[5][0x27 - 1] = "Hon Hai Precision Industry", +[5][0x28 - 1] = "White Rock Networks Inc", +[5][0x29 - 1] = "Telegent Systems USA Inc", +[5][0x2a - 1] = "Atrua Technologies Inc", +[5][0x2b - 1] = "Acbel Polytech Inc", +[5][0x2c - 1] = "eRide Inc", +[5][0x2d - 1] = "ULi Electronics Inc", +[5][0x2e - 1] = "Magnum Semiconductor Inc", +[5][0x2f - 1] = "neoOne Technology Inc", +[5][0x30 - 1] = "Connex Technology Inc", +[5][0x31 - 1] = "Stream Processors Inc", +[5][0x32 - 1] = "Focus Enhancements", +[5][0x33 - 1] = "Telecis Wireless Inc", +[5][0x34 - 1] = "uNav Microelectronics", +[5][0x35 - 1] = "Tarari Inc", +[5][0x36 - 1] = "Ambric Inc", +[5][0x37 - 1] = "Newport Media Inc", +[5][0x38 - 1] = "VMTS", +[5][0x39 - 1] = "Enuclia Semiconductor Inc", +[5][0x3a - 1] = "Virtium Technology Inc", +[5][0x3b - 1] = "Solid State System Co Ltd", +[5][0x3c - 1] = "Kian Tech LLC", +[5][0x3d - 1] = "Artimi", +[5][0x3e - 1] = "Power Quotient International", +[5][0x3f - 1] = "Avago Technologies", +[5][0x40 - 1] = "ADTechnology", +[5][0x41 - 1] = "Sigma Designs", +[5][0x42 - 1] = "SiCortex Inc", +[5][0x43 - 1] = "Ventura Technology Group", +[5][0x44 - 1] = "eASIC", +[5][0x45 - 1] = "M.H.S. SAS", +[5][0x46 - 1] = "Micro Star International", +[5][0x47 - 1] = "Rapport Inc", +[5][0x48 - 1] = "Makway International", +[5][0x49 - 1] = "Broad Reach Engineering Co", +[5][0x4a - 1] = "Semiconductor Mfg Intl Corp", +[5][0x4b - 1] = "SiConnect", +[5][0x4c - 1] = "FCI USA Inc", +[5][0x4d - 1] = "Validity Sensors", +[5][0x4e - 1] = "Coney Technology Co Ltd", +[5][0x4f - 1] = "Spans Logic", +[5][0x50 - 1] = "Neterion Inc", +[5][0x51 - 1] = "Qimonda", +[5][0x52 - 1] = "New Japan Radio Co Ltd", +[5][0x53 - 1] = "Velogix", +[5][0x54 - 1] = "Montalvo Systems", +[5][0x55 - 1] = "iVivity Inc", +[5][0x56 - 1] = "Walton Chaintech", +[5][0x57 - 1] = "AENEON", +[5][0x58 - 1] = "Lorom Industrial Co Ltd", +[5][0x59 - 1] = "Radiospire Networks", +[5][0x5a - 1] = "Sensio Technologies Inc", +[5][0x5b - 1] = "Nethra Imaging", +[5][0x5c - 1] = "Hexon Technology Pte Ltd", +[5][0x5d - 1] = "CompuStocx (CSX)", +[5][0x5e - 1] = "Methode Electronics Inc", +[5][0x5f - 1] = "Connect One Ltd", +[5][0x60 - 1] = "Opulan Technologies", +[5][0x61 - 1] = "Septentrio NV", +[5][0x62 - 1] = "Goldenmars Technology Inc", +[5][0x63 - 1] = "Kreton Corporation", +[5][0x64 - 1] = "Cochlear Ltd", +[5][0x65 - 1] = "Altair Semiconductor", +[5][0x66 - 1] = "NetEffect Inc", +[5][0x67 - 1] = "Spansion Inc", +[5][0x68 - 1] = "Taiwan Semiconductor Mfg", +[5][0x69 - 1] = "Emphany Systems Inc", +[5][0x6a - 1] = "ApaceWave Technologies", +[5][0x6b - 1] = "Mobilygen Corporation", +[5][0x6c - 1] = "Tego", +[5][0x6d - 1] = "Cswitch Corporation", +[5][0x6e - 1] = "Haier (Beijing) IC Design Co", +[5][0x6f - 1] = "MetaRAM", +[5][0x70 - 1] = "Axel Electronics Co Ltd", +[5][0x71 - 1] = "Tilera Corporation", +[5][0x72 - 1] = "Aquantia", +[5][0x73 - 1] = "Vivace Semiconductor", +[5][0x74 - 1] = "Redpine Signals", +[5][0x75 - 1] = "Octalica", +[5][0x76 - 1] = "InterDigital Communications", +[5][0x77 - 1] = "Avant Technology", +[5][0x78 - 1] = "Asrock Inc", +[5][0x79 - 1] = "Availink", +[5][0x7a - 1] = "Quartics Inc", +[5][0x7b - 1] = "Element CXI", +[5][0x7c - 1] = "Innovaciones Microelectronicas", +[5][0x7d - 1] = "VeriSilicon Microelectronics", +[5][0x7e - 1] = "W5 Networks", +[6][0x01 - 1] = "MOVEKING", +[6][0x02 - 1] = "Mavrix Technology Inc", +[6][0x03 - 1] = "CellGuide Ltd", +[6][0x04 - 1] = "Faraday Technology", +[6][0x05 - 1] = "Diablo Technologies Inc", +[6][0x06 - 1] = "Jennic", +[6][0x07 - 1] = "Octasic", +[6][0x08 - 1] = "Molex Incorporated", +[6][0x09 - 1] = "3Leaf Networks", +[6][0x0a - 1] = "Bright Micron Technology", +[6][0x0b - 1] = "Netxen", +[6][0x0c - 1] = "NextWave Broadband Inc", +[6][0x0d - 1] = "DisplayLink", +[6][0x0e - 1] = "ZMOS Technology", +[6][0x0f - 1] = "Tec-Hill", +[6][0x10 - 1] = "Multigig Inc", +[6][0x11 - 1] = "Amimon", +[6][0x12 - 1] = "Euphonic Technologies Inc", +[6][0x13 - 1] = "BRN Phoenix", +[6][0x14 - 1] = "InSilica", +[6][0x15 - 1] = "Ember Corporation", +[6][0x16 - 1] = "Avexir Technologies Corporation", +[6][0x17 - 1] = "Echelon Corporation", +[6][0x18 - 1] = "Edgewater Computer Systems", +[6][0x19 - 1] = "XMOS Semiconductor Ltd", +[6][0x1a - 1] = "GENUSION Inc", +[6][0x1b - 1] = "Memory Corp NV", +[6][0x1c - 1] = "SiliconBlue Technologies", +[6][0x1d - 1] = "Rambus Inc", +[6][0x1e - 1] = "Andes Technology Corporation", +[6][0x1f - 1] = "Coronis Systems", +[6][0x20 - 1] = "Achronix Semiconductor", +[6][0x21 - 1] = "Siano Mobile Silicon Ltd", +[6][0x22 - 1] = "Semtech Corporation", +[6][0x23 - 1] = "Pixelworks Inc", +[6][0x24 - 1] = "Gaisler Research AB", +[6][0x25 - 1] = "Teranetics", +[6][0x26 - 1] = "Toppan Printing Co Ltd", +[6][0x27 - 1] = "Kingxcon", +[6][0x28 - 1] = "Silicon Integrated Systems", +[6][0x29 - 1] = "I-O Data Device Inc", +[6][0x2a - 1] = "NDS Americas Inc", +[6][0x2b - 1] = "Solomon Systech Limited", +[6][0x2c - 1] = "On Demand Microelectronics", +[6][0x2d - 1] = "Amicus Wireless Inc", +[6][0x2e - 1] = "SMARDTV SNC", +[6][0x2f - 1] = "Comsys Communication Ltd", +[6][0x30 - 1] = "Movidia Ltd", +[6][0x31 - 1] = "Javad GNSS Inc", +[6][0x32 - 1] = "Montage Technology Group", +[6][0x33 - 1] = "Trident Microsystems", +[6][0x34 - 1] = "Super Talent", +[6][0x35 - 1] = "Optichron Inc", +[6][0x36 - 1] = "Future Waves UK Ltd", +[6][0x37 - 1] = "SiBEAM Inc", +[6][0x38 - 1] = "InicoreInc", +[6][0x39 - 1] = "Virident Systems", +[6][0x3a - 1] = "M2000 Inc", +[6][0x3b - 1] = "ZeroG Wireless Inc", +[6][0x3c - 1] = "Gingle Technology Co Ltd", +[6][0x3d - 1] = "Space Micro Inc", +[6][0x3e - 1] = "Wilocity", +[6][0x3f - 1] = "Novafora Inc", +[6][0x40 - 1] = "iKoa Corporation", +[6][0x41 - 1] = "ASint Technology", +[6][0x42 - 1] = "Ramtron", +[6][0x43 - 1] = "Plato Networks Inc", +[6][0x44 - 1] = "IPtronics AS", +[6][0x45 - 1] = "Infinite-Memories", +[6][0x46 - 1] = "Parade Technologies Inc", +[6][0x47 - 1] = "Dune Networks", +[6][0x48 - 1] = "GigaDevice Semiconductor", +[6][0x49 - 1] = "Modu Ltd", +[6][0x4a - 1] = "CEITEC", +[6][0x4b - 1] = "Northrop Grumman", +[6][0x4c - 1] = "XRONET Corporation", +[6][0x4d - 1] = "Sicon Semiconductor AB", +[6][0x4e - 1] = "Atla Electronics Co Ltd", +[6][0x4f - 1] = "TOPRAM Technology", +[6][0x50 - 1] = "Silego Technology Inc", +[6][0x51 - 1] = "Kinglife", +[6][0x52 - 1] = "Ability Industries Ltd", +[6][0x53 - 1] = "Silicon Power Computer & Communications", +[6][0x54 - 1] = "Augusta Technology Inc", +[6][0x55 - 1] = "Nantronics Semiconductors", +[6][0x56 - 1] = "Hilscher Gesellschaft", +[6][0x57 - 1] = "Quixant Ltd", +[6][0x58 - 1] = "Percello Ltd", +[6][0x59 - 1] = "NextIO Inc", +[6][0x5a - 1] = "Scanimetrics Inc", +[6][0x5b - 1] = "FS-Semi Company Ltd", +[6][0x5c - 1] = "Infinera Corporation", +[6][0x5d - 1] = "SandForce Inc", +[6][0x5e - 1] = "Lexar Media", +[6][0x5f - 1] = "Teradyne Inc", +[6][0x60 - 1] = "Memory Exchange Corp", +[6][0x61 - 1] = "Suzhou Smartek Electronics", +[6][0x62 - 1] = "Avantium Corporation", +[6][0x63 - 1] = "ATP Electronics Inc", +[6][0x64 - 1] = "Valens Semiconductor Ltd", +[6][0x65 - 1] = "Agate Logic Inc", +[6][0x66 - 1] = "Netronome", +[6][0x67 - 1] = "Zenverge Inc", +[6][0x68 - 1] = "N-trig Ltd", +[6][0x69 - 1] = "SanMax Technologies Inc", +[6][0x6a - 1] = "Contour Semiconductor Inc", +[6][0x6b - 1] = "TwinMOS", +[6][0x6c - 1] = "Silicon Systems Inc", +[6][0x6d - 1] = "V-Color Technology Inc", +[6][0x6e - 1] = "Certicom Corporation", +[6][0x6f - 1] = "JSC ICC Milandr", +[6][0x70 - 1] = "PhotoFast Global Inc", +[6][0x71 - 1] = "InnoDisk Corporation", +[6][0x72 - 1] = "Muscle Power", +[6][0x73 - 1] = "Energy Micro", +[6][0x74 - 1] = "Innofidei", +[6][0x75 - 1] = "CopperGate Communications", +[6][0x76 - 1] = "Holtek Semiconductor Inc", +[6][0x77 - 1] = "Myson Century Inc", +[6][0x78 - 1] = "FIDELIX", +[6][0x79 - 1] = "Red Digital Cinema", +[6][0x7a - 1] = "Densbits Technology", +[6][0x7b - 1] = "Zempro", +[6][0x7c - 1] = "MoSys", +[6][0x7d - 1] = "Provigent", +[6][0x7e - 1] = "Triad Semiconductor Inc", +[7][0x01 - 1] = "Siklu Communication Ltd", +[7][0x02 - 1] = "A Force Manufacturing Ltd", +[7][0x03 - 1] = "Strontium", +[7][0x04 - 1] = "ALi Corp (Abilis Systems)", +[7][0x05 - 1] = "Siglead Inc", +[7][0x06 - 1] = "Ubicom Inc", +[7][0x07 - 1] = "Unifosa Corporation", +[7][0x08 - 1] = "Stretch Inc", +[7][0x09 - 1] = "Lantiq Deutschland GmbH", +[7][0x0a - 1] = "Visipro.", +[7][0x0b - 1] = "EKMemory", +[7][0x0c - 1] = "Microelectronics Institute ZTE", +[7][0x0d - 1] = "u-blox AG", +[7][0x0e - 1] = "Carry Technology Co Ltd", +[7][0x0f - 1] = "Nokia", +[7][0x10 - 1] = "King Tiger Technology", +[7][0x11 - 1] = "Sierra Wireless", +[7][0x12 - 1] = "HT Micron", +[7][0x13 - 1] = "Albatron Technology Co Ltd", +[7][0x14 - 1] = "Leica Geosystems AG", +[7][0x15 - 1] = "BroadLight", +[7][0x16 - 1] = "AEXEA", +[7][0x17 - 1] = "ClariPhy Communications Inc", +[7][0x18 - 1] = "Green Plug", +[7][0x19 - 1] = "Design Art Networks", +[7][0x1a - 1] = "Mach Xtreme Technology Ltd", +[7][0x1b - 1] = "ATO Solutions Co Ltd", +[7][0x1c - 1] = "Ramsta", +[7][0x1d - 1] = "Greenliant Systems Ltd", +[7][0x1e - 1] = "Teikon", +[7][0x1f - 1] = "Antec Hadron", +[7][0x20 - 1] = "NavCom Technology Inc", +[7][0x21 - 1] = "Shanghai Fudan Microelectronics", +[7][0x22 - 1] = "Calxeda Inc", +[7][0x23 - 1] = "JSC EDC Electronics", +[7][0x24 - 1] = "Kandit Technology Co Ltd", +[7][0x25 - 1] = "Ramos Technology", +[7][0x26 - 1] = "Goldenmars Technology", +[7][0x27 - 1] = "XeL Technology Inc", +[7][0x28 - 1] = "Newzone Corporation", +[7][0x29 - 1] = "ShenZhen MercyPower Tech", +[7][0x2a - 1] = "Nanjing Yihuo Technology", +[7][0x2b - 1] = "Nethra Imaging Inc", +[7][0x2c - 1] = "SiTel Semiconductor BV", +[7][0x2d - 1] = "SolidGear Corporation", +[7][0x2e - 1] = "Topower Computer Ind Co Ltd", +[7][0x2f - 1] = "Wilocity", +[7][0x30 - 1] = "Profichip GmbH", +[7][0x31 - 1] = "Gerad Technologies", +[7][0x32 - 1] = "Ritek Corporation", +[7][0x33 - 1] = "Gomos Technology Limited", +[7][0x34 - 1] = "Memoright Corporation", +[7][0x35 - 1] = "D-Broad Inc", +[7][0x36 - 1] = "HiSilicon Technologies", +[7][0x37 - 1] = "Syndiant Inc.", +[7][0x38 - 1] = "Enverv Inc", +[7][0x39 - 1] = "Cognex", +[7][0x3a - 1] = "Xinnova Technology Inc", +[7][0x3b - 1] = "Ultron AG", +[7][0x3c - 1] = "Concord Idea Corporation", +[7][0x3d - 1] = "AIM Corporation", +[7][0x3e - 1] = "Lifetime Memory Products", +[7][0x3f - 1] = "Ramsway", +[7][0x40 - 1] = "Recore Systems B.V.", +[7][0x41 - 1] = "Haotian Jinshibo Science Tech", +[7][0x42 - 1] = "Being Advanced Memory", +[7][0x43 - 1] = "Adesto Technologies", +[7][0x44 - 1] = "Giantec Semiconductor Inc", +[7][0x45 - 1] = "HMD Electronics AG", +[7][0x46 - 1] = "Gloway International (HK)", +[7][0x47 - 1] = "Kingcore", +[7][0x48 - 1] = "Anucell Technology Holding", +[7][0x49 - 1] = "Accord Software & Systems Pvt. Ltd", +[7][0x4a - 1] = "Active-Semi Inc", +[7][0x4b - 1] = "Denso Corporation", +[7][0x4c - 1] = "TLSI Inc", +[7][0x4d - 1] = "Qidan", +[7][0x4e - 1] = "Mustang", +[7][0x4f - 1] = "Orca Systems", +[7][0x50 - 1] = "Passif Semiconductor", +[7][0x51 - 1] = "GigaDevice Semiconductor (Beijing) Inc", +[7][0x52 - 1] = "Memphis Electronic", +[7][0x53 - 1] = "Beckhoff Automation GmbH", +[7][0x54 - 1] = "Harmony Semiconductor Corp", +[7][0x55 - 1] = "Air Computers SRL", +[7][0x56 - 1] = "TMT Memory", +[7][0x57 - 1] = "Eorex Corporation", +[7][0x58 - 1] = "Xingtera", +[7][0x59 - 1] = "Netsol", +[7][0x5a - 1] = "Bestdon Technology Co Ltd", +[7][0x5b - 1] = "Baysand Inc", +[7][0x5c - 1] = "Uroad Technology Co Ltd", +[7][0x5d - 1] = "Wilk Elektronik S.A.", +[7][0x5e - 1] = "AAI", +[7][0x5f - 1] = "Harman", +[7][0x60 - 1] = "Berg Microelectronics Inc", +[7][0x61 - 1] = "ASSIA Inc", +[7][0x62 - 1] = "Visiontek Products LLC", +[7][0x63 - 1] = "OCMEMORY", +[7][0x64 - 1] = "Welink Solution Inc", +[7][0x65 - 1] = "Shark Gaming", +[7][0x66 - 1] = "Avalanche Technology", +[7][0x67 - 1] = "R&D Center ELVEES OJSC", +[7][0x68 - 1] = "KingboMars Technology Co Ltd", +[7][0x69 - 1] = "High Bridge Solutions Industria Eletronica", +[7][0x6a - 1] = "Transcend Technology Co Ltd", +[7][0x6b - 1] = "Everspin Technologies", +[7][0x6c - 1] = "Hon-Hai Precision", +[7][0x6d - 1] = "Smart Storage Systems", +[7][0x6e - 1] = "Toumaz Group", +[7][0x6f - 1] = "Zentel Electronics Corporation", +[7][0x70 - 1] = "Panram International Corporation", +[7][0x71 - 1] = "Silicon Space Technology", +[7][0x72 - 1] = "LITE-ON IT Corporation", +[7][0x73 - 1] = "Inuitive", +[7][0x74 - 1] = "HMicro", +[7][0x75 - 1] = "BittWare Inc", +[7][0x76 - 1] = "GLOBALFOUNDRIES", +[7][0x77 - 1] = "ACPI Digital Co Ltd", +[7][0x78 - 1] = "Annapurna Labs", +[7][0x79 - 1] = "AcSiP Technology Corporation", +[7][0x7a - 1] = "Idea! Electronic Systems", +[7][0x7b - 1] = "Gowe Technology Co Ltd", +[7][0x7c - 1] = "Hermes Testing Solutions Inc", +[7][0x7d - 1] = "Positivo BGH", +[7][0x7e - 1] = "Intelligence Silicon Technology", +[8][0x01 - 1] = "3D PLUS", +[8][0x02 - 1] = "Diehl Aerospace", +[8][0x03 - 1] = "Fairchild", +[8][0x04 - 1] = "Mercury Systems", +[8][0x05 - 1] = "Sonics Inc", +[8][0x06 - 1] = "ICC Intelligent Platforms GmbH", +[8][0x07 - 1] = "Shenzhen Jinge Information Co Ltd", +[8][0x08 - 1] = "SCWW", +[8][0x09 - 1] = "Silicon Motion Inc", +[8][0x0a - 1] = "Anurag", +[8][0x0b - 1] = "King Kong", +[8][0x0c - 1] = "FROM30 Co Ltd", +[8][0x0d - 1] = "Gowin Semiconductor Corp", +[8][0x0e - 1] = "Fremont Micro Devices Ltd", +[8][0x0f - 1] = "Ericsson Modems", +[8][0x10 - 1] = "Exelis", +[8][0x11 - 1] = "Satixfy Ltd", +[8][0x12 - 1] = "Galaxy Microsystems Ltd", +[8][0x13 - 1] = "Gloway International Co Ltd", +[8][0x14 - 1] = "Lab", +[8][0x15 - 1] = "Smart Energy Instruments", +[8][0x16 - 1] = "Approved Memory Corporation", +[8][0x17 - 1] = "Axell Corporation", +[8][0x18 - 1] = "Essencore Limited", +[8][0x19 - 1] = "Phytium", +[8][0x1a - 1] = "Xi'an UniIC Semiconductors Co Ltd", +[8][0x1b - 1] = "Ambiq Micro", +[8][0x1c - 1] = "eveRAM Technology Inc", +[8][0x1d - 1] = "Infomax", +[8][0x1e - 1] = "Butterfly Network Inc", +[8][0x1f - 1] = "Shenzhen City Gcai Electronics", +[8][0x20 - 1] = "Stack Devices Corporation", +[8][0x21 - 1] = "ADK Media Group", +[8][0x22 - 1] = "TSP Global Co Ltd", +[8][0x23 - 1] = "HighX", +[8][0x24 - 1] = "Shenzhen Elicks Technology", +[8][0x25 - 1] = "ISSI/Chingis", +[8][0x26 - 1] = "Google Inc", +[8][0x27 - 1] = "Dasima International Development", +[8][0x28 - 1] = "Leahkinn Technology Limited", +[8][0x29 - 1] = "HIMA Paul Hildebrandt GmbH Co KG", +[8][0x2a - 1] = "Keysight Technologies", +[8][0x2b - 1] = "Techcomp International (Fastable)", +[8][0x2c - 1] = "Ancore Technology Corporation", +[8][0x2d - 1] = "Nuvoton", +[8][0x2e - 1] = "Korea Uhbele International Group Ltd", +[8][0x2f - 1] = "Ikegami Tsushinki Co Ltd", +[8][0x30 - 1] = "RelChip Inc", +[8][0x31 - 1] = "Baikal Electronics", +[8][0x32 - 1] = "Nemostech Inc", +[8][0x33 - 1] = "Memorysolution GmbH", +[8][0x34 - 1] = "Silicon Integrated Systems Corporation", +[8][0x35 - 1] = "Xiede", +[8][0x36 - 1] = "BRC", +[8][0x37 - 1] = "Flash Chi", +[8][0x38 - 1] = "Jone", +[8][0x39 - 1] = "GCT Semiconductor Inc", +[8][0x3a - 1] = "Hong Kong Zetta Device Technology", +[8][0x3b - 1] = "Unimemory Technology(s) Pte Ltd", +[8][0x3c - 1] = "Cuso", +[8][0x3d - 1] = "Kuso", +[8][0x3e - 1] = "Uniquify Inc", +[8][0x3f - 1] = "Skymedi Corporation", +[8][0x40 - 1] = "Core Chance Co Ltd", +[8][0x41 - 1] = "Tekism Co Ltd", +[8][0x42 - 1] = "Seagate Technology PLC", +[8][0x43 - 1] = "Hong Kong Gaia Group Co Limited", +[8][0x44 - 1] = "Gigacom Semiconductor LLC", +[8][0x45 - 1] = "V2 Technologies", +[8][0x46 - 1] = "TLi", +[8][0x47 - 1] = "Neotion", +[8][0x48 - 1] = "Lenovo", +[8][0x49 - 1] = "Shenzhen Zhongteng Electronic Corp Ltd", +[8][0x4a - 1] = "Compound Photonics", +[8][0x4b - 1] = "in2H2 inc", +[8][0x4c - 1] = "Shenzhen Pango Microsystems Co Ltd", +[8][0x4d - 1] = "Vasekey", +[8][0x4e - 1] = "Cal-Comp Industria de Semicondutores", +[8][0x4f - 1] = "Eyenix Co Ltd", +[8][0x50 - 1] = "Heoriady", +[8][0x51 - 1] = "Accelerated Memory Production Inc", +[8][0x52 - 1] = "INVECAS Inc", +[8][0x53 - 1] = "AP Memory", +[8][0x54 - 1] = "Douqi Technology", +[8][0x55 - 1] = "Etron Technology Inc", +[8][0x56 - 1] = "Indie Semiconductor", +[8][0x57 - 1] = "Socionext Inc", +[8][0x58 - 1] = "HGST", +[8][0x59 - 1] = "EVGA", +[8][0x5a - 1] = "Audience Inc", +[8][0x5b - 1] = "EpicGear", +[8][0x5c - 1] = "Vitesse Enterprise Co", +[8][0x5d - 1] = "Foxtronn International Corporation", +[8][0x5e - 1] = "Bretelon Inc", +[8][0x5f - 1] = "Graphcore", +[8][0x60 - 1] = "Eoplex Inc", +[8][0x61 - 1] = "MaxLinear Inc", +[8][0x62 - 1] = "ETA Devices", +[8][0x63 - 1] = "LOKI", +[8][0x64 - 1] = "IMS Electronics Co Ltd", +[8][0x65 - 1] = "Dosilicon Co Ltd", +[8][0x66 - 1] = "Dolphin Integration", +[8][0x67 - 1] = "Shenzhen Mic Electronics Technolog", +[8][0x68 - 1] = "Boya Microelectronics Inc", +[8][0x69 - 1] = "Geniachip (Roche)", +[8][0x6a - 1] = "Axign", +[8][0x6b - 1] = "Kingred Electronic Technology Ltd", +[8][0x6c - 1] = "Chao Yue Zhuo Computer Business Dept.", +[8][0x6d - 1] = "Guangzhou Si Nuo Electronic Technology.", +[8][0x6e - 1] = "Crocus Technology Inc", +[8][0x6f - 1] = "Creative Chips GmbH", +[8][0x70 - 1] = "GE Aviation Systems LLC.", +[8][0x71 - 1] = "Asgard", +[8][0x72 - 1] = "Good Wealth Technology Ltd", +[8][0x73 - 1] = "TriCor Technologies", +[8][0x74 - 1] = "Nova-Systems GmbH", +[8][0x75 - 1] = "JUHOR", +[8][0x76 - 1] = "Zhuhai Douke Commerce Co Ltd", +[8][0x77 - 1] = "DSL Memory", +[8][0x78 - 1] = "Anvo-Systems Dresden GmbH", +[8][0x79 - 1] = "Realtek", +[8][0x7a - 1] = "AltoBeam", +[8][0x7b - 1] = "Wave Computing", +[8][0x7c - 1] = "Beijing TrustNet Technology Co Ltd", +[8][0x7d - 1] = "Innovium Inc", +[8][0x7e - 1] = "Starsway Technology Limited", +[9][0x01 - 1] = "Weltronics Co LTD", +[9][0x02 - 1] = "VMware Inc", +[9][0x03 - 1] = "Hewlett Packard Enterprise", +[9][0x04 - 1] = "INTENSO", +[9][0x05 - 1] = "Puya Semiconductor", +[9][0x06 - 1] = "MEMORFI", +[9][0x07 - 1] = "MSC Technologies GmbH", +[9][0x08 - 1] = "Txrui", +[9][0x09 - 1] = "SiFive Inc", +[9][0x0a - 1] = "Spreadtrum Communications", +[9][0x0b - 1] = "XTX Technology Limited", +[9][0x0c - 1] = "UMAX Technology", +[9][0x0d - 1] = "Shenzhen Yong Sheng Technology", +[9][0x0e - 1] = "SNOAMOO (Shenzhen Kai Zhuo Yue)", +[9][0x0f - 1] = "Daten Tecnologia LTDA", +[9][0x10 - 1] = "Shenzhen XinRuiYan Electronics", +[9][0x11 - 1] = "Eta Compute", +[9][0x12 - 1] = "Energous", +[9][0x13 - 1] = "Raspberry Pi Trading Ltd", +[9][0x14 - 1] = "Shenzhen Chixingzhe Tech Co Ltd", +[9][0x15 - 1] = "Silicon Mobility", +[9][0x16 - 1] = "IQ-Analog Corporation", +[9][0x17 - 1] = "Uhnder Inc", +[9][0x18 - 1] = "Impinj", +[9][0x19 - 1] = "DEPO Computers", +[9][0x1a - 1] = "Nespeed Sysems", +[9][0x1b - 1] = "Yangtze Memory Technologies Co Ltd", +[9][0x1c - 1] = "MemxPro Inc", +[9][0x1d - 1] = "Tammuz Co Ltd", +[9][0x1e - 1] = "Allwinner Technology", +[9][0x1f - 1] = "Shenzhen City Futian District Qing Xuan Tong Computer Trading Firm", +[9][0x20 - 1] = "XMC", +[9][0x21 - 1] = "Teclast", +[9][0x22 - 1] = "Maxsun", +[9][0x23 - 1] = "Haiguang Integrated Circuit Design", +[9][0x24 - 1] = "RamCENTER Technology", +[9][0x25 - 1] = "Phison Electronics Corporation", +[9][0x26 - 1] = "Guizhou Huaxintong Semi-Conductor", +[9][0x27 - 1] = "Network Intelligence", +[9][0x28 - 1] = "Continental Technology (Holdings)", +[9][0x29 - 1] = "Guangzhou Huayan Suning Electronic", +[9][0x2a - 1] = "Guangzhou Zhouji Electronic Co Ltd", +[9][0x2b - 1] = "Shenzhen Giant Hui Kang Tech Co Ltd", +[9][0x2c - 1] = "Shenzhen Yilong Innovative Co Ltd", +[9][0x2d - 1] = "Neo Forza", +[9][0x2e - 1] = "Lyontek Inc", +[9][0x2f - 1] = "Shanghai Kuxin Microelectronics Ltd", +[9][0x30 - 1] = "Shenzhen Larix Technology Co Ltd", +[9][0x31 - 1] = "Qbit Semiconductor Ltd", +[9][0x32 - 1] = "Insignis Technology Corporation", +[9][0x33 - 1] = "Lanson Memory Co Ltd", +[9][0x34 - 1] = "Shenzhen Superway Electronics Co Ltd", +[9][0x35 - 1] = "Canaan-Creative Co Ltd", +[9][0x36 - 1] = "Black Diamond Memory", +[9][0x37 - 1] = "Shenzhen City Parker Baking Electronics", +[9][0x38 - 1] = "Shenzhen Baihong Technology Co Ltd", +[9][0x39 - 1] = "GEO Semiconductors", +[9][0x3a - 1] = "OCPC", +[9][0x3b - 1] = "Artery Technology Co Ltd", +[9][0x3c - 1] = "Jinyu", +[9][0x3d - 1] = "ShenzhenYing Chi Technology Development", +[9][0x3e - 1] = "Shenzhen Pengcheng Xin Technology", +[9][0x3f - 1] = "Pegasus Semiconductor (Shanghai) Co", +[9][0x40 - 1] = "Mythic Inc", +[9][0x41 - 1] = "Elmos Semiconductor AG", +[9][0x42 - 1] = "Kllisre", +[9][0x43 - 1] = "Shenzhen Winconway Technology", +[9][0x44 - 1] = "Shenzhen Xingmem Technology Corp", +[9][0x45 - 1] = "Gold Key Technology Co Ltd", +[9][0x46 - 1] = "Habana Labs Ltd", +[9][0x47 - 1] = "Hoodisk Electronics Co Ltd", +[9][0x48 - 1] = "SemsoTai (SZ) Technology Co Ltd", +[9][0x49 - 1] = "OM Nanotech Pvt. Ltd", +[9][0x4a - 1] = "Shenzhen Zhifeng Weiye Technology", +[9][0x4b - 1] = "Xinshirui (Shenzhen) Electronics Co", +[9][0x4c - 1] = "Guangzhou Zhong Hao Tian Electronic", +[9][0x4d - 1] = "Shenzhen Longsys Electronics Co Ltd", +[9][0x4e - 1] = "Deciso B.V.", +[9][0x4f - 1] = "Puya Semiconductor (Shenzhen)", +[9][0x50 - 1] = "Shenzhen Veineda Technology Co Ltd", +[9][0x51 - 1] = "Antec Memory", +[9][0x52 - 1] = "Cortus SAS", +[9][0x53 - 1] = "Dust Leopard", +[9][0x54 - 1] = "MyWo AS", +[9][0x55 - 1] = "J&A Information Inc", +[9][0x56 - 1] = "Shenzhen JIEPEI Technology Co Ltd", +[9][0x57 - 1] = "Heidelberg University", +[9][0x58 - 1] = "Flexxon PTE Ltd", +[9][0x59 - 1] = "Wiliot", +[9][0x5a - 1] = "Raysun Electronics International Ltd", +[9][0x5b - 1] = "Aquarius Production Company LLC", +[9][0x5c - 1] = "MACNICA DHW LTDA", +[9][0x5d - 1] = "Intelimem", +[9][0x5e - 1] = "Zbit Semiconductor Inc", +[9][0x5f - 1] = "Shenzhen Technology Co Ltd", +[9][0x60 - 1] = "Signalchip", +[9][0x61 - 1] = "Shenzen Recadata Storage Technology", +[9][0x62 - 1] = "Hyundai Technology", +[9][0x63 - 1] = "Shanghai Fudi Investment Development", +[9][0x64 - 1] = "Aixi Technology", +[9][0x65 - 1] = "Tecon MT", +[9][0x66 - 1] = "Onda Electric Co Ltd", +[9][0x67 - 1] = "Jinshen", +[9][0x68 - 1] = "Kimtigo Semiconductor (HK) Limited", +[9][0x69 - 1] = "IIT Madras", +[9][0x6a - 1] = "Shenshan (Shenzhen) Electronic", +[9][0x6b - 1] = "Hefei Core Storage Electronic Limited", +[9][0x6c - 1] = "Colorful Technology Ltd", +[9][0x6d - 1] = "Visenta (Xiamen) Technology Co Ltd", +[9][0x6e - 1] = "Roa Logic BV", +[9][0x6f - 1] = "NSITEXE Inc", +[9][0x70 - 1] = "Hong Kong Hyunion Electronics", +[9][0x71 - 1] = "ASK Technology Group Limited", +[9][0x72 - 1] = "GIGA-BYTE Technology Co Ltd", +[9][0x73 - 1] = "Terabyte Co Ltd", +[9][0x74 - 1] = "Hyundai Inc", +[9][0x75 - 1] = "EXCELERAM", +[9][0x76 - 1] = "PsiKick", +[9][0x77 - 1] = "Netac Technology Co Ltd", +[9][0x78 - 1] = "PCCOOLER", +[9][0x79 - 1] = "Jiangsu Huacun Electronic Technology", +[9][0x7a - 1] = "Shenzhen Micro Innovation Industry", +[9][0x7b - 1] = "Beijing Tongfang Microelectronics Co", +[9][0x7c - 1] = "XZN Storage Technology", +[9][0x7d - 1] = "ChipCraft Sp. z.o.o.", +[9][0x7e - 1] = "ALLFLASH Technology Limited", +[10][0x01 - 1] = "Foerd Technology Co Ltd", +[10][0x02 - 1] = "KingSpec", +[10][0x03 - 1] = "Codasip GmbH", +[10][0x04 - 1] = "SL Link Co Ltd", +[10][0x05 - 1] = "Shenzhen Kefu Technology Co Limited", +[10][0x06 - 1] = "Shenzhen ZST Electronics Technology", +[10][0x07 - 1] = "Kyokuto Electronic Inc", +[10][0x08 - 1] = "Warrior Technology", +[10][0x09 - 1] = "TRINAMIC Motion Control GmbH & Co", +[10][0x0a - 1] = "PixelDisplay Inc", +[10][0x0b - 1] = "Shenzhen Futian District Bo Yueda Elec", +[10][0x0c - 1] = "Richtek Power", +[10][0x0d - 1] = "Shenzhen LianTeng Electronics Co Ltd", +[10][0x0e - 1] = "AITC Memory", +[10][0x0f - 1] = "UNIC Memory Technology Co Ltd", +[10][0x10 - 1] = "Shenzhen Huafeng Science Technology", +[10][0x11 - 1] = "ChangXin Memory Technologies Inc", +[10][0x12 - 1] = "Guangzhou Xinyi Heng Computer Trading Firm", +[10][0x13 - 1] = "SambaNova Systems", +[10][0x14 - 1] = "V-GEN", +[10][0x15 - 1] = "Jump Trading", +[10][0x16 - 1] = "Ampere Computing", +[10][0x17 - 1] = "Shenzhen Zhongshi Technology Co Ltd", +[10][0x18 - 1] = "Shenzhen Zhongtian Bozhong Technology", +[10][0x19 - 1] = "Tri-Tech International", +[10][0x1a - 1] = "Silicon Intergrated Systems Corporation", +[10][0x1b - 1] = "Shenzhen HongDingChen Information", +[10][0x1c - 1] = "Plexton Holdings Limited", +[10][0x1d - 1] = "AMS (Jiangsu Advanced Memory Semi)", +[10][0x1e - 1] = "Wuhan Jing Tian Interconnected Tech Co", +[10][0x1f - 1] = "Axia Memory Technology", +[10][0x20 - 1] = "Chipset Technology Holding Limited", +[10][0x21 - 1] = "Shenzhen Xinshida Technology Co Ltd", +[10][0x22 - 1] = "Shenzhen Chuangshifeida Technology", +[10][0x23 - 1] = "Guangzhou MiaoYuanJi Technology", +[10][0x24 - 1] = "ADVAN Inc", +[10][0x25 - 1] = "Shenzhen Qianhai Weishengda Electronic Commerce Company Ltd", +[10][0x26 - 1] = "Guangzhou Guang Xie Cheng Trading", +[10][0x27 - 1] = "StarRam International Co Ltd", +[10][0x28 - 1] = "Shen Zhen XinShenHua Tech Co Ltd", +[10][0x29 - 1] = "UltraMemory Inc", +[10][0x2a - 1] = "New Coastline Global Tech Industry Co", +[10][0x2b - 1] = "Sinker", +[10][0x2c - 1] = "Diamond", +[10][0x2d - 1] = "PUSKILL", +[10][0x2e - 1] = "Guangzhou Hao Jia Ye Technology Co", +[10][0x2f - 1] = "Ming Xin Limited", +[10][0x30 - 1] = "Barefoot Networks", +[10][0x31 - 1] = "Biwin Semiconductor (HK) Co Ltd", +[10][0x32 - 1] = "UD INFO Corporation", +[10][0x33 - 1] = "Trek Technology (S) PTE Ltd", +[10][0x34 - 1] = "Xiamen Kingblaze Technology Co Ltd", +[10][0x35 - 1] = "Shenzhen Lomica Technology Co Ltd", +[10][0x36 - 1] = "Nuclei System Technology Co Ltd", +[10][0x37 - 1] = "Wuhan Xun Zhan Electronic Technology", +[10][0x38 - 1] = "Shenzhen Ingacom Semiconductor Ltd", +[10][0x39 - 1] = "Zotac Technology Ltd", +[10][0x3a - 1] = "Foxline", +[10][0x3b - 1] = "Shenzhen Farasia Science Technology", +[10][0x3c - 1] = "Efinix Inc", +[10][0x3d - 1] = "Hua Nan San Xian Technology Co Ltd", +[10][0x3e - 1] = "Goldtech Electronics Co Ltd", +[10][0x3f - 1] = "Shanghai Han Rong Microelectronics Co", +[10][0x40 - 1] = "Shenzhen Zhongguang Yunhe Trading", +[10][0x41 - 1] = "Smart Shine(QingDao) Microelectronics", +[10][0x42 - 1] = "Thermaltake Technology Co Ltd", +[10][0x43 - 1] = "Shenzhen O'Yang Maile Technology Ltd", +[10][0x44 - 1] = "UPMEM", +[10][0x45 - 1] = "Chun Well Technology Holding Limited", +[10][0x46 - 1] = "Astera Labs Inc", +[10][0x47 - 1] = "VMEMORY Co Ltd", +[10][0x48 - 1] = "Advantech Co Ltd", +[10][0x49 - 1] = "Chengdu Fengcai Electronic Technology", +[10][0x4a - 1] = "The Boeing Company", +[10][0x4b - 1] = "ThinCI Inc", +[10][0x4c - 1] = "Ramonster Technology Co Ltd", +[10][0x4d - 1] = "Wuhan Naonongmai Technology Co Ltd", +[10][0x4e - 1] = "Shenzhen Hui ShingTong Technology", +[10][0x4f - 1] = "Yourlyon", +[10][0x50 - 1] = "Fabu Technology", +[10][0x51 - 1] = "Shenzhen Yikesheng Technology Co Ltd", +[10][0x52 - 1] = "NOR-MEM", +[10][0x53 - 1] = "Cervoz Co Ltd", +[10][0x54 - 1] = "Bitmain Technologies Inc.", +[10][0x55 - 1] = "Facebook Inc", +[10][0x56 - 1] = "Shenzhen Longsys Electronics Co Ltd", +[10][0x57 - 1] = "Guangzhou Siye Electronic Technology", +[10][0x58 - 1] = "Silergy", +[10][0x59 - 1] = "Adamway", +[10][0x5a - 1] = "PZG", +[10][0x5b - 1] = "Shenzhen King Power Electronics", +[10][0x5c - 1] = "Guangzhou ZiaoFu Tranding Co Ltd", +[10][0x5d - 1] = "Shenzhen SKIHOTAR Semiconductor", +[10][0x5e - 1] = "PulseRain Technology", +[10][0x5f - 1] = "Seeker Technology Limited", +[10][0x60 - 1] = "Shenzhen OSCOO Tech Co Ltd", +[10][0x61 - 1] = "Shenzhen Yze Technology Co Ltd", +[10][0x62 - 1] = "Shenzhen Jieshuo Electronic Commerce", +[10][0x63 - 1] = "Gazda", +[10][0x64 - 1] = "Hua Wei Technology Co Ltd", +[10][0x65 - 1] = "Esperanto Technologies", +[10][0x66 - 1] = "JinSheng Electronic (Shenzhen) Co Ltd", +[10][0x67 - 1] = "Shenzhen Shi Bolunshuai Technology", +[10][0x68 - 1] = "Shanghai Rei Zuan Information Tech", +[10][0x69 - 1] = "Fraunhofer IIS", +[10][0x6a - 1] = "Kandou Bus SA", +[10][0x6b - 1] = "Acer", +[10][0x6c - 1] = "Artmem Technology Co Ltd", +[10][0x6d - 1] = "Gstar Semiconductor Co Ltd", +[10][0x6e - 1] = "ShineDisk", +[10][0x6f - 1] = "Shenzhen CHN Technology Co Ltd", +[10][0x70 - 1] = "UnionChip Semiconductor Co Ltd", +[10][0x71 - 1] = "Tanbassh", +[10][0x72 - 1] = "Shenzhen Tianyu Jieyun Intl Logistics", +[10][0x73 - 1] = "MCLogic Inc", +[10][0x74 - 1] = "Eorex Corporation", +[10][0x75 - 1] = "Arm Technology (China) Co Ltd", +[10][0x76 - 1] = "Lexar Co Limited", +[10][0x77 - 1] = "QinetiQ Group plc", +[10][0x78 - 1] = "Exascend", +[10][0x79 - 1] = "Hong Kong Hyunion Electronics Co Ltd", +[10][0x7a - 1] = "Shenzhen Banghong Electronics Co Ltd", +[10][0x7b - 1] = "MBit Wireless Inc", +[10][0x7c - 1] = "Hex Five Security Inc", +[10][0x7d - 1] = "ShenZhen Juhor Precision Tech Co Ltd", +[10][0x7e - 1] = "Shenzhen Reeinno Technology Co Ltd", +[11][0x01 - 1] = "ABIT Electronics (Shenzhen) Co Ltd", +[11][0x02 - 1] = "Semidrive", +[11][0x03 - 1] = "MyTek Electronics Corp", +[11][0x04 - 1] = "Wxilicon Technology Co Ltd", +[11][0x05 - 1] = "Shenzhen Meixin Electronics Ltd", +[11][0x06 - 1] = "Ghost Wolf", +[11][0x07 - 1] = "LiSion Technologies Inc", +[11][0x08 - 1] = "Power Active Co Ltd", +[11][0x09 - 1] = "Pioneer High Fidelity Taiwan Co. Ltd", +[11][0x0a - 1] = "LuoSilk", +[11][0x0b - 1] = "Shenzhen Chuangshifeida Technology", +[11][0x0c - 1] = "Black Sesame Technologies Inc", +[11][0x0d - 1] = "Jiangsu Xinsheng Intelligent Technology", +[11][0x0e - 1] = "MLOONG", +[11][0x0f - 1] = "Quadratica LLC", +[11][0x10 - 1] = "Anpec Electronics", +[11][0x11 - 1] = "Xi'an Morebeck Semiconductor Tech Co", +[11][0x12 - 1] = "Kingbank Technology Co Ltd", +[11][0x13 - 1] = "ITRenew Inc", +[11][0x14 - 1] = "Shenzhen Eaget Innovation Tech Ltd", +[11][0x15 - 1] = "Jazer", +[11][0x16 - 1] = "Xiamen Semiconductor Investment Group", +[11][0x17 - 1] = "Guangzhou Longdao Network Tech Co", +/* EOF */ diff --git a/lib/swd.c b/lib/swd.c new file mode 100644 index 0000000..273de57 --- /dev/null +++ b/lib/swd.c @@ -0,0 +1,324 @@ +/** library for Serial Wire Debug (SWD) communication + * @file + * @author King Kévin + * @copyright SPDX-License-Identifier: GPL-3.0-or-later + * @date 2018-2021 + * @note peripherals used: timer @ref swd_timer, GPIO @ref swd_gpio + * @implements "ARM Debug Interface Architecture Specification ADIv6.0" (ARM IHI 0074A) + * @note this library implements DP architecture version 3 (DPv3), but only DPv1 feature could be tested. + * @implements The physical layer (electrical characteristic and timing) is described in "ARM DSTREAM System and Interface Design Reference Guide" (ARM DUI0499K) + */ + +/* standard libraries */ +#include // standard integer types +#include // boolean type +#include // NULL definition + +/* STM32 (including CM3) libraries */ +#include // Cortex M3 utilities +#include // interrupt handler +#include // real-time control clock library +#include // general purpose input output library +#include // timer library + +/* own libraries */ +#include "global.h" // helper macros +#include "swd.h" // own definitions + +/** @defgroup swd_gpio GPIO used for SWDIO and SWCLK + * @{ + */ +#define SWD_SWCLK_PIN PB10 /**< GPIO pin for clock signal */ +#define SWD_SWDIO_PIN PB2 /**< GPIO pin for data input/output signal */ +/** @} */ + +/** @defgroup swd_timer timer used to generate a periodic clock + * @note the clock does not actually need to be periodic (it makes it just more readable) + * @{ + */ +#define SWD_TIMER 2 /**< timer ID */ +/** @} */ + +static volatile uint64_t swd_bits_out = 0; /** a buffer for the data bits to output/write (LSb first) */ +static volatile uint64_t swd_bits_in = 0; /** a buffer for the data bits to input/read (LSB first) */ +static volatile uint8_t swd_bits_count = 0; /** number of bits to read/write */ +static volatile uint8_t swd_bits_i = 0; /** transaction bit index */ + +void swd_setup(uint32_t freq) +{ + // setup GPIO for clock and data signals + rcc_periph_clock_enable(GPIO_RCC(SWD_SWCLK_PIN)); // enable clock for GPIO peripheral for clock signal + gpio_set(GPIO_PORT(SWD_SWCLK_PIN), GPIO_PIN(SWD_SWCLK_PIN)); // inactive clock is high + gpio_mode_setup(GPIO_PORT(SWD_SWCLK_PIN), GPIO_MODE_OUTPUT, GPIO_PUPD_NONE, GPIO_PIN(SWD_SWCLK_PIN)); // the host controls the clock + gpio_set_output_options(GPIO_PORT(SWD_SWCLK_PIN), GPIO_OTYPE_PP, GPIO_OSPEED_50MHZ, GPIO_PIN(SWD_SWCLK_PIN)); // set SWCLK pin output as push-pull + rcc_periph_clock_enable(GPIO_RCC(SWD_SWDIO_PIN)); // enable clock for GPIO peripheral for data signal + gpio_set(GPIO_PORT(SWD_SWDIO_PIN), GPIO_PIN(SWD_SWDIO_PIN)); // inactive data is high (resetting the target when clock is active) + gpio_mode_setup(GPIO_PORT(SWD_SWDIO_PIN), GPIO_MODE_OUTPUT, GPIO_PUPD_NONE, GPIO_PIN(SWD_SWDIO_PIN)); // the data signal is half duplex, with the host controlling who is driving the data signal when + gpio_set_output_options(GPIO_PORT(SWD_SWDIO_PIN), GPIO_OTYPE_PP, GPIO_OSPEED_50MHZ, GPIO_PIN(SWD_SWDIO_PIN)); // set SWDIO pin output as push-pull + + // setup timer to generate periodic clock + rcc_periph_clock_enable(RCC_TIM(SWD_TIMER)); // enable clock for timer peripheral + rcc_periph_reset_pulse(RST_TIM(SWD_TIMER)); // reset timer state + timer_disable_counter(TIM(SWD_TIMER)); // disable timer to configure it + timer_set_mode(TIM(SWD_TIMER), TIM_CR1_CKD_CK_INT, TIM_CR1_CMS_EDGE, TIM_CR1_DIR_UP); // set timer mode, use undivided timer clock, edge alignment (simple count), and count up + timer_set_prescaler(TIM(SWD_TIMER), 1 - 1); // don't use prescaler, allowing period down to 72 MHz / 2^16 = 1099 Hz + uint32_t period = rcc_ahb_frequency / freq / 2; // get period based on frequency (/2 because on cycle has 2 edges) + if (period > 0xffff) { // maximum frequency reached + period = 0xffff; + } else if (period > 0) { // not minimum frequency reached + period -= 1; // correct timer overflow offset + } + timer_set_period(TIM(SWD_TIMER), period); // set period the generate clock frequency (x2 for the two edges) + timer_clear_flag(TIM(SWD_TIMER), TIM_SR_UIF); // clear update (overflow) flag + timer_update_on_overflow(TIM(SWD_TIMER)); // only use counter overflow as UEV source (use overflow as start time or timeout) + timer_enable_irq(TIM(SWD_TIMER), TIM_DIER_UIE); // enable update interrupt for overflow to generate the clock signal + nvic_enable_irq(NVIC_TIM_IRQ(SWD_TIMER)); // catch interrupt in service routine + + // reset variables + swd_bits_count = 0; +} + +void swd_release(void) +{ + // release timer + timer_disable_counter(TIM(SWD_TIMER)); // disable timer + rcc_periph_reset_pulse(RST_TIM(SWD_TIMER)); // reset timer state + rcc_periph_clock_disable(RCC_TIM(SWD_TIMER)); // disable clock for timer peripheral + + // release GPIO + gpio_mode_setup(GPIO_PORT(SWD_SWCLK_PIN), GPIO_MODE_INPUT, GPIO_PUPD_NONE, GPIO_PIN(SWD_SWCLK_PIN)); // put clock signal pin back to input floating + gpio_mode_setup(GPIO_PORT(SWD_SWDIO_PIN), GPIO_MODE_INPUT, GPIO_PUPD_NONE, GPIO_PIN(SWD_SWDIO_PIN)); // put data signal pin back to input floating +} + +/** perform SWD transaction (one sequence of bits read or write) + * @param[in] output bits to write (LSb first) + * @param[in] bit_count number of bits to read/write + * @param[in] write true for write transaction, false for read transaction + * @return the bits read + */ +uint64_t swd_transaction(uint64_t output, uint8_t bit_count, bool write) +{ + // sanity check + if (0 == bit_count) { + return ~0ULL; + } + // initialize read/write + if (write) { + gpio_mode_setup(GPIO_PORT(SWD_SWDIO_PIN), GPIO_MODE_OUTPUT, GPIO_PUPD_NONE, GPIO_PIN(SWD_SWDIO_PIN)); // we drive the data signal to output data + swd_bits_out = output; // set data to output + } else { + gpio_mode_setup(GPIO_PORT(SWD_SWDIO_PIN), GPIO_MODE_INPUT, GPIO_PUPD_PULLUP, GPIO_PIN(SWD_SWDIO_PIN)); // the target will drive the data signal, we just pull it up + swd_bits_out = ~0ULL; // set the value so we pull up + } + swd_bits_in = 0; // reset input buffer + swd_bits_count = bit_count; // set the number of bits to read/write + swd_bits_i = 0; // reset read index + // start transaction + timer_enable_counter(TIM(SWD_TIMER)); // start timer + while (swd_bits_i < swd_bits_count) { // wait until all bits are transmitted + __WFI(); // go to sleep + } + return swd_bits_out; +} + +void swd_line_reset(void) +{ + swd_transaction(~0ULL, 50+1, true); // sent high for at least 50 cycle to issue line reset and put target in reset state +} + +void swd_jtag_to_swd(void) +{ + swd_transaction(0xE79E, 16, true); // the sequence is a constant magic value +} + +void swd_swd_to_jtag(void) +{ + swd_transaction(0xE73C, 16, true); // the sequence is a constant magic value +} + +void swd_idle_cycles(uint8_t nb) +{ + swd_transaction(0, nb, true); // idle has data signal low +} + +void swd_packet_request(bool apndp, uint8_t a, bool rnw) +{ + uint8_t request = (1<<0)|(0<<6)|(1<<7); // start, stop, and park bits are set + if (apndp) { + request |= (1<<1); // set APnDP bit + } + if (rnw) { + request |= (1<<2); // set RnW bit + } + request |= ((a & 0xc)<<1); // set A[3:2] + static const bool parity_lut[] = {false, true, true, false, true, false, false, true, true, false, false, true, false, true, true, false}; // true if the number of 1's is a 4-bit value is odd, false else + if (parity_lut[(request >> 1) & 0xf]) { + request |= (1<<5); // set even parity bit + } + swd_transaction(request, 8, true); // write packet request +} + +void swd_turnaround(uint8_t nb) +{ + swd_transaction(~0ULL, nb, false); // switch to input to read and pull up +} + +enum swd_ack_e swd_acknowledge_response(void) +{ + return swd_transaction(~0ULL, 3, false) & 0x7; // read 3 bits +} + +void swd_write(uint32_t wdata) +{ + swd_transaction(wdata | ((0 == __builtin_parity(wdata)) ? (0ULL << 32) : (1ULL << 32)), 33, true); // set parity and send data +} + +bool swd_read(uint32_t* rdata) +{ + uint64_t data = swd_transaction(~0UL, 33, false); // read 33 bits + *rdata = data; // return the 32 bits of read data + return ((0==__builtin_parity(*rdata)) ? (0ULL << 32) : (1ULL << 32)) == (data & (1ULL << 32)); // check parity +} + +void swd_jtag_to_ds(void) +{ + swd_transaction(~0ULL, 5, true); // place JTAG TAP in TLR state + swd_transaction(0x33BBBBBA, 21, true); // send JTAG-to-DS select sequence +} + +void swd_swd_to_ds(void) +{ + swd_transaction(~0ULL, 50+1, true); // place SWD TAP is reset state + swd_transaction(0xE3BC, 16, true); // send SWD-to-DS select sequence +} + +void swd_selection_alert(enum swd_activation_code_e activation_code) +{ + swd_transaction(~0ULL, 5, true); // ensure selection alert is detected + swd_transaction(0x6209F392, 32, true); // send selection alert sequence (part 1) + swd_transaction(0x86852D95, 32, true); // send selection alert sequence (part 2) + swd_transaction(0xE3DDAFE9, 32, true); // send selection alert sequence (part 3) + swd_transaction(0x19BC0EA2, 32, true); // send selection alert sequence (part 4) + swd_transaction(0, 4, true); // send 4 low cycles + // send activation code, if known + switch (activation_code) { + case SWD_ACTIVATION_CODE_JTAG: + swd_transaction(0, 24, true); + break; + case SWD_ACTIVATION_CODE_SWDP: + swd_transaction(0x58, 16, true); + break; + case SWD_ACTIVATION_CODE_JTAGDP: + swd_transaction(0x50, 16, true); + break; + default: + break; // unknown, but let the user issue it using swd_transaction + } +} + +/** name of the manufacturer corresponding to its bank and id + * @implements JEDEC JEP106 + * @note auto-generated and provided by the OpenOCD project ( https://sourceforge.net/p/openocd/code/ci/master/tree/src/helper/jep106.inc?format=raw ) + */ +static const char * const swd_jep106[][126] = { +#include "jep106.inc" +}; + +const char *swd_jep106_manufacturer(uint8_t bank, uint8_t id) +{ + // check id + if (id < 1 || id > 126) { + return ""; + } + + // index is zero based + id--; + + // check band and name + if (bank >= LENGTH(swd_jep106) || 0 == swd_jep106[bank][id]) { + return ""; + } + + return swd_jep106[bank][id]; +} + +static const struct swd_partno_s { + uint16_t designer; + uint8_t partno; + const char* name; +} swd_partno[] = { + // based on https://developer.arm.com/docs/103489943/latest/what-is-the-id-code-of-a-cortex-m0-dap-or-cortex-m0-dap + { + .designer = 0x23B, // ARM + .partno = 0xBA, + .name = "CM3DAP", // used in Cortex-M3 and Cortex-M4 + }, + { + .designer = 0x23B, // ARM + .partno = 0xBB, + .name = "CM0DAP", // used in Cortex-M0 + }, + { + .designer = 0x23B, // ARM + .partno = 0xBC, + .name = "CM0PDAP", // used in Cortex-M0+ + }, +}; + +const char* swd_dpidr_partno(uint16_t designer, uint8_t partno) +{ + uint32_t i = 0; // swd_partno index + // find matching part number + for (i = 0; i < LENGTH(swd_partno); i++) { + if (designer == swd_partno[i].designer && partno == swd_partno[i].partno) { + break; + } + } + if (i < LENGTH(swd_partno)) { + return swd_partno[i].name; + } else { + return ""; + } +} + +/** interrupt service routine called for timer + * + * this is just acting as a shift register + * the host will write data on the falling edge, and read data just before the rising edge (we could also do it on the rising edge) + * the target will read and write data signal on clock rising edge + * this phase shift is not very clear in the standard, but explains the line turn-round cycle when switching between writing and reading. + * + * only this ISR should change the data and clock signal output + * the timer stops on rising edge when the last bit is sent + * @implements ARM DUI0499K 2.1.2 Serial Wire Debug + */ +void TIM_ISR(SWD_TIMER)(void) +{ + static bool edge_falling = true; + if (timer_get_flag(TIM(SWD_TIMER), TIM_SR_UIF)) { // overflow update event happened + timer_clear_flag(TIM(SWD_TIMER), TIM_SR_UIF); // clear flag + if (swd_bits_i >= swd_bits_count) { // end of activity reached, and no data has been made available in time + timer_disable_counter(TIM(SWD_TIMER)); // disable timer + return; // nothing to do + } + if (edge_falling) { // falling edge: we output data + if (swd_bits_out & (1ULL << swd_bits_i)) { // output data, LSb first + gpio_set(GPIO_PORT(SWD_SWDIO_PIN), GPIO_PIN(SWD_SWDIO_PIN)); // output high + } else { + gpio_clear(GPIO_PORT(SWD_SWDIO_PIN), GPIO_PIN(SWD_SWDIO_PIN)); // output low + } + gpio_clear(GPIO_PORT(SWD_SWCLK_PIN), GPIO_PIN(SWD_SWCLK_PIN)); // output falling clock edge + } else { // rising edge: read data + if (gpio_get(GPIO_PORT(SWD_SWDIO_PIN), GPIO_PIN(SWD_SWDIO_PIN))) { // read data + swd_bits_out |= (1ULL << swd_bits_i); // set bit + } else { + swd_bits_out &= ~(1ULL << swd_bits_i); // clear bit + } + swd_bits_i++; + gpio_set(GPIO_PORT(SWD_SWCLK_PIN), GPIO_PIN(SWD_SWCLK_PIN)); // output rising clock edge + } + edge_falling = !edge_falling; // remember opposite upcoming edge + } else { // no other interrupt should occur + while (true); // unhandled exception: wait for the watchdog to bite + } +} diff --git a/lib/swd.h b/lib/swd.h new file mode 100644 index 0000000..c08eada --- /dev/null +++ b/lib/swd.h @@ -0,0 +1,197 @@ +/** library for Serial Wire Debug (SWD) communication + * @file + * @author King Kévin + * @copyright SPDX-License-Identifier: GPL-3.0-or-later + * @date 2018-2021 + * @note peripherals used: timer @ref swd_timer, GPIO @ref swd_gpio + * @implements "ARM Debug Interface Architecture Specification ADIv6.0" (ARM IHI 0074A) + * @note this library implements DP architecture version 3 (DPv3), but only DPv1 feature could be tested. + * @implements The physical layer (electrical characteristic and timing) is described in "ARM DSTREAM System and Interface Design Reference Guide" (ARM DUI0499K) + */ +/** @remark{ + * This library implements DP architecture version 3 (DPv3), but only DPv1 feature could be tested. + * + * See B2.1.1 DP architecture versions summary for more details about the versions: + * - DPv0 is only available using JTAG (e.g. does not support SWD). + * - DPv1 introduces SWD (with protocol version 1). + * - DPv2 adds multi-drop support (with protocol version 2). + * - DPv3 add register for 64-bit support. + * + * I couldn't find any hardware supporting SWD protocol version 2 to test DPv2 and DPv3 features, in particular dormant state and target select. + * According to https://developer.arm.com/docs/103489514/latest/does-the-cortex-m3-or-cortex-m4-processor-that-i-have-licensed-support-multi-drop-serial-wire-debug, although it is a property of the debug standard (e.g. CoreSight block) rather than core, no Cortex-M3 or Cortex-M4 seem to support DPv2/SWDv2. + * } + */ +#pragma once + +/** Debug Port (DP) register address + * @implements ARM IHI 0074A B2.1.2 DP architecture version 3 (DPv3) address map + */ +enum swd_a_dp_e { + SWD_A_DP_DPIDR = 0x0, /**< Debug Port Identification Register (DP: v1, access: RO) */ + SWD_A_DP_DPIDR1 = 0x0, /**< Debug Port Identification Register 1 (DP: v3, access: RO) */ + SWD_A_DP_BASEPTR0 = 0x0, /**< Base Pointer 0 (DP: v3, access: RO) */ + SWD_A_DP_BASEPTR1 = 0x0, /**< Base Pointer 1 (DP: v3, access: RO) */ + SWD_A_DP_ABORT = 0x0, /**< AP Abort register (DP: v0, access: WO) */ + SWD_A_DP_CTRL_STAT = 0x4, /**< Control/Status register (DP: v0, access: RW) */ + SWD_A_DP_DLCR = 0x4, /**< Data Link Control Register (DP: v1, access: RW) */ + SWD_A_DP_TARGETID = 0x4, /**< Target Identification register (DP: v2, access: RO) */ + SWD_A_DP_DLPIDR = 0x4, /**< Data Link Protocol Identification Register (DP: v2, access: RO) */ + SWD_A_DP_EVENTSTAT = 0x4, /**< Event Status register (DP: v0, access: RO) */ + SWD_A_DP_SELECT1 = 0x4, /**< AP Select register 1 (DP: v3, access: WO) */ + SWD_A_DP_SELECT = 0x8, /**< AP Select register (DP: v0, access: WO) */ + SWD_A_DP_RESEND = 0x8, /**< Read Resend register (DP: v1, access: RO) */ + SWD_A_DP_RDBUFF = 0xc, /**< Read Buffer register (DP: v0, access: RO) */ + SWD_A_DP_TARGETSEL = 0xc, /**< Target Selection register (DP: v2, access: WO) */ +}; + +/** Access Port (AP) MEM-AP register address + * @implements ARM IHI 0074A C2.5 MEM-AP Programmers’ Model + * @note only the registers addressable with A[3:2] are included + */ +enum swd_a_ap_memap_e { + SWD_A_AP_MEMAP_CSW = 0x0, /**< Control/Status Word register (access: RW) */ + SWD_A_AP_MEMAP_TAR = 0x4, /**< Transfer Address Register (access: RW) */ + SWD_A_AP_MEMAP_TAR_EXT = 0x8, /**< Transfer Address Register, large physical address extension (access: RW) */ + SWD_A_AP_MEMAP_DRW = 0xc, /**< Data Read/Write register (access: RW) */ +}; + +/** Access Port (AP) JTAG-AP register address + * @implements ARM IHI 0074A C3.4 JTAG-AP programmers’ model + * @note only the registers addressable with A[3:2] are included + */ +enum swd_a_ap_jtagap_e { + SWD_A_AP_JTAGAP_CSW = 0x0, /**< Control/Status Word register (access: RW) */ + SWD_A_AP_JTAGAP_PSEL = 0x4, /**< Port Select register (access: RW) */ + SWD_A_AP_JTAGAP_PSTA = 0x8, /**< Port Status Register (access: RW) */ +}; + +/** ACk acknowledge response + * @implements ARM IHI 0074A B4.2 SWD protocol operation + */ +enum swd_ack_e { + SWD_ACK_OK = 0x1, /**< Successful operation */ + SWD_ACK_WAIT = 0x2, /**< Wait for response */ + SWD_ACK_FAULT = 0x4, /**< Fault */ + SWD_ACK_ERROR = 0x7, /**< Error (pulled-up line not driven) */ +}; + +/** Activation codes + * @implements ARM IHI 0074A B5.3.4 Leaving dormant state + */ +enum swd_activation_code_e { + SWD_ACTIVATION_CODE_JTAG, /**< JTAG-Serial */ + SWD_ACTIVATION_CODE_SWDP, /**< ARM CoreSight SW-DP */ + SWD_ACTIVATION_CODE_JTAGDP, /**< ARM CoreSight JTAG-DP */ +}; + +/** setup SWD peripheral + */ +void swd_setup(uint32_t freq); +/** release 1-wire peripheral + */ +void swd_release(void); + +/* DPv1/SWDv1 operations */ + +/** send line reset sequence to put target in reset state + * @implements ARM IHI 0074A B4.3.3 Connection and line reset sequence + * @note this does not include the tailing idle cycles + */ +void swd_line_reset(void); +/** send JTAG to SWD sequence to switch the target SWJ-DP from JTAG to SWD + * @note a line reset must be perform just before + * @implements ARM IHI 0074A B5.2.2 Switching from JTAG to SWD operation + */ +void swd_jtag_to_swd(void); +/** send SWD to JTAG sequence to switch the target SWJ-DP from SWD to JTAG + * @note a line reset must be perform just before + * @implements ARM IHI 0074A B5.2.3 Switching from SWD to JTAG operation + */ +void swd_swd_to_jtag(void); +/** send idle cycles + * @param[in] nb number idle cycles to send + * @note at least two idle cycles a required after a line reset and before a packet request + * @implements ARM IHI 0074A B4.1.4 Idle cycles + */ +void swd_idle_cycles(uint8_t nb); +/** send packet request + * @param[in] apndp true to access the Access Port (AP) or false to access the Debug Port (DP) access register + * @param[in] a address field for the DP or AP register Address (complete address, not just bits 3:2) + * @param[in] rnw true for read access, false for write access + * @implements ARM IHI 0074A B4.2 SWD protocol operation + */ +void swd_packet_request(bool apndp, uint8_t a, bool rnw); +/** insert turnaround cycle + * @param[in] nb number idle for the turnaround (by default 1, else set in DLCR.TURNROUND) + * @note used to switch between reading and writing on the data signal + * @implements ARM IHI 0074A B4.1.3 Line turnaround + */ +void swd_turnaround(uint8_t nb); +/** read acknowledge response (ACK) + * @return ACK + * @implements ARM IHI 0074A B4.2 SWD protocol operation + */ +enum swd_ack_e swd_acknowledge_response(void); +/** write data + * @param[in] wdata data to write + * @implements ARM IHI 0074A B4.2 SWD protocol operation + */ +void swd_write(uint32_t wdata); +/** read data + * @param[out] rdata read data + * @return if parity check passed + * @implements ARM IHI 0074A B4.2 SWD protocol operation + */ +bool swd_read(uint32_t* rdata); + +/* DPv2/SWDv2 operations */ + +/** send JTAG to dormant state (DS) sequence + * @note the preceding line reset does not seem mandatory, but recommended + * @implements ARM IHI 0074A B5.3.2 Switching from JTAG to dormant state + * @remark it is not mentioned what happens if the TAP is in SWD state (probably nothing) + */ +void swd_jtag_to_ds(void); + +/** send SWD to dormant state (DS) sequence + * @note no preceding line reset is requires + * @implements ARM IHI 0074A B5.3.3 Switching from SWD to dormant state + * @remark it is not mentioned what happens if the TAP is in JTAG state (probably nothing) + */ +void swd_swd_to_ds(void); + +/** send selection code and activation alert to leave dormant state and go into JTAG or SWD mode + * @param[in] activation_code activation code to select protocol (JTAG, or SWD) + * @implements ARM IHI 0074A B5.3.3 Switching from SWD to dormant state + * @remark it is not mentioned what happens if the TAP is in any other state + */ +void swd_selection_alert(enum swd_activation_code_e activation_code); + + +/** perform SWD transaction (one sequence of bits read or write) + * @param[in] output bits to write (LSb first) + * @param[in] bit_count number of bits to read/write + * @param[in] write true for write transaction, false for read transaction + * @return the bits read + * @note this should only be used for unimplemented operations + */ +uint64_t swd_transaction(uint64_t output, uint8_t bit_count, bool write); + +/** get manufacturer name corresponding to the designer id + * @param[in] bank bank number (first 4 bits of the DESIGNER value) + * @param[in] id JEP106 id (last 7 bits of the DESIGNER value) + * @return manufacturer name + * @implements JEDEC JEP106 + * @note from the OpenOCD project + * @date 2015 + * @copyright Andreas Fritiofson + */ +const char* swd_jep106_manufacturer(uint8_t bank, uint8_t id); + +/** get DAP name corresponding to the DPIDR part number + * @param[in] designer DESIGNER value + * @param[in] partno DPIDR part number + * @return DAP name + */ +const char* swd_dpidr_partno(uint16_t designer, uint8_t partno); +