Search found 14 matches

by cbaurtx
Thu Apr 04, 2024 8:13 pm
Forum: ESP-IDF
Topic: Bug in header file ulp_riscv_gpio.h
Replies: 4
Views: 1572

Re: Bug in header file ulp_riscv_gpio.h (solved)

I was a complete fool, yes the code is not identical and it does work as intended.
by cbaurtx
Mon Apr 01, 2024 11:20 am
Forum: ESP-IDF
Topic: Bug in header file ulp_riscv_gpio.h
Replies: 4
Views: 1572

Bug in header file ulp_riscv_gpio.h

static inline void ulp_riscv_gpio_output_level(gpio_num_t gpio_num, uint8_t level) { if (level) { REG_SET_FIELD(RTC_GPIO_OUT_W1TS_REG, RTC_GPIO_OUT_DATA_W1TS, BIT(gpio_num)); } else { REG_SET_FIELD(RTC_GPIO_OUT_W1TC_REG, RTC_GPIO_OUT_DATA_W1TS, BIT(gpio_num)); } } Code for if(level) and else is ide...
by cbaurtx
Fri Mar 01, 2024 6:53 pm
Forum: ESP-IDF
Topic: [solved] Setting RTC register bits fails (ESP32-S3)
Replies: 5
Views: 1275

Re: Setting RTC register bits fails (ESP32-S3)

Finally I got it working and I blame poor documentation for my problem. Looking how the RiskV ULP initializes the rtc i2c I found this: /* For esp32s3, we need to enable the rtc_i2c clock gate before accessing rtc i2c registers */ SET_PERI_REG_MASK(SENS_SAR_PERI_CLK_GATE_CONF_REG, SENS_RTC_I2C_CLK_E...
by cbaurtx
Fri Mar 01, 2024 4:55 pm
Forum: IDEs for ESP-IDF
Topic: Best IDE for Linux - Eclipse or Visual Studio?
Replies: 4
Views: 4968

Re: Best IDE for Linux - Eclipse or Visual Studio?

Use neither as both are bloated. I use geany which works nicely.
If you want I post the Geany configuration I use.
by cbaurtx
Tue Feb 27, 2024 10:13 pm
Forum: ESP-IDF
Topic: [solved] Setting RTC register bits fails (ESP32-S3)
Replies: 5
Views: 1275

[solved] Re: Setting RTC register bits fails (ESP32-S3)

#include <stdio.h> #include <stdlib.h> #include <string.h> #include "freertos/FreeRTOS.h" #include "freertos/task.h" #define TAG "test_write_rtc_reg.c" #if ESP_IDF_VERSION_MAJOR < 5 #include "driver/rtc_cntl.h" #else #include "esp_private/rtc_ctrl.h" #endif #include "driver/rtc_io.h" #include "soc/...
by cbaurtx
Mon Feb 19, 2024 10:13 pm
Forum: ESP-IDF
Topic: [solved] Setting RTC register bits fails (ESP32-S3)
Replies: 5
Views: 1275

Re: Setting RTC register bits fails (ESP32-S3)

Thank you for answering that quickly. What you said makes a lot of sense, however I can
use the RTC GPIO without any problems. How can I turn the RTC power domain on or off to
double check?
by cbaurtx
Sat Feb 17, 2024 1:17 pm
Forum: ESP-IDF
Topic: [solved] Setting RTC register bits fails (ESP32-S3)
Replies: 5
Views: 1275

[solved] Setting RTC register bits fails (ESP32-S3)

I want to initialize the RTC I2C controller using the main processor of the ESP32-S3 As en example setting RTC_I2C_SCL_LOW_REG SET_PERI_REG_BITS(RTC_I2C_SCL_LOW_REG, RTC_I2C_SCL_LOW_PERIOD_REG, 40, RTC_I2C_SCL_LOW_PERIOD_REG_S); // SCL low/high period = 40, which result driving SCL with 100kHz. ESP_...
by cbaurtx
Thu Apr 15, 2021 4:30 pm
Forum: ESP-IDF
Topic: ESP32 custom component with ULP code link failure
Replies: 1
Views: 1902

Re: ESP32 custom component with ULP code link failure

i was able to fix that myself.
The working code is here:
https://github.com/cbaurtx/ESP32_keypad_rotdecode
by cbaurtx
Sat Apr 10, 2021 6:51 pm
Forum: ESP-IDF
Topic: ESP32 custom component with ULP: Link failure
Replies: 1
Views: 2054

Re: ESP32 custom component with ULP: Link failure

I did some digging...
It seems that the command ulp_embed_binary creates executables only. So no code for libraries :cry:
by cbaurtx
Sat Apr 10, 2021 3:57 pm
Forum: ESP-IDF
Topic: How to add folder in project with some separate code
Replies: 3
Views: 3401

Re: How to add folder in project with some separate code

That was the wrong example (ULP and not a custom component)
So here you go....