/*
 * measurements.h
 *
 *  Created on: Aug 22, 2024
 *      Author: jakubski
 */

#ifndef INC_MEASUREMENTS_H_
#define INC_MEASUREMENTS_H_

#define SLAVES_COUNT 4
#define PHASES_QTY 3
#define TEMPERATURE_QTY 2

struct _RESMeasurements {
    float voltageRMS[PHASES_QTY];
    float voltagePeak[PHASES_QTY];
    float currentRMS[PHASES_QTY];
    float currentPeak[PHASES_QTY];
    float power[PHASES_QTY];
};

struct _SesnorsInfo {
    float pvTemperature[TEMPERATURE_QTY];
    float fanVoltage;
    float pvEncoder;
    uint8_t motorXStatus;
    uint8_t motorYStatus;
    float motorXAveCurrent;
    float motorYAveCurrent;
    float motorXPeakCurrent;
    float motorYPeakCurrent;
    uint8_t limitSwitchUp;
    uint8_t limitSwitchDown;
    uint8_t limitSwitchCenter;
    uint8_t powerSupplyFailMask;
};

typedef struct _RESMeasurements RESMeasurements;
typedef struct _SesnorsInfo SesnorsInfo;

#endif /* INC_MEASUREMENTS_H_ */
