# NeoPixel LED Controller Configuration

# Hardware configuration
hardware:
  num_leds: 30              # Total number of NeoPixels
  gpio_pin: 18              # GPIO pin for data line
  brightness_max: 255       # Maximum brightness (0-255)
  brightness_min: 10        # Minimum brightness for visible LEDs
  update_frequency: 30      # Update frequency in Hz

# Brightness control
brightness:
  enabled: true
  auto_dim: true            # Enable automatic brightness dimming
  day_brightness: 200       # Daytime brightness (0-255)
  night_brightness: 80      # Night-time brightness (0-255)
  dim_threshold: 50         # Light sensor threshold for dimming

# Animation settings
animation:
  transition_duration: 0.5  # Smooth transition duration in seconds
  breathing_speed: 1.5      # Breathing pattern speed (cycles/sec)
  pulse_speed: 2.0          # Pulse pattern speed (cycles/sec)
  chase_speed: 3.0          # Chase pattern speed (LEDs/sec)

# LED patterns: define colors as [R, G, B] (0-255)
patterns:
  idle:
    name: "Breathing Blue"
    color: [0, 50, 200]
    pattern: "breathing"
    speed: 1.5

  follow:
    name: "Green Pulse"
    color: [0, 200, 50]
    pattern: "pulse"
    speed: 2.0

  error:
    name: "Red Flash"
    color: [255, 0, 0]
    pattern: "flash"
    speed: 3.0

  celebrate:
    name: "Rainbow"
    color: null             # Rainbow uses spectrum
    pattern: "rainbow"
    speed: 2.0

  low_battery:
    name: "Amber Warning"
    color: [255, 165, 0]
    pattern: "pulse"
    speed: 1.5

  search:
    name: "White Chase"
    color: [255, 255, 255]
    pattern: "chase"
    speed: 3.0

# State priorities (higher value = higher priority)
state_priorities:
  error: 100
  low_battery: 50
  celebrate: 40
  follow: 30
  idle: 10

# Subscription topics
subscriptions:
  battery: "/saltybot/battery/level"
  balance: "/saltybot/balance/status"
  social: "/saltybot/social/state"
  emotion: "/saltybot/emotion/state"
  health: "/saltybot/health/status"

# Publishing topics
publications:
  led_state: "/saltybot/led_state"

# Thresholds
thresholds:
  low_battery_percent: 20   # Battery % to trigger low battery LED
  error_timeout: 2.0        # Seconds without heartbeat before error
