You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Hi, I'm trying to work a Liquid Crystal display using a Raspberry Pi B+ using the itead SDK but when I build the program in C and try to compile it, it posts an error
/usr/local/includeitead_LiquidCrystal.h:50:1: error: unknown type name 'class'
/usr/local/includeitead_LiquidCrystal.h:50:21: error: expected '=', ',', ';', 'asm' or 'attribute' before ':' token.
I only downloaded the new version last night from Git hub so I should be up todate. I am knew to raspberry Pi so please bare with me if i'm doing something silly. It does look like all include files that use the defenation 'class' will have the same error.
Any help would be great.
The code i'm using is:
//***********************************************************************************************
// include the library code:
#include <time.h>
#include <stdio.h>
#include <itead_LiquidCrystal.h>
// initialize the library with the numbers of the interface pins
LiquidCrystal lcd(16,18,11,12,13,15);
void setup() {
// set up the LCD's number of columns and rows:
lcd.begin(16, 2);
}
main() {
time_t rawtime;
struct tm * timeinfo;
setup();
// set the cursor to column 0, line 1
// (note: line 1 is the second row, since counting begins with 0):
// lcd.setCursor(0, 0);
// print system time
time ( &rawtime );
timeinfo = localtime ( &rawtime );
while(1)
{
lcd.setCursor(0,0);
lcd.print(asctime (timeinfo));
delay(1000);
}
}
Hi, I'm trying to work a Liquid Crystal display using a Raspberry Pi B+ using the itead SDK but when I build the program in C and try to compile it, it posts an error
/usr/local/includeitead_LiquidCrystal.h:50:1: error: unknown type name 'class'
/usr/local/includeitead_LiquidCrystal.h:50:21: error: expected '=', ',', ';', 'asm' or 'attribute' before ':' token.
I only downloaded the new version last night from Git hub so I should be up todate. I am knew to raspberry Pi so please bare with me if i'm doing something silly. It does look like all include files that use the defenation 'class' will have the same error.
Any help would be great.
The code i'm using is:
//***********************************************************************************************
// include the library code:
#include <time.h>
#include <stdio.h>
#include <itead_LiquidCrystal.h>
//******************************************************************************************
Thanks.
The text was updated successfully, but these errors were encountered: