Showing posts from May, 2020

Use Bodmer TFT_eSPI Library with PlatformIO

If you start playing around with TFT on your ESP8266 or ESP32, you will arrive at the excellent TFT_eSPI Library by Bodmer . It's not only magnitudes faster than the Adafruit driver , it's also comes with support for a wide range of display drivers. Test results of the TFT_eSPI library Unfortunately it has one catch: The library is not really ready to be included as a library in your projects as it requires adjustments in the library itself. While it's not uncommon to define your settings with #define directives, this library expects you to patch files to configure it . The official way goes like this Locate the library folder (Windows would be Documents\Arduino\libraries\TFT_eSPI ) and create your own setup in the library sub folder User_Setups To use your configuration, patch the file User_Setup_Select.h  to include your configuration This has obviously some disadvantages. At latest when you wan't to update the library or work with different screens at the same tim

Migrating from Arduino IDE to Visual Studio Code to PlatformIO

Like every other beginner on ESP8266 I started with my first steps in the official Arduino IDE. I was impressed by the simplicity and easy to use examples that were build-in to the UI. Also the simple UI made it easy to start in uncharted land, especially for someone that did never develop embedded firmware. The library manager let me install additional libraries to play around with, and it also mostly worked. Standard Arduino Editor (IDE) Needless to say, I missed a lot of the features that I was used to from more powerful IDE's like IntelliJ or Visual Studio. I think even Visual Basic 6 had a better IntelliSense support than the Arduino IDE. In fact, Arduino IDE has none. Also, the lack of a dependency management (for libraries) makes it really hard to share code between multiple peers, as you have to manually install the correct version of a library in the global libraries folder. Guess what happens if you use different versions? But overall the Arduino IDE is a g