nordic,nrf-lpcomp

Vendor: Nordic Semiconductor

Note

An implementation of a driver matching this compatible is available in drivers/comparator/comparator_nrf_lpcomp.c.

Description

Nordic nRF LPCOMP (analog Low-Power COMParator)

The following example displays the minimum node layout:

  comp: comp@deadbeef {
          compatible = "nordic,nrf-lpcomp";
          reg = <0xdeadbeef 0x1000>;
          interrupts = <0 NRF_DEFAULT_IRQ_PRIORITY>;
          status = "disabled";
  };

Enabling the comparator node requires setting the default
configuration of the comparator.

The following example displays enabling the comparator
using an internal reference:

  &comp {
          status = "okay";
          psel = <NRF_COMP_AIN0>;
          refsel = "VDD_4_8";
          enable-hyst;
  };

To select an external reference, select the "AREF"
reference and add the external reference:

  &comp {
          ...
          refsel = "AREF";
          extrefsel = <NRF_COMP_AIN1>;
          ...
  };

Properties

Properties not inherited from the base binding file.

Name

Type

Details

psel

int

extrefsel

int

refsel

string

Legal values: 'VDD_1_8', 'VDD_2_8', 'VDD_3_8', 'VDD_4_8', 'VDD_5_8', 'VDD_6_8', 'VDD_7_8', 'VDD_1_16', 'VDD_3_16', 'VDD_5_16', 'VDD_7_16', 'VDD_9_16', 'VDD_11_16', 'VDD_13_16', 'VDD_15_16', 'AREF'

enable-hyst

boolean