User Tools

Site Tools


ttgo_esp32_vga32_v1.4

TTGO ESP32 VGA32 v1.4

Makefile Environment Setup

  • Install python-serial:
    DEBIAN# apt-get install python3-serial
    or
    GENTOO# emerge dev-python/pyserial
    or
    PYTHON# pip install pyserial
  • Clone the repo makeEspArduino
    cd ~/
    mkdir src
    git clone https://github.com/plerup/makeEspArduino.git
  • Clone the esp32 environment arduino-esp32
    cd ~/src
    git clone https://github.com/espressif/arduino-esp32.git  esp32
    cd esp32
    git checkout tags/2.0.8
    git submodule update --init
    cd tools
    python3 get.py
  • Create core_version.h file (This file is required by some of the FabGL examples)
    austin@mightymouse ~/src/esp32 $ cat /home/austin/src/esp32/cores/esp32/core_version.h
    #define ARDUINO_ESP32_GIT_VER 0xd3254f75
    #define ARDUINO_ESP32_GIT_DESC 2.0.8
    #define ARDUINO_ESP32_RELEASE_2_0_8
    #define ARDUINO_ESP32_RELEASE "2_0_8"

Building FabGL Examples

  • Clone the FabGL repo FabGL
    cd ~/src
    git clone https://github.com/fdivitto/FabGL.git
  • Create a Makefile
    • SpaceInvaders
      austin@mightymouse ~/src/FabGL/examples/VGA/SpaceInvaders $ cat Makefile
      LIBS = /home/austin/src/FabGL/src
      SKETCH = /home/austin/src/FabGL/examples/VGA/SpaceInvaders/SpaceInvaders.ino
      UPLOAD_PORT = /dev/ttyACM0
      CHIP = esp32
      ESP_ROOT=/home/austin/src/esp32
      include /home/austin/src/makeEspArduino/makeEspArduino.mk
  • Compile and upload the sketch
    make flash

PCEmulator

  • Makefile
    austin@mightymouse ~/src/FabGL/examples/VGA/PCEmulator $ cat Makefile
    LIBS = /home/austin/src/FabGL/src
    SKETCH = /home/austin/src/FabGL/examples/VGA/PCEmulator/PCEmulator.ino
    UPLOAD_PORT = /dev/ttyACM0
    CHIP = esp32
    ESP_ROOT=/home/austin/src/esp32
    include /home/austin/src/makeEspArduino/makeEspArduino.mk
  • PCEmulator also requires a code change to the sketch as v1.4 of the SBC uses slightly different pinout
    diff --git a/examples/VGA/PCEmulator/PCEmulator.ino b/examples/VGA/PCEmulator/PCEmulator.ino
    index 2154fc24..27bef0e5 100644
    --- a/examples/VGA/PCEmulator/PCEmulator.ino
    +++ b/examples/VGA/PCEmulator/PCEmulator.ino
    @@ -388,7 +388,8 @@ void setup()
       esp_spiram_init_cache();
       #endif
    
    -  if (!FileBrowser::mountSDCard(false, SD_MOUNT_PATH, 8))   // @TODO: reduce to 4?
    +  //if (!FileBrowser::mountSDCard(false, SD_MOUNT_PATH, 8))   // @TODO: reduce to 4?
    +  if (!FileBrowser::mountSDCard(false, "/SD", 8, 16*1024, 2, 12, 14, 13))
         ibox.message("Error!", "This app requires a SD-CARD!", nullptr, nullptr);
    
       // uncomment to format SD!
  • To edit the floppy disk images that are downloaded you can loopback mount like so:
    mkdir imgmount
    mount -o loop floppy_FREEDOS.img imgmount/
  • To edit the hdd images you need to include the offset:
    mount -o loop,offset=32256 hd20_DOSPROG.img imgmount/
ttgo_esp32_vga32_v1.4.txt · Last modified: 2024/03/17 03:07 by austin