Low power mode for OBD co-processor

User feedbacks of the latest ESP32 based Freematics ONE+
lauka
Posts: 5
Joined: Sun Oct 27, 2019 8:13 pm

Low power mode for OBD co-processor

Postby lauka » Sun Nov 03, 2019 7:39 am

As the OBD port power is always on, I want to have my ONE+ in low power mode when the engine is not running to save the battery.

I have managed to get the current consumption down to 14 mA. It seems that the co-processor goes in to some low power mode roughly 20 seconds after the boot, if the FreematicsESP32::begin() is not called. I have not managed to get the processor back to low power mode after calling the begin(). The only way I have found to work is to enter deep sleep mode for the ESP32. After the ESP32 wakes up the co processor also seems to reset and go to low power mode after 20 seconds.

I have tried calling the FreematicsESP32::resetLink() and manually toggling the PIN_LINK_RESET, but I can't get it to work.

stanley
Site Admin
Posts: 758
Joined: Sat Mar 01, 2014 3:15 am

Re: Low power mode for OBD co-processor

Postby stanley » Fri Nov 08, 2019 7:25 pm

If you use model A, the link between co-processor and ESP32 is SPI. After ESP32 wakes up from deep sleep, SPI might need to be re-initialized. You can try call begin() again.

lauka
Posts: 5
Joined: Sun Oct 27, 2019 8:13 pm

Re: Low power mode for OBD co-processor

Postby lauka » Sun Nov 24, 2019 10:21 pm

The issue in my case was that when the ESP32 wakes up from light sleep it somehow triggers the SPI waking up the co-processor.

Using following config for the sleep fixed the issue:
esp_sleep_pd_config(ESP_PD_DOMAIN_RTC_PERIPH, ESP_PD_OPTION_ON);
esp_sleep_pd_config(ESP_PD_DOMAIN_RTC_SLOW_MEM, ESP_PD_OPTION_OFF);
esp_sleep_pd_config(ESP_PD_DOMAIN_RTC_FAST_MEM, ESP_PD_OPTION_OFF);
esp_sleep_pd_config(ESP_PD_DOMAIN_XTAL, ESP_PD_OPTION_OFF);

The important option is ESP_PD_DOMAIN_RTC_PERIPH turned ON.

stanley
Site Admin
Posts: 758
Joined: Sat Mar 01, 2014 3:15 am

Re: Low power mode for OBD co-processor

Postby stanley » Mon Nov 25, 2019 10:39 am

Thanks for this information!


Return to “Freematics ONE+”

Who is online

Users browsing this forum: No registered users and 0 guests