Complete display + add JPEG

This commit is contained in:
philippe44
2020-02-26 23:27:28 -08:00
parent a9f1240965
commit 1ae8f80e53
10 changed files with 290 additions and 12 deletions

View File

@@ -89,11 +89,12 @@ void display_init(char *welcome) {
// Detect driver interface
if (strstr(config, "I2C") && i2c_system_port != -1) {
int address = 0x3C;
int speed = 0;
if ((p = strcasestr(config, "address")) != NULL) address = atoi(strchr(p, '=') + 1);
init = true;
GDS_I2CInit( i2c_system_port, -1, -1 ) ;
GDS_I2CInit( i2c_system_port, -1, -1, i2c_system_speed ) ;
GDS_I2CAttachDevice( display, width, height, address, -1 );
ESP_LOGI(TAG, "Display is I2C on port %u", address);