Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Regenerate sdkconfig.<board> if missing #588

Closed
maxgerhardt opened this issue Jul 22, 2021 · 2 comments
Closed

Regenerate sdkconfig.<board> if missing #588

maxgerhardt opened this issue Jul 22, 2021 · 2 comments

Comments

@maxgerhardt
Copy link
Contributor

maxgerhardt commented Jul 22, 2021

I just wanted to apply a new sdkconfig.defaults file (from https://github.com/espressif/esp-idf/tree/v4.3/examples/bluetooth/bluedroid/classic_bt/a2dp_sink/main), but I already had a sdkconfig.pico32 in my project folder after an initial build. So, wanting to apply the defaults file, I deleted sdkconfig.pico32 in hopes that the next pio run -t menuconfig regenerates the default options plus the options from the sdkconfig.defaults -- instead it gives an assertion error that the file is not found

>pio run -t menuconfig
..
Reading CMake configuration...
AssertionError: Missing auto-generated SDK configuration file `C:\Users\Max\temp\espidf_a2dp_sink\sdkconfig.pico32`:
  File "C:\Users\Max\AppData\Local\Programs\Python\Python38\Lib\site-packages\platformio\builder\main.py", line 178:
    env.SConscript("$BUILD_SCRIPT")
  File "C:\Users\Max\.platformio\packages\tool-scons\scons-local-4.1.0\SCons\Script\SConscript.py", line 591:
    return _SConscript(self.fs, *files, **subst_kw)
  File "C:\Users\Max\.platformio\packages\tool-scons\scons-local-4.1.0\SCons\Script\SConscript.py", line 280:
    exec(compile(scriptdata, scriptname, 'exec'), call_stack[-1].globals)
  File "C:\Users\Max\.platformio\platforms\espressif32\builder\main.py", line 228:
    target_elf = env.BuildProgram()
  File "C:\Users\Max\.platformio\packages\tool-scons\scons-local-4.1.0\SCons\Util.py", line 658:
    return self.method(*nargs, **kwargs)
  File "C:\Users\Max\AppData\Local\Programs\Python\Python38\Lib\site-packages\platformio\builder\tools\platformio.py", line 61:
    env.ProcessProgramDeps()
  File "C:\Users\Max\.platformio\packages\tool-scons\scons-local-4.1.0\SCons\Util.py", line 658:
    return self.method(*nargs, **kwargs)
  File "C:\Users\Max\AppData\Local\Programs\Python\Python38\Lib\site-packages\platformio\builder\tools\platformio.py", line 128:
    env.BuildFrameworks(env.get("PIOFRAMEWORK"))
  File "C:\Users\Max\.platformio\packages\tool-scons\scons-local-4.1.0\SCons\Util.py", line 658:
    return self.method(*nargs, **kwargs)
  File "C:\Users\Max\AppData\Local\Programs\Python\Python38\Lib\site-packages\platformio\builder\tools\platformio.py", line 343:
    SConscript(env.GetFrameworkScript(f), exports="env")
  File "C:\Users\Max\.platformio\packages\tool-scons\scons-local-4.1.0\SCons\Script\SConscript.py", line 654:
    return method(*args, **kw)
  File "C:\Users\Max\.platformio\packages\tool-scons\scons-local-4.1.0\SCons\Script\SConscript.py", line 591:
    return _SConscript(self.fs, *files, **subst_kw)
  File "C:\Users\Max\.platformio\packages\tool-scons\scons-local-4.1.0\SCons\Script\SConscript.py", line 280:
    exec(compile(scriptdata, scriptname, 'exec'), call_stack[-1].globals)
  File "C:\Users\Max\.platformio\platforms\espressif32\builder\frameworks\espidf.py", line 1164:
    assert os.path.isfile(SDKCONFIG_PATH), (
========================================================================================== [FAILED] Took 2.02 seconds ==========================================================================================

I think the behavior should be changed to generate the file if missing, while respecting the .defaults file.

Using latest Espressif 32 (3.3.0).

@valeros
Copy link
Member

valeros commented Jul 22, 2021

Thanks for reporting, should be fixed in the dev branch!

@maxgerhardt maxgerhardt changed the title Regenerate sdkconfig.<board> if misisng Regenerate sdkconfig.<board> if missing Jul 22, 2021
@maxgerhardt
Copy link
Contributor Author

I've just tested this and the regeneration, while respecting the sdkconfig.defaults file, works like a charm. Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants