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 support@ccsinfo.com

Stupid Streams question

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



Joined: 07 Sep 2003
Posts: 1640
Location: Cape Cod Mass USA

View user's profile Send private message

Stupid Streams question
PostPosted: Fri Oct 14, 2005 8:29 am     Reply with quote

I have been beating my head against this all morning. In many years of PIC work I have never used streams before. What am I doing wrong?

I have these serial ports
#use RS232(baud=9600, xmit=PIN_C6, rcv=PIN_C7, stream=TTY)
#use RS232(baud=1200, xmit=PIN_B4, rcv=PIN_B4, stream=TXR)

This compiles:
comms = getc(TTY);

This compiles:
printf(__DATE__);

This does not:
printf(TTY, __DATE__);
It reports: Expecting LVALUE such as variable name.....

PCM version 3.104 for the 16F877
_________________
The search for better is endless. Instead simply find very good and get the job done.
drh



Joined: 12 Jul 2004
Posts: 192
Location: Hemet, California USA

View user's profile Send private message

PostPosted: Fri Oct 14, 2005 8:37 am     Reply with quote

Use fprintf().
_________________
David
SherpaDoug



Joined: 07 Sep 2003
Posts: 1640
Location: Cape Cod Mass USA

View user's profile Send private message

PostPosted: Fri Oct 14, 2005 8:41 am     Reply with quote

Ah HA!!!!

Thank you muchly!
_________________
The search for better is endless. Instead simply find very good and get the job done.
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