📄 simple.c
字号:
/* ***********************************************************************
**
** Copyright (C) 2005 Christian Kranz
**
** Siemens S65 Display Control
**
*********************************************************************** */
/*********************************************
* Chip type : ATMEGA128
* Clock frequency : clock 16 MHz
*********************************************/
#include <avr/io.h>
#include <inttypes.h>
#include "disp.h"
#include "lcd.h"
int main(void)
{
uint8_t i;
char txt[]={'H','e','l','l','o',' ','W','o','r','l','d',0};
/* INITIALIZE */
lcd_init();
backcolor=0xA000;
textcolor=0xFFFF;
fill_screen(backcolor);
i=0;
while (txt[i]!=0)
{
// two possible text outputs, same lower left (0) upper left (90) corner pixel
// put_char(10+i*CHAR_W,60,txt[i],1); // 90 deg. rotated
put_char(45+i*CHAR_W,60,txt[i],0); // 0 deg. rotated
i++;
}
while (1)
{
}
return(0);
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -