|
|
View previous topic :: View next topic |
Author |
Message |
Tuga Guest
|
mplab error |
Posted: Wed Aug 08, 2007 8:07 am |
|
|
Dear all,
I am using mplab and my compiler ccs indicates an error in the following line:
int8 const LCD_INIT_STRING[4] =
{
0x20 | (lcd_type << 2), // Func set: 4-bit, 2 lines, 5x8 dots
0xc, // Display on
1, // Clear display
6 // Increment cursor
};
the message error is:
*** Error 128 "C:\...\flex_lcd.c" Line 28(1,42): A #DEVICE required before this line
I am using PIC18F4455 and LCD 16x2.
How I can decide this problem?
Thanks |
|
|
axmanjr
Joined: 07 Aug 2007 Posts: 25 Location: Las Vegas, NV
|
|
Posted: Wed Aug 08, 2007 9:45 am |
|
|
It seems to me that you're missing a predecessor (sp). I'm not sure what you're trying to do with your code, but if you look at the ccs manual (pg 38), it explains about the #device protocol:
#device CHIP OPTIONS
CHIP: the name of a specific processor (like: PIC18F4455)
OPTIONS: qualifiers to the standard operation of the device.
Page 38 and 39 give a bunch of valid OPTIONS, which is probably what the compiler is looking for with your code |
|
|
Tuga Guest
|
Thanks |
Posted: Thu Aug 09, 2007 9:29 am |
|
|
Debtor for the aid.
I decided the problem. I simply changed projecto for a new folder without modifying the code, and works.
thanks for help. |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|