We strongly encourage users to use Package manager for sharing their code on Libstock website, because it boosts your efficiency and leaves the end user with no room for error. [more info]
Rating:
Author: MIKROE
Last Updated: 2020-09-18
Package Version: 1.0.0.0
mikroSDK Library: 1.0.0.0
Category: Interface
Downloaded: 1910 times
Not followed.
License: MIT license
8-pin I2C Click is a compact add-on board that represents a breakout board that simplifies the connection of add-on boards with 8 pin Female Connector to mikroBUSâ„¢ socket.
Do you want to subscribe in order to receive notifications regarding "8 pin I2C click" changes.
Do you want to unsubscribe in order to stop receiving notifications regarding "8 pin I2C click" changes.
Do you want to report abuse regarding "8 pin I2C click".
Library Description
The library contains a basic functions for using 8 pin I2C click.
Key functions:
void c8pini2c_i2c_write(uint8_t slave_addr, uint8_t *data_buf,uint16_t len, uint8_t end_mode)
- I2C Write functionvoid c8pini2c_i2c_read(uint8_t slave_addr, uint8_t *data_buf,uint16_t len, uint8_t end_mode)
- I2C Read functionvoid c8pini2c_i2c_start ( void )
- I2C Start functionExamples description
The application is composed of three sections :
void application_task ( )
{
float temperature;
char demo_text[ 20 ];
temperature = surfacetemp_get_temperature( );
FloatToStr( temperature, demo_text );
mikrobus_logWrite( "> Temperature : ", _LOG_TEXT );
mikrobus_logWrite( demo_text, _LOG_LINE );
Delay_ms( 1500 );
}
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.