majicdesigns / md_ds1307 Goto Github PK
View Code? Open in Web Editor NEWDS1307 Real Time Clock Library
License: GNU Lesser General Public License v2.1
DS1307 Real Time Clock Library
License: GNU Lesser General Public License v2.1
The line "while (!Wire.available()) ; // wait
" after the Wire.requestFrom() in the file "MD_DS1307/src/MD_DS1307.cpp" may be removed. There is nothing to wait for.
When the Wire.requestFrom() returns, the I2C transaction has completely finished and the received data is waiting in a buffer in the Wire library.
The pre-declaration of RTC cause error with M0 processors as RTC is predefined in the Atmel CMSIS-Atmel libraries...
I might suggest: or leave it to the user to create the instance define in his program.
class MD_DS1307 RTCLOCK; // one instance created when the library is included
/Users/lafleur/Library/Arduino15/packages/arduino/tools/arm-none-eabi-gcc/4.8.3-2014q1/bin/arm-none-eabi-g++" -mcpu=cortex-m0plus -mthumb -c -g -Os -std=gnu++11 -ffunction-sections -fdata-sections -fno-threadsafe-statics -nostdlib --param max-inline-insns-single=500 -fno-rtti -fno-exceptions -MMD -DF_CPU=48000000L -DARDUINO=10805 -DARDUINO_SAMD_ZERO -DARDUINO_ARCH_SAMD -DARDUINO_SAMD_ZERO -DARM_MATH_CM0PLUS -DADAFRUIT_FEATHER_M0 -D__SAMD21G18A__ -DUSB_VID=0x239A -DUSB_PID=0x800B -DUSBCON '-DUSB_MANUFACTURER="Adafruit"' '-DUSB_PRODUCT="Feather M0"' "-I/Users/lafleur/Library/Arduino15/packages/arduino/tools/CMSIS/4.5.0/CMSIS/Include/" "-I/Users/lafleur/Library/Arduino15/packages/arduino/tools/CMSIS-Atmel/1.2.0/CMSIS/Device/ATMEL/" "-I/Users/lafleur/Library/Arduino15/packages/adafruit/hardware/samd/1.2.7/cores/arduino" "-I/Users/lafleur/Library/Arduino15/packages/adafruit/hardware/samd/1.2.7/variants/feather_m0" "-I/Users/lafleur/Desktop/MySensor-Arduino-development/MCCI/libraries/Adafruit_GFX_Library" "-I/Users/lafleur/Desktop/MySensor-Arduino-development/MCCI/libraries/RGB_matrix_Panel" "-I/Users/lafleur/Desktop/MySensor-Arduino-development/MCCI/libraries/MD_DS1307/src" "-I/Users/lafleur/Library/Arduino15/packages/adafruit/hardware/samd/1.2.7/libraries/Wire" "-I/Users/lafleur/Library/Arduino15/packages/adafruit/hardware/samd/1.2.7/libraries/SPI" "/var/folders/53/f8mlg0xn1xv3fsm58phqmtb40000gn/T/arduino_build_327706/sketch/LED-Clock.ino.cpp" -o "/var/folders/53/f8mlg0xn1xv3fsm58phqmtb40000gn/T/arduino_build_327706/sketch/LED-Clock.ino.cpp.o"
In file included from /Users/lafleur/Library/Arduino15/packages/arduino/tools/CMSIS-Atmel/1.2.0/CMSIS/Device/ATMEL/samd21/include/samd21.h:69:0,
from /Users/lafleur/Library/Arduino15/packages/arduino/tools/CMSIS-Atmel/1.2.0/CMSIS/Device/ATMEL/samd.h:105,
from /Users/lafleur/Library/Arduino15/packages/arduino/tools/CMSIS-Atmel/1.2.0/CMSIS/Device/ATMEL/sam.h:540,
from /Users/lafleur/Library/Arduino15/packages/adafruit/hardware/samd/1.2.7/cores/arduino/Arduino.h:48,
from /var/folders/53/f8mlg0xn1xv3fsm58phqmtb40000gn/T/arduino_build_327706/sketch/LED-Clock.ino.cpp:1:
/Users/lafleur/Library/Arduino15/packages/arduino/tools/CMSIS-Atmel/1.2.0/CMSIS/Device/ATMEL/samd21/include/samd21g18a.h:487:38: error: expected ')' before '*' token
#define RTC ((Rtc *)0x40001400UL) /**< \brief (RTC) APB Base Address */
~~
MD_DS1307_LCD_Time.ino dosen’t return DayofWeek
lcd.print(dow2String(RTC.dow));
this lines
" RTC.dow " return 0 at always;
i guess this line must be
lcd.print(dow2String(RTC.calcDoW(RTC.yyyy, RTC.mm, RTC.dd)));
anyway Thank you so much .
This library is good for me.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.