diff options
author | Joshua Drake <joshua.drake@ditchwitch.com> | 2022-11-21 16:34:17 -0600 |
---|---|---|
committer | Joshua Drake <joshua.drake@ditchwitch.com> | 2022-11-21 16:34:17 -0600 |
commit | 179ed918aed1c9f190ae6846ea4bcccccbeab18f (patch) | |
tree | 1fabd0bbc20e102097eeecf18e2238f121629d0f /precharge.h | |
parent | 341e61f7a6f9deebf086a2b8147e252be6d45f33 (diff) |
Added Pre-Charge functionality and made thing prettier.
Diffstat (limited to 'precharge.h')
-rw-r--r-- | precharge.h | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/precharge.h b/precharge.h new file mode 100644 index 0000000..376b067 --- /dev/null +++ b/precharge.h @@ -0,0 +1,38 @@ +#ifndef PRECHARGE_H +#define PRECHARGE_H + +#include <QObject> +#include <QtMath> + +class Precharge : public QObject +{ + Q_OBJECT +public: + Precharge(); + + void setMaximumVoltage(double voltage); + void setPreChargeTime(double time); + void setPreChargePercentage(double percentage); + void setSystemCapacitance(float capacitance); + void setChosenResistance(double resistance); + + double maximumResistance(void); + double actualPreChargeTime(void); + double peakInRushCurrent(void); + double averagePower(void); +public slots: + void calculate(void); + +private: + double maximumVoltage; + double preChargeTime; + double preChargePercentage; + double chosenResistance; + float systemCapacitance; + +signals: + void calculation(void); + +}; + +#endif // PRECHARGE_H |