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.

TMS320C6748 UARTprintf函数串口不输出

我在C6748的UART1_POLL例程中for循环中添加了UARTprinrf函数,但是串口不显示,编译没错,创龙的那句话也显示了,说明串口也通了!头文件也加了!为什么不显示那?同样也把uartstdio.c文件放在工程里了。但是就是串口不显示,只显示了Tronlong UART1 Application......程序如下

#include "TL6748.h" // 创龙 DSP6748 开发板相关声明

#include "hw_types.h" // 宏命令
#include "hw_syscfg0_C6748.h" // 系统配置模块寄存器
#include "soc_C6748.h" // DSP C6748 外设寄存器

#include "psc.h" // 电源与睡眠控制宏及设备抽象层函数声明
#include "gpio.h" // 通用输入输出口宏及设备抽象层函数声明
#include "uart.h" // 通用异步串口宏及设备抽象层函数声明
#include "uartStdio.h" // 串口标准输入输出终端函
#include <string.h>
#include <stdio.h>
/****************************************************************************/
/* */
/* 宏定义 */
/* */
/****************************************************************************/
// 软件断点
#define SW_BREAKPOINT asm(" SWBP 0 ");

// 时钟
#define SYSCLK_1_FREQ (456000000)
#define SYSCLK_2_FREQ (SYSCLK_1_FREQ/2)
#define UART_1_FREQ (SYSCLK_2_FREQ)

/****************************************************************************/
/* */
/* 全局变量 */
/* */
/****************************************************************************/
// 发送缓存
char Send[] = "Tronlong UART1 Application......\n\r";

/****************************************************************************/
/* */
/* 函数声明 */
/* */
/****************************************************************************/
// 外设使能配置
void PSCInit(void);

// GPIO 管脚复用配置
void GPIOBankPinMuxSet();
// GPIO 管脚初始化
void GPIOBankPinInit();

// UART 初始化
void UARTInit(void);
void Delay(unsigned int n);

/****************************************************************************/
/* */
/* 主函数 */
/* */
/****************************************************************************/
int main(void)
{
// 外设使能配置
PSCInit();

// GPIO 管脚复用配置
GPIOBankPinMuxSet();

// UART 初始化
UARTInit();

// 发送字符串
unsigned char i;
for(i = 0; i < 34; i++)
UARTCharPut(SOC_UART_1_REGS, Send[i]);

// 接收缓存
unsigned char Receive;
// 主循环
for(;;)
{
Receive=UARTCharGet(SOC_UART_1_REGS);
UARTCharPut(SOC_UART_1_REGS, Receive);
UARTprintf("success\n");

}
}

/****************************************************************************/
/* */
/* PSC 初始化 */
/* */
/****************************************************************************/
void PSCInit(void)
{
// 使能 UART1 模块
// 对相应外设模块的使能也可以在 BootLoader 中完成
PSCModuleControl(SOC_PSC_1_REGS, HW_PSC_UART1, PSC_POWERDOMAIN_ALWAYS_ON,PSC_MDCTL_NEXT_ENABLE);
}

/****************************************************************************/
/* */
/* GPIO 管脚复用配置 */
/* */
/****************************************************************************/
void GPIOBankPinMuxSet(void)
{
// 使能 UART1 禁用流控
UARTPinMuxSetup(1, FALSE);
}

/****************************************************************************/
/* */
/* UART 初始化 */
/* */
/****************************************************************************/
void UARTInit(void)
{
// 配置 UART1 参数
// 波特率 115200 数据位 8 停止位 1 无校验位
UARTConfigSetExpClk(SOC_UART_1_REGS, UART_1_FREQ, BAUD_115200, UART_WORDL_8BITS, UART_OVER_SAMP_RATE_16);
// 使能 UART1
UARTEnable(SOC_UART_1_REGS);
}
void Delay(unsigned int n)
{
unsigned int i;

for(i=n;i>0;i--);
}