mainmenu "Lemon totem"

config LEMON_SERVER_DEFAULT
	string "Default relay server (host or dotted IP)"
	default "10.64.0.1"
	help
	  Compiled-in fallback for g_cfg.server before the fixture provisions the unit (or after a
	  factory reset). The fixture overwrites this via "factory provision" / "lemon server", which
	  is what actually ships on production units -- this default only matters for a bench build
	  that never runs provisioning.

config LEMON_BACK_WINDOW_S
	int "Squeeze-back window (s)"
	default 60
	help
	  How long after a felt hug (or after noticing a missed one) a squeeze counts as HUG_BACK
	  ("they felt it") instead of a new HUG. Rev B spec: 60 s.

config LEMON_NOTICE_WINDOW_S
	int "Time before an un-noticed hug starts the missed-hug LED (s)"
	default 120

config LEMON_MISSED_MAX_H
	int "Give up breathing the missed-hug LED after (h)"
	default 24
	help
	  Matches lemon_net.h's MSG_SEEN arg (minutes, capped at 0xffff = ~45 days) -- 24 h is the
	  product default so the LED does not glow forever on a lemon left alone.

config LEMON_LED_MAX_PERMILLE
	int "Missed-hug LED peak brightness (permille of max)"
	default 350
	range 0 1000
	help
	  Caps the swell in led.c's pwm-leds path (dimmed breathe). Not used on the gpio-leds
	  fallback path, which is plain on/off. Tune once real hardware and the acrylic light pipe
	  are in hand -- HW-VERIFY.

config LEMON_DEV_SHELL
	bool "Development shell (lemon ... commands)"
	default y
	help
	  Compiles in lemon_shell.c's "lemon" command tree (status/server/test/hug/back/breathe/
	  arm/fota) for bench and prototype builds. Per COMPLIANCE.md/EN 18031 this must be turned
	  off for production images -- see overlay-prod.conf. Provisioning does not need this shell;
	  it uses the separate "factory" command tree (LEMON_FACTORY_SHELL), which stays compiled in.

config LEMON_FACTORY_SHELL
	bool "Factory test/provisioning shell (factory ... commands)"
	default y
	help
	  Compiles in factory.c's "factory" command tree used by firmware/tools/fixture.py at the
	  production jig. Stays enabled even in overlay-prod.conf: it is what performs provisioning
	  and "factory lock", and it is only reachable over the pogo-pad UART before lemon_console_off()
	  runs (g_cfg.locked) and before APPROTECT is engaged on the SWD port -- disabling this Kconfig
	  would make units impossible to provision on the line.

config LEMON_FACTORY_VIB_MIN_MG
	int "Factory LRA vibration pass threshold (mg)"
	default 50
	help
	  Minimum accelerometer-measured vibration (in mg, see factory.c cmd_lra) during the heartbeat
	  pattern for a unit to pass the fixture's "is the LRA actually glued to the shell" check.
	  Placeholder -- set from the first prototype batch's measured numbers.

config LEMON_FOTA_PORT
	int "Relay's plain-HTTP FOTA port"
	default 8080
	help
	  Must match [fota] port in backend/relay.toml. Separate from the UDP relay port (5683):
	  fota_download() speaks plain HTTP inside the 1NCE private network, not the app protocol.

config LEMON_FOTA_CONFIRM_MIN
	int "Minutes to wait for a server-acked HELLO before MCUboot reverts"
	default 10
	help
	  fota.c schedules a revert_work at boot if the running image is not yet mcuboot-confirmed.
	  main.c calls lemon_fota_confirm() once the first HELLO after boot is acked by the relay,
	  which cancels it. If attach or the relay is unreachable for longer than this, MCUboot swaps
	  back to the previous (known-good) image on the next boot.

source "Kconfig.zephyr"
