fix definitions
This commit is contained in:
parent
334fecb472
commit
7a9c6b28a9
|
@ -56,10 +56,10 @@ const uint8_t *digits[10] = { image_data_icon_digit_0, image_data_icon_digit_1,
|
||||||
|
|
||||||
//CHANGE HERE ---------------
|
//CHANGE HERE ---------------
|
||||||
|
|
||||||
char *ssid = "Freifunk";
|
const char *ssid = "Freifunk";
|
||||||
char *pass = "";
|
const char *pass = "";
|
||||||
char *calendarURL = "https://mail.unitas-network.de/mergedCalendars.json";
|
const char *calendarURL = "";
|
||||||
char *timeZone = "CET-1CEST,M3.5.0/02,M10.5.0/03";
|
const char *timeZone = "CET-1CEST,M3.5.0/02,M10.5.0/03";
|
||||||
|
|
||||||
//Set to 1 to flip the screen 180 degrees
|
//Set to 1 to flip the screen 180 degrees
|
||||||
#define ROTATION 3
|
#define ROTATION 3
|
||||||
|
|
|
@ -35,11 +35,10 @@ void Network::begin()
|
||||||
void Network::getTime(int *timeDigits)
|
void Network::getTime(int *timeDigits)
|
||||||
{
|
{
|
||||||
struct tm timeinfo;
|
struct tm timeinfo;
|
||||||
|
time_t nowSecs = time(nullptr);
|
||||||
|
|
||||||
setenv("TZ", timeZone, 1);
|
setenv("TZ", timeZone, 1);
|
||||||
tzset();
|
tzset();
|
||||||
|
|
||||||
time_t nowSecs = time(nullptr);
|
|
||||||
localtime_r(&nowSecs, &timeinfo);
|
localtime_r(&nowSecs, &timeinfo);
|
||||||
|
|
||||||
// fill in the digits
|
// fill in the digits
|
||||||
|
|
12
Network.h
12
Network.h
|
@ -4,17 +4,15 @@
|
||||||
#include <WiFiClientSecure.h>
|
#include <WiFiClientSecure.h>
|
||||||
|
|
||||||
// To get vars from main file
|
// To get vars from main file
|
||||||
extern char *timeZone;
|
extern const char *ssid;
|
||||||
|
extern const char *pass;
|
||||||
|
extern const char *calendarURL;
|
||||||
|
extern const char *timeZone;
|
||||||
|
|
||||||
extern char calName[5][31];
|
extern char calName[5][31];
|
||||||
extern char calStart[5][26];
|
extern char calStart[5][26];
|
||||||
extern char calTitle[5][81];
|
extern char calTitle[5][81];
|
||||||
|
|
||||||
// Wifi ssid and password
|
|
||||||
extern char *ssid;
|
|
||||||
extern char *pass;
|
|
||||||
|
|
||||||
extern char *calendarURL;
|
|
||||||
|
|
||||||
#ifndef NETWORK_H
|
#ifndef NETWORK_H
|
||||||
#define NETWORK_H
|
#define NETWORK_H
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue