DIGI POT 7 Click Board
DIGI POT 7 Click Board
The Digi Pot 7 Click Board™ is a compact add-on board used as a digitally controlled potentiometer. This board features the AD5175, a single-channel 1024-position digital rheostat with less than ±1% end-to-end resistor tolerance error and 50-time programmable wiper memory from Analog Devices. This I2C configurable IC is designed to operate as a variable resistor for analogue signals, within the voltage range of single-supply operation at 2.7 V to 5.5 V. Unlimited adjustments are allowed before programming the resistance value into the programmable memory. This Click Board™ can be used as mechanical rheostat replacements, in a voltage to current conversions, for gain and offset adjustment, and many more applications.
The Digi Pot 7 Click Board™ is supported by a mikroSDK compliant library, which includes functions that simplify software development. This Click Board™ comes as a fully tested product, ready to be used on a system equipped with the mikroBUS™ socket.
Software Support
We provide a library for the DIGI POT 7 Click Board™ on our LibStock page, as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
The package can be downloaded/installed directly from NECTO Studio The package Manager (recommended), downloaded from our LibStock™ or found on mikroE Github account.
Library Description
The library covers all the necessary functions to control the DIGI POT 7 Click Board™. Library performs a standard I2C interface communication.
Key Functions
void digipot7_enable_write ( void )
- Enable write function.void digipot7_operating_mode ( uint8_t mode )
- Set operating mode function.DIGIPOT7_RETVAL_T digipot7_set_resistance ( uint16_t res_ohm )
- Set resistance function.
Example Description
The application is composed of three sections :
- System Initialization - Initializes I2C, set RST pin as an output and start to write a log.
- Application Initialization - Initialization driver enables - I2C, perform a hardware reset, enable write and set to normal operating mode, also write log.
- Application Task - (code snippet) This is an example that demonstrate the use of the DIGI POT 7 Click Board™. In this example we set different resistance values: 1.024 kΩ, 2.048 kΩ, 4.096 kΩ and 8.192 kΩ. Results are being sent to the USART Terminal where you can track their changes. All data logs write on USB UART changes approximately for every 5 sec.
void application_task ( ) { mikrobus_logWrite( " Set Resistance: 1.024 kOhm ", _LOG_LINE ); mikrobus_logWrite( "----------------------------", _LOG_LINE ); digipot7_set_resistance( 1024 ); Delay_ms( 5000 ); mikrobus_logWrite( " Set Resistance: 2.048 kOhm ", _LOG_LINE ); mikrobus_logWrite( "----------------------------", _LOG_LINE ); digipot7_set_resistance( 2048 ); Delay_ms( 5000 ); mikrobus_logWrite( " Set Resistance: 4.096 kOhm ", _LOG_LINE ); mikrobus_logWrite( "----------------------------", _LOG_LINE ); digipot7_set_resistance( 4096 ); Delay_ms( 5000 ); mikrobus_logWrite( " Set Resistance: 8.192 kOhm ", _LOG_LINE ); mikrobus_logWrite( "----------------------------", _LOG_LINE ); digipot7_set_resistance( 8192 ); Delay_ms( 5000 ); }
The full application code, and ready to use projects can be found on our LibStock page.
Other MikroE Libraries used in the example:
- I2C
- UART
- Conversions
Additional Notes and Information
Depending on the development board you are using, you may need a USB UART click, USB UART 2 click or RS232 click to connect to your PC, for development systems with no UART to USB interface available on the board. The terminal available in all MikroElektronika compilers, or any other terminal application of your choice, can be used to read the message.
MIKROSDK
The DIGI POT 7 Click Board™ is supported with mikroSDK - MikroElektronika Software Development Kit. To ensure proper operation of mikroSDK compliant Click board™ demo applications, mikroSDK should be downloaded from the LibStock and installed for the compiler you are using.
DIGI POT 7 Click Board
Frequently Asked Questions
Have a Question?
Be the first to ask a question about this.