This thread has been locked.

If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.

CC2652P7: API to get Z-Stack version

Part Number: CC2652P7
Other Parts Discussed in Thread: Z-STACK

My customer is running ZNP for a Zigbee gateway. They would like to get the Z-Stack version from sys_version from Z-Stack monitor and test API, but the returned version does not match the version number in the release note.

From the returned value it seems the sys_version API is retuning the version from \source\ti\zstack\stack\api\zsversion.h, but the Z-stack version in release note is the same as the core SDK version. What does the version numbers in zsversion.h represent?

Is there an API to get the version matching the release note version? It's better to be a monitor and test API since ZNP is running on the device.

Best regards,

Shuyang

  • Hi Shuyang,

    Here is a link to the MT API Guide.  SYS_VERSION is the MT version and can be modified from mt_version.c

    const uint8_t MTVersionString[] = {
                                       2,  /* Transport protocol revision */
                                       0,  /* Product ID */
                                       2,  /* Software major release number */
                                       7,  /* Software minor release number */
                                       1,  /* Software maintenance release number */
                                     };

    zversion.h more closely represents the Z-Stack core version and is used in zstackmsg_CmdIDs_SYS_VERSION_REQ -> processSysVersionReq.  You can modify whichever for your custom needs.

    Regards,
    Ryan

  • Hi Ryan,

    Thanks for clarifying about the difference between the MT version and zsversion.h. However I found the definitions in zsversion.h does not match the SDK manifest either.

    Take simplelink_cc13xx_cc26xx_sdk_8_30_01_01 for an example, the TI Z-Stack version in the manifest file is 8.30.00.x:

    But in zsversion.h the version definitions are 2.6.3:

    Is my following understanding correct?

    1. No code in Z-Stack is reflecting the version number in the SDK manifest, customer needs to define a string by themselves if to reflect the manifest version.

    2. Customer can modify the MTVersionString to define a custom version, the MT API sys_version will return the modified value after this string is changed.

    3. Customer can also modify the macros in zsversion.h to reflect a custom version, but no standard MT API is linked to the macros, customer needs to write a custom MT command to call Zstackapi_sysVersionReq() in order to get the macro values from ZNP.

    Could you help confirm if above is true? Please let me know if there is a better way to get the required SDK version.

    Best regards,

    Shuyang

  • Affirmative to the first two.  The third does not have access to processSysVersionReq since the NPI is defined and there is no Zigbee application in the ZNP project.  Thus your custom MT command should not call Zstackapi_sysVersionReq, but you should be able to access zsversion.h definitions from your custom MT command directly.

    Regards,
    Ryan