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

simple question about floating pins

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







simple question about floating pins
PostPosted: Thu Jan 13, 2005 11:18 am     Reply with quote

i am using a pic for a school project. The pic I
m using is an overkill. I have about 8 pins not used. The code works fine when I run it, but I recall someone here saying I should never leave the pins floating.

So I should use a 10k pull down resistor and pull all the unused pins to ground?

Thanks
SherpaDoug



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

View user's profile Send private message

PostPosted: Thu Jan 13, 2005 12:06 pm     Reply with quote

That will certainly work. Often people have a fixed PCB with no room for resistors. Then I tell then to make the pins outputs.
The reason not to leave pins open is at least twofold:
1) If the pin decides to sit halfway between 0 and 1 it can cause the input buffer to draw lots of current or oscillate, which consumes power, generates heat, and if oscillating, generates electrical noise.
2) Floating pins are more susceptable to static damage. This is likely only to damage the pin involved, but may also hurt other circuits on the chip.
_________________
The search for better is endless. Instead simply find very good and get the job done.
Mark



Joined: 07 Sep 2003
Posts: 2838
Location: Atlanta, GA

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

PostPosted: Thu Jan 13, 2005 12:07 pm     Reply with quote

http://www.ccsinfo.com/forum/viewtopic.php?t=3861&highlight=unused+pins
LaTech
Guest







PostPosted: Thu Jan 13, 2005 12:35 pm     Reply with quote

Yep that answered the question, I did a search before i posted but the term 'floating' retrieved alot of number problems not pin problems.

Thanks again!
guest2
Guest







RE:
PostPosted: Sun Jan 16, 2005 6:26 am     Reply with quote

Hi,

Maybe you should configure them as inputs instead, if you connect the output to ground inadvertently then you might short the +5 V line.

thanks
arun
Mark



Joined: 07 Sep 2003
Posts: 2838
Location: Atlanta, GA

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

Re: RE:
PostPosted: Sun Jan 16, 2005 8:41 am     Reply with quote

guest2 wrote:
Hi,

Maybe you should configure them as inputs instead, if you connect the output to ground inadvertently then you might short the +5 V line.

thanks
arun


Now that is just plain silly Razz What if you inadvertently connected a pin you wanted to be an output to ground Question
dyeatman



Joined: 06 Sep 2003
Posts: 1934
Location: Norman, OK

View user's profile Send private message

Pullups/Pulldowns
PostPosted: Sun Jan 16, 2005 9:03 am     Reply with quote

FWIW, I agree with Mark.

As a matter of practice I NEVER EVER connect any I/O pins (even ones normally A/D) directly to +V or ground... If something happens, regardless of how inadvertantly (even a compiler error), to configure the pins incorrectly you destroy the chip.

I always use pullups or pulldowns in SIL resistor packages to minimize the room required. In real tight situations, being as small as they are, I have even soldered them directly to the pin connections on the bottom of the board so they don't require real estate.
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