CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

Transmit and receive unicast message

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
evios



Joined: 24 Nov 2008
Posts: 8

View user's profile Send private message

Transmit and receive unicast message
PostPosted: Mon Dec 01, 2008 8:40 pm     Reply with quote

Within the digit.h file, I declare
Code:
#define EXP_OUT_ENABLE PIN_C1
#define EXP_OUT_CLOCK PIN_B4
#define EXP_OUT_DO PIN_B5

#define NUMBER_OF_74595 3
#include<74595.c>


For the base station, named BS.c:
Code:
#include<18F4620.h>
#fuses HS,NOWDT,NOLVP,PUT,NOBROWNOUT
#use delay(clock=10000000)
#use rs232(xmit=PIN_C6, rcv=PIN_C7, baud=9600)

#define COORDINATOR 1

#include "em260.h"

#include "ember_utilities.c"
#include<digit.h>


But when I compile BS.c it comes out with the error for the 74595 library file:
The error file:


But I already define it at digit.h for the PIN_DO.
Anyone can help? Thanks
treitmey



Joined: 23 Jan 2004
Posts: 1094
Location: Appleton,WI USA

View user's profile Send private message Visit poster's website

PostPosted: Tue Dec 02, 2008 9:35 am     Reply with quote

Can you put the include for digit.h before the include for 74595?

The compiler works from top down.. and doesn't know about the digit.h
when its compiling the 74595 part,.. so it doesn't know about the define.
Ttelmah
Guest







PostPosted: Tue Dec 02, 2008 10:55 am     Reply with quote

He already is.
The 74595 include is immediately after his pin define, in the 'digit.h' file.
It should work.
However, the error message, suggests that something is wrong, possibly _in_ the define.
Try retyping it. It looks as if the define may have a hidden character in the pin number. You can get this sort of behavious/message, if there is an invisible character inside the text line.
It compiles fine for me (added a 'main', and a data definition for the array of bits to send).

Best Wishes
treitmey



Joined: 23 Jan 2004
Posts: 1094
Location: Appleton,WI USA

View user's profile Send private message Visit poster's website

PostPosted: Tue Dec 02, 2008 3:29 pm     Reply with quote

Of course your right.
behavious Smile
http://www.urbandictionary.com/define.php?term=behavious
Ttelmah
Guest







PostPosted: Tue Dec 02, 2008 4:05 pm     Reply with quote

Don't chips do this all the time!.... Smile

Best Wishes
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
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