Search found 566 matches

by boarchuz
Sun Feb 07, 2021 5:57 pm
Forum: ESP-IDF
Topic: MAX44009 two I2C reads without a stop in between
Replies: 6
Views: 4214

Re: MAX44009 two I2C reads without a stop in between

static esp_err_t read_max44009(i2c_port_t i2c_num, uint8_t *byte_low, uint8_t* byte_high) { i2c_cmd_handle_t cmd = i2c_cmd_link_create(); i2c_master_start(cmd); i2c_master_write_byte(cmd, (MAX44009_ADDRESS << 1) | I2C_MASTER_WRITE, 1); i2c_master_write_byte(cmd, 0x03, 1); i2c_master_start(cmd); i2c...
by boarchuz
Sun Feb 07, 2021 4:07 am
Forum: ESP-IDF
Topic: MAX44009 two I2C reads without a stop in between
Replies: 6
Views: 4214

Re: MAX44009 two I2C reads without a stop in between

The IDF I2C example has a function showing how to set up a standard multi-byte read like this:
https://github.com/espressif/esp-idf/bl ... .c#L62-L78
by boarchuz
Wed Feb 03, 2021 7:05 am
Forum: ESP-IDF
Topic: esp_http_client_read corrupts and offsets in stream
Replies: 4
Views: 3285

Re: esp_http_client_read corrupts and offsets in stream

Sorry rfleming, I was a bit quick on that. Yes I think the issue is that the default internal read buffer is 512 (DEFAULT_HTTP_BUF_SIZE) and the _perform() api will read right through the response. So the internal buffer will have only the tail end of the response when you _read() from it. I'm not s...
by boarchuz
Wed Feb 03, 2021 12:36 am
Forum: ESP-IDF
Topic: esp_http_client_read corrupts and offsets in stream
Replies: 4
Views: 3285

Re: esp_http_client_read corrupts and offsets in stream

You read into buffer "data" then dump uninitialised buffer "tmp"
by boarchuz
Tue Feb 02, 2021 3:40 pm
Forum: ESP-IDF
Topic: Light Sleep GPIO Workaround Unnecessary?
Replies: 0
Views: 1749

Light Sleep GPIO Workaround Unnecessary?

Recent changes in IDF [0] allow significantly lower light sleep current. Testing this today, I found some interesting behaviour I don't quite understand. The TL;DR is that this is a great improvement (825uA -> 375uA) but it seems it can be achieved much more easily by resetting a small number of off...
by boarchuz
Thu Jan 28, 2021 1:31 am
Forum: ESP-IDF
Topic: Touch pad wake up from deep sleep only works once if Brownout detector is turned off
Replies: 2
Views: 3901

Re: Touch pad wake up from deep sleep only works once if Brownout detector is turned off

Isn't it likely that you still have power supply problems? That could cause odd behaviour with touch sensors, but you won't know about it now with brownout detection disabled. If you have a reliable reproduction for the brownout reset issue you should reply to @igrr: https://github.com/adafruit/circ...
by boarchuz
Thu Jan 28, 2021 12:52 am
Forum: General Discussion
Topic: doubt with memory when using esp_http_client
Replies: 1
Views: 2539

Re: doubt with memory when using esp_http_client

Don't dwell on it, there's no leak if there's not a consistent pattern of reduction. See this post: https://esp32.com/viewtopic.php?t=14056#p55646 And also consider that there are other tasks doing work behind the scenes - especially WiFi/lwip in this case, which will be dynamically allocating/deall...
by boarchuz
Tue Jan 26, 2021 11:26 pm
Forum: ESP-IDF
Topic: how to disable server validation (CA)
Replies: 3
Views: 10997

Re: skip server validation seems not to work

skip_cert_common_name_check will not allow you to bypass TLS, it will only avoid checking the certificate's CN (so a possible mismatch would not fail validation). To completely disable the certificate check, you will need to go to ESP-TLS in menuconfig, enable "Allow potentially insecure options" an...