After more extensive googling, I found the answer to part of my problem via this post: ESP01 code upload works with Arduino IDE but not with PIO? - #5 by romney.duy
tl;dr: I needed to add board_build.flash_mode = dout
on my ini file, which now looks like this:
[env:esp01]
platform = espressif8266
framework = arduino
board = esp01
; change microcontroller
board_build.mcu = esp8266
; change MCU frequency
board_build.f_cpu = 26000000L
board_build.flash_mode = dout
monitor_speed = 9600
I can now see the built-in blue LED of my ESP8266-01 blink, so the program executes.
However, serial monitor will give me a weird “nul” character instead of the expected output: