Class that stores state and functions for interacting with the DS3502 I2C Potentiometer.
More...
#include <Adafruit_DS3502.h>
|
Adafruit_BusIO_Register * | mode_selector |
| BusIO Register for selecting the write mode.
|
|
Class that stores state and functions for interacting with the DS3502 I2C Potentiometer.
◆ begin()
Sets up the hardware and initializes I2C.
- Parameters
-
i2c_address | The I2C address to be used. |
wire | The Wire object to be used for I2C connections. |
- Returns
- True if initialization was successful, otherwise false.
◆ getWiper()
uint8_t Adafruit_DS3502::getWiper |
( |
void |
| ) |
|
Gets the current value of the wiper register.
- Returns
- The 7-bit wiper value.
◆ setWiper()
void Adafruit_DS3502::setWiper |
( |
uint8_t |
new_wiper_value | ) |
|
Sets the potentiometer wiper to a new value.
- Parameters
-
new_wiper_value | The new wiper value to set. Must be from 0-127 |
◆ setWiperDefault()
void Adafruit_DS3502::setWiperDefault |
( |
uint8_t |
new_wiper_default | ) |
|
Sets the Wiper and IVR (Initial Value Register) to the given value.
- Parameters
-
new_wiper_default | The new wiper default to be set the wiper and default wiper value to. The wiper register will be set to the given value when written and when the device is powered on. Must be from 0-127 |
The documentation for this class was generated from the following files: