下载后可能需要改系统时钟, /********函数声明*************************************************************/ void WriteDataLCD(unsigned int WDLCD); void WriteCommandLCD(unsigned int WCLCD,unsigned int BuysC); unsigned int ReadDataLCD(void); unsigned int ReadStatusLCD(void); void LCDInit(void); void LCDClear(void); void LCDFlash(void); void DisplayOneChar(unsigned char X, unsigned char Y, unsigned char DData); void DisplayListChar(unsigned int X, unsigned int Y, unsigned char *DData); void DisplayImage (unsigned char *DData); void Delay5Ms(void); void Delay400Ms(void); void xie(unsigned int dz); void delay(); void GPIO_int(); /********数据定义*************************************************************/ unsigned char uctech[] = {"******"}; unsigned char net[] = {"====星嵌电子===="}; unsigned char mcu[] = {"自学单片机的首选"}; unsigned char qq[] = {" QQ: 29986535 "}; void main(void) { SysCtlClockSet(SYSCTL_SYSDIV_4|SYSCTL_USE_PLL|SYSCTL_XTAL_16MHZ| SYSCTL_OSC_MAIN); GPIO_int();
* @brief: LDC1000应用程序
* _____________ _______________
* |PB4(SSI2CLK) ----> SCLK|
* |PB5(SSI2FSS) ----> CSB |
* |PB6(SSI2RX) <---- SDO |
* Tiva M4 |PB7(SSI2TX) ----> SDI | LDC1000
* |PA4(INT/GPIO) <---- INTB|
* |PB0(Timer CLK) ----> TBCLK|
* _____________| |______________
*****************************************************************************************************/
#include <stdint.h>
#include <stdbool.h>
#include "driverlib/rom.h"
#include "driverlib/adc.h"
#include "driverlib/sysctl.h"
#include "driverlib/pwm.h"
#include "driverlib/timer.h"
#include "driverlib/gpio.h"
#include "driverlib/pin_map.h"
#include "driverlib/interrupt.h"
#include "driverlib/ssi.h"
#include "inc/hw_ints.h"
#include "inc/hw_memmap.h"
#include "inc/hw_gpio.h"
#include "LDC1000_cmd.h"
#include "inc/hw_timer.h"
#include "inc/hw_types.h"
#include "inc/hw_ssi.h"
//sbit LCD_RS=P1^0;//c4
//sbit LCD_RW=P1^1;//c5
//sbit LCD_E=P1^2;//c6
//sbit PSB =P1^6;//c7 //PSB脚为12864-12系列的串、并通讯功能切换,我们使用8位并行接口,PSB=1
/********宏定义***********************************************************/
#define Busy 0x80 //用于检测LCD状态字中的Busy标识
/********函数声明*************************************************************/
void WriteDataLCD(unsigned int WDLCD);
void WriteCommandLCD(unsigned int WCLCD,unsigned int BuysC);
unsigned int ReadDataLCD(void);
unsigned int ReadStatusLCD(void);
void LCDInit(void);
void LCDClear(void);
void LCDFlash(void);
void DisplayOneChar(unsigned char X, unsigned char Y, unsigned char DData);
void DisplayListChar(unsigned int X, unsigned int Y, unsigned char *DData);
void DisplayImage (unsigned char *DData);
void Delay5Ms(void);
void Delay400Ms(void);
void xie(unsigned int dz);
void delay();
void GPIO_int();
/********数据定义*************************************************************/
unsigned char uctech[] = {"******"};
unsigned char net[] = {"====星嵌电子===="};
unsigned char mcu[] = {"自学单片机的首选"};
剩余10页未读,继续阅读
- 粉丝: 0
- 资源: 1
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助