The Dialog DA9063 PMIC provides a 10-bit general purpose analog-to-digital converter (ADC) with track and hold circuitry and an analog input multiplexer that allows the conversion of up to nine different inputs.

The ADC measures the following inputs:

  • Channel 0: VSYS_RES - measurement of the system VDD (2.5 - 5.5V)

  • Channel 1: ADCIN1_RES - high impedance input (0 - 2.5V)

  • Channel 2: ADCIN2_RES - high impedance input (0 - 2.5V)

  • Channel 3: ADCIN3_RES - high impedance input (0 - 2.5V)

  • Channel 4: Tjunc - measurement of internal temperature sensor

  • Channel 5: VBBAT - measurement of the backup battery voltage (0 - 5.0V)

  • Channel 8: MON_A8_RES - group 1 internal regulators voltage (0 - 5.0V)

  • Channel 9: MON_A9_RES - group 2 internal regulators voltage (0 - 5.0V)

  • Channel 10: MON_A10_RES group 3 internal regulators voltage (0 - 5.0V)

Kernel configuration

You can manage the hardware monitor support device driver through the following kernel configuration option:

  • Dialog Semiconductor DA9063 (CONFIG_SENSORS_DA9063)

This option is enabled as built-in on the ConnectCore 6 Plus SBC kernel configuration file.

Kernel driver

The hardware monitor support device driver for Dialog DA9063 is located at drivers/hwmon/da9063-hwmon.c.

Device tree bindings and customization

The PMIC ADC device tree binding is documented at Documentation/devicetree/bindings/hwmon/da9063-hwmon.txt.

The device tree node for the hardware monitor support device driver is defined in the ConnectCore 6 Plus device tree.

i.MX6QP device tree
hwmon {
    compatible = "dlg,da9063-hwmon";
    dlg,tjunc-offset = <(-5)>
}

ADC user space usage

You can access the ADC values through the sys file system:

root@ccimx6qpsbc:# cd /sys/class/hwmon/hwmon0/device
root@ccimx6qpsbc:# ls
driver       in0_label    in2_input    in3_label    modalias     subsystem    uevent
hwmon        in1_input    in2_label    in4_input    name         temp1_input
in0_input    in1_label    in3_input    in4_label    power        temp1_label
root@ccimx6qpsbc:# cat in0_label in0_input
VSYS
4968
root@ccimx6qpsbc:# cat in1_label in1_input
ADCIN1
1124
root@ccimx6qpsbc:# cat in2_label in2_input
ADCIN2
2096
root@ccimx6qpsbc:# cat in3_label in3_input
ADCIN3
1632
root@ccimx6qpsbc:# cat in4_label in4_input
VBBAT
425
root@ccimx6qpsbc:# cat temp1_label temp1_input
TJUNC
50