Search found 6 matches

by bitmandu
Sat May 15, 2021 3:39 pm
Forum: General Discussion
Topic: Component: Include header inside main folder
Replies: 1
Views: 2420

Re: Component: Include header inside main folder

I think you want to add "main" to INCLUDE_DIRS in CMakeLists.txt. This should add the main folder to the global include search path.

For example

Code: Select all

idf_component_register(SRCS ...
                       INCLUDE_DIRS "main" ...
                       REQUIRES ...)
by bitmandu
Thu May 13, 2021 11:49 pm
Forum: General Discussion
Topic: ESP32-S2 ULP-RISC-V clock frequency? Microsecond delay
Replies: 2
Views: 4013

ESP32-S2 ULP-RISC-V clock frequency? Microsecond delay

I'm trying to communicate with a sensor using the 1-Wire protocol from the ULP-RISC-V coprocessor on the ESP32-S2. To do this I need microsecond-ish precision delays. There is an older post on the forum looking at how to implement a cycle-based wait, similar to the wait instruction for the ULP-FSM ,...
by bitmandu
Thu May 06, 2021 1:12 am
Forum: General Discussion
Topic: ULP RISC-V calling assembly from C not working
Replies: 2
Views: 3824

Re: ULP RISC-V calling assembly from C not working

Thanks for the help ESP_Angus! Your explanation (and solution) really made things clear.
by bitmandu
Mon May 03, 2021 10:10 pm
Forum: General Discussion
Topic: ULP RISC-V calling assembly from C not working
Replies: 2
Views: 3824

ULP RISC-V calling assembly from C not working

According to the manual , the ULP-RISC-V co-processor on the esp32-s2 can be programmed with both C and assembly. I'm having trouble getting a trivial example using both C and assembly to work. My code ( on GitHub ) builds and runs, but doesn't return the correct result from a function implemented i...
by bitmandu
Mon Apr 26, 2021 10:46 pm
Forum: General Discussion
Topic: How / where to include?
Replies: 3
Views: 4127

Re: How / where to include?

I don't use VSC, so I can't help with it specifically, but maybe this is better than nothing! 1. You can import code using the CMake build system . The file CMakeLists.txt specifies the paths for all the source and header files your project needs. idf_component_register(SRCS "hello-world.c" INCLUDE_...
by bitmandu
Mon Apr 26, 2021 3:23 pm
Forum: General Discussion
Topic: ULP RISC-V temperature sensor configuration
Replies: 0
Views: 1836

ULP RISC-V temperature sensor configuration

I am trying to take periodic temperature measurements from the ULP RISC-V coprocessor on the ESP32-s2. The following code reads the on-chip temperature sensor from the ULP and is based on section 30.4.3 of the technical reference . static uint32_t read_temperature(void) { uint32_t temp, ready; SET_P...