{
  "metadata": {
    "id": "adafruit-as7341-breakout",
    "name": "Adafruit AS7341 10-Channel Light / Color Sensor Breakout - STEMMA QT / Qwiic",
    "type": "sensor",
    "description": "Adafruit breakout board for the AS7341 10-channel light / color sensor, with STEMMA QT / Qwiic connectors, onboard 3–5V to 1.8V regulation, level-shifted I2C pullups, and exposed INT and GPIO pins.",
    "manufacturer": "Adafruit",
    "part_number": "4698",
    "datasheet_url": "https://look.ams-osram.com/m/24266a3e584de4db/original/AS7341-DS000504.pdf",
    "tags": [
      "as7341",
      "spectral",
      "color",
      "light",
      "flicker",
      "i2c",
      "0x39",
      "stemmaqt",
      "qwiic",
      "jst-sh",
      "breakout",
      "adafruit"
    ],
    "schema_version": "1.4.0",
    "version": "1.1",
    "taxonomy": [
      "sensor.color",
      "expansion.breakout"
    ]
  },
  "domains": [
    {
      "domain": "electrical",
      "power_domains": [
        {
          "id": "vin_3to5",
          "name": "VIN (3–5 V)",
          "nominal_voltage_V": 3.3,
          "voltage_range_V": [
            3,
            5
          ],
          "isolation_type": "non_isolated",
          "ground_reference": "common",
          "description": "Board input feeding onboard regulator (sensor runs at 1.8V) and level-shifted I2C."
        }
      ],
      "resources": [
        {
          "id": "vin",
          "name": "VIN",
          "description": "3–5V power input (onboard regulator to 1.8V for the AS7341).",
          "functions": [
            {
              "name": "power_in",
              "signal_class": "power"
            }
          ],
          "connector_type": "pin_header",
          "power_domain_id": "vin_3to5"
        },
        {
          "id": "gnd",
          "name": "GND",
          "description": "Common ground for power and logic.",
          "functions": [
            {
              "name": "ground",
              "signal_class": "ground"
            }
          ],
          "connector_type": "pin_header",
          "power_domain_id": "vin_3to5"
        },
        {
          "id": "scl",
          "name": "SCL",
          "description": "I2C clock. Level shifted for 3–5V logic with 10K pullup on-board.",
          "functions": [
            {
              "name": "i2c_scl",
              "signal_class": "clock"
            }
          ],
          "connector_type": "pin_header",
          "power_domain_id": "vin_3to5",
          "has_internal_pullup": true,
          "recommended_pullup_res_kΩ": 10
        },
        {
          "id": "sda",
          "name": "SDA",
          "description": "I2C data. Level shifted for 3–5V logic with 10K pullup on-board.",
          "functions": [
            {
              "name": "i2c_sda",
              "signal_class": "data"
            }
          ],
          "connector_type": "pin_header",
          "power_domain_id": "vin_3to5",
          "has_internal_pullup": true,
          "recommended_pullup_res_kΩ": 10
        },
        {
          "id": "i2c_header",
          "name": "I2C Header",
          "description": "Grouped 0.1 in breakout header carrying VIN, GND, SDA, and SCL.",
          "functions": [
            {
              "name": "power_in",
              "signal_class": "power",
              "shareable_with": [
                "ground",
                "i2c_sda",
                "i2c_scl"
              ]
            },
            {
              "name": "ground",
              "signal_class": "ground",
              "shareable_with": [
                "power_in",
                "i2c_sda",
                "i2c_scl"
              ]
            },
            {
              "name": "i2c_sda",
              "signal_class": "data",
              "shareable_with": [
                "power_in",
                "ground",
                "i2c_scl"
              ]
            },
            {
              "name": "i2c_scl",
              "signal_class": "clock",
              "shareable_with": [
                "power_in",
                "ground",
                "i2c_sda"
              ]
            }
          ],
          "connector_type": "pin_header",
          "power_domain_id": "vin_3to5",
          "notes": "Grouped representation of the breakout's main VIN/GND/SDA/SCL header pins."
        },
        {
          "id": "int",
          "name": "INT",
          "description": "Interrupt output; can be configured to pull low on events such as new measurement data ready.",
          "functions": [
            {
              "name": "interrupt",
              "signal_class": "data"
            }
          ],
          "connector_type": "pin_header",
          "power_domain_id": "vin_3to5"
        },
        {
          "id": "gpio",
          "name": "GPIO",
          "description": "GPIO pin; can be used as an input/output and to trigger measurements (per AS7341 usage).",
          "functions": [
            {
              "name": "digital_io",
              "signal_class": "data"
            }
          ],
          "connector_type": "pin_header",
          "power_domain_id": "vin_3to5"
        },
        {
          "id": "stemmaqt_input",
          "name": "STEMMA QT Input",
          "description": "Input-side JST-SH STEMMA QT / Qwiic connector carrying VIN, GND, SDA, and SCL.",
          "functions": [
            {
              "name": "control_port",
              "direction": "bidirectional",
              "description": "Bundled 4-wire STEMMA QT / Qwiic port."
            }
          ],
          "connector_type": "jst-sh",
          "power_domain_id": "vin_3to5"
        },
        {
          "id": "stemmaqt_output",
          "name": "STEMMA QT Output",
          "description": "Output/pass-through JST-SH STEMMA QT / Qwiic connector carrying VIN, GND, SDA, and SCL.",
          "functions": [
            {
              "name": "control_port",
              "direction": "bidirectional",
              "description": "Bundled 4-wire STEMMA QT / Qwiic port."
            }
          ],
          "connector_type": "jst-sh",
          "power_domain_id": "vin_3to5"
        }
      ],
      "interfaces": [
        {
          "id": "pin_header_i2c",
          "name": "Pin Header I2C",
          "protocol": {
            "type": "i2c",
            "role": "target"
          },
          "requires": [
            {
              "function": "power_in",
              "count": 1
            },
            {
              "function": "ground",
              "count": 1
            },
            {
              "function": "i2c_sda",
              "count": 1,
              "shareable_with": [
                "i2c_scl"
              ]
            },
            {
              "function": "i2c_scl",
              "count": 1,
              "shareable_with": [
                "i2c_sda"
              ]
            }
          ],
          "constraints": {
            "requires_connector_type": "pin_header"
          },
          "timing": {
            "max_i2c_freq_hz": 400000
          },
          "description": "I2C plus VIN/GND exposed on the breakout's main header pins. 7-bit address 0x39; board includes level shifting and pullups."
        },
        {
          "id": "stemmaqt_connector",
          "name": "STEMMA QT / Qwiic Connector",
          "protocol": {
            "type": "custom",
            "role": "peer"
          },
          "requires": [
            {
              "function": "control_port",
              "count": 1
            }
          ],
          "constraints": {
            "requires_connector_type": "jst-sh"
          },
          "description": "Bundled STEMMA QT / Qwiic connector interface. Each port carries VIN, GND, SDA, and SCL; either the input or output connector can be used for a cable connection."
        },
        {
          "id": "int_out",
          "name": "Interrupt output",
          "protocol": {
            "type": "gpio_interrupt",
            "role": "source"
          },
          "requires": [
            {
              "function": "interrupt",
              "count": 1
            }
          ],
          "description": "INT pin output from the breakout for data-ready and threshold events."
        },
        {
          "id": "gpio_signal",
          "name": "GPIO signal",
          "protocol": {
            "type": "gpio",
            "role": "peer"
          },
          "requires": [
            {
              "function": "digital_io",
              "count": 1
            }
          ],
          "description": "Auxiliary GPIO exposed on the breakout header; can be used for trigger and general digital signaling."
        }
      ],
      "supply_voltage_V": [
        3,
        5
      ],
      "pin_count": 14,
      "metadata": {
        "i2c_address_7bit": "0x39",
        "i2c_pullups_present": true,
        "spectral_range_nm": [
          350,
          1000
        ],
        "adc_resolution_bits": 16,
        "adc_channel_count": 6,
        "smux_present": true,
        "sensor_channels": {
          "visible_band_centers_nm": [
            415,
            445,
            480,
            515,
            555,
            590,
            630,
            680
          ],
          "clear_channel": true,
          "nir_channel": true,
          "flicker_channel": true,
          "readable_channel_count": 11,
          "light_channel_count": 10
        }
      }
    },
    {
      "domain": "mechanical",
      "package_type": "PCB Module",
      "dimensions_mm": {
        "length": 25.4,
        "width": 17.8
      },
      "resources": [],
      "interfaces": []
    }
  ],
  "design_rules": [
    "Power VIN from 3–5V to match the logic level of your microcontroller; onboard regulator converts down to 1.8V for the sensor.",
    "The AS7341 uses an internal SMUX to route 10 light channels plus the flicker path through a 16-bit 6-channel ADC; use the Adafruit libraries unless you intend to manage channel sequencing yourself.",
    "The I2C address is fixed at 0x39, so multiple AS7341 breakouts on the same bus require an I2C mux or separate buses.",
    "Keep the optical aperture unobstructed and avoid stray enclosure reflections if you need repeatable spectral readings.",
    "If multiple I2C devices with pullups share the same bus, check the effective pullup resistance and bus capacitance.",
    "I2C bus speed up to 400 kHz per AS7341 timing characteristics."
  ],
  "usage_notes": "This breakout is best treated as a compact multispectral/color module rather than a simple lux sensor. The AS7341 measures eight visible bands plus clear, near-IR, and flicker information, but not all channels are sampled simultaneously; the device uses a Super MUX (SMUX) to route sensor elements into a 16-bit 6-channel ADC. In practice, the Adafruit Arduino and CircuitPython drivers are the easiest way to sequence channels, set gain and integration timing, and read calibrated channel groups over I2C.",
  "application_examples": [
    "Color matching and material sorting based on relative spectral content.",
    "Ambient light and illumination spectrum logging in robotics or embedded systems.",
    "LED, lamp, and display backlight comparison using visible-band plus flicker data.",
    "Fluid, reagent, or filter comparison where repeatable relative spectral signatures matter more than full laboratory spectrometry."
  ],
  "compatibility_notes": "The board is intended for 3.3V and 5V hosts over I2C through either the breakout header or either STEMMA QT / Qwiic connector. Adafruit provides both Arduino and CircuitPython drivers, and the Python library can be used on Linux hosts such as Raspberry Pi via Blinka. Because the address is fixed at 0x39, multiple identical boards on one bus require bus segmentation or an I2C multiplexer.",
  "warnings": [
    "INT is configured to pull low when conditions are met; ensure your firmware config matches your intended interrupt behavior.",
    "Only SDA and SCL are documented by Adafruit as level shifted for 3–5V hosts; verify INT and GPIO voltage compatibility before connecting them to 5V-only logic.",
    "Board has onboard I2C pullups (10K) and level shifting; account for this when mixing devices on the same I2C bus.",
    "The fixed 0x39 I2C address can collide with another AS7341 breakout or any other device that also occupies 0x39."
  ]
}