dsp28_sci.c
来自「tms320f2812利用异步串口与计算机进行数据接收与发送子程序」· C语言 代码 · 共 38 行
C
38 行
//
// TMDX ALPHA RELEASE
// Intended for product evaluation purposes
//
//###########################################################################
//
// FILE: DSP28_Sci.c
//
// TITLE: DSP28 SCI Initialization & Support Functions.
//
//###########################################################################
//
// Ver | dd mmm yyyy | Who | Description of changes
// =====|=============|======|===============================================
// 0.55| 06 May 2002 | L.H. | EzDSP Alpha Release
// 0.56| 20 May 2002 | L.H. | No change
// 0.57| 27 May 2002 | L.H. | No change
//###########################################################################
#include "DSP28_Device.h"
unsigned int * UART_MODE = (unsigned int *) 0x4010;
//---------------------------------------------------------------------------
// InitSPI:
//---------------------------------------------------------------------------
// This function initializes the SPI(s) to a known state.
//
void InitSci(void)
{
// Initialize SCI-A:
*UART_MODE = 0x44;
EALLOW;
GpioMuxRegs.GPFMUX.all = 0x0030;
EDIS;
/* loopback 8 bit data */
SciaRegs.SCICCR.all = 0x07;//一个结束位,奇极性,禁止极性功能,禁止回送测试模式功能,选择空闲
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?