LMA
Lightweight Metrology for AC
Loading...
Searching...
No Matches
Measurement

Description

LMA Measurement API

The LMA Measurement API is used to retrieve measurement metrics from LMA at runtime.

Collaboration diagram for Measurement:

Functions

void LMA_MeasurementsGet (LMA_Phase *const p_phase, LMA_Measurements *const p_measurements)
 Outputs current snap shot of measurement set.
void LMA_ConsumptionDataGet (const LMA_SystemEnergy *const p_se, LMA_ConsumptionData *const p_ec)
 Converts current snap shot of energy consumed by the meter in Wh.
bool LMA_MeasurementsReady (LMA_Phase *const p_phase)
 Checks whether measurements are ready.

Function Documentation

◆ LMA_MeasurementsGet()

void LMA_MeasurementsGet ( LMA_Phase *const p_phase,
LMA_Measurements *const p_measurements )

Outputs current snap shot of measurement set.

Parameters
[in,out]p_phase- pointer to the phase block on which to get measurements from.
[out]p_measurements- pointer to the measurement structure to populate.

◆ LMA_ConsumptionDataGet()

void LMA_ConsumptionDataGet ( const LMA_SystemEnergy *const p_se,
LMA_ConsumptionData *const p_ec )

Converts current snap shot of energy consumed by the meter in Wh.

Must call LMA_EnergyGet first.

Parameters
[in]p_se- pointer to the system energy structure (containing system energy counters)
[out]p_ec- pointer to the energy consumption structure to populate.

◆ LMA_MeasurementsReady()

bool LMA_MeasurementsReady ( LMA_Phase *const p_phase)

Checks whether measurements are ready.

Parameters
p_phase- pointer to the phase to check.
Returns
true if new measurements are ready, false otherwise.