【已解决】TLSR8258 zigbee SDK打开log后全擦1016K flash系统起不来

Zigbee 子设备开发


Post Reply
jiefengwang
Posts: 5

同样一份固件,使能了打印log
#define APP_DEBUG 1

擦除 Sector Erase Size(K):512后,在烧录自己开发的固件后系统可以运行,出现初始化log。
擦除 Sector Erase Size(K):1016后,在烧录自己开发的固件后系统起不来并且log不可见。

再擦除1016后,需要烧录回没有打开log的固件后需要先配网操作后再烧录打开log的固件系统才可以正常跑起来,如果不配网操作,烧录回打开log的固件系统仍然起不来。

uart打印配置:
#define TL8258_USART_CONFIG_DEFAULT {\
UART_ID_UART0,\
UART_PIN_TYPE_CONFIG,\
{PORT_B, PIN_1},\
{PORT_B, PIN_7},\
LOC_29, \
LOC_25, \
115200,\
USART_PARITY_NONE,\
USART_STOPBITS_ONE,\
USART_DATABITS_8BIT,\
NULL\
}

void dev_power_on_init(void)
{
#ifdef APP_DEBUG
user_uart_config_t *default_config = mf_test_uart_config();
user_uart_init(default_config);
#endif
dev_zigbee_init();
}

白芷冉然
Posts: 39

Re: TLSR8258 zigbee SDK打开log后全擦1016K flash系统起不来

1.烧录提供的擦除1016K后的固件后点击PC,可以看到 pc 在 0x0153ce 附近运行,请在提供boot.lst用于查找 0x0153ce 所处函数。
2.烧录提供的擦除1016K后的固件后在烧录开启打印的测试固件,固件可以正常运行。

41518468@qq.com
Posts: 7

Re: TLSR8258 zigbee SDK打开log后全擦1016K flash系统起不来

如果是在power on中使用了串口打印,因为power on中还没有使能中断,所以串口会卡住。可以用gpio口模拟打印。
#define APP_DEBUG 1

bool_t app_print_get_cfg(uint8_t *print_type, uint8_t *disable_irq, GPIO_PORT_PIN_T *gpio)
{
gpio->port = PORT_C;
gpio->pin = PIN_4;
*print_type = 0; //1:uart, 0:gpio
*disable_irq = 1;
#ifdef APP_DEBUG
return 1;
#else
return 0;
#endif
}

Post Reply