Forum Replies Created

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • Mariano B
    Participant

      SOLVED!

      It seems as there is a bug in EmailSender.h file when using STORAGE_SDFAT2 option: using SdFat library with ESP8266, you have to edit line 323 of this file in the section ‘#elif (EXTERNAL_STORAGE == STORAGE_SDFAT2)’
      from ‘extern SdFat EXTERNAL_STORAGE_CLASS;’
      to ‘extern SdFs EXTERNAL_STORAGE_CLASS;’

      For others interested to use this wonderful library to build small devices that must log data in the SD and send a file by email, my settings in file EMailSenderKey.h from default must be set as follows:
      #define SD_CS_PIN D4 // GPIO pin connected to my SD CS pin
      #define DEFAULT_EXTERNAL_ESP8266_STORAGE STORAGE_SDFAT2
      #define DEFAULT_EXTERNAL_ESP32_STORAGE STORAGE_SDFAT2
      #define DEFAULT_INTERNAL_ESP8266_STORAGE STORAGE_NONE
      #define DEFAULT_INTERNAL_ESP32_STORAGE STORAGE_NONE
      #define STORAGE_INTERNAL_FORCE_DISABLE // if internal storage is not needed

      With this, it works as charm and uses much less resources to send emails than other similar libraries.

      Thank you, Renzo!

      in reply to: Email with sd files #28815
      Mariano B
      Participant

        (*)

        • This reply was modified 1 year ago by Mariano B.
      Viewing 2 posts - 1 through 2 (of 2 total)