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

new to PCM

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



Joined: 24 Apr 2006
Posts: 3

View user's profile Send private message

new to PCM
PostPosted: Mon Apr 24, 2006 12:03 pm     Reply with quote

I just bought and installed PCM. Been Trying to run the sample code in the compilerto see if everything OK.
Built Succeeded in MPLAB 7.30. Why I could not run "Animate" to walk thru the C code?
Do I miss something here.
Thanks for your help.

eetrung
_________________
Newbie
PCM programmer



Joined: 06 Sep 2003
Posts: 21708

View user's profile Send private message

PostPosted: Mon Apr 24, 2006 1:43 pm     Reply with quote

Did you fully install the compiler, including the CCS "Plug-in", etc. ?

Did you go to the Debugger menu in MPLAB and then in the Select Tool
menu, did you pick MPLAB SIM ?

In the Configure menu, did you go to Select Device, and make sure
it matches the PIC specified in the #include statement in your program ?

Then compile and in the Debugger menu, select Animate.

Using the UART1 output window, the following program slowly
spells out Hello World. It works.

Code:
#include <16F877.H>
#fuses XT, NOWDT, NOPROTECT, BROWNOUT, PUT, NOLVP
#use delay(clock=4000000)
#use rs232(baud=9600, xmit=PIN_C6, rcv=PIN_C7, ERRORS)

void main()
{
   
while(1)
  {
   printf("Hello World\n\r");
  }

}


Instructions on how to use UART1 to display output in MPLAB simulator:
http://www.ccsinfo.com/forum/viewtopic.php?t=23408&start=1
eetrung



Joined: 24 Apr 2006
Posts: 3

View user's profile Send private message

PostPosted: Tue Apr 25, 2006 5:56 am     Reply with quote

I followed your steps. It works out fine.
Thanks for your help.
_________________
Newbie
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