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

FORCE_SW

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



Joined: 01 Aug 2007
Posts: 38
Location: AUckland, NEW ZEALAND

View user's profile Send private message Send e-mail MSN Messenger

FORCE_SW
PostPosted: Sat Feb 14, 2009 10:32 pm     Reply with quote

Hi,
Trying to use the software to generate UART on pin B3 of a pic18F1220. Code is compiling fine. Programming chip fine. Nothing seems to exit out of pin B3. Here is my code.
Code:
#include <18f1220.h>
#fuses HS, NOWDT, BROWNOUT, NOLVP,
#use delay( clock=4000000)

#use rs232 (baud=9600, xmit=PIN_B3, parity=N, bits=8, ERRORS, FORCE_SW)

void main(){
   while (1){
      putc('a');
      delay_ms(1000);
   }
}


What am i doing wrong? any help appreciated. Cheers
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Sat Feb 14, 2009 11:13 pm     Reply with quote

1. Post your compiler version.

2. Post a description of the external circuits on Pin B3. If you're using
a MAX232-type chip, give the pin number that you connect to your PIC.

3. Post a description of the connections between your board and your PC.
Give the pin numbers on the DB-9 that you connect between your board and the PC.
uni_student



Joined: 01 Aug 2007
Posts: 38
Location: AUckland, NEW ZEALAND

View user's profile Send private message Send e-mail MSN Messenger

PostPosted: Sat Feb 14, 2009 11:20 pm     Reply with quote

Sorry , fundamental mistake. Just found problem. Should have been xmit=PIN_B1 not xmit=PIN_B3. Thanx for reply but fixed now
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