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

Unable to resolve dacDisable() when compiling an ESP32/Arduino project #3058

Closed
MrYsLab opened this issue Mar 9, 2022 · 4 comments
Closed

Comments

@MrYsLab
Copy link

MrYsLab commented Mar 9, 2022

I am using Ubuntu 21.04 and the latest version of VSCode. In building a project for the ESP32 using Arduino for esp32doit-devkit-v1
I get the following error:

error: 'dacDisable' was not declared in this scope

The file correctly compiles when using the Arduino IDE.

The source file I used to test is:

#include <Arduino.h>

void setup() {
  // put your setup code here, to run once:
  dacWrite(25, 233);
  dacDisable(25);
}

void loop() {
  // put your main code here, to run repeatedly:
}

By modifying platform.ini from:

[env:esp32doit-devkit-v1]
platform = espressif32
board = esp32doit-devkit-v1
framework = arduino

to:

[env:esp32doit-devkit-v1]
platform = https://github.com/platformio/platform-espressif32.git#feature/arduino-upstream
platform_packages = framework-arduinoespressif32 @ https://github.com/espressif/arduino-esp32.git#2.0.2
board = esp32doit-devkit-v1
framework = arduino

It now compiles correctly.

Please update the vscode extension to correct this issue.

@mrengineer7777
Copy link

This is not an issue with the PIO Extension for VSCode

@MrYsLab
Copy link
Author

MrYsLab commented Mar 11, 2022

Thanks for the reply. Could you point to where the problem lies (which project) so I can enter an issue there?

@mrengineer7777
Copy link

@MrYsLab https://github.com/platformio/platform-espressif32

I suspect your issue is because platform-espressif32 is still based on Arduino 1.0.6 and an old version (3.3.1?) of the IDF.
See platformio/platform-espressif32#710

See also
https://github.com/espressif/arduino-esp32

I use a custom fork by TASMOTA
https://github.com/tasmota/platform-espressif32/

@MrYsLab
Copy link
Author

MrYsLab commented Mar 11, 2022

@mrengineer7777 Thanks.

@MrYsLab MrYsLab closed this as completed Mar 11, 2022
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