How can I use Pulse Detector?

I was trying to use the pulse detector to detect a simple movement, but I can't make it call the receivedFilterOutput callback.
What kind of config I need to make it work?
Can anyone post a example of the Pulse Detector working?


Thanks in advance,

Comments

  • What kind of movement are you looking for?  Pulse detection settings will be highly dependent on your type of motion and will probably require other filter to clean up the data.
  • Hi Eric,

    I'm trying to read a simple motion like "move left", using a fixed orientation (Negative Y is left, Positive Y is right, Positive X is forward and Negative X is backward), by reading the accelerometer sampling values and plotting them into a line graph, I noticed that a linear movement with this orientation fixed, plots a sine like graph. So when I saw the Pulse Detector documentation I thought that this kind of movement would fit into this filter.

    I recorded a video of the movement that I want to detect: https://vid.me/5cG0 https://vid.me/l5e9

    Thanks,
  • The accelerometer has built in motion detection.  You can enable it with the enableMotionDetection method and receive motion notifications from the movementDetected callback function.
  • edited April 2015
    The motion detection didn't work with this movement, it was the first thing that I tried.
    I tested with different thresholds, but it was inconsistent.

  • Using a threshold of 0.25g seems to detect the motion you linked.
  • I tested with 0.25g but didn't work like I expected, sometimes it dispatch both negative and positive movement on the same axis.

    Another question, it's possible to have different thresholds to on different axis?

    Thanks Eric!
  • There is both acceleration (at the beginning) and deceleration (at the end) of the motion so you should see both.  The accelerometer (mma8452q) on the MetaWear does not support different axis thresholds.
  • Thanks Eric!
This discussion has been closed.