50 lines
1.3 KiB
C++
50 lines
1.3 KiB
C++
#ifndef DRIVERVIEWSTATUSITEM_HPP
|
|
#define DRIVERVIEWSTATUSITEM_HPP
|
|
|
|
#include "touchgfx/Color.hpp"
|
|
#include "touchgfx/hal/Types.hpp"
|
|
#include <gui_generated/containers/DriverViewStatusItemBase.hpp>
|
|
|
|
enum class DriverViewStatusType {
|
|
TS_R2D,
|
|
AMS,
|
|
SDC,
|
|
SCS,
|
|
PDU,
|
|
INV,
|
|
LV,
|
|
SNF,
|
|
DB,
|
|
FTCU,
|
|
SNR,
|
|
Shunt,
|
|
BPR,
|
|
BPF,
|
|
};
|
|
|
|
class DriverViewStatusItem : public DriverViewStatusItemBase {
|
|
public:
|
|
DriverViewStatusItem();
|
|
virtual ~DriverViewStatusItem() {}
|
|
|
|
virtual void initialize();
|
|
|
|
virtual void setType(DriverViewStatusType type);
|
|
|
|
void update();
|
|
|
|
static inline colortype COLOR_OFF = touchgfx::Color::getColorFromRGB(0x00, 0x00, 0x00); // #000000
|
|
static inline colortype COLOR_OK = touchgfx::Color::getColorFromRGB(0x0D, 0xBF, 0x00); // #0DBF00
|
|
static inline colortype COLOR_WARNING = touchgfx::Color::getColorFromRGB(0xEB, 0xC4, 0x00); // #EBC400
|
|
static inline colortype COLOR_ERROR = touchgfx::Color::getColorFromRGB(0xC5, 0x0E, 0x1F); // #C50E1F
|
|
static inline colortype COLOR_TS = touchgfx::Color::getColorFromRGB(0xEB, 0x7D, 0x00); // #EB7D00
|
|
static inline colortype COLOR_BLUE = touchgfx::Color::getColorFromRGB(0x00, 0x8F, 0xEE); // #008FEE
|
|
|
|
protected:
|
|
private:
|
|
DriverViewStatusType type;
|
|
touchgfx::Unicode::UnicodeChar valueBuffer[16];
|
|
};
|
|
|
|
#endif // DRIVERVIEWSTATUSITEM_HPP
|