102 lines
2.3 KiB
C++
102 lines
2.3 KiB
C++
#include <InternalDisplay.hpp>
|
|
|
|
|
|
void InternalDisplay::begin(ESPMegaPRO *espmega) {
|
|
this->espmega = espmega;
|
|
}
|
|
|
|
void InternalDisplay::loop() {
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::bindInputCard(uint8_t card_id) {
|
|
this->bindedInputCard = card_id;
|
|
if(currentPage == INTERNAL_DISPLAY_INPUT_PAGE) {
|
|
refreshInput();
|
|
}
|
|
}
|
|
|
|
void InternalDisplay::bindOutputCard(uint8_t card_id) {
|
|
this->bindedOutputCard = card_id;
|
|
if(currentPage == INTERNAL_DISPLAY_OUTPUT_PAGE) {
|
|
refreshOutput();
|
|
}
|
|
}
|
|
|
|
void InternalDisplay::handleInputStateChange(uint8_t pin, bool state) {
|
|
// If the input card is binded to the display and the current page is the input page
|
|
// then update the respective input component
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::handlePwmStateChange(uint8_t pin, uint16_t value) {
|
|
// If the output card is binded to the display and the current page is the output page
|
|
// then update the respective output component
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::handlePageChange(uint8_t page) {
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::saveNetworkConfig() {
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::saveMQTTConfig() {
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::updateStatusIcons() {
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::updateClock() {
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::refreshPage() {
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::refreshPage(uint8_t page) {
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::refreshDashboard() {
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::refreshInput() {
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::refreshOutput() {
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::refreshAC() {
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::setOutputBar(uint8_t pin, uint16_t value) {
|
|
// Write the value to the output bar
|
|
this->displayAdapter->print("j");
|
|
this->displayAdapter->print(pin);
|
|
this->displayAdapter->print(".val=");
|
|
this->displayAdapter->print(value);
|
|
this->sendStopBytes();
|
|
}
|
|
|
|
void InternalDisplay::setPWMAdjustmentSlider(uint16_t value) {
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::setPWMAdjustmentPin(uint8_t pin) {
|
|
// TODO: implementation
|
|
}
|
|
|
|
void InternalDisplay::setPWMAdjustmentButton(bool state) {
|
|
// TODO: implementation
|
|
}
|