极客工坊

 找回密码
 注册

QQ登录

只需一步,快速开始

查看: 13202|回复: 5

请教ks0108驱动12864,用例程提示错误,怎么修正?

[复制链接]
发表于 2014-10-6 15:03:30 | 显示全部楼层 |阅读模式
arduino新人,想用库(这里下的: https://code.google.com/p/glcd-arduino/downloads/list) 驱动ks0108 的lcd,不过提示好多错误,后来又在这里下载了https://www.pjrc.com/teensy/td_libs_GLCD.html,同样例程提示错误。下面是第一个地址下载的库的例程提示的错误,请教各位前辈怎么解决啊?谢谢
glcdBitmap:10: error: 'PImage' does not name a type
glcdBitmap:11: error: expected unqualified-id before '[' token
glcdBitmap.pde: In function 'void setup()':
glcdBitmap:16: error: 'noFill' was not declared in this scope
glcdBitmap:17: error: 'stroke' was not declared in this scope
glcdBitmap:18: error: 'frameRate' was not declared in this scope
glcdBitmap:20: error: 'a' was not declared in this scope
glcdBitmap:20: error: 'loadImage' was not declared in this scope
glcdBitmap:21: error: 'null' was not declared in this scope
glcdBitmap:22: error: 'size' was not declared in this scope
glcdBitmap:23: error: 'aPixels' was not declared in this scope
glcdBitmap:23: error: 'width' was not declared in this scope
glcdBitmap:23: error: 'height' was not declared in this scope
glcdBitmap:28: error: 'loadPixels' was not declared in this scope
glcdBitmap:30: error: 'pixels' was not declared in this scope
glcdBitmap:31: error: 'updatePixels' was not declared in this scope
glcdBitmap:33: error: 'println' was not declared in this scope
glcdBitmap.pde: In function 'void writeFile(String)':
glcdBitmap:38: error: expected unqualified-id before '[' token
glcdBitmap:39: error: 'f' was not declared in this scope
glcdBitmap:42: error: 'PrintWriter' was not declared in this scope
glcdBitmap:42: error: expected `;' before 'output'
glcdBitmap:43: error: 'output' was not declared in this scope
glcdBitmap:43: error: 'createWriter' was not declared in this scope
glcdBitmap:47: error: expected unqualified-id before '[' token
glcdBitmap:48: error: 'day' was not declared in this scope
glcdBitmap:48: error: 'monthName' was not declared in this scope
glcdBitmap:48: error: 'month' was not declared in this scope
glcdBitmap:48: error: 'year' was not declared in this scope
glcdBitmap:63: error: 'a' was not declared in this scope
glcdBitmap:69: error: invalid operands of types 'const char*' and 'const char [9]' to binary 'operator+'
glcdBitmap:72: error: 'Integer' was not declared in this scope
glcdBitmap:74: error: 'println' was not declared in this scope
glcdBitmap.pde: In function 'int getValue(int, int)':
glcdBitmap:92: error: 'a' was not declared in this scope
glcdBitmap:93: error: 'aPixels' was not declared in this scope
回复

使用道具 举报

发表于 2014-10-6 15:47:35 | 显示全部楼层
你要把你的代码贴上来,看这个情况可能是没有实例化,你代码这句有没有啊:U8GLIB_KS0108_128 u8g();
回复 支持 反对

使用道具 举报

发表于 2014-10-6 15:48:19 | 显示全部楼层
另外库有没有正确引用
回复 支持 反对

使用道具 举报

 楼主| 发表于 2014-10-6 16:26:20 | 显示全部楼层
谢谢lz的回复,我是下载官网的 ks0108GLCD-v2.zip库,解压后直接放到libraries这个文件夹里,卡板选择nano,再在example里选择例程,编译时就提示错误了

本帖子中包含更多资源

您需要 登录 才可以下载或查看,没有帐号?注册

x
回复 支持 反对

使用道具 举报

 楼主| 发表于 2014-10-6 16:35:16 | 显示全部楼层
carney 发表于 2014-10-6 15:48
另外库有没有正确引用

谢谢回复,看提示应该是有些库没有引用,不过就是不知怎么修正。
回复 支持 反对

使用道具 举报

发表于 2014-10-6 16:55:42 | 显示全部楼层
以为你用的U8glib库呢,你这个库我没有用过
回复 支持 反对

使用道具 举报

您需要登录后才可以回帖 登录 | 注册

本版积分规则

Archiver|联系我们|极客工坊

GMT+8, 2026-6-16 01:10 , Processed in 0.050103 second(s), 20 queries .

Powered by Discuz! X3.4

Copyright © 2001-2021, Tencent Cloud.

快速回复 返回顶部 返回列表