Search found 10 matches

by kb3523
Sat Mar 21, 2020 9:06 pm
Forum: ESP-IDF
Topic: I2C - Using both Ports - First Transaction fails
Replies: 2
Views: 3890

Re: I2C - Using both Ports - First Transaction fails

Lol. This is so obvious, I dont know how I could not notice this.. :D
Maybe I should stop working for today :) Thank you, please consider thes topic closed. Is there an option to close the topic with the resolution: "Used did not have eyes to read his own code, others had.." ;)
by kb3523
Sat Mar 21, 2020 4:15 pm
Forum: ESP-IDF
Topic: I2C - Using both Ports - First Transaction fails
Replies: 2
Views: 3890

I2C - Using both Ports - First Transaction fails

Dear ESP community, If the i2c driver is 'installed twice', the first transaction of the first initialized port fails. Afterwards the communication happens without any error on both ports. Am I initializing both ports correctly? Is there anything else I could consider? My current ESP-IDF Version is:...
by kb3523
Sun May 06, 2018 3:53 pm
Forum: General Discussion
Topic: ESP32 shutdown without external circuits?
Replies: 8
Views: 24031

Re: ESP32 shutdown without external circuits?

Thank you very much for the replies. The purpose of "shutting the device down" is to prevent it from draining the lion cell powering it below 2.9V and to make sure that the brown out detection wont get triggered which could put the device in a reset loop.
by kb3523
Sun May 06, 2018 7:35 am
Forum: General Discussion
Topic: ESP32 shutdown without external circuits?
Replies: 8
Views: 24031

ESP32 shutdown without external circuits?

Dear All,
is it possible to shut down the ESP32 programatically without using external circuits?
Thank you!
by kb3523
Sat Mar 24, 2018 9:40 am
Forum: General Discussion
Topic: Trigger an action every "exact" second after syncing with NTP Server
Replies: 5
Views: 12722

Re: Trigger a Function every "exact" second after syncing with NTP Server.

Hello everyone, I’m still looking for a better approach on how to get an action happen every second the sntp synced internal clock ticks.. I would really like to know how someone with experience in programming would try to solve this. I read everything what could have something to do with this.. SNT...
by kb3523
Sat Mar 17, 2018 8:38 am
Forum: General Discussion
Topic: Trigger an action every "exact" second after syncing with NTP Server
Replies: 5
Views: 12722

Re: Sync with NTP and trigger an interrupt every second the clock ticks

Thank you for your hint @thethinker! Is SNTP_GET_SYSTEM_TIME under the surface the same as calling gettimeofday()? #define SNTP_GET_SYSTEM_TIME(sec, us) \ do { \ struct timeval tv = { .tv_sec = 0, .tv_usec = 0 }; \ gettimeofday(&tv, NULL); \ (sec) = tv.tv_sec; \ (us) = tv.tv_usec; \ } while (0); I c...
by kb3523
Mon Mar 12, 2018 9:32 am
Forum: General Discussion
Topic: Trigger an action every "exact" second after syncing with NTP Server
Replies: 5
Views: 12722

Trigger an action every "exact" second after syncing with NTP Server

Dear Guys and Girls, /* you can also fast forward to my last post ;) */ How would you accomplish the above mentioned Task? (Using ESP-IDF) I'm thinking of something similar: 1 Sync Time with NTP Service from a server and set the local clock in the ESP32 (this is well documented and working) 2 Read c...
by kb3523
Fri Mar 09, 2018 9:27 pm
Forum: General Discussion
Topic: How to get two HS LEDC channels fading in two "parallel" Tasks?
Replies: 2
Views: 5045

Re: How to get two HS LEDC channels fading in two "parallel" Tasks?

Sorry :) I was too noob to initialize an array of structs correctly.. False: ledc_channel_config_t ledc_channel[2]; . . . ledc_channel_config_t ledc_channel[2] = { { .channel = LEDC_CHANNEL_0, .duty = 0, . . Right: ledc_channel_config_t ledc_channel[2]; . . . ledc_channel[0].channel = LEDC_CHANNEL_0...
by kb3523
Fri Mar 09, 2018 10:38 am
Forum: General Discussion
Topic: How to get two HS LEDC channels fading in two "parallel" Tasks?
Replies: 2
Views: 5045

Re: How to get two HS LEDC channels fading in two "parallel" Tasks?

I forget to mention, that with this code was successfully fading both outputs: #include <stdio.h> #include "freertos/FreeRTOS.h" #include "freertos/task.h" #include "driver/ledc.h" #include "esp_err.h" #define LEDC_HS_CH0_GPIO (GPIO_NUM_21) #define LEDC_HS_CH1_GPIO (GPIO_NUM_22) #define LEDC_DUTY (4...
by kb3523
Thu Mar 08, 2018 11:54 pm
Forum: General Discussion
Topic: How to get two HS LEDC channels fading in two "parallel" Tasks?
Replies: 2
Views: 5045

How to get two HS LEDC channels fading in two "parallel" Tasks?

Dear ESP Communitiy, I can't get this working - what am I missing? Also tried using two different Timers for this. Both tasks are running as far as I can tell, but the second output stays shut. I tried at first fading led1 and as it finishes fading led2 without using tasks with the same configuratio...