TI中文支持网
TI专业的中文技术问题搜集分享网站

CC2642R 怎样使能串口显示,即系统的uart_display

用sysconfig 把uart_log 前面的√选中,但是 仍然没看到sdk中的uart_display输出的内容。

user1388075:

回复 Kevin Qiu1:

simple_perial 这个例程怎么开启这个打印功能,只勾选uart_log 没效果

user1388075:

回复 Kevin Qiu1:

case GAP_LINK_ESTABLISHED_EVENT:{gapEstLinkReqEvent_t *pPkt = (gapEstLinkReqEvent_t *)pMsg;
BLE_LOG_INT_TIME(0, BLE_LOG_MODULE_APP, "APP : —- got GAP_LINK_ESTABLISHED_EVENT", 0);// Display the amount of current connectionsuint8_t numActive = linkDB_NumActive();Display_printf(dispHandle, SP_ROW_STATUS_2, 0, "Num Conns: %d",(uint16_t)numActive);
if (pPkt->hdr.status == SUCCESS){// Add connection to list and start RSSISimplePeripheral_addConn(pPkt->connectionHandle);
// Display the address of this connectionDisplay_printf(dispHandle, SP_ROW_STATUS_1, 0, "Connected to %s",Util_convertBdAddr2Str(pPkt->devAddr));
// Enable connection selection optiontbm_setItemStatus(&spMenuMain, SP_ITEM_SELECT_CONN,SP_ITEM_AUTOCONNECT);
// Start Periodic Clock.Util_startClock(&clkPeriodic);bleLinkState = 1;}

Display_printf這個怎么沒輸出

Kevin Qiu1:

回复 user1388075:

simple_peripheral中可以直接使用Display_printf,是否在之前使用了Display_open。 如果想使用log的话,需要添加UartLog.c和Uartlog.h文件,具体参考project_zero例程

user1388075:

回复 Kevin Qiu1:

我看sdk的蓝牙部分好多都调用了Display_printf 这个函数,但是没见着串口有什么输出。

Kevin Qiu1:

回复 user1388075:

使用了的串口有输出的啊,simple_peripheral中就有输出

赞(0)
未经允许不得转载:TI中文支持网 » CC2642R 怎样使能串口显示,即系统的uart_display
分享到: 更多 (0)