Connect with us

linear motion sensor- help

Discussion in 'Sensors and Actuators' started by mor1989, Jul 12, 2014.

  1. mor1989

    mor1989

    1
    0
    Jul 12, 2014
    hey,
    I want to write a program that do something whenever it detects a change in movement... (such as moving up and than moving down).
    I'm sure I will need to use a motion sensor for it..
    could you help me about the steps I sould do??
    how will the software programming part integrate with the sensor??

    Thanks!!
     
  2. Ehsan

    Ehsan

    100
    1
    Jun 12, 2014
    What kind of movement do you intent to detect ? Cold lifeless objects ? or human body parts ? or ... ?
     
  3. Arouse1973

    Arouse1973 Adam

    5,164
    1,078
    Dec 18, 2013
    I know a few humans that are cold and lifeless :)
    Adam
     
  4. davenn

    davenn Moderator

    13,242
    1,743
    Sep 5, 2009
    a tri-axis accelerometer would be the ideal sensor

    google it :)
    and then ask any other questions

    hahaha Adam ... the wife ?? ;)

    (I'm so bad )

    cheers
    Dave
     
    Arouse1973 likes this.
  5. shumifan50

    shumifan50

    548
    56
    Jan 16, 2014
    What motion do you want to detect:
    1. The movement of the object on which the sensor is mounted
    OR
    2. The movement of object(s) in the field of vision of the computer sensors

    In the case of (20 distance, lighting conditions?

    They require VERY different solutions.
    And what level of experience do you have?
    Go and have a look at some robotic code examples of both types motion detection = use google to find examples.
     
    davenn and KrisBlueNZ like this.
  6. davenn

    davenn Moderator

    13,242
    1,743
    Sep 5, 2009
    Yeah that's the important bit ;)
    I neglected that though in my response


    soooo mor1989, what are you trying to do ?

    Dave
     
  7. Gryd3

    Gryd3

    4,098
    875
    Jun 25, 2014
    Here's hopin' a response comes back soon.
    It would be difficult for an accelerometer to detect linear motion if the object changes speed at a slow rate. Remember it only detects change in motion. (Imagine replacing the speedometer and trip counter in your car with a bar for your current brake and gas pedal position) The sensor will usually show -9.8 m/s^2 in the vertical axis (depending on it's orientation), this reading will not change while the device is in motion, but if it stops or starts in any given direction, you will see a momentary change in the reading. This method would require frequent polling of the sensor and comparing any readings to a baseline. You will then need to determine what your cut off should be (ie, how fast should the object change it's motion) so that you can avoid false readings. This sensor however can be invaluable to tamper proofing an item, as almost any change shows that the object has moved and is no longer on the floor/ground.
    Using alternative methods, like optical sensors, proximity sensors, etc. will allow you to measure the current distance from a reference. You can poll your reference as slow or as fast as you want, if the value changes your object has moved. This will also be much more reliable if you need to know the distance travelled, or require an event to trigger based on a distance travelled.
     
Ask a Question
Want to reply to this thread or ask your own question?
You'll need to choose a username for the site, which only take a couple of moments (here). After that, you can post your question and our members will help you out.
Electronics Point Logo
Continue to site
Quote of the day

-