Search found 8 matches

by chofsass
Thu Nov 19, 2020 2:39 pm
Forum: ESP-IDF
Topic: BLE iBeacon example uses +100k of DRAM
Replies: 0
Views: 2121

BLE iBeacon example uses +100k of DRAM

I am using the ibeacon example found in the IDF repo here: https://github.com/espressif/esp-idf/blob/357a2776032299b8bc4044900a8f1d6950d7ce89/examples/bluetooth/bluedroid/ble/ble_ibeacon/main/ibeacon_demo.c If you look at the code you can see that it is using the esp_bt_controller_mem_release(ESP_BT...
by chofsass
Thu Nov 05, 2020 3:27 pm
Forum: ESP-IDF
Topic: It would appear that the ADC configuration is driving the pin high
Replies: 0
Views: 1337

It would appear that the ADC configuration is driving the pin high

I'm trying to use the ADC to sample the voltage on GPIO_26. It would appear that the ADC configuration is driving the pin high. I have tested this electrically (when the GPIO_26 is configured as an ADC input the pin is driven high to 3.3V and if it is not configure as a ADC input it is 2.2V which is...
by chofsass
Fri May 01, 2020 11:43 pm
Forum: General Discussion
Topic: Dual Core Synchronization
Replies: 10
Views: 10085

Re: Dual Core Synchronization

could Arduino's Wire library not be multi core safe for some reason?
by chofsass
Fri May 01, 2020 11:35 pm
Forum: General Discussion
Topic: Dual Core Synchronization
Replies: 10
Views: 10085

Re: Dual Core Synchronization

The class implements scope guard (RAII) pattern so the lock is acquired when the constructor is called and released when the destructor is called. If you look in the code you can see that I am caching the error in a map _failures[_tag]++; for reporting later. So, I think I have a pretty good lead on...
by chofsass
Fri May 01, 2020 7:27 pm
Forum: General Discussion
Topic: Dual Core Synchronization
Replies: 10
Views: 10085

Re: Dual Core Synchronization

#include "STI2c.h" #include "SMCommon.h" #include "Wire.h" #define TRACKER() printf("[I2C TRACKER] %u\n", __LINE__); std::map<uint8_t, std::string> I2cErrorNameLookup = { { i2c_err_t::I2C_ERROR_OK, "I2C_ERROR_OK" }, { i2c_err_t::I2C_ERROR_DEV, "I2C_ERROR_DEV" }, { i2c_err_t::I2C_ERROR_ADDR_NACK, "I...
by chofsass
Fri May 01, 2020 3:20 pm
Forum: General Discussion
Topic: Dual Core Synchronization
Replies: 10
Views: 10085

Re: Dual Core Synchronization

Okay, what is your question? Also, it may help if you post your source code and are more precise than 'lots of errors'. Sorry let me be more clear. So, I am using the I2C bus on one core (CORE_0) across multiple task on the same core. I am using the xSemaphoreCreateMutex() function provided by free...
by chofsass
Thu Apr 30, 2020 7:49 pm
Forum: General Discussion
Topic: Dual Core Synchronization
Replies: 10
Views: 10085

Dual Core Synchronization

I have multiple tasks on the same core accessing the I2C bus using a freeRTOS mutex for synchronization an that is working. But once I try to use the I2C bus from a task on a different core I get a lot of errors. I am guessing this is a synchronization issue but I'm not sure. I have tried to use a c...
by chofsass
Mon Apr 06, 2020 3:47 pm
Forum: ESP-IDF
Topic: Power Management - Automatic Light Sleep - Issues
Replies: 1
Views: 2984

Power Management - Automatic Light Sleep - Issues

Hi, I am using esp-idf v3.3.1. I have setup automatic light sleep and I have 2 issues. The first issue is that the tick counter is shifting by about 10 milliseconds of a one second period. The second is that the printf() function which is using the UART doesn't appear to be sleep safe (the UART is d...