Incremental counter from 1 pin

Using the “Pulse Count Controller” (PCNT) CMakeLists.txt REQUIRES Ensure the following is added to the REQUIRES section of your CMakeLists.txt file in the \main folder: Configuring Reading value More useful version

Read More

Shelly devices

There’s a whole range of really cool Shelly modules for use in the home, here’s a Knowledgebase https://kb.shelly.cloud/knowledge-base/ UK store https://shellystore.co.uk/

Read More

Light sleep

In light sleep mode, digital peripherals, most of the RAM, and CPUs are clock-gated, and supply voltage is reduced. Upon exit from light sleep, peripherals and CPUs resume operation, their internal state is preserved. Documentation https://docs.espressif.com/projects/esp-idf/en/v4.4.5/esp32c3/api-reference/system/sleep_modes.html Example light sleep function Used with ESP32 C3

Read More

Crashing issues

Documentation https://docs.espressif.com/projects/esp-idf/en/latest/esp32/api-guides/fatal-errors.html Settings you can utilise Panic handler behaviour (CONFIG_ESP_SYSTEM_PANIC configuration) What happens when a fatal issue occurs and what is output can be changed, including having the CPU halt if you wish: menuconfig > Component config > ESP System Settings > Panic handler behaviour

Read More

.6 Releasing a project

ESP32 release config Check the ESP32 settings as detailed on this page menuconfig particular settings to check: Panic handler behaviour (CONFIG_ESP_SYSTEM_PANIC configuration) What happens when a fatal issue occurs and the CPU has to halt.Component config > ESP System Settings > Panic handler behaviour = Print registers and reboot Releasing files and setup for production […]

Read More

File access issues

fgets() does not handle 0x0d only Macintosh formatted text files In our use of fgets() (2023-11) using fgets with the esp-idf failed with mac formatted text files. The missing 0x0a LF character meant it did not detect the end of each line.

Read More