minor cleanup and optimizations

This commit is contained in:
ionsurdu@github.com
2024-08-13 14:49:51 +03:00
parent d2c02b62eb
commit b388ef6fdc
3 changed files with 176 additions and 192 deletions

View File

@@ -37,19 +37,21 @@
#define OSD_X_START 1
#define OSD_Y_START 16
int osd_chart_buffer[OSD_CHART_WIDTH];
DFRobot_OSD osd(CS);
/*Define Chinese characters*/
int buf0[36] = {0x02, 0x80, 0x02, 0x40, 0x7F, 0xE0, 0x42, 0x00, 0x42, 0x00, 0x7A, 0x40,
0x4A, 0x40, 0x4A, 0x80, 0x49, 0x20, 0x5A, 0xA0, 0x44, 0x60, 0x88, 0x20};
int buf1[36] = {0x20, 0x00, 0x25, 0xE0, 0x75, 0x20, 0x29, 0x20, 0xFD, 0x40, 0x21, 0x40,
0x7D, 0x20, 0xC5, 0x20, 0x7D, 0x20, 0x45, 0xC0, 0x7D, 0x00, 0x45, 0x00};
int buf2[36] = {0x20, 0x00, 0x2F, 0xC0, 0x24, 0x40, 0xF4, 0x40, 0x24, 0x80, 0x64, 0xE0,
0x74, 0x20, 0xA6, 0x20, 0x25, 0x40, 0x28, 0x80, 0x29, 0x40, 0x32, 0x20};
int buf3[36] = {0x3F, 0x00, 0x2A, 0xE0, 0xFA, 0x20, 0x2E, 0xA0, 0x2A, 0xA0, 0xFE, 0xA0,
0x2A, 0x40, 0xAB, 0x40, 0xBE, 0xA0, 0xA3, 0x20, 0xE2, 0x00, 0xBF, 0xE0};
static const int buf0[36] = {0x02, 0x80, 0x02, 0x40, 0x7F, 0xE0, 0x42, 0x00,
0x42, 0x00, 0x7A, 0x40, 0x4A, 0x40, 0x4A, 0x80,
0x49, 0x20, 0x5A, 0xA0, 0x44, 0x60, 0x88, 0x20};
static const int buf1[36] = {0x20, 0x00, 0x25, 0xE0, 0x75, 0x20, 0x29, 0x20,
0xFD, 0x40, 0x21, 0x40, 0x7D, 0x20, 0xC5, 0x20,
0x7D, 0x20, 0x45, 0xC0, 0x7D, 0x00, 0x45, 0x00};
static const int buf2[36] = {0x20, 0x00, 0x2F, 0xC0, 0x24, 0x40, 0xF4, 0x40,
0x24, 0x80, 0x64, 0xE0, 0x74, 0x20, 0xA6, 0x20,
0x25, 0x40, 0x28, 0x80, 0x29, 0x40, 0x32, 0x20};
static const int buf3[36] = {0x3F, 0x00, 0x2A, 0xE0, 0xFA, 0x20, 0x2E, 0xA0,
0x2A, 0xA0, 0xFE, 0xA0, 0x2A, 0x40, 0xAB, 0x40,
0xBE, 0xA0, 0xA3, 0x20, 0xE2, 0x00, 0xBF, 0xE0};
// SPI pins
// .pio/libdeps/heltec_wifi_lora_32_V3/Heltec_ESP32_LoRa_v3/src/heltec_unofficial.h#L34-L35