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.

Linux/CC2530: CC2530 : gw_soc_fw_version_query.bin used in Z-Stack Linux Gateway Server contains support for SPI interface or not

Part Number: CC2530
Other Parts Discussed in Thread: Z-STACK, , TIDC-ZNP-HOST-SW3, CC2538, Z-STACK-ARCHIVE

Tool/software: Linux

Hi Yikai,

I am facing issues in commuincating with SPI interface of CC2530 with Raspberry pi through SPI interface. In the process of debugging the issue, I have found that "gw_soc_fw_version_query.bin" present in Z-Stack Linux Gateway Server code contains suport for UART interface only and not for SPI ? 

These are the file which are used for compilation of " gw_soc_fw_version_query.bin"  : main.c  zbSocCmd.c  zbSocTransportUart.c in which this file  zbSocTransportUart.c contains support for UART interface as I have checked few functions like : zbSocTransportOpen() and zbSocTransportUpdateBaudrate() which contains support for UART only.

Is my understanding correct above?

Thanks and Regards,

Mohit

  • Also, I want to add one more point in this discussion for support of SPI interface on Z-Stack Linux Gateway server I have only modified the NPI_Gateway.cfg file which is present as part of tar.
  • I think Z-Stack Linux Home GW reference design only uses UART interface. Either you revise source code by yourself or change to use TIDC-ZNP-HOST-SW3
  • Hi Yikai,

    Ok. I thought I am on right track in using Z- Stack Linux Home Gateway on Host Processor of Raspberry pi using SPI interface with CC2530.

    Since you have the opinion that the Z-Stack Linux Home gateway requires source code changes which I thought to be a big task requiring a lot of changes. I just need some API's in C from which I can send and receive data between nodes (Zigbee lights , switches etc) in Zigbee network & ZNP as Coordinator running on CC2530 (my board).

    I have gone through some of the documentation in TIDC-ZNP-HOST-SW3 in which main reference is given for CC2538 processor. Is ZNP host framework can also be used with CC2530 ?

    Most important of all will it (ZNP host framework) be able to use SPI interface to communicate with ZNP?

    Can you please help me answer the above doubts?

    Regards
    Mohit
  • Yes, ZNP host framework can also be used with CC2530 and according to document it can use SPI. However, I also don’t have experience to use SPI to run ZNP host framework.
  • Hi Yikai,

    Thanks for the response.

    In the ZNP Host Framework repo on git (git.ti.com/.../master) , I have checked it that SPI interface file "rpcTransportSPI.c" file is missing. Can you please help me to get this file ?

    or if I can get corresponding file "zbSocTransportSPi.c " file in Z-Stack Linux Home Gateway project that will be great for me too.

    I feel that in most of the Zigbee projects that I have seen , even though they contain support for SPI interface but files for SPI trasnport are missing.

    Regards,
    Mohit
  • Hi Yikai,

    Any update for me on this ?

    Thanks for all the support.

    Regards,
    Mohit
  • I don't know where to get the file. Do you?
  • Hi Mohit, YK,

    I convened with the author of the TIDC-ZNP-HOST-SW3 and they only implemented and tested UART, the SPI counterpart was never created but the backbone structure was left in as an option for users to add if they wanted. The same holds true for the Z-STACK-LINUX-GATEWAY although it does contain npi_lnx_spi files. Z-STACK-HOME from Z-STACK-ARCHIVE has znp/hal_spi files that can be used as a reference.

    Regards,
    Ryan
  • It sounds not good news to Mohit.
  • Hi Ryan , YK

    Thanks for the above information.

    I just want to check is the npi_lnx_spi files for SPI interfacing are tested or not ? I get to know that SPI interface is not tested rigorously in Z-Stack Linux Gateway, but still If I plan to add SPI interfacing in this framework (ZStack-Linux-Gateway) wherever required will it work fine with other servers like NPI Server , ZNP server etc ?

    Regards,
    Mohit
  • Hey Mohit,

    I'm honestly not too sure since I've never tested it myself, however SPI was supported on Z-STACK-HOME ZNP projects so I'd say that it is likely in your favor.

    Regards,
    Ryan