Help with pressure sensor.


Closed Thread
Results 1 to 27 of 27

Hybrid View

  1. #1
    Join Date
    May 2004
    Location
    NW France
    Posts
    3,653


    Did you find this post helpful? Yes | No

    Wink simple maths

    Quote Originally Posted by DavyJones View Post
    woohoo I think I got it. Were X is my value read from the AD. I get a nice looking number. What do you think?

    x = x - 24
    res = x * 7812
    res = div32 1000
    Hi, Davy

    I think you could have got it better !!!

    .78125 = ... exactly 25/32 !!!

    so, res = ( x * 25 ) >> 5


    Alain
    ************************************************** ***********************
    Why insist on using 32 Bits when you're not even able to deal with the first 8 ones ??? ehhhhhh ...
    ************************************************** ***********************
    IF there is the word "Problem" in your question ...
    certainly the answer is " RTFM " or " RTFDataSheet " !!!
    *****************************************

  2. #2
    Join Date
    Jul 2007
    Posts
    74


    Did you find this post helpful? Yes | No

    Default

    What if I switched the VRef+ and Vref- to

    Vref+ = 0v
    Vref- = 5v

    Would that work?

  3. #3
    Join Date
    Nov 2003
    Location
    Wellton, U.S.A.
    Posts
    5,924


    Did you find this post helpful? Yes | No

    Default

    Quote Originally Posted by erice1984 View Post
    What if I switched the VRef+ and Vref- to

    Vref+ = 0v
    Vref- = 5v

    Would that work?
    Not sure.
    From what I found out about that sensor it has a variable resistance output. So to use it with an ADC I think you are going to need to change it to a variable voltage with a voltage divider.
    Dave
    Always wear safety glasses while programming.

Similar Threads

  1. Need a cheap touch sensor idea.. here it is
    By mister_e in forum Code Examples
    Replies: 20
    Last Post: - 16th April 2016, 23:42
  2. Is this a K Type sensor?
    By jessey in forum mel PIC BASIC Pro
    Replies: 20
    Last Post: - 21st November 2009, 14:55
  3. PICBASIC PRO-coding for wireless sensor node
    By syazila in forum mel PIC BASIC Pro
    Replies: 2
    Last Post: - 10th February 2009, 01:05
  4. Replies: 6
    Last Post: - 18th January 2008, 09:17
  5. 1-Wire Pressure Sensor
    By Mith in forum mel PIC BASIC Pro
    Replies: 0
    Last Post: - 13th August 2005, 01:32

Members who have read this thread : 0

You do not have permission to view the list of names.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts