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.

SensorDemo application on cc2530 callback functions

Other Parts Discussed in Thread: Z-STACK

Hi all, 

i am working with cc2530zDk and orj SensorDemo application is running on the system.

i am trying to run callback functions from serialport. but i have no exp on it. i run only ping callback function.

i don't know what should i send from serial port  to coordinator getting network address and etc. i am looking for a list .

for example: 

getting network address  0x 0011223344    answer: 0x2345

getting IEEE adress          0x1122334455     answer: 0x123456789ABCDEF

do you have a document like that. What should i do?

  • i find the document for explaining using form of the callback functions.
    there is a document in zstack documents named Z-Stack Monitor and Test API.pdf
    But sample applications can't run all the functions i believe.
    A developer should decide which functions will be necassary and add them into code before debugging.
    Am i right or all the functions will be work if i SET a REGISTER or MACRO.

  • Hi,

    You are right. You have to build the application with a compile flag for the group of MT function that you want to use. This is summarized in the 'Overview' section in the document you are referring to.

    Regards,

    Bjørn

  •  in  option part, the  C/C++ compiler section ==> Preprocessor tab

    there is a list in defined Symbols:

    i added  some symbols explained in overview section at Monitor and Test Api.pdf

    Right Now, My defined Symbols list looks like that: 

    (So i can run all the functions, is it correct? should i do something more?)

    HOLD_AUTO_START
    BUILD_ALL_DEVICES
    REFLECTOR
    NV_INIT
    NV_RESTORE
    ZTOOL_P1
    MT_TASK
    DEVICE_LOGICAL_TYPE=ZG_DEVICETYPE_ROUTER
    LCD_SUPPORTED
    ZIGBEEPRO
    MT_AF_FUNC
    MT_AF_CB_FUNC
    MT_APP_FUNC
    MT_DEBUG_FUNC
    MT_NWK_FUNC
    MT_NWK_CB_FUNC
    MT_SAPI_FUNC
    MT_SAPI_CB_FUNC
    MT_SYS_FUNC
    MT_UTIL_FUNC
    MT_ZDO_FUNC
    MT_ZDO_CB_FUNC

  • Actually i need a general coordinator gateway.

    So i will get off the compiler and code problems.

    i will add all Ztool functions to SensorDemo coordinator so the problem will be solved. Then i run or stop everything from Com-port on PC.

    But On my idea,  there is a problem which i don't know.