the _BV is a macro defined here http://www.atmel.com/webdoc/AVRLibcReferenceManual/group__avr__sfr_1ga11643f271076024c395a93800b3d9546.html. (I searched a solution during 3 hours)
I was having the same problem with this library, so I've added these lines:
#define _BV(bit) \
(1 << (bit))
in DS3231RTC.h and tcharam! it works.
I've to added time.h (It was found here http://www.pjrc.com/teensy/td_libs_Time.html)in /<User>/Documents/Energia/Libraries
I was setting to: Wire.begin(); and Wire.setModule(0); cause I'm used the SCL(0) and SDA(0) in my launchpad. References here: http://energia.nu/wordpress/wp-content/uploads/2014/01/tm4c123pinmap.png
I'm using Tiva C 123GXL.
This example works with me and I hope it works with you:
* Example code illustrating Time library with Real Time Clock.
* This example is identical to the example provided with the Time Library,
* only the #include statement has been changed to include the DS3232RTC library.
#include <DS3232RTC.h> //http://github.com/JChristensen/DS3232RTC
#include <Time.h> //http://www.arduino.cc/playground/Code/Time
#include <Wire.h> //http://arduino.cc/en/Reference/Wire (included with Arduino IDE)
setSyncProvider(RTC.get); // the function to get the time from the RTC
if(timeStatus() != timeSet)
Serial.println("Unable to sync with the RTC");
Serial.println("RTC has set the system time");
// digital clock display of the time
void printDigits(int digits)
// utility function for digital clock display: prints preceding colon and leading 0
if(digits < 10)
This library will be useful to me, because I need the alarm function to wake up the launch pad.