Android RMS Average

Hello together.

we currently implementing an app (IOS and Android) to monitor activity of an object. Therefore we are using the following code on Android:

Mma8452qAccelerometer mma8452qAccelerometer = (Mma8452qAccelerometer) accelerometer;
mma8452qAccelerometer.configureAxisSampling()
                    .setFullScaleRange(Mma8452qAccelerometer.FullScaleRange.FSR_8G)
                    .enableHighPassFilter((byte) 0)
                    .commit();
mma8452qAccelerometer.setOutputDataRate(Mma8452qAccelerometer.OutputDataRate.ODR_12_5_HZ);
accelerometer.routeData().fromAxes()
        .process(new Rms())
        .process(new Average((byte) 8))
        .process(new Time(Time.OutputMode.ABSOLUTE, 30000L)) // every 30 seconds
.log("rms_average")

Afterwards we download log and get all rms_average datasets.

What we need is a data entry every 30 second with the average RMS of the past last 30seconds. Ist this the correct way?

best,
Chris

Comments

This discussion has been closed.