1、基于 DSP 的 SPI 接口 DA 转换系统设计 I 摘 要 DSP 是以数字信号来处理大量信息的器件是一种特别适合各种数字信号处理运算 的微处理器。以数字计算的方法对信号进行处理器具有处理速度快、灵活、精确、抗干 扰能力强、 体积小及可靠性强等优点满足了对信号快速、 精确、 实时处理及控制的要求。 串行外设接口 SPI 是一个高速、 同步串行接口 I/O 通常应用于 DSP 控制器与外部设备或 DSP 控制器与其他控制器之间的通信。SPI 接口的 DA 转换采用 TLV5617 进行数字到模 拟的转换通过观察输出的结果来验证通信和转换的情况。TLV5617 是单极性,10 位串 口 DA,
2、所以生成的正弦波数据要换算到 TLV5617 的数据范围,而且根据 TLV5617 要 求的数据格式还要对换算后的数据做响应的变换才能最终通过 SPI 接口发送给 TLV5617。在这个应用中 SPI 用于控制 TLV5617 工作,所以配置为主模式。从 TLV5617 的控制时序中可以发现串行数据在时钟的上升沿锁存。 因此 SPI 时钟配置选择无延下降 沿即 SPI 在时钟的下降沿发送数据在时钟的上升沿数据被锁存在 TLV5617.本设计通过 对DA转换的工作原理的分析以及对DSP的数模转换系统进行功能分析设计出数模转换 接口的系统框图硬件电路图和软件程序。 关键词:D/A 转换,串行外设,
3、TLV5617,SPI,中断 基于 DSP 的 SPI 接口 DA 转换系统设计 II ABSTRACT DSP is based on digital signal processing large amounts of information devices is a particularly suitable for the operation of various digital signal processing microprocessor. Digital method of calculation of the signal processor has the processi
4、ng speed is fast, flexible ,precise, strong anti-jamming capability ,small size and high reliability to meet the signal fast, accurate ,real time processing and control requirements .serial peripheral interface (SPI) is a high-speed, synchronous serial I/O port often used in communication between th
5、e DSP controller and external devices or DSP controller with other controller .The SPI interface of the DA converter using the TLV5617 digital to analog conversion by observing the output of the results to verify communication and conversion .TheTLV5617 is a univocal 10 serial DA generated sine wave
6、 data to be converted to the TLV5617 data range and also respond to the converted data according to the TLV5617 requirements of data format transformation in order to ultimately through the SPI port to send to TLV5617 ,In this application ,SPI is used to control the TLV5617 work so configured as master mode ,TLV5617 control timing diagram can be found in the serial data is latched in the rising edge of the clock .therefore ,The SPI clock is