Correct settings for ESP8266 D1 Mini

I’m using ESP8266 D1 Mini with Arduino IDE 2.02 successfully.
ESP8266 D1 Mini
I run Check Flash Config
which reports:
Flash real size: 4194304 bytes
Flash ide size: 4194304 bytes
Flash ide speed: 40000000 Hz
Flash ide mode: DOUT
Flash Chip configuration ok.

Now, I’m trying to use this board with Visual Studio Code and PlatformIO . However, the only boards that exist in PIO with 8266 is Wemos D1 Mini Lite & Wemos D1 Mini Pro.
Neither has the same specs as my card as per above.
Lite has 1 MB flash and 80 kB RAM

My platformio.ini:
[env:d1_mini_pro]
platform = espressif8266
board = d1_mini_pro
framework = arduino
monitor_speed = 115200

I can use both Lite and Pro settings in platformio,ini to compile & upload
but PIO reports:
RAM: [=== ] 34.6% (used 28304 bytes from 81920 bytes)
Flash: [=== ] 25.5% (used 266121 bytes from 1044464 bytes)
(My board has 64kByte RAM and 4MByte flash).

There is either no output on the serial monitor or just garbage. If I connect the card to another serial monitor it outputs correctly as above.

EDIT: After uploading the program to the board and connecting it to the Arduino IDE I got this:
Flash real id: 0016405E
Flash real size: 4194304 bytes
Flash ide size: 16777216 bytes
Flash ide speed: 40000000 Hz
Flash ide mode: DIO
Flash Chip configuration wrong!

Where can I change the memory settings for the card in PlatformIO?

See docs

https://docs.platformio.org/en/latest/platforms/espressif8266.html#configuration

Set the same flash mode and frequency as you did in the Arduino IDE, DOUT @ 40mhz.

Flash size does not equal available application size. The flash is partitioned according to the linker scripts in accordance with the limitations of the chip.

Thanks for the answer.
I didn’t set any configuration in Arduino IDE. I just selected LOLIN(WEMOS) D1 mini (clone) and everything works except uploading to LittleFS as I use IDE 2.0.
Could you please tell me how my configuration should look like to set flash size, ide mode etc?

Then better use board = d1_mini instead of d1_mini_pro. You can also force DOUT mode by adding

board_build.flash_mode = dout

to the platformio.ini.

1 Like

Many thanks, yet it is strange because I did try d1_mini before and got “board not found”
Program is running correctly but I can only see the serial communication in Arduino IDE (2.0.2)
Serial Monitor in PratformIO is opening:
-– Terminal on COM12 | 115200 8-N-1
— Available filters and text transformations: colorize, debug, default, direct, esp8266_exception_decoder, hexlify, log2file, nocontrol, printable, send_on_enter, time
— More details at Redirecting...
— Quit: Ctrl+C | Menu: Ctrl+T | Help: Ctrl+T followed by Ctrl+H

No output even after a reset.

Viewing the same on Arduino:
Connecting …
Connected to Wireless
IP address: 192.168.9.108
Filesystem mounted
HTTP server started

Please try all 4 combinations of monitor_rts / dtr = 0/1 as explained in Noob stuck on ESP32-CAM+MB with PIO/vscode - #5 by maxgerhardt.

1 Like

Wonderful!
monitor_rts = 0
monitor_dtr = 0
did it!

Many thanks for your engagement in my problem!