Skip to content
BatteryMonitorConfig.h 1.03 KiB
Newer Older
#ifndef BATTERYMONITORCONFIG_H
#define BATTERYMONITORCONFIG_H

#include <QWidget>
class BatteryMonitorConfig : public AP2ConfigWidget
{
    Q_OBJECT
    
public:
    explicit BatteryMonitorConfig(QWidget *parent = 0);
    ~BatteryMonitorConfig();
private slots:
    void parameterChanged(int uas, int component, QString parameterName, QVariant value);
    void monitorCurrentIndexChanged(int index);
    void sensorCurrentIndexChanged(int index);
    void apmVerCurrentIndexChanged(int index);
    void calcDividerSet();
    void ampsPerVoltSet();
    void batteryCapacitySet();
    void alertOnLowClicked(bool checked);
    void activeUASSet(UASInterface *uas);
    void batteryChanged(UASInterface* uas, double voltage, double current, double percent, int seconds);
    inline float calculatemVPerAmp(float maxvoltsout,float maxamps);
    inline float calculatemVPerVolt(float maxvoltsout,float maxvolts);