TOP Contributors

  1. MIKROE (2650 codes)
  2. Alcides Ramos (350 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 (136553 times)
  2. FAT32 Library (69756 times)
  3. Network Ethernet Library (55855 times)
  4. USB Device Library (46195 times)
  5. Network WiFi Library (41816 times)
  6. FT800 Library (41009 times)
  7. GSM click (28931 times)
  8. PID Library (26386 times)
  9. mikroSDK (26296 times)
  10. microSD click (25304 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

RTC 9 click

Rating:

5

Author: MIKROE

Last Updated: 2020-07-23

Package Version: 1.0.0.0

mikroSDK Library: 1.0.0.0

Category: RTC

Downloaded: 1721 times

Not followed.

License: MIT license  

RTC 9 Click is a real-time clock module which has an extremely low power consumption, allowing it to be used with a single button cell battery, for an extended period of time. This board features the M41T82, real-time clock (RTC) with battery switchover, from ST Microelectronics.

No Abuse Reported

Do you want to subscribe in order to receive notifications regarding "RTC 9 click" changes.

Do you want to unsubscribe in order to stop receiving notifications regarding "RTC 9 click" changes.

Do you want to report abuse regarding "RTC 9 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

RTC 9 Click

RTC 9 Click

Native view of the RTC 9 Click board.

View full image
RTC 9 Click

RTC 9 Click

Front and back view of the RTC 9 Click board.

View full image

Library Description

The library contains basic functions for working with RTC 9 click. The user is enabled to adjust and read the time and date. it also has the ability to set alarms.

Key functions:

  • void rtc9_set_time( uint8_t hour, uint8_t min, uint8_t sec ) - Set new time - 24 hour format.
  • void rtc9_set_date ( uint8_t day, uint8_t day_of_week, uint8_t month, uint8_t year ) - Set new date.
  • void rtc9_wakeup ( void ) - Wake-up process.

Examples description

The application is composed of three sections :

  • System Initialization - Initializes the I2C module and all necessary gpio pins.
  • Application Initialization - Starts waking the chip and sets the start time and date.
  • Application Task - It reads current time and date and logs to usb uart every 1000 ms.
void application_init ( )
{
    rtc9_i2c_driver_init
    ( 
        ( rtc9_obj_t )&_MIKROBUS1_GPIO, 
        ( rtc9_obj_t )&_MIKROBUS1_I2C, 
        RTC9_SLAVE_ADDRESS
    );
    Delay_ms( 500 );

    rtc9_wakeup( );

    rtc9_set_time( 12, 15, 45 );
    rtc9_set_date ( 20, RTC9_DAY_FRIDAY, RTC9_MONTH_MARCH, 20 );
}

void application_task ( )
{
    time_process( );
    date_process( );
    mikrobus_logWrite( "----------------------------------------", _LOG_LINE );
    Delay_ms( 1000 );
}

Additional Functions :

  • time_process ( ) - Reads and displays current time
  • date_process ( ) - Reads and displays current date

Other mikroE Libraries used in the example:

  • I2C
  • UART

Additional notes and informations

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

ALSO FROM THIS AUTHOR

DC MOTOR 7 click

6

DC MOTOR 7 click is a dual brushed DC motor driving Click board, featuring the advanced PWM chopper-type integrated DC motor driver, labeled as TB67H400AFTG.

[Learn More]

LTE IoT 9 click

0

LTE IoT 9 Click is a compact add-on board containing a cellular IoT Module that supports 3GPP Release 14 and all LTE bands.

[Learn More]

RTC 5 click

5

RTC5 click carries MCP79510, a real-time clock/calendar with an SPI interface. The example sets and reads the time, and displays it on the Lcd.

[Learn More]