You've already forked TEF6686_ESP32
i2c raw control
This commit is contained in:
@@ -9,6 +9,7 @@ void Communication();
|
||||
void XDRGTKRoutine();
|
||||
void passwordcrypt();
|
||||
void tryWiFi();
|
||||
void total_pc_control();
|
||||
|
||||
extern void BuildDisplay();
|
||||
extern void BuildAdvancedRDS();
|
||||
|
||||
@@ -336,6 +336,9 @@ extern bool rds_settings_changed;
|
||||
extern const size_t language_totalnumber;
|
||||
extern const size_t language_entrynumber;
|
||||
|
||||
extern volatile bool i2c_pc_control;
|
||||
extern volatile bool i2c_pc_control_init;
|
||||
|
||||
extern mem presets[EE_PRESETS_CNT];
|
||||
extern TEF6686 radio;
|
||||
|
||||
|
||||
@@ -2,6 +2,8 @@
|
||||
#include <Arduino.h>
|
||||
#include <TFT_eSPI.h>
|
||||
|
||||
#define CONSOLE_FONT 2
|
||||
|
||||
class Console {
|
||||
public:
|
||||
explicit Console(TFT_eSPI* display) : tft(display), y(0) {}
|
||||
@@ -9,9 +11,9 @@ public:
|
||||
tft->setTextColor(TFT_WHITE, background);
|
||||
tft->setTextDatum(TL_DATUM);
|
||||
auto data = "[" + String(millis() / 1000.0f) + "] " + text;
|
||||
tft->fillRect(0, y, tft->textWidth(data), tft->fontHeight(2), background);
|
||||
tft->drawString(data, 0, y, 2);
|
||||
y += tft->fontHeight(2);
|
||||
tft->fillRect(0, y, tft->textWidth(data, CONSOLE_FONT), tft->fontHeight(CONSOLE_FONT), background);
|
||||
tft->drawString(data, 0, y, CONSOLE_FONT);
|
||||
y += tft->fontHeight(CONSOLE_FONT);
|
||||
}
|
||||
void reset() {
|
||||
y = 0;
|
||||
|
||||
Reference in New Issue
Block a user