2017-02-19 11:57 PM
Hi,
I am using LIS2DH in our custom board and I am trying to detect some scenarios using this accelerometer. I read the datasheet and application note and tested almost all features. But I'm not sure how to apply them to my scenarios. The sensor is connected to my device which is attached to an underground waste container. The accelerometer can not detect constant speed. So I can not know if the waste collection vehicle is lifting it up(assuming it is lifting it on a constant speed). All I can do is detecting the transition between the device's stable position and the first movement using the free-fall interrupt on the Z axis.
Is there any chance to differentiate the situation of my device between the stable and getting lifted on constant speed? Is there any article about collecting the accelerometer data for such scenarios?
#teft #detect #lis2dh #accelerometer #lifting2017-02-20 02:42 AM
I think the waste container movement will be far from the constant speed in one axis, there will be a lot of peaks of acceleration in all axis. So you can use threshold interrupt to detect that certain value was reached. If your needs are more complex, I would recommend you to record acceleration data during device movement and stable position and process them off-line to find a pattern which can be then recognized by your MCU. You can combine both approaches, for example to wake-up your MCU by interrupt generated by the accelerometer and then search for particular pattern by MCU.
2017-02-20 04:45 AM
Thanks for the reply.
Yes, it is actually far from constant speed in one axis, I just wanted to start from here. So you suggest that I should set an interrupt threshold for waking the MCU and then process the output data of the sensor. Offline working is a good idea to understand the pattern. But I don't really know what type of data is expected. As you said, there are lots of peaks of acceleration in all axis. But I can only understand the instant movements according to this data.
For example, below should be an expected scenario:
- Device is stable on the ground: +1g on Z axis
- A positive peak output when the vehicle first lifts the device instantly. +3g on Z axis
- Constant output while the vehicle is lifting the container to the sky on a constant speed. +1g on Z axis
- A negative peak output when the vehicle stops lifting and the device is hanging in the air. -1g on Z axis
- Device is stable on the air:
+1g on Z axis-
A negative peak output at the moment when the vehicle starts levelling down the container to the ground.
-1g on Z axis- Constant output while the vehicle is levelling down the container on a constant speed.
+1g on Z axis- A positive peak output when the vehicle releases the container on the ground(crashing to the ground).
+3g on Z axis- Device is stable on the ground:
+1g on Z axis