English
Language : 

HCS515_11 Datasheet, PDF (17/38 Pages) Microchip Technology – KEELOQ® Code Hopping Decoder stand-alone decoder
HCS515
6.0 KEY GENERATION
The HCS515 supports two learning schemes which are selected during the initialization of the system EEPROM. The
learning schemes are:
• Normal learn using the KEELOQ decryption algorithm
• Secure learn using the KEELOQ decryption algorithm
6.1 Normal (Serial Number derived) Learn using the Decryption Algorithm
This learning scheme uses the KEELOQ decryption algorithm and the 28-bit serial number of the transmitter to derive
the encoder decryption key. The 28-bit serial number is patched with predefined values as indicated below to form two
32-bit seeds.
SourceH = 60000000 00000000H + Serial Number | 28 bits
SourceL = 20000000 00000000H + Serial Number | 28 bits
Then, using the KEELOQ decryption algorithm and the manufacturer’s code the encoder decryption key is
derived as follows:
KeyH Upper 32 bits = F KEELOQ Decryption (SourceH) | 64-bit Manufacturer’s Code
KeyL Lower 32 bits = F KEELOQ Decryption (SourceL) | 64-bit Manufacturer’s Code
6.2 Secure (Seed Derived) Learn using the Decryption Algorithm
This scheme uses the secure seed transmitted by the encoder to derive the two input seeds. The decoder always uses
the lower 64 bits of the transmission to form a 60-bit seed. The upper 4 bits are always forced to zero.
For 32-bit seed encoders:
SourceH = Serial Number Lower 28 bits
SourceL = Seed 32 bits
For 48-bit seed encoders:
SourceH = Seed Upper 16 bits + Serial Number Upper 16 bits (with upper 4 bits set to zero) << 16
SourceL = Seed Lower 32 bits
For 60-bit seed encoders:
SourceH = Seed Upper 28 bits with upper 4 bits set to zero
SourceL = Seed Lower 32 bits
The KEELOQ decryption algorithm and the manufacturer’s code is used to derive the encoder decryption key as
follows:
KeyH Upper 32 bits = Decrypt (SourceH) 64-bit Manufacturer’s Code
KeyL Lower 32 bits = Decrypt (SourceL) 64-bit Manufacturer’s Code
© 2011 Microchip Technology Inc.
DS40183E-page 17