这是显示屏可以显示的字母
#include "LCD12864RSPI.h"
#define AR_SIZE( a ) sizeof( a ) / sizeof( a[0] )
unsigned char show0[]= "qyjx" ; //qyjx
unsigned char show1[]="h u a t"; //huat
void setup()
{
LCDA.Initialise(); // 屏幕初始化
delay(100);
}
void loop()
{
LCDA.CLEAR();//清屏
delay(100);
LCDA.DisplayString(0,3,show0,AR_SIZE(show0));//第一行第三格开始,显示qyjx
delay(100);
LCDA.DisplayString(2,2,show1,AR_SIZE(show1));;//第三行第二格开始,显示huat/
delay(5000);
}
这是串口读取的值
#include <Serial.h>
void setup()
{
Serial.begin(9600);
}
void loop()
{
Serial.println(analogRead(A5));
}
两者结合起来怎么用?? |