man.bsd.lv manual page server

Manual Page Search Parameters

MCP3KADC(4) Device Drivers Manual MCP3KADC(4)

mcp3kadcMicrochip 3x0x SAR analog to digital converter

mcp3kadc* at spi? slave ? flags N

The mcp3kadc driver reports the current voltage on the chip's ADC channels through the envsys(4) API. The driver calculates these values according to the currently selected reference voltage (Vref). It can be changed through the sysctl(8) node hw.mcp3kadc0.vref.

The following table shows the supported chips. The type of the chip can be selected with the flags argument in the config file.

10 bits 1 0
10 bits 2 1
10 bits 4 2
10 bits 8 3
12 bits 1 4
12 bits 2 5
12 bits 4 6
12 bits 8 7
13 bits 1 8
13 bits 4 9
13 bits 8 10

The following sysctl(3) variables are provided:

hw.mcp3kadc0.vref
Defines the reference voltage on the chip's Vref pin in millivolts (mV). It defaults to the ADC's maximum output value + 1 in millivolts (e.g., 4096 for a 12-bit ADC).

envsys(4), spi(4), sysctl(8)

The mcp3kadc driver first appeared in NetBSD 8.0.

The mcp3kadc driver was written by Frank Wille.

August 18, 2015 NetBSD-9.2