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-02-19
Package Version: 1.0.0.0
mikroSDK Library: 1.0.0.0
Category: Temperature & humidity
Downloaded: 2402 times
Not followed.
License: MIT license
Heater Click is designed with intention of PCB heater concept testing and useful tool for heating complete casing where staying in specified temperature range is crucial. Exact PCB temperature can be set and controlled using TMP235 on board temperature sensor from Texas Instruments.
Do you want to subscribe in order to receive notifications regarding "Heater click" changes.
Do you want to unsubscribe in order to stop receiving notifications regarding "Heater click" changes.
Do you want to report abuse regarding "Heater click".
Library Description
Library provides control over led pins and function for reading raw ADC data as well a fucntion for reading converted data in temperature.
Key functions:
uint16_t heater_read_data ( void );
- Function for reading raw ADC datafloat heater_read_temp ( void );
- Function that raw data converts in temperatureExamples description
The application is composed of three sections :
void application_task ( )
{
temp_read = heater_read_temp( );
if ( ( temp_read > HOT_TEMP ) && ( status_dev == HEATER_WAITING ) )
{
status_dev = HEATER_COOLING;
}
else if ( ( temp_read < COOL_TEMP ) && ( status_dev == HEATER_WAITING ) )
{
status_dev = HEATER_HEATING;
}
if ( status_dev == HEATER_HEATING )
{
heater_pwm_start( );
heater_set_led1_status( HEATER_LED_ON );
heater_set_led2_status( HEATER_LED_OFF );
status_dev = HEATER_WAITING;
}
else if ( status_dev == HEATER_COOLING )
{
heater_pwm_stop( );
heater_set_led1_status( HEATER_LED_OFF );
heater_set_led2_status( HEATER_LED_ON );
status_dev = HEATER_WAITING;
}
FloatToStr( temp_read, demo_txt );
mikrobus_logWrite( " - Temperature: ", _LOG_TEXT );
mikrobus_logWrite( demo_txt, _LOG_TEXT );
mikrobus_logWrite( log_degree, _LOG_LINE );
mikrobus_logWrite( "***************", _LOG_LINE );
Delay_ms( 1000 );
}
Note:
The full application code, and ready to use projects can be found on our LibStock page.
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.