
MC1322x SMAC Software Architecture
MC1322x SMAC Reference Manual, Rev. 1.7
Freescale Semiconductor
2-3
•
OTAP-enabled target Board (The board having its firmware updated.)
— Download and run an OTAP-enabled application on the board. The currently loaded
application will be replaced by the new application using the OTAP Programmer.
– The application being replaced must have its OTAP module property enabled when the
project is generated in BeeKit.
— Any of the MC1322x development boards can be used as an OTAP enabled target board.
2.3.2
Security Module
The security module is a software component that allows the ciphering and deciphering of messages
through its API. This section describes the procedure for implementing security in a MC1322x SMAC
application.
The MC1322x SMAC security management module allows implementation of wireless security
mechanisms. The MC1322x SMAC security module defines all functions required to cipher and decipher
the messages to be sent or received with the MC1322x SMAC on the MC1322x transceiver. The cipher
process is executed by the ASM module which implements the AES algorithm. It can perform CTR, CBC,
and CCM. CCM is a combination of CTR and CBC. For further details about the security implemented on
22x SMAC and the MC1322x, see Annex B of the IEEE standard 802.15.4-2003.
To enable security features, the security module must first be initialized, then the key and counter must be
set. After that, plain/cipher text can be ciphered/deciphered.
NOTE
The resulting ciphered/deciphered text is put on the same buffer where the
plain text is provided, for CBC and CCM modes which generate Message
Authentication Code, the provided buffer must also allocate 16 extra bytes
for the MAC.
The Security Module API is as follows:
FuncReturn_t CipherEngineInit(void)
FuncReturn_t CipherConfigure(cipher_mode_t u8CipherMode, cipher_key_t * pCipherKey,
ctr_value_t * pCtrValue)
FuncReturn_t CipherMsg (uint32_t * pu32CipherBuffer, uint8_t u8BufferLength)
FuncReturn_t DecipherMsg (uint32_t *pu32DecipherBuffer, uint8_t u8BufferLength)
FuncReturn_t CipherMsgU8(uint8_t *pu8CipherBuffer, uint8_t u8BufferLength)
FuncReturn_t DecipherMsgU8(uint8_t *pu8CipherBuffer, uint8_t u8BufferLength)
2.4
MC1322x SMAC Messages
This section describes the MC1322x SMAC messages, their types, operations and states. Send and receive
are basic functions of the MC1322x SMAC and they are implemented as messages. Energy detection and
radio idle time out are also implemented as messages. That is why messages are the core of the MC1322x
SMAC and it is important to explain the messages in detail both in how are they structured and how they
are processed and interfaced.