How Install Espressif IDF Command line on Windows

Ardyesp
Posts: 5
Joined: Thu Dec 01, 2022 1:17 pm

How Install Espressif IDF Command line on Windows

Postby Ardyesp » Wed Mar 01, 2023 11:06 am

I am trying to use (Espressif IDF command line version on windows 11) to run DAC examples of audio to the internal DAC ports pin 25 and 26 on ESP32-PICO-KIT.
I started from here.....
https://docs.espressif.com/projects/esp ... index.html
Then clicked Manual installation ..... Windows Installer....
I see there is and updated bug fixed version 5.0.1 .... so I clicked this...
and selected ESP-IDF v5.0.1 - Offline Installer ..... and all appeared to install correctly and got 2 icons one for powershell and one for CMD line. I am using ESP32-PICO-D4-KIT board. I can compile and run basic sketches, blink, hello world etc. but when I try to run the examples/peripherals/dac sketches they wont compile..... dac_cosine.h no such file or directory etc etc. and I cannot find that file any where within the installation... Where are library files stored in windows..??. If I go to the Github pages I see updates etc....how do I update these pages into my installation......???

Ardyesp
Posts: 5
Joined: Thu Dec 01, 2022 1:17 pm

Re: How Install Espressif IDF Command line on Windows

Postby Ardyesp » Wed Mar 01, 2023 8:45 pm

I am using the examples in the 5.0.1 installed folder examples/peripherals and dac example is not there as it is in the github webpage...??
There is a "wave_gen" example that outputs as signal generator sine, triangle, square etc.... this example compiles and runs OK
but if I copy the dac example from the latest github webpage I cannot get it to build. It wants for the dac_cosine example driver/dac_cosine.h and errors no such file or directory. The wave_gen example uses dac.h......

According to the docs the I2S is no longer supporting the DAC output as copy below
/* ADC/DAC are not supported in the new I2S driver, but still available in the legacy I2S driver for backward compatibility
* Please turn to the dedicated ADC/DAC driver instead */
so...... confused by what is happening...????

Ardyesp
Posts: 5
Joined: Thu Dec 01, 2022 1:17 pm

Re: How Install Espressif IDF Command line on Windows

Postby Ardyesp » Thu Mar 02, 2023 5:15 pm

Regards Running Examples published on Github....
I have installed the Espressif IDF 5.0.1 powershell/command line version.
Have followed the install guidance as best as I think I can and basic examples in the examples folder within the installation run OK including the audio example "wave_gen"
I want to try what I think are the latest examples on Github and in particular the "dac examples"....
What I have done so far to try to get it to work....

So starting from this webpage.......
Welcome to Espressif’s site on GitHub
https://github.com/espressif

Then click this link....
IoT Development Framework (ESP-IDF)
it takes me to....
https://github.com/espressif/esp-idf
which shows a list of all the files and folders available..

If I click on "examples" it takes me list of all the example categories etc....
If I then click on "peripherals" it takes me to all the examples for peripherals such as adc, dac, spi, timers usb etc.....
If I now click on "dac".... it takes me to 3 examples for "dac" .... eg. dac_continuous, dac_cosine_wave and dac_oneshot. .....
If for example I click on "dac_cosine_wave" it takes me to the related files....this is the Overview in the the README.md file .....

" This example shows the basic usage of outputting cosine wave by the DAC driver. The cosine wave is generated by the hardware cosine wave generator in the DAC module.

This example will output cosine wave on both channels.".....

If I click on "main" I see the " dac_cosine_example_main.c "......

This is the list of includes in the file .....

#include "freertos/FreeRTOS.h"
#include "freertos/task.h"
#include "driver/dac_cosine.h"
#include "esp_adc/adc_oneshot.h"
#include "esp_check.h"

This example is not included in the examples folder of the latest 5.0.1 Espressif IDF so how is files in this Github to be built and run.

If I copy the " dac" folder into the 5.0.1 installation I get errors "driver/dac_cosine.h" no such file or directory ... etc etc.

Is there any other files or library I need to install in order to run these, OR is there some other "PATH" settings I need to do...???

I would be grateful if someone to tell me if they have run the "dac" examples on Espressif IDF and let me know what else I need to do.

Who is online

Users browsing this forum: Baidu [Spider] and 74 guests