mirror of
https://github.com/wled/WLED.git
synced 2025-07-19 08:46:34 +00:00
code spell checking - part2 (dependencies)
This commit is contained in:
parent
f513cae66e
commit
9f79e64678
@ -28,7 +28,7 @@
|
|||||||
#define BREAKFORMAT SERIAL_8N1
|
#define BREAKFORMAT SERIAL_8N1
|
||||||
|
|
||||||
bool dmxStarted = false;
|
bool dmxStarted = false;
|
||||||
int sendPin = 2; //dafault on ESP8266
|
int sendPin = 2; //default on ESP8266
|
||||||
|
|
||||||
//DMX value array and size. Entry 0 will hold startbyte
|
//DMX value array and size. Entry 0 will hold startbyte
|
||||||
uint8_t dmxDataStore[dmxMaxChannel] = {};
|
uint8_t dmxDataStore[dmxMaxChannel] = {};
|
||||||
|
@ -34,7 +34,7 @@
|
|||||||
#define DS1307_CTRL_ID 0x68
|
#define DS1307_CTRL_ID 0x68
|
||||||
|
|
||||||
// PUBLIC FUNCTIONS
|
// PUBLIC FUNCTIONS
|
||||||
time_t DS1307RTC::get() // Aquire data from buffer and convert to time_t
|
time_t DS1307RTC::get() // Acquire data from buffer and convert to time_t
|
||||||
{
|
{
|
||||||
tmElements_t tm;
|
tmElements_t tm;
|
||||||
if (read(tm) == false) return 0;
|
if (read(tm) == false) return 0;
|
||||||
@ -48,7 +48,7 @@ bool DS1307RTC::set(time_t t)
|
|||||||
return write(tm);
|
return write(tm);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Aquire data from the RTC chip in BCD format
|
// Acquire data from the RTC chip in BCD format
|
||||||
bool DS1307RTC::read(tmElements_t &tm)
|
bool DS1307RTC::read(tmElements_t &tm)
|
||||||
{
|
{
|
||||||
uint8_t sec;
|
uint8_t sec;
|
||||||
|
@ -101,9 +101,9 @@ int year(time_t t) { // the year for the given time
|
|||||||
|
|
||||||
/*============================================================================*/
|
/*============================================================================*/
|
||||||
/* functions to convert to and from system time */
|
/* functions to convert to and from system time */
|
||||||
/* These are for interfacing with time serivces and are not normally needed in a sketch */
|
/* These are for interfacing with time services and are not normally needed in a sketch */
|
||||||
|
|
||||||
// leap year calulator expects year argument as years offset from 1970
|
// leap year calculator expects year argument as years offset from 1970
|
||||||
#define LEAP_YEAR(Y) ( ((1970+Y)>0) && !((1970+Y)%4) && ( ((1970+Y)%100) || !((1970+Y)%400) ) )
|
#define LEAP_YEAR(Y) ( ((1970+Y)>0) && !((1970+Y)%4) && ( ((1970+Y)%100) || !((1970+Y)%400) ) )
|
||||||
|
|
||||||
static const uint8_t monthDays[]={31,28,31,30,31,30,31,31,30,31,30,31}; // API starts months from 1, this array starts from 0
|
static const uint8_t monthDays[]={31,28,31,30,31,30,31,31,30,31,30,31}; // API starts months from 1, this array starts from 0
|
||||||
@ -193,7 +193,7 @@ time_t makeTime(tmElements_t &tm){
|
|||||||
}
|
}
|
||||||
|
|
||||||
time_t getUnixTime(int hr,int min,int sec,int dy, int mnth, int yr){
|
time_t getUnixTime(int hr,int min,int sec,int dy, int mnth, int yr){
|
||||||
// year can be given as full four digit year or two digts (2010 or 10 for 2010);
|
// year can be given as full four digit year or two digits (2010 or 10 for 2010);
|
||||||
//it is converted to years since 1970
|
//it is converted to years since 1970
|
||||||
if( yr > 99)
|
if( yr > 99)
|
||||||
yr = yr - 1970;
|
yr = yr - 1970;
|
||||||
|
@ -11,7 +11,7 @@
|
|||||||
|
|
||||||
#include "Timezone.h"
|
#include "Timezone.h"
|
||||||
|
|
||||||
//THIS LINE WAS ADDED FOR COMPATIBILY WITH THE WLED DEPENDENCY STRUCTURE. REMOVE IF YOU USE IT OUTSIDE OF WLED!
|
//THIS LINE WAS ADDED FOR COMPATIBILITY WITH THE WLED DEPENDENCY STRUCTURE. REMOVE IF YOU USE IT OUTSIDE OF WLED!
|
||||||
#include "../time/TimeLib.h"
|
#include "../time/TimeLib.h"
|
||||||
|
|
||||||
#ifdef __AVR__
|
#ifdef __AVR__
|
||||||
|
Loading…
x
Reference in New Issue
Block a user