-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsdkconfig.defaults
More file actions
76 lines (70 loc) · 4.13 KB
/
Copy pathsdkconfig.defaults
File metadata and controls
76 lines (70 loc) · 4.13 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
# Essentials for an esp-matter Wi-Fi node (mirrors esp-matter/examples/*/sdkconfig.defaults).
CONFIG_PARTITION_TABLE_CUSTOM=y
CONFIG_PARTITION_TABLE_CUSTOM_FILENAME="partitions.csv"
CONFIG_PARTITION_TABLE_OFFSET=0x8000
# 4MB flash (ESP32-D0WDQ6). The partitions.csv 4MB map (2x 1.875MB OTA slots + fctry)
# needs this; without it flash size defaults to 2MB and the partition table won't fit.
CONFIG_ESPTOOLPY_FLASHSIZE_4MB=y
CONFIG_ESPTOOLPY_FLASHSIZE="4MB"
# BLE (commissioning) + Wi-Fi (operational)
CONFIG_BT_ENABLED=y
CONFIG_BT_NIMBLE_ENABLED=y
CONFIG_ENABLE_CHIPOBLE=y
CONFIG_USE_MINIMAL_MDNS=n
# Commissioning credentials. For bring-up use esp-matter's built-in TEST providers
# (example test DAC + discriminator 3840 + passcode 20202021) -- no mfg data flash needed.
# PRODUCTION: flash per-device factory data with esp-matter-mfg-tool and flip these back on.
# CONFIG_ENABLE_ESP32_FACTORY_DATA_PROVIDER=y
# CONFIG_ENABLE_ESP32_DEVICE_INSTANCE_INFO_PROVIDER=y
# Room A/C has multiple clusters -> give the event/attr paths headroom
CONFIG_ESP_MAIN_TASK_STACK_SIZE=5120
CONFIG_FREERTOS_HZ=1000
# --- Matter operational essentials (from esp-matter examples/*/sdkconfig.defaults) ---
# CHIP crypto (SPAKE2+/HKDF) fails to LINK without HKDF in mbedtls (undefined mbedtls_hkdf).
CONFIG_MBEDTLS_HKDF_C=y
# Matter operates over IPv6: autoconf + route/nd6 hooks + one address per fabric (MAX_FABRIC+1).
CONFIG_LWIP_IPV6_AUTOCONFIG=y
CONFIG_LWIP_HOOK_IP6_ROUTE_DEFAULT=y
CONFIG_LWIP_HOOK_ND6_GET_GW_DEFAULT=y
CONFIG_LWIP_IPV6_NUM_ADDRESSES=6
# Commission over BLE only -- no Wi-Fi SoftAP.
CONFIG_ESP_WIFI_SOFTAP_SUPPORT=n
CONFIG_ENABLE_WIFI_AP=n
# We ship OTA updates to the node.
CONFIG_ENABLE_OTA_REQUESTOR=y
# Custom DeviceInfoProvider (in-RAM) so the UserLabel cluster can serve "ha_entitylabel"
# entity names without the factory-data provider (which would break test-cred commissioning).
CONFIG_CUSTOM_DEVICE_INFO_PROVIDER=y
# Matter OTA software version. Unified scheme (issue #77): the int is DERIVED from PROJECT_VER
# in CMakeLists.txt (MAJOR*10000+MINOR*100+PATCH) and injected as a compile definition that WINS
# over this Kconfig NUMBER (CHIPDeviceConfig.h #ifndef guard). The STRING is NOT overridden by CMake,
# so it (and the fallback NUMBER) MUST stay equal to PROJECT_VER or the device reports a stale
# softwareVersionString. Edit PROJECT_VER in CMakeLists.txt, then update both lines below.
# esp32-lint.sh enforces this equality (fails the commit/CI if they drift).
CONFIG_DEVICE_SOFTWARE_VERSION_NUMBER=10105
CONFIG_DEVICE_SOFTWARE_VERSION_STRING="1.1.5"
# --- OTA hardening (faster + reliable on marginal Wi-Fi) ---
# Delta OTA: ship a diff (tens of KB) instead of the full ~1.5MB image over BDX.
CONFIG_ENABLE_DELTA_OTA=y
# MRP: survive deep fades during the long BDX transfer (default MAX_RETRANS=4 too low at ~-67dBm).
CONFIG_MRP_MAX_RETRANS=8
CONFIG_MRP_LOCAL_ACTIVE_RETRY_INTERVAL_FOR_WIFI_ETHERNET=500
CONFIG_MRP_LOCAL_IDLE_RETRY_INTERVAL_FOR_WIFI_ETHERNET=800
CONFIG_MRP_RETRY_INTERVAL_SENDER_BOOST_FOR_WIFI_ETHERNET=300
# Size-optimize the image (-Os) -> fewer bytes for the one-time full OTA + flash headroom.
CONFIG_COMPILER_OPTIMIZATION_SIZE=y
# HTTPS-OTA manual backup path (plain HTTP from a local file server; LAN-only).
CONFIG_ESP_HTTPS_OTA_ALLOW_HTTP=y
# Brownout threshold (#12): level 0 (~2.43 V, the LOWEST), kept deliberately.
# The reasoning lives with the evidence trail at app_main.cpp (reset_reason_str): a
# module hung mid-OTA and had to be USB-recovered, and the suspicion is the A/C's 5 V
# rail sagging under flash-write + Wi-Fi TX peaks. Level 0 is the worst setting for
# THAT failure -- the rail can upset the flash chip or the PHY while the CPU keeps
# executing, so an OTA write HANGS the module instead of resetting it -- but raising
# the threshold is an evidence-driven decision, and the brownout reset-reason logging
# exists to collect exactly that evidence. Do not bump on a hunch: if `bootreason`
# starts reporting ESP_RST_BROWNOUT, that is the signal to raise it (and if it reports
# frequent brownouts at idle once raised, the supply needs fixing, not the threshold).
CONFIG_ESP_BROWNOUT_DET=y
CONFIG_ESP_BROWNOUT_DET_LVL_SEL_0=y
CONFIG_ESP_BROWNOUT_DET_LVL=0