B+IMU+SD

Dependencies:   BMI160 RTC SDFileSystem USBDevice max32630fthr sd-driver

Fork of MPSMAXbutton by Faizan Ahmad

Embed: (wiki syntax)

« Back to documentation index

Show/hide line numbers RTClock.cpp Source File

RTClock.cpp

00001 #include "RTClock.h"
00002 extern Serial _serialport;
00003 
00004 void initRTC(){
00005     time_t seconds = time(NULL);
00006 }
00007 
00008 void setRTCTime(){
00009 
00010 }
00011 
00012 
00013 void loadNextMove(){
00014 
00015 }
00016 
00017 void printRTCTime(){
00018     time_t seconds = time(NULL);
00019     _serialport.printf("Time as seconds since January 1, 1970 = %d\n", seconds);
00020     _serialport.printf("Time as a basic string = %s", ctime(&seconds));
00021     char buffer[32];
00022     strftime(buffer, 32, "%I:%M %p\n", localtime(&seconds));
00023     _serialport.printf("Time as a custom formatted string = %s", buffer);
00024 
00025 }