HCS512 HCS512 KEELOQ Code Hopping Decoder FEATURES DESCRIPTION The Microchip Technology Inc. HCS512 is a code hop- Security ping decoder designed for secure Remote Keyless Secure storage of Manufacturers Code Entry (RKE) systems. The HCS512 utilizes the pat- ented KEELOQ code hopping system and high security Secure storage of transmitters keys learning mechanisms to make this a canned solution Up to four transmitters can be learned when used with the HCS encoders to implement a uni- EELOQ code hopping technology K directional remote keyless entry system. Normal and secure learning mechanisms PACKAGE TYPE Operating PDIP, SOIC 4.0V 6.0V operation 4 MHz external RC oscillator LRNIN 1 18 RFIN Learning indication on LRNOUT LRNOUT 2 17 NC Auto baud rate detection NC 3 16 OSCIN Power saving SLEEP mode MCLR 4 15 OSCOUT Other GND 5 14 VDD Stand-alone decoder S0 6 13 DATA On-chip EEPROM for transmitter storage Four binary function outputs15 functions S1 7 12 CLK 18-pin DIP/SOIC package S2 8 11 SLEEP Typical Applications S3 9 10 VLOW Automotive remote entry systems Automotive alarm systems BLOCK DIAGRAM Automotive immobilizers RFIN Gate and garage openers Reception Register Electronic door locks DECRYPTOR Identity tokens Burglar alarm systems DATA EEPROM CONTROL CLK Compatible Encoders LRNIN All KEELOQ encoders and transponders configured for MCLR OSCIN OSCILLATOR SLEEP the following setting: PWM modulation format (1/3-2/3) OUTPUT CONTROL TE in the range from 100 s to 400 s S0 S1 S2 S3 VLOW LRNOUT E Header 10 x T 28-bit Serial Number The Manufacturers Code, transmitter keys, and syn- 16-bit Synchronization counter chronization information are stored in protected on- Discrimination bits equal to Serial Number 8 LSbs chip EEPROM. The HCS512 uses the DATA and CLK 66- to 69-bit length code word. inputs to load the Manufacturers Code which cannot be read out of the device. 2011 Microchip Technology Inc. DS40151E-page 1HCS512 The HCS512 operates over a wide voltage range of during normal operation to derive the crypt 3.0 volts to 6.0 volts. The decoder employs automatic key and decrypt the received code words baud rate detection which allows it to compensate for encrypted portion. wide variations in transmitter data rate. The decoder - Secure Learn contains sophisticated error checking algorithms to The transmitter is activated through a special ensure only valid codes are accepted. button combination to transmit a stored 60-bit seed value used to generate the transmitters crypt key. The receiver uses this seed value 1.0 SYSTEM OVERVIEW to derive the same crypt key and decrypt the Key Terms received code words encrypted portion. Manufacturers code A unique and secret 64- The following is a list of key terms used throughout this bit number used to generate unique encoder crypt EELOQ and data sheet. For additional information on K Code Hopping, refer to Technical Brief 3 (TB003). keys. Each encoder is programmed with a crypt key that is a function of the manufacturers code. RKE - Remote Keyless Entry Each decoder is programmed with the manufac- Button Status - Indicates what button input(s) turer code itself. activated the transmission. Encompasses the 4 button status bits S3, S2, S1 and S0 (Figure 8-2). 1.1 HCS Encoder Overview Code Hopping - A method by which a code, The HCS encoders have a small EEPROM array which viewed externally to the system, appears to must be loaded with several parameters before use. change unpredictably each time it is transmitted. The most important of these values are: Code word - A block of data that is repeatedly A crypt key that is generated at the time of pro- transmitted upon button activation (Figure 8-1). duction Transmission - A data stream consisting of A 16-bit synchronization counter value repeating code words (Figure 8-1). A 28-bit serial number which is meant to be Crypt key - A unique and secret 64-bit number unique for every encoder used to encrypt and decrypt data. In a symmetri- cal block cipher such as the KEELOQ algorithm, The manufacturer programs the serial number for each the encryption and decryption keys are equal and encoder at the time of production, while the Key Gen- will therefore be referred to generally as the crypt eration Algorithm generates the crypt key (Figure 1-1). key. Inputs to the key generation algorithm typically consist Encoder - A device that generates and encodes of the encoders serial number and a 64-bit manufac- data. turers code, which the manufacturer creates. Encryption Algorithm - A recipe whereby data is Note: The manufacturer code is a pivotal part of scrambled using a crypt key. The data can only be the systems overall security. Conse- interpreted by the respective decryption algorithm quently, all possible precautions must be using the same crypt key. taken and maintained for this code. Decoder - A device that decodes data received from an encoder. Decryption algorithm - A recipe whereby data scrambled by an encryption algorithm can be unscrambled using the same crypt key. Learn Learning involves the receiver calculating the transmitters appropriate crypt key, decrypting the received hopping code and storing the serial number, synchronization counter value and crypt key in EEPROM. The KEELOQ product family facil- itates several learning strategies to be imple- mented on the decoder. The following are examples of what can be done. - Simple Learning The receiver uses a fixed crypt key, common to all components of all systems by the same manufacturer, to decrypt the received code words encrypted portion. - Normal Learning The receiver uses information transmitted DS40151E-page 2 2011 Microchip Technology Inc.