   else {
     OLED.init();
     ESP_LOGI( TAG, "Found SSD1306 OLED on I2C at address 0x%x.", OLED_ADDRESS );
-    if ( preferences.getString( "oledorientation", "normal" ) == "upsidedown" ) {
+    if ( preferences.getString( "oledorientation", "normal" ).equals( "upsidedown" ) ) {
       oledOrientation = OLED_ORIENTATION_UPSIDEDOWN;
       OLED.flipScreenVertically();
     }


  /* check if a ffat partition is defined and halt the system if it is not defined*/
  if (!esp_partition_find_first(ESP_PARTITION_TYPE_DATA, ESP_PARTITION_SUBTYPE_DATA_FAT, "ffat")) {
    ESP_LOGI( TAG, "No FFat partition defined. Halting.\nCheck 'Tools>Partition Scheme' in the Arduino IDE and select a FFat partition." );
    const char * noffatStr = "No FFat found...";
    if ( xTftTaskHandle ) {
      tft.println( noffatStr );

    }
    ESP_LOGI( TAG, "%s", formatStr );
    if (!FFat.format( true, (char*)"ffat" ) || !FFat.begin()) {
      ESP_LOGE( TAG, "FFat error while formatting. Halting." );
      const char * errorffatStr = "FFat error.";
      if ( xTftTaskHandle ) {
        tft.println( errorffatStr );
