#include <LiquidCrystal_I2C.h>
#include <Wire.h>
[mw shl code=applescript,true];
LiquidCrystal_I2C lcd(0x27,16,2);
#if defined(ARDUINO) && ARDUINO >= 100
#define printByte(args) write(args);
#else
#define printByte(args) print(args,BYTE);
#endif
uint8_t a[8]= {0x04,0x04,0x04,0x07,0x04,0x04,0x04,0x1F,};
uint8_t b[8]= {0x08,0x08,0x0E,0x14,0x04,0x1F,0x04,0x04,};
uint8_t c[8] = {0x1F,0x04,0x04,0x06,0x05,0x04,0x04,0x04,};
uint8_t d[8] = {0x1F,0x04,0x1F,0x15,0x1F,0x15,0x1F,0x15,};
uint8_t e[8] = {0x1F,0x01,0x02,0x04,0x04,0x04,0x04,0x0C,};
void setup(){
lcd.init();
lcd.backlight();
lcd.createChar(0, a);
lcd.createChar(1, b);
lcd.createChar(2, c);
lcd.createChar(3, d);
lcd.createChar(4, e);
lcd.setCursor(0,0);
lcd.printByte(0);
lcd.printByte(1);
lcd.printByte(2);
lcd.printByte(3);
lcd.printByte(4);
}
void loop(){
}
[/mw shl code]
Arduino:1.8.9 (Windows 10), 开发板:"Arduino/Genuino Uno"
sketch_aug18a:3:1: error: expected unqualified-id before '[' token
[mw shl code=applescript,true];
^
sketch_aug18a:32:1: error: expected unqualified-id before '[' token
[/mw shl code]
^
exit status 1
expected unqualified-id before '[' token
在文件 -> 首选项开启
“编译过程中显示详细输出”选项
这份报告会包含更多信息。
|