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

Pic18F452 breadboard question

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



Joined: 15 Jul 2005
Posts: 59

View user's profile Send private message

Pic18F452 breadboard question
PostPosted: Tue Jul 19, 2005 5:08 pm     Reply with quote

Hi all,

I'm trying to put my pic18f452 on my breadboard (removing it from the proto board). I think I have it all wired correctly, but since it does not work, I do not! HA! Confused

This is what I've done.

#1. Pins 12 & 31 --> Vss
#2. Pins 11 & 32 --> Vdd. +5v w/0.1 uf cap to ground
#3. Pin 1 --> 10k res --> +5v
#4. Pin 25 --> Serial out to Max232

I got everything working on the protoboard so I know the lcd and max are wired correctly as they have always been on the breadboard and not the protoboard.

Now,

I the software (ccs) I compiled using these flags:

Code:

   // setup chip
   setup_adc_ports(NO_ANALOGS);
   setup_adc(ADC_OFF);
   setup_psp(PSP_DISABLED);
   setup_spi(FALSE);
   setup_wdt(WDT_OFF);
   setup_timer_0(RTCC_INTERNAL);
   setup_timer_1(T1_DISABLED);
   setup_timer_2(T2_DISABLED,0,1);
   setup_timer_3(T3_DISABLED|T3_DIV_BY_1);
   setup_low_volt_detect(FALSE);
   setup_oscillator(OSC_NORMAL);


I am NOT using an osc as I want to use the internal...

I checked to make sure power was getting to everything, and that looks good!

Again, I have only hooked up these pins: 1/11/12/25/31/32

Any thoughts?

~Kam (^8*
newguy



Joined: 24 Jun 2004
Posts: 1909

View user's profile Send private message

PostPosted: Tue Jul 19, 2005 5:38 pm     Reply with quote

Sorry, but the 18F452 doesn't have an internal oscillator. That's probably the problem.

Refer to chapter 2 of the 18F452's data sheet.
kam



Joined: 15 Jul 2005
Posts: 59

View user's profile Send private message

I'm lost then!
PostPosted: Tue Jul 19, 2005 5:49 pm     Reply with quote

According to the spec on chapter 2, they mention 8 different types etc. They talk about a "RC" which is an internal one. Yes? Confused Confused

So, if that is the case then, I can just add a 4mhz to pins 13/14.

Apart from that, did I miss anything else for my minimal hookup?

~Kam (^8*
newguy



Joined: 24 Jun 2004
Posts: 1909

View user's profile Send private message

PostPosted: Tue Jul 19, 2005 6:09 pm     Reply with quote

RC means you hook up an external RC network. It's not internal.
kam



Joined: 15 Jul 2005
Posts: 59

View user's profile Send private message

got it!
PostPosted: Tue Jul 19, 2005 6:33 pm     Reply with quote

You are absolutly correct! I hooked up the chrystal to the osc pins and it works! Thanks for the pointers.

~Kam (^8*
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