Silicon Laboratories Si4010 User Manual

Si4010-Keyfob-AES-DEMO
Si4010 KEY FOB DEMO KIT WITH AES CAPABILITY U
SERS GUIDE

1. Purpose

Thank you for your interest in Silicon Laboratories’ Si4010 SoC RF key fob demo kit with AES capability. The Silicon Laboratories Si4010 key fob demo kit with AES capability contains everything you need to familiarize yourself with and evaluate the Si4010 RF SoC. The kit has two versions, one for the 434 MHz band and one for the 868 MHz band. The key features of the developme nt pla tform are as fo llows :
The key fob demo board has five push buttons and one LED output, a PCB antenna, and a battery in a plastic
case.
The key fob uses hardware-accelerated 128-bit advanced encryption standard (AES) encryption and rolling
counter for RKE application.
The receiver demo board has a graphic LCD to display received key fob commands.The provided software pack contains all the d ocum entation and files needed to develop a user application. Th e
kit supports the use of Silicon Laboratories’ Integrated Development Environment (IDE) for software debugging and the use of the Keil C compiler, assembler, and linker toolchain.
Contains demo applications using API functions and the key fob demo application.

2. Kit Contents

The kit contains the following items:
Qty Part Number Description
4010-DAAKF_434 Si4010 Key Fob Demo Kit with AES Capability 434 MHz
1 4010-DAPB_434 Si4010 Universal Key Fob 434 MHz 1 4313-DACB_ANY Si4313 LCD FSK/OOK Receiver any band 1 MSC-AT50-434 434 MHz Antenna 1 MSC-PLPB_1 Key Fob Plastic Case (translucent grey) 1 CRD2032 CR2032 3 V coin battery 1 MSC-DKSW1 Wireless Development Suite disc
4010-DAAKF_868 Si4010 Key Fob Demo Kit with AES Capability 868 MHz
1 4010-DAPB_868 Si4010 Universal Key Fob 868 MHz 1 4313-DACB_ANY Si4313 LCD FSK/OOK Receiver any band 1 MSC-AT50-868 868 MHz Antenna 1 MSC-PLPB_2 Key Fob Plastic Case (translucent red) 1 CRD2032 CR2032 3 V coin battery 1 MSC-DKSW1 Wireless Development Suite disc
Rev 1.1 4/11 Copyright © 2011 by Silicon Laboratories Si4010-Keyfob-AES-DEMO
Si4010-Keyfob-AES-DEMO

Figure 1. Si4010 Universal Key Fob and Plastic Case (P/N 4010-DAPB 868 and MSC-PLPB_1)

Figure 2. Si4313 LCD FSK/OOK Receiver Any-Band (P/N 4313-DACB ANY) with 434 MHz Antenna
(P/N MSC-AT50-434)
2 Rev 1.1
Si4010-Keyfob-AES-DEMO

3. Key Fob Demo with AES Capability

The 4010-DAPB RKE key fob transmitter and the Si4313 FSK receiver are the transmit and receive devices used in this key fob demo. This transmit/receive pair can be used to evaluate the capabilities of the Si4010 transmitter and the Si4313 receiver.

3.1. Operation of the Demo

The Si4313 demo receiver board uses the following RF parameters:
9.6 kbpsFSK modulation433.92 MHz or 868.3 MHz center frequency (menu selectable)±70 kHz deviation
If any push button is pressed on the key fob, it sends a message to the receiver. The demo uses Silicon Labs' general EZMacPRO protocol.

Table 1. General EZMacPRO Extended Packet Configuration Used by Demo Key Fobs

Preamble SynchWord MACHeader MACPayload CRC
Min.13 bytes 2 bytes 5 bytes 0...64 bytes 2 bytes 0xAA...0xAA 0x2DD4 CTRL CID SID DID PL NHDR NWK payload CRC

3.2. Association

To enable the receiver to react to the button presses on the key fob(s), they have to be paired (i.e., the key fob has to be associated to the receiver by pressing the left and right buttons simultaneously on the key fob).

Table 2. The MAC Payload Field of the “Associate Request from TX only Device” Packet

MACPayload
NHDR NWK Payload
1 byte 1 bytes 1 byte 1 byte 4 byte 4 byte
0x47 0x05 0x01 AES Address Rolling Counter

3.2.1. Meanings of the Different Fields

AES—Defines whether the transmitter is using AES-128 encryption or not. It is set to 0x01; then, the Rolling
counter field of the packets is extended to 16 bytes length (12 dummy bytes are appended) and is encoded by AES-128. Other fields of the packet are not affected by the encryption.
Address—4 bytes of key fob address. The four byte random number factory burned in the Si4010 is used as
the address.
Rolling Counter—The transmitter increments a 4 byte counter after every packet transmission. This counter is
stored in the MTP memory of the Si4010.
If the receiver accepts the association, it registers the Address, Master Key, and Rolling Counter value of the requesting key fob.
The Master accepts the association if it is in pairing mode and there is a free slot for a key fob (i.e., if there are fewer than four key fobs associated to the receiver).
After power up, the Receiver board is in pairing mode automatically. After pairing, it goes to normal packet reception mode. The Pairing mode can be invoked by pressing the push button, PB3, on the Receiver Board. This button needs to be pressed before the second and any subsequent pairing. If the PB is pressed for more than one second, the receiver disassociates all key fobs.
Rev 1.1 3
Si4010-Keyfob-AES-DEMO

3.3. Button is Pressed on the Key Fob

If any single button or button combination (except association combination) is pressed on the key fob, then it transmits a key fob data packet showing the button number in the button field.

Table 3. The MAC Payload Field of the “Key Fob Data” Packet

MAC Payload
NHDR NWK payload
1byte 1byte 4bytes 1byte 2bytes 1byte 4byte
0x04 AES Address Button TEMP Battery Rolling Counter

3.3.1. Meaning of the Different Fields

AES—Defines whether the transmitter is using AES-128 encryption. It is set to 0x01, then Button, Temp,
Battery, and Rolling counter fields of the packets are extended to 16 bytes length all together and are encoded by AES-128. Other fields of the packet are not affected by the encryption.
Address—4 bytes of key fob address. The four-byte random number factory burned in the Si4010 is used as
the address.
Button—Each bit of this byte corresponds to the status of a push button on the key fob. If the bit is set, the
given button is pressed. If the bit is cleared, the button is released.
TEMP—The temperature is encoded as a signed 16-bit integer. Each incremental bit of temperature reading
represents 0.1 °C. If the temperature function is not implemented in the key fob, this field is set to 0xFFFF.
Battery—1 byte unsigned char showing the actual power supply status of the key fob. It must be interpreted as
follows:
1bit 1bit 1bit 5bits
Lbd Available LBD Status Battery Voltage Available Battery Voltage[4:0]
LBD Available Bit—If set, the LBD status bit shows the actual status of the batter y.LBD Status—Shows whether the actual battery voltage is above the LBD limit (set if the actual voltage is below
the threshold). The LBD limit is configurable in the key fob program.
Battery Voltage Available—If set, the battery voltage information is available.Battery Voltage—It shows the actual battery voltage of the key fob. Each increment of the battery voltage bit
corresponds to 50 mV. However, 0 represents 1.7 V.
Rolling Counter—The transmitter increments a 4 byte counter after every packet transmission. This counter is
stored in the MTP memory of the Si4010.
Since AES is used by the key fob, the receiver board decrypts the encrypted portion of the packet and discards the dummy bytes. Then, the receiver board checks the sync counte r value agains t it s own copy of the sender key fob's counter. If the key fob sync counter value minus the copy counter value is more than zero and less than a configurable window value (default value is 10), the master increments the copy.
4 Rev 1.1

3.4. Key Handling

Application
Level
MK: Master Key SK: Session Key
RKE_MK
Function
Level
AES_128AES_128 AES_128Node_Association Node_ButtonPress Functionzzzzzzzz
Btn_K
Session
Level
FuncX_K
Assoc_K
AES_128
12byte padding(0) +
Node Addr
Assoc_SK
AES_128
12byte padding(0) +
Node Addr
Btn_SK
Si4010-Keyfob-AES-DEMO

Figure 3. SRW AES128 Applications Key Hierarchy

AES keys used in the demos are generated according to the hierarchy shown in Figure 3. Only the Application level keys are stored on the receiver board. The function level keys are calculated at power-up. The Session level keys are calculated at their first use.
In the key fobs Function level, keys are not generated but only stored to save power. The Session level keys are calculated at each power up.
The Assoc_SK is used for association packets, and the Btn_SK is used for encrypting the messages generated by a button press.

3.5. Key Fob Firmware Description

The complete project of the program used in the demo key fob can be fo und in the Si4 010 documentation kit in the “rke_demo” folder.
The key fob wakes up for button push or battery insert. If the battery was inserted, the vSys_FirstPowerUp() API function is called, which shuts down the chip after 600 ms. This is for safe startup in case of battery contact bouncing. Upon button push wakeup, the system variables and hardware control registers are initialized first, and the session keys used in the AES encoding are generated from the function keys and the device address. Then, button debouncing is made.
If a valid button push is detected, first a packet is assembled and transmitted six times for the LED receiver demo board used in the Si4010 Simplified Key Fob Demo Kit (see details in “AN516: Si4010 Simplified Key Fob Demo Quick Start Guide”). Then, a packet is assembled according to the description in the previous chapters. It is transmitted in FSK modulation for the Si4313 receiver board (part of this kit), and then also in OOK modulation. The next step is to increment the sync counter stored in the MTP memory.
If there is no valid button push detected for 3.2 s, the program shuts down the chip.
Rev 1.1 5
Loading...
+ 9 hidden pages