Skip to content

Shimmer3R Calibration: division by 4095 or 16383 #201

@czy10383

Description

@czy10383
    protected double CalibrateMspAdcChannel(double unCalData)
    {
        double offset = 0; double vRefP = 3; double gain = 1;
        double calData = CalibrateU12AdcValue(unCalData, offset, vRefP, gain);
        return calData;
    }

    protected double CalibrateShimmer3RAdcChannel(double unCalData)
    {
        double offset = 0; double vRefP = 3; double gain = 1;
        double calData = CalibrateU12AdcValue(unCalData, offset, vRefP, gain);
        return calData;
    }

    protected double CalibrateU12AdcValue(double uncalibratedData, double offset, double vRefP, double gain)
    {
        double calibratedData = (uncalibratedData - offset) * (((vRefP * 1000) / gain) / 4095);
        return calibratedData;
    }

    protected double CalibrateU14AdcValue(double uncalibratedData, double offset, double vRefP, double gain)
    {
        double calibratedData = (uncalibratedData - offset) * (((vRefP * 1000) / gain) / 16383);
        return calibratedData;
    }

I refer to the above codes in ShimmerBluetooth.cs Line 7496 onwards

When we call CalibrateShimmer3RAdcChannel for Shimmer3R, it will call CalibrateU12AdcValue which divides the data by 4095 as shown above.

Shouldn't it call CalibrateU14AdcValue which will divde the data by 16383 instead?

thank you

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions