Hallo Leute,
ich habe ein Problem, normalerweise Programmiere ich mit dem C18
Compiler. Nun wollte ich wie oben beschrieben eine LCD Anzeige mit 16x2
ansteuern als PIC haben ich den 16F877a genommen.
Ich wollte nur mal ein Test-Programm von CCS laufen lassen aber
irgendwie läuft das nicht.
Code:
1 | #include <16F877.h>
|
2 | #include <lcd.c>
|
3 | #fuses HS,NOWDT,NOPROTECT,NOLVP
|
4 | #use delay(clock=20000000)
|
5 |
|
6 |
|
7 | #define RESET_BUTTON PIN_d0
|
8 |
|
9 |
|
10 |
|
11 | void main() {
|
12 |
|
13 | lcd_init();
|
14 | delay_ms(6);
|
15 |
|
16 | while(TRUE)
|
17 | {
|
18 |
|
19 | printf(lcd_putc,"\fHello World");
|
20 | delay_ms(500);
|
21 | }
|
22 | }
|
1 | C:\Program Files (x86)\PICC\devices\16F877A.h:2:9: Error#23 Can not change device type this far into the code
|
2 | C:\Program Files (x86)\PICC\devices\16F877A.h:2:8: Error#23 Can not change device type this far into the code
|
3 | C:\Program Files (x86)\PICC\devices\16F877A.h:178:2: Error#48 Expecting a (
|
4 | C:\Program Files (x86)\PICC\devices\16F877A.h:178:21: Error#48 Expecting a (
|
5 | C:\Program Files (x86)\PICC\devices\16F877A.h:178:0: Error#43 Expecting a declaration
|
Diese Fehlermeldung bekomme ich:/