mirror of
https://github.com/torvalds/linux.git
synced 2024-11-10 14:11:52 +00:00
cdf3ecb0d8
Adds driver for the MCP48xx series of DACs. Device uses a simplex SPI channel. To set the value of an output channel, a 16-bit data of following format must be written: Bit field | Description 15 [MSB] | Channel selection bit 0 -> Channel A 1 -> Channel B 13 | Output Gain Selection bit 0 -> 2x Gain (Vref = 4.096V) 1 -> 1x Gain (Vref = 2.048V) 12 | Output Shutdown Control bit 0 -> Shutdown the selected channel 1 -> Active mode operation 11-0 [LSB]| DAC Input Data bits Value's big endian representation is taken as input for the selected DAC channel. For devices with a resolution of less than 12-bits, only the x most significant bits are considered where x is the resolution of the device. Reference: Page#22 [MCP48x2 Datasheet] Supported devices: +---------+--------------+-------------+ | Device | Resolution | Channels | |---------|--------------|-------------| | MCP4801 | 8-bit | 1 | | MCP4802 | 8-bit | 2 | | MCP4811 | 10-bit | 1 | | MCP4812 | 10-bit | 2 | | MCP4821 | 12-bit | 1 | | MCP4822 | 12-bit | 2 | +---------+--------------+-------------+ Devices tested: MCP4821 [12-bit single channel] MCP4802 [8-bit dual channel] Tested on Raspberry Pi Zero 2W Datasheet: https://ww1.microchip.com/downloads/en/DeviceDoc/22244B.pdf #MCP48x1 Datasheet: https://ww1.microchip.com/downloads/en/DeviceDoc/20002249B.pdf #MCP48x2 Signed-off-by: Anshul Dalal <anshulusr@gmail.com> Link: https://lore.kernel.org/r/20231220151954.154595-2-anshulusr@gmail.com Signed-off-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
54 lines
1.8 KiB
Makefile
54 lines
1.8 KiB
Makefile
# SPDX-License-Identifier: GPL-2.0
|
|
#
|
|
# Makefile for industrial I/O DAC drivers
|
|
#
|
|
|
|
# When adding new entries keep the list in alphabetical order
|
|
obj-$(CONFIG_AD3552R) += ad3552r.o
|
|
obj-$(CONFIG_AD5360) += ad5360.o
|
|
obj-$(CONFIG_AD5380) += ad5380.o
|
|
obj-$(CONFIG_AD5421) += ad5421.o
|
|
obj-$(CONFIG_AD5624R_SPI) += ad5624r_spi.o
|
|
obj-$(CONFIG_AD5064) += ad5064.o
|
|
obj-$(CONFIG_AD5504) += ad5504.o
|
|
obj-$(CONFIG_AD5446) += ad5446.o
|
|
obj-$(CONFIG_AD5449) += ad5449.o
|
|
obj-$(CONFIG_AD5592R_BASE) += ad5592r-base.o
|
|
obj-$(CONFIG_AD5592R) += ad5592r.o
|
|
obj-$(CONFIG_AD5593R) += ad5593r.o
|
|
obj-$(CONFIG_AD5755) += ad5755.o
|
|
obj-$(CONFIG_AD5758) += ad5758.o
|
|
obj-$(CONFIG_AD5761) += ad5761.o
|
|
obj-$(CONFIG_AD5764) += ad5764.o
|
|
obj-$(CONFIG_AD5766) += ad5766.o
|
|
obj-$(CONFIG_AD5770R) += ad5770r.o
|
|
obj-$(CONFIG_AD5791) += ad5791.o
|
|
obj-$(CONFIG_AD5686) += ad5686.o
|
|
obj-$(CONFIG_AD5686_SPI) += ad5686-spi.o
|
|
obj-$(CONFIG_AD5696_I2C) += ad5696-i2c.o
|
|
obj-$(CONFIG_AD7293) += ad7293.o
|
|
obj-$(CONFIG_AD7303) += ad7303.o
|
|
obj-$(CONFIG_AD8801) += ad8801.o
|
|
obj-$(CONFIG_CIO_DAC) += cio-dac.o
|
|
obj-$(CONFIG_DPOT_DAC) += dpot-dac.o
|
|
obj-$(CONFIG_DS4424) += ds4424.o
|
|
obj-$(CONFIG_LPC18XX_DAC) += lpc18xx_dac.o
|
|
obj-$(CONFIG_LTC1660) += ltc1660.o
|
|
obj-$(CONFIG_LTC2632) += ltc2632.o
|
|
obj-$(CONFIG_LTC2688) += ltc2688.o
|
|
obj-$(CONFIG_M62332) += m62332.o
|
|
obj-$(CONFIG_MAX517) += max517.o
|
|
obj-$(CONFIG_MAX5522) += max5522.o
|
|
obj-$(CONFIG_MAX5821) += max5821.o
|
|
obj-$(CONFIG_MCP4725) += mcp4725.o
|
|
obj-$(CONFIG_MCP4728) += mcp4728.o
|
|
obj-$(CONFIG_MCP4821) += mcp4821.o
|
|
obj-$(CONFIG_MCP4922) += mcp4922.o
|
|
obj-$(CONFIG_STM32_DAC_CORE) += stm32-dac-core.o
|
|
obj-$(CONFIG_STM32_DAC) += stm32-dac.o
|
|
obj-$(CONFIG_TI_DAC082S085) += ti-dac082s085.o
|
|
obj-$(CONFIG_TI_DAC5571) += ti-dac5571.o
|
|
obj-$(CONFIG_TI_DAC7311) += ti-dac7311.o
|
|
obj-$(CONFIG_TI_DAC7612) += ti-dac7612.o
|
|
obj-$(CONFIG_VF610_DAC) += vf610_dac.o
|