⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 main._c

📁 Proteus 仿真练习:LCD3202测试电路
💻 _C
字号:
/*--------------------------------------------------*/
/*             AVR-ARM开发网论坛                    */
/*           http://www.avrarm.com                  */
/*            AVR生成代码测试程序                   */
/*--------------------------------------------------*/
/*     程序由AVR辅助开发工具V2.1.1自动生成          */
/*     AVR系统的处理器为:   ATMega16               */
/*     AVR系统的晶振频率:   8.0000 Mhz             */
/*--------------------------------------------------*/

#include <avr/interrupt.h>       //中断函数
#include <avr/sfr_defs.h>       //寄存器
#include <compat/deprecated.h>  //宏指令
#include <avr/pgmspace.h>       //FLASH宏指令
#include <avr/portpins.h>       //PORT定义
#include <avr/io.h>             //IO口描述
#include "lcd.h"
#include "delay.h"

//-----------------------------------------------------------
//主函数
//-----------------------------------------------------------
int main(void)
{

   LCD16xx_init();
   LCD16xx_clr();                     //显示清屏
   delay_nms(1); 
   LCD16xx_write_string(3,0,"Welcome to");
   LCD16xx_write_string(1,1,"www.avrarm.com!");
   delay_nms(500);
   LCD16xx_clr();                     //显示清屏
   delay_nms(2);

   while(1)
   {
      LCD16xx_write_string(3,0,"Welcome to");
      LCD16xx_write_string(1,1,"www.avrarm.com!");
      delay_nms(1000);
      LCD16xx_clr();                     //显示清屏
      delay_nms(1000);
   }
}

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -