Shop OBEX P1 Docs P2 Docs Learn Events
Inputs that are near 3v3/2 — Parallax Forums

Inputs that are near 3v3/2

T ChapT Chap Posts: 4,223
edited 2015-04-07 06:38 in Propeller 1
I have a sensor that has a .06 per amp output. I only have about an amp pulled so the output of the sensor will range from 2.5V to 2.56. I am running the sensor through an op amp and can get a more dynamic range of output. What would be acceptable to you guys above and below 3v3/2 as a one and zero?

Comments

  • BeanBean Posts: 8,129
    edited 2014-10-06 08:29
    It depends on how much noise is on the input and how stable the voltage to the propeller is.

    Bean
  • Mark_TMark_T Posts: 1,981
    edited 2014-10-07 06:09
    A comparator is the correct way to turn such a signal to a digital one. Most opamps are too slow to provide a clean
    edge to a fast chip like the Prop. Since the prop doesn't have hysteresis on its pins this is especially important.

    Opamps tend to have slew rates measured in V/us, not the V/ns that logic uses.

    If the sensor is a hall-effect current sensor these are particularly noisy and amplifying them will
    just produce lots of noise causing multiple transitions all over the place. Setting up a comparator
    with enough hysteresis to stop this will be a much saner approach. Or using an ADC to measure
    the level.
  • T ChapT Chap Posts: 4,223
    edited 2014-10-07 06:48
    Thanks guys. I was able to tweak the values and get a very wide swing on the output for two devices. Electro clutch and electro brake. Strangely, on the brake the transition is much slower on a scope, as in visibly slow in the hundreds of ms. I am thinking I am clipping the brake output on the slow swing to zero and that may be the slowness problem. ACS712 into OPA2340. It is workable for a first proto. I will likely add a comp on the next board design or Schmitt.

    http://www.daycounter.com/Calculators/Op-Amp/Op-Amp-Voltage-Calculator.phtml

    This calculator was extremely helpful to get the range I wanted.
  • TubularTubular Posts: 4,702
    edited 2014-10-07 16:13
    Its been a while since a looked at it, but the prop input switching threshold is somewhere around 1.42v when running from 3v3 supplies. Ie more like 43% than 50% of 3v3.

    You can check this by putting a pin into positive feedback mode (eg sigma delta adc measurements) and measure the level its hunting using a dmm.
  • T ChapT Chap Posts: 4,223
    edited 2015-04-06 17:37
    Its been a while since a looked at it, but the prop input switching threshold is somewhere around 1.42v when running from 3v3 supplies. Ie more like 43% than 50% of 3v3.

    I guess I missed this last post back when this was active. Today I was using this circuit with the op amp that ranged from 1.44V to 2.55V and it never would show as LOW. I always though 1.65V was the threshold but this is not true.
  • Mark_TMark_T Posts: 1,981
    edited 2015-04-07 06:38
    CMOS is never very symmetrical since the electron mobility is about 3 times hole-mobility in
    silicon, everything else being constant (which it isn't, such as doping levels). p-FETs and n-FETS
    usually have different geometry to roughly overcome this imbalance. The important word there
    is roughly....

    Note that at mid-rail you typically have both n-FET and p-FET's conducting simultaneously so
    the output depends on the on-resistances, as well as the voltage thresholds of each FET (lots
    of manufacturing variability in thresholds).
Sign In or Register to comment.