Author Topic: Pull Down resistors.....  (Read 5875 times)

fabrolone

  • Full Member
  • ***
  • Posts: 14
    • View Profile
Pull Down resistors.....
« on: March 21, 2010, 10:54:45 AM »
I've a SBC65.
I tried to read port (all configured as input) with default web pages.
It seems that the input are floating.....
I do not know why but B-ports are more floating than others.
In particoular port B0 is almost always at logic level 1.
The problem is that in order to read logic level 0, I need to put a resistor between BO input and gnd of 1k Ohm.
With such resistor, when 5V is connected at the port, I need 5mA for each port just for logic level.
Question is .. is it normal that to pull down the input I need resistor value like 1kOhm ?

What is suggested/necessary value for pullup ?

Any suggestion ?


Fabrizio

Phil Wieland

  • Full Member
  • ***
  • Posts: 17
    • View Profile
Re: Pull Down resistors.....
« Reply #1 on: March 21, 2010, 12:52:46 PM »
According to the circuit diagram B0 is used for the I2C interface and has a pull-up connected.

I suggest you use a free port.
Phil
Liverpool, UK

fabrolone

  • Full Member
  • ***
  • Posts: 14
    • View Profile
Re: Pull Down resistors.....
« Reply #2 on: March 21, 2010, 01:19:14 PM »
Ciao Phil,

I'm using a "plain" SBC65 without any daughter and/or frontend boards.
According to the SBC65 Modtr data sheet I see that I2C is involved only with that boards and in any case it involves RC3 and RC4.

I also check the schematic on the datasheet and I can only see a pull down on the RB6.

There is other docs that I should check to see wich kind of I/O are really available ?

Fabrizio


According to the circuit diagram B0 is used for the I2C interface and has a pull-up connected.

I suggest you use a free port.


Phil Wieland

  • Full Member
  • ***
  • Posts: 17
    • View Profile
Re: Pull Down resistors.....
« Reply #3 on: March 21, 2010, 05:03:29 PM »
I'm using sbc65ecr3.pdf downloaded from the web site.  On sheet 2 of the schematic it shows pull-ups on RB0, RC3 and RC4.

Not sure how accurate it is, I notice it shows the wrong PIC!

Phil
Liverpool, UK

fabrolone

  • Full Member
  • ***
  • Posts: 14
    • View Profile
Re: Pull Down resistors.....
« Reply #4 on: March 22, 2010, 12:54:49 AM »
Ciao Phil,

if your interpretation is right, I can understand why B0 is always to logic level 1, and I need at least a 1K resistor to GND to set it to 0.
But I thought that sheet 2/3 of the scehamtic was referring to the daughter connector schematic.
If this is the right interpretation, in case daughter connector is not  connected (as in my case), these 3 signal should not be pull-up and moreover they could be used as regular I/O. .... but ... if my interpretation is right ... why B0 is so willing to stay at high !!??!! I'll check RC3 and RC4, but I thought that the problem was only on RB0, the other input with a 33KOhm to GND where stable to low level.


Fabri

I'm using sbc65ecr3.pdf downloaded from the web site.  On sheet 2 of the schematic it shows pull-ups on RB0, RC3 and RC4.

Not sure how accurate it is, I notice it shows the wrong PIC!



Phil Wieland

  • Full Member
  • ***
  • Posts: 17
    • View Profile
Re: Pull Down resistors.....
« Reply #5 on: March 22, 2010, 07:42:52 AM »
I've got the magnifying glass out and looked at my board (HW V3.01) and I can see RA2 and CON4 are fitted on the main board so I it looks like the components on Sheet 2/3 are fitted.

Phil
Liverpool, UK

fabrolone

  • Full Member
  • ***
  • Posts: 14
    • View Profile
Re: Pull Down resistors.....
« Reply #6 on: March 22, 2010, 03:48:54 PM »
Ciao Phil,

I think that you are 100% right.
So B0 is pulled up (4.4KOhm), but is it usable for I/O? INT0 does not have any effect ?
Could be the attached table the right I/O usable for SBC65 ?





I've got the magnifying glass out and looked at my board (HW V3.01) and I can see RA2 and CON4 are fitted on the main board so I it looks like the components on Sheet 2/3 are fitted.



Phil Wieland

  • Full Member
  • ***
  • Posts: 17
    • View Profile
Re: Pull Down resistors.....
« Reply #7 on: March 23, 2010, 02:40:59 AM »
The code says that INT0 is tri-stated, so it should have no effect as you say.

That looks like a very useful list.  I would add that C3 and C4 are used to access the socketed eeprom on the I2C bus, so are not free even if you are not using I2C off the board.  RB0 doesn't seem to be involved with this.
Phil
Liverpool, UK

fabrolone

  • Full Member
  • ***
  • Posts: 14
    • View Profile
Re: Pull Down resistors.....
« Reply #8 on: February 09, 2012, 02:30:48 AM »
Just going back to the beginning....

Other than B0, what is appropiate pull down resistor value to pull down to logic level 0 the input ?

I know that for generic input (other than B0) value greater than 1kOhm are possible, but what is the greatest value that allow to read a stable 0 ?

Fabri

gr

  • Hero Member
  • *****
  • Posts: 171
    • View Profile
Re: Pull Down resistors.....
« Reply #9 on: February 09, 2012, 07:41:43 AM »
According to the PIC specification the leakage current is < 200nA if power to the chip is < 5.5V (50nA if < 3V).

So assuming no noise and assuming 0.1V is close enough to 0V you could use a .1/.0000002 or 500K resistor.

However if there is much capacitance in your circuit this will slow down signals.  The pic alone has 10pF which is pretty small.  For example if you switched from outputting 5V to then tristate mode, with only 10pF it would take about 3*500K*10p or 15 uS for the voltage to get most of the way to .1V.  This is pretty fast but if you hook this up to other circuitry and even just wires can increase this capacitance.

Noise is your last problem.  With such a large resistor the circuit might have trouble keeping the voltage constant.  It just depends on how much wire (antenna) you have hanging off the board.   And if you have significant noise you can help that by adding some more capacitance but then your rise and fall times will slow more and now you might want to reduce that pull down resistor.

Another issue is that with 500K on there you might have trouble measuring it because scope and volt meter probes could affect the voltage (crappy scope and meter probes - normal scope probes are 10MOhm so no problem).  This is probably not much of an issue with a 500K resistor.

 500K would probably work in most situations but why risk it?  Why not do something more like 10K?  And if you plan to have a 3 foot wire off of that signal or if you are controlling some machinery with high capacitance or high noise then again you have to look up the specifications (mostly leakage currents, noise, and capacitance) and re-evaluate.