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.

Debugging codes from CC2430 with a CC2530

Other Parts Discussed in Thread: CC2430, Z-STACK, CC2530

Hi,

I am starting to work with a CC2530ZDK. I have some codes developed by someone else  (GenericApp.c, GenericApp.h, OSAL_GenericApp.c, Serial.c and Serial.h) for the CC2430.

I replaced the corresponding files of GenericApp project (that I had downloaded from TI website) for these codes.

I tried to build it with the IAR Embedded Workench IDE 8.11, but I did not get success.

"Fatal Error[Pe1696]: cannot open source file "OSAL_Custom.h" C:\Texas Instruments\ZStack-CC2530-2.5.1a\Projects\zstack\Samples\Test\Source\OSAL_GenericApp.c 17"

"Fatal Error[Pe1696]: cannot open source file "MTEL.h" C:\Texas Instruments\ZStack-CC2530-2.5.1a\Projects\zstack\Samples\Test\Source\Serial.c 15"

So, I commented both lines: GenericApp.c 17 and Serial.c 15.

Now, I can build the coordinator, but another problem has happen with end-devices and router:

Error[e104]: Failed to fit all segments into specified ranges. Problem discovered in segment XDATA_N. Unable to place 2 block(s) (0x802 byte(s) total) in
0x1e5 byte(s) of memory. The problem occurred while processing the segment placement command
"-P(XDATA)XDATA_N=_XDATA_START-_XDATA_END", where at the moment of placement the available memory ranges were "XDATA:1d1b-1eff"
Error while running Linker

Could someone help me? If necessary, I can send you the files that I am trying to build.

Regards,
Victor Farias. 

  • Hi Victor,

    What is the version of Z-stack you are working with?

    CC2530 and CC2430 are very different, moreover, the APIs used in Z-stack versions

    for CC2430 are a lot different from the APIs used in Z-stack for CC2530 (The latest

    version of Z-stack for CC2530 is 2.5.1).

    My suggestion to you is to merge these files (algorithms, logic and such) rather then

    completely replacing.

    Also make sure, that your algorithms and logic from CC2430 SoC uses the right

    registers of CC2530 SoC and an updated API of OSAL, HAL, etc...

  • Hi Igor,

     Thanks for your response.

    I am using the v.2.5.1 and I suppose that the code which I had mentioned used the 1.4.3-1.2.1.

    Following your advice, I am trying to merge these files. Do you know what are the main differences between them that I should be careful?

    Victor.

  • Hey,
    1. Evaluation boards are different, so the hal_board_cfg.h
    2. OSAL API; just go through OSAL API.pdf in Z-stack 1.4.3 and the equivalent document in Z-stack 2.5.1
    3. Register's names, and registers in general
    4. Z-stack API if used.
    Try to do it step by step. Change one thing at a time, check it for bugs, verify it and only then move to the next
    thing.
  • Hi Igor,

    Since yesterday I have tried to do what you said. But as a newbie, I am not sure about what to change. Could you help me step by step?

    First of all, I found here the hal_board_cfg.h for CC2430EB  from ZStack-1.4.3-1.2. I compared it with that one for CC2530 and I found some differences like the polarity of the leds. (active high or active low); but in that one from CC2430 there is no reference for "OSAL NV implemented by internal flash pages" neither for  "Serial Boot Loader: reserving the first 4 pages of flash and other memory in cc2530-sb.xcl". What should I do about this?

    Thanks, 
    Victor. 

  • I can not find "Osal_Custom.h" on ZigBee v.2.5.1. Is is still there or it was deleted on the upgrade from v.1.4.3-1.2.1 to V.2.5.1 ?

  • Hi Victor,

    I'm not familiar with modules in Z-stack v1.4.3, nor with the registers set of cc2430.

    So I can't help you much in this one, I hope that someone from TI who is familiar

    with both solutions can be of a help to you.

  • Hi,

    no problem. Actually, I was facing problem in the memory allocation, but now it is ok.

    Anyway, thanks for your help.

    Victor.