微波EDA网,见证研发工程师的成长!
首页 > 研发问答 > 无线和射频 > TI Zigbee设计交流 > 怎么得到/设置每个设备的installation code

怎么得到/设置每个设备的installation code

时间:10-02 整理:3721RD 点击:

在《Smart-Energy-Sample-Application-User’s-Guide》中,有涉及通过Z-Converter来转换Certicom Certificates,

其中包括CA Pub Key, Device Implicit Cert, Device Private Key, Device Public key, 在设置Z-Converter输入文件时,这些数

列是根据什么设置的呢?SE中有Installation code的概念,怎么得到/设置每个设备的installation code?

Installation code is the number to generate the initial TC Link Key using MMO Hash. Z-Stack provides the function sspMMOHash() that can be used for that purpose.

The prototype of sspMMOHash() is sspMMOHash(uint8 *Pb, uint8 prefix, uint8 *Mb, uint16 bitlen, uint8 *Cstate)

You can use this function to generate a preconfigured TCLK from an install code as following:

sspMMOHash(NULL, 0, *installCode, bitLen, *tclk);

where, installCode is the buffer containing the given install code, bitLen is the length of the install code in bit(byte*8), and tclk is 16-byte long buffer to get the derived TC Link Key as a result.

Once you get the output, you can put it in the NV item area ZCD_NV_TCLK_TABLE_START-ZCD_NV_TCLK_TABLE_END to use it as the initial TC Link Key.

Copyright © 2017-2020 微波EDA网 版权所有

网站地图

Top