Search found 58 matches

by gregstewart90
Tue Dec 19, 2017 8:09 pm
Forum: General Discussion
Topic: NVS Read/Write Over Usage
Replies: 3
Views: 141

NVS Read/Write Over Usage

Is there a limit to the number of times I can write to or read from NVS? If I implement a timer with the ESP32 by updating the value total_time in NVS once a second by simply incrementing the value, will this cause problems? If there is a limitation, what are the best practices to avoid over use? vo...
by gregstewart90
Tue Oct 24, 2017 1:44 pm
Forum: General Discussion
Topic: Pause or stop bluetooth
Replies: 0
Views: 144

Pause or stop bluetooth

I'm using libssh2 to ssh into a few devices from the esp32. It works great for my application, but when I enable bluetooth, the ssh session cannot connect. I know there are [ur=https://esp32.com/viewtopic.php?f=2&t=3364&p=15863&hilit=wifi+and+bluetooth&sid=1230275b322ae4fe7bf00058ddd...
by gregstewart90
Tue Oct 24, 2017 1:35 pm
Forum: General Discussion
Topic: Somrtimes ota works well,sometimes ota will go wrong.
Replies: 7
Views: 542

Re: Somrtimes ota works well,sometimes ota will go wrong.

Is bluetooth enabled? I had to disable bluetooth to make OTA work successfully. WIFI and bluetooth can exist at the same time, but it can cause issues.
by gregstewart90
Thu Oct 12, 2017 10:50 pm
Forum: General Discussion
Topic: How to recover from I2C failure?
Replies: 2
Views: 247

Re: How to recover from I2C failure?

THANK YOU THANK YOU! #include "driver/periph_ctrl.h" void reset_i2c(void){ i2c_reset_tx_fifo(I2C_N); i2c_reset_rx_fifo(I2C_N); periph_module_disable(PERIPH_I2C0_MODULE); periph_module_enable(PERIPH_I2C0_MODULE); i2c_driver_delete(I2C_N); init_I2C(); } This worked perfectly for me without a...
by gregstewart90
Thu Oct 12, 2017 4:21 pm
Forum: General Discussion
Topic: How to recover from I2C failure?
Replies: 2
Views: 247

How to recover from I2C failure?

I'm using a MCP23017 port expander which uses i2c. Occasionally I get a problem on the lines and the timeout is reached. This throws an error that I read. I simply reset the esp32 and then it starts working again. I've upgraded my IDF to the latest version, and now the reset no longer works. When it...
by gregstewart90
Tue Oct 10, 2017 3:47 pm
Forum: General Discussion
Topic: Reset I2C
Replies: 8
Views: 1516

Re: Reset I2C

I haven't checked for the slowing clock speed, but I got mine to work with the following code. It's nothing perfect, but I don't miss anything. Occasionally I still get stuck on the i2c line, but I just monitor that and reset as necessary. void initI2C() { i2c_config_t conf; conf.mode = I2C_MODE_MAS...
by gregstewart90
Wed Sep 13, 2017 1:48 pm
Forum: General Discussion
Topic: Storing Logs
Replies: 11
Views: 1002

Re: Storing Logs

If you can pack two int32 variables into an int64 and store that instead of a blob, that will be twice as efficient. I definitely can pack them together. Should I make an array of the log entries and save that to the blob or should I try to rename each entry? BlobLog blob_logs[]; ... nvs_set_blob(m...
by gregstewart90
Wed Sep 13, 2017 1:27 pm
Forum: General Discussion
Topic: Storing Logs
Replies: 11
Views: 1002

Re: Storing Logs

So I see my two options are to keep doing everything in nvs storage or take a big risk with the partition tables. I'll have a new run of boards soon that I can flash with a different partition table. Is there anything wrong with using the blob? My current plan uses a struct with two int32_t variable...
by gregstewart90
Tue Sep 12, 2017 10:58 pm
Forum: General Discussion
Topic: Storing Logs
Replies: 11
Views: 1002

Re: Storing Logs

(bump)
by gregstewart90
Mon Sep 04, 2017 3:36 pm
Forum: General Discussion
Topic: Panic Handler Constantly Resetting
Replies: 3
Views: 414

Re: Panic Handler Constantly Resetting

Thanks for the advice. I went to version 2.1, and that seems to have resolved the issue. It's difficult to reproduce.