Giter VIP home page Giter VIP logo

Comments (6)

yellobyte avatar yellobyte commented on September 28, 2024

Hi Kurt,
when building for ESP32 then DAC_CHANNEL_MAX is declared in "..../.platformio/packages/framework-arduinoespressif32/tools/sdk/esp32/include/hal/include/hal/dac_types.h" which should start like this:

#pragma once

#include "soc/soc_caps.h"
#include "hal/adc_types.h"
#include "sdkconfig.h"

typedef enum {
    DAC_CHANNEL_1 = 0,    /*!< DAC channel 1 is GPIO25(ESP32) / GPIO17(ESP32S2) */
    DAC_CHANNEL_2 = 1,    /*!< DAC channel 2 is GPIO26(ESP32) / GPIO18(ESP32S2) */
    DAC_CHANNEL_MAX,
} dac_channel_t;
....
....

Building for ESP32-S2, ESP32-S3 or ESP32-C3 might fail for those MCUs don't have a DAC module integrated.
And of course, always make sure you use the latest ESP32 framework.
Cheers
Thomas

from dacesp32.

nitricware avatar nitricware commented on September 28, 2024

I don't know what I'm missing.

I include the library via the Arduino IDE and upload the sketch to the ESP32. Other code ran fine that way.

I have the same problem with the Arduino IDE/physical ESP32 and Wokwi.

from dacesp32.

yellobyte avatar yellobyte commented on September 28, 2024

Make sure you have all recent updates for IDE, framework & libs. If no success then a clean IDE install might help.
Just did a build with settings as below.
IDE Board Settings
Here the complete build log just for reference:
DacESP32-Build.log

from dacesp32.

Jay-esp avatar Jay-esp commented on September 28, 2024

I have the same problem, the definition changed in the latest version of the esp32 libraries.

from dacesp32.

yellobyte avatar yellobyte commented on September 28, 2024

Ok, I'll have a look at it.

from dacesp32.

yellobyte avatar yellobyte commented on September 28, 2024

Just released V1.1.1. Please give it a try and have a look at the release info.

from dacesp32.

Related Issues (6)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.