platformio.ini. Build Setup lists declared environments. Select one explicitly when the project has multiple choices. A single project default can be used without an override.
The selected environment scopes native commands such as pio run --environment <environment>. The native configuration continues to own the platform, board, framework, libraries and flags. Prescaler does not guess board identity from the first section.
If the project uses inheritance, extra configuration files or interpolated values, inspect the effective configuration using PlatformIO tools. An unresolved UI board label is preferable to a falsely verified target.
Use the native SDK environment when diagnosing upload/debug support. Check that the upload/debug protocol and selected probe are compatible with the environment’s board.
PlatformIO environment configuration