Zigbee Program Flow Problem

取消
显示结果 
显示  仅  | 搜索替代 
您的意思是: 

Zigbee Program Flow Problem

1,372 次查看
toffer
Contributor I
hi,
 
    i have a problem with my zigbee program. i used the SMAC codebase of BeeKit and modified some codes to fit into my own customized hardware. i used the program of Range Demo Plus. since i have already a SARD board with me, i decided to use the SARD as my receiving end. i used my own-made hardware as the transmitter. i made changes to the port configurations in the generated code and everything went as planned until the progam reached the TX_STATE wherein in the MCPSDataRequest code, the program went out of nowhere pointing to BRSET and finally into STX, X in the assembly window. Can anyone please help me solve this problem? i am aware that this problem has already been posted and the remedy was to change/adjust the stacksize which i already did. since i am still new to this field of microcontrollers, i also would like to ask on how to determine the required stacksize of a program and where is it stored, in the RAM or ROM? thanks ahead for the reply!
 
regards,
toffer
标签 (1)
0 项奖励
回复
1 回复

703 次查看
allawtterb
Contributor IV


toffer wrote:
i also would like to ask on how to determine the required stacksize of a program and where is it stored, in the RAM or ROM? thanks ahead for the reply!
 
regards,
toffer


For checking the size of the stack I would refer you to this thread:
 
There are several posts that talk about methods to find the needed stack size.  The size of the stack is not stored in RAM or ROM, instead the compiler uses this value and the value of the starting location of the stack to set aside an area in RAM in which no global or static variable are to be placed.  When the stack overflows it will start to write any variables stored in these locations. 
 
I am hoping that one of these days CodeWarrior will implement some way of displaying at least a good guess at the needed size of the stack.  The thread above talks about why this can be difficult, but it should be able to give you a good estimate of the needed stack size. 
 
 - Brett
0 项奖励
回复