This website works better with JavaScript.
Home
Explore
Help
Sign In
mh
/
mhsw-espurna
Watch
1
Star
0
Fork
0
Code
Releases
0
Activity
Fork of the espurna firmware for `mhsw` switches
2018
Commits
18
Branches
212 MiB
C
59.9%
C++
32.2%
HTML
2.9%
Objective-C
1.8%
JavaScript
1.6%
Other
1.5%
Tree:
4152caab93
mhsw-espurna
/
code
/
espurna
/
rtc
History
poulch74
8fec2a03d7
add RTC support (ds3231 ds1307 etc)
7 years ago
..
README.md
add RTC support (ds3231 ds1307 etc)
7 years ago
ds1307.h
add RTC support (ds3231 ds1307 etc)
7 years ago
ds3231.h
add RTC support (ds3231 ds1307 etc)
7 years ago
dummy.h
add RTC support (ds3231 ds1307 etc)
7 years ago
README.md
RTC support module
commands in debug terminal
RTC return current rtc time
RTC YYYY-MM-DD DoW HH:MM:SS setup rtc
defines to enable support for modules in hardware.h
#define RTC_SUPPORT 0/1 enable/disable RTC support
#define RTC_PROVIDER RTC_PROVIDER_DS3231 etc... spec which rtc ic to use
#define RTC_RECOVERY_CNT 10(def) // 0 no attempt to switch back to NTP time
#define RTC_NTP_SYNC_ENA 0/1 // 0 independed rtc, not synced with ntp, 1 rtc synced with ntp on ntp success
to add new rtc ic support
see ds3231.h as example, create your_ic.h file and write two functions time_t getTime_rtc() and uint8_t setTime_rtc(time_t nt)
define your provider constant in config/types.h
add your provider section in config/rtc.h