| Details | Message |
|---|
Read-Only Author Andrew Young Posted 11-Mar-2004 17:12 GMT Toolset C166 |  Using second serial example code - error 67 Andrew Young I am trying to use the second serial port and have been trying to use the example from
http://www.keil.com/support/docs/2601.htm
I get the error 67 undefined identifier.
Any body know how I can get rid of this. Thanks |
|
Read-Only Author Andy Neil Posted 11-Mar-2004 17:31 GMT Toolset C166 |  RE: Using second serial example code - error 67 Andy Neil "I get the error 67 undefined identifier. Any body know how I can get rid of this."
Supply a suitable definition for the identifier in question, of course! |
|
Read-Only Author Andrew Young Posted 11-Mar-2004 17:42 GMT Toolset C166 |  RE: Using second serial example code - error 67 Andrew Young If I knew how to do that in this case I would have, unfortunatley I dont and that is why I asked. |
|
Read-Only Author Andy Neil Posted 11-Mar-2004 17:48 GMT Toolset C166 |  RE: Using second serial example code - error 67 Andy Neil IF you don't know, how is anyone else supposed to know?!
You haven't even said which identifier is undefined, nor where the error occurs! |
|
Read-Only Author Andrew Young Posted 11-Mar-2004 17:56 GMT Toolset C166 |  RE: Using second serial example code - error 67 Andrew Young Fair enough,
ASC1_TIC ASC1_RIC ASC1_BG ASC1_CON ALTSEL0P3
I think they may have been defined like #define ASCx_TBUF ASC1_TBUF #define ASCx_RBUF ASC1_RBUF #define ASCx_RIC_IR ASC1_RIC_IR #define ASCx_TIC_IR ASC1_TIC_IR
Doesn't seem to work. Prob something ive done. |
|
Read-Only Author Andy Neil Posted 11-Mar-2004 18:13 GMT Toolset C166 |  RE: Using second serial example code - error 67 Andy Neil They should be SFR definitions in XC16X.h
Are you sure there weren't also other errors and/or warnings that you have omitted to mention? |
|
Read-Only Author Andrew Young Posted 11-Mar-2004 18:21 GMT Toolset C166 |  RE: Using second serial example code - error 67 Andrew Young I changed the library to;
#include <reg167.h>
This is probably why. I changed this as it could not find the,
#include <XC167.H>
Take it I shouldn't have. Doh! |
|
Read-Only Author Andrew Young Posted 11-Mar-2004 18:25 GMT Toolset C166 |  RE: Using second serial example code - error 67 Andrew Young error 318: can't open file XC167.h |
|
Read-Only Author Andy Neil Posted 11-Mar-2004 18:36 GMT Toolset C166 |  RE: Using second serial example code - error 67 Andy Neil "error 318: can't open file XC167.h"
So, you got an error saying that a header file couldn't be found, and then you got errors about undefined identifiers...!
"Doh!"
Yes, I think you deserve a Homer Simpson award here...! ;-)
But you know what to do now, don't you...? |
|
Read-Only Author Andrew Young Posted 14-Mar-2004 20:50 GMT Toolset C166 |  RE: Using second serial example code - error 67 Andrew Young Hello again.
I am not sure how to sort this, I know I need XC167.H file and think I have copied it but it says I need XC16x.H which I dont have.
May even be going entirely in wrong direction. Can anyone help? |
|
Read-Only Author Andy Neil Posted 15-Mar-2004 08:11 GMT Toolset C166 |  RE: Using second serial example code - error 67 Andy Neil "it says I need XC16x.H which I dont have."
it's on the free CD. (I don't use C166 - so that's where I found it).
Have you tried the free download?
"I have copied it"
Shouldn't it just be part of the standard installation? You shouldn't need to be copying anything? |
|
Read-Only Author Mike Kleshov Posted 11-Mar-2004 18:17 GMT Toolset C166 |  RE: Using second serial example code - error 67 Mike Kleshov You are compiling for XC161 or XC167, aren't you? The special function register definitions for ASC1 in the file XC16X.H are braced with the following ifdefs:
#if defined (__XC161_H__) || defined (__XC167_H__)
...
#endif
- mike |
|