mux2 2.0.0.0
|
MUX 2 click is a Click boardâ„¢ that switches one of the eight inputs to one output. It employs the MUX508, a modern CMOS analog multiplexing integrated circuit, produced by Texas Instruments.
We provide a library for the Mux2 Click as well as a demo application (example), developed using MikroElektronika compilers. The demo can run on all the main MikroElektronika development boards.
Package can be downloaded/installed directly form compilers IDE(recommended way), or downloaded from our LibStock, or found on mikroE github account.
This library contains API for Mux2 Click driver.
- Initialization function.void mux2_cfg_setup ( mux2_cfg_t *cfg );
MUX2_RETVAL mux2_init ( mux2_t *ctx, mux2_cfg_t *cfg );
void mux2_default_cfg ( mux2_t *ctx );
- Enable MUX device function.void mux2_active_mux_channel ( mux2_t *ctx, uint8_t sel_ch );
void mux2_device_disable ( mux2_t *ctx );
void mux2_device_enable ( mux2_t *ctx );
Sets the current active channel. Changes the channel every 5 sec.
The demo application is composed of two sections :
Initializes GPIO module and sets RST, CS, PWM and INT pins as OUTPUT.
Changes currently active channel every 5 sec.
The full application code, and ready to use projects can be installed directly form compilers IDE(recommneded) or found on LibStock page or mikroE GitHub accaunt.
Other mikroE Libraries used in the example:
Additional notes and informations
Depending on the development board you are using, you may need 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.