TOP Contributors

  1. MIKROE (2662 codes)
  2. Alcides Ramos (357 codes)
  3. Shawon Shahryiar (307 codes)
  4. jm_palomino (112 codes)
  5. Chisanga Mumba (90 codes)
  6. S P (73 codes)
  7. dany (71 codes)
  8. MikroBUS.NET Team (35 codes)
  9. NART SCHINACKOW (34 codes)
  10. Armstrong Subero (27 codes)

Most Downloaded

  1. Timer Calculator (137028 times)
  2. FAT32 Library (70152 times)
  3. Network Ethernet Library (56032 times)
  4. USB Device Library (46355 times)
  5. Network WiFi Library (41970 times)
  6. FT800 Library (41297 times)
  7. GSM click (29071 times)
  8. mikroSDK (26509 times)
  9. PID Library (26452 times)
  10. microSD click (25436 times)
Libstock prefers package manager

Package Manager

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]

< Back
mikroSDK Library

Temp-Log click

Rating:

5

Author: MIKROE

Last Updated: 2018-02-14

Package Version: 1.0.0.0

mikroSDK Library: 1.0.0.0

Category: Temperature & humidity

Downloaded: 4882 times

Not followed.

License: MIT license  

Temp-Log click uses for temperature measurement. This click reads temperature and shows this temperature data in decimal and celsius value with determined resolution. Temp-Log click also has ALERT pin for checking high temperature limit.

No Abuse Reported

Do you want to subscribe in order to receive notifications regarding "Temp-Log click" changes.

Do you want to unsubscribe in order to stop receiving notifications regarding "Temp-Log click" changes.

Do you want to report abuse regarding "Temp-Log click".

  • mikroSDK Library 2.0.0.0
  • Comments (0)
DOWNLOAD LINK RELATED COMPILER CONTAINS
mikroBasic PRO for ARM
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for AVR
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for dsPIC30/33 & PIC24
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for FT90x
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for PIC
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroBasic PRO for PIC32
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for ARM
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for AVR
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for dsPIC30/33 & PIC24
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for FT90x
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for PIC
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroC PRO for PIC32
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for ARM
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for AVR
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for dsPIC30/33 & PIC24
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for FT90x
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for PIC
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc
mikroPascal PRO for PIC32
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc

mikroSDK Library Blog

Temp-Log Click

Temp-Log Click

Native view of the Temp-Log Click board.

View full image
Temp-Log Click

Temp-Log Click

Front and back view of the Temp-Log Click board.

View full image

Library Description

Initializes and defines I2C driver, defines driver's function which writes data in registers, reads data from registers, reads and converts temperature to Celsius value with determined resolution, and checks Alert pin for temperature limit.

Key functions

Function writes 8-bit or 16-bit data in register- Function writes 8-bit or 16-bit data in register

uint16_t temp_log_readReg(uint8_t register_address);- Function reads 16-bit data from register

uint16_t temp_log_readTempDec(uint16_t resolution);- Function reads 16-bit temperature data from register with determined resolution

float temp_log_convertToCelsius(uint16_t temperature_data);- Function converts 16-bit temperature data to Celsius value

uint8_t temp_log_getAlert();- Function checks state of Alert pin (ALT)

Example description

  • System Initialization - Initializes peripherals and pins.
  • Application Initialization - Initializes click driver.
  • Application Task - Reads temperature from the temperature register in decimal value in 9-bit resolution, converts that decimal value in Celsius value and checks Alert pin which becomes active (low) if the measured temperature meets or exceeds the high temperature limit.
void applicationTask()
{
    uint16_t temperature = 0;
    float temp = 0;
    uint16_t temp_limit = 0;
    char txt[4] = {0};
    char txt1[10] = {0};

    temperature = temp_log_readTempDec(_TEMP_LOG_RESOLUTION_9_BITS);
    temp = temp_log_convertToCelsius(temperature);

    IntToStr(temperature, txt);
    mikrobus_logWrite("Temperature in decimal value is: ", _LOG_TEXT);
    mikrobus_logWrite(txt, _LOG_LINE);

    FloatToStr(temp, txt1);
    mikrobus_logWrite("Temperature in celsius value is: ", _LOG_TEXT);
    mikrobus_logWrite(txt1, _LOG_LINE);

    if(temp_log_getAlert() == 0)
    {
        mikrobus_logWrite("TEMPERATURE LIMIT ALARMING!", _LOG_LINE);
    }

    Delay_ms(1000);
}

Additional notes and information

Depending on the development board you are using, you may need USB UART clickUSB UART 2 clickor 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.

ALSO FROM THIS AUTHOR

DTMF click

0

DTMF Click is a compact add-on board designed for projects that demand reliable telephony interactions. This board features the CMX865A, a DTMF Codec/FSK Combo multi-standard modem from CML Micro. The CMX865A excels in encoding and decoding DTMF signals, alongside supporting FSK data transmission compatible with V.23, V.21, Bell 103, and Bell 202 standards, making it versatile for various telephony applications. It's particularly adept at enabling dual-mode operations for transmitting and receiving data, ensuring high fidelity in signal processing and resistance to voice falsing. Ideal for security systems, automated response services, and IoT devices requiring telephonic interaction, DTMF Click provides a solution for developers looking to incorporate reliable telecommunication capabilities.

[Learn More]

LED Curtain Demo

0

The application demonstrates GPIO SDK functionality.

[Learn More]

ProxFusion 2 click

5

ProxFusion 2 Click is an ambient lighting, capacitive, Hall-effect, and inductive sensing Click board which features a single multifunctional sensor IC.

[Learn More]