TOP Contributors

  1. MIKROE (2784 codes)
  2. Alcides Ramos (404 codes)
  3. Shawon Shahryiar (307 codes)
  4. jm_palomino (132 codes)
  5. Bugz Bensce (97 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 (141027 times)
  2. FAT32 Library (73566 times)
  3. Network Ethernet Library (58376 times)
  4. USB Device Library (48558 times)
  5. Network WiFi Library (44177 times)
  6. FT800 Library (43711 times)
  7. GSM click (30582 times)
  8. mikroSDK (29353 times)
  9. PID Library (27224 times)
  10. microSD click (26969 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
Library

RTC 1307 Library

Rating:

10

Author: Richard Lowe

Last Updated: 2013-09-19

Package Version: 1.0.0.0

Category: Timers (Real time clock)

Downloaded: 2178 times

Not followed.

License: MIT license  

Makes easy addition of ds1307 RTC.

No Abuse Reported

Do you want to subscribe in order to receive notifications regarding "RTC 1307 Library" changes.

Do you want to unsubscribe in order to stop receiving notifications regarding "RTC 1307 Library" changes.

Do you want to report abuse regarding "RTC 1307 Library".

  • Information
  • Comments (0)
DOWNLOAD LINK RELATED COMPILER CONTAINS
mikroC PRO for AVR
  • lib
  • src
  • exa
  • hlp
  • hex
  • sch
  • pcb
  • doc

Library Blog


Currently only for AVR but ARM coming soon.

Requires: Boolean support found on libstock

Easy access to all RTC functions including RAM read / write as well as RTC output.  Has "daylight savings time" support.  This is the current law for dst, but future revisions will allow for a custom dst if the law were to change.

Several functions exist in this library including GMT HTTP header output for your web server project.

Example:

#include "ds1307.h"
#include <stdbool.h>

#define msg( txt ) UART1_Write_Text( txt )

void main() 
{
   ds1307_config_t rtc;
   rtc.time_zone = -8;
   rtc.dst_enable = TRUE;
   rtc.config = DS1307_SQW_1HZ;
   
   UART1_Init( 38400 );
   Delay_ms( 100 );
   
   ds1307_init( &rtc );
   
   EICRA |= (1<<ISC01) | (1<<ISC00);
   EIMSK |= (1<<INT0);
   SREG_I_bit = 1;
   
}

void rtc_sw_ISR() iv IVT_ADDR_INT0 ics ICS_AUTO {
    msg( ds1307_get_system_time_str() );
    msg( "\r\n" );
}

NOTE* Time is kept in GMT on the hardware.  Local time is supported through "time_zone". 

ALSO FROM THIS AUTHOR

Add Standard bool / true / false to MikroC

0

This is not my library, but a opensource header file that adds boolean datatype to MikroC. Copy this file to the ../Mikroeleckronika/"your ide"/include/ directory. In your project that will use boolean types include this line: #include <stdbool.h>

[Learn More]

STM DMA Library

15

This is the first of DMA functions that will be available for the ST line of ARM microcontrollers. The idea was born from a forum post. The idea worked so well I made it into a convenient MikroC library. So far.... memory to memory transfers is what is functional

[Learn More]

DS18X20 One Wire Library

5

Easily add DS18x20 sensor functions to your project.

[Learn More]