fix definitions

This commit is contained in:
Jörg Deckert 2020-10-31 10:59:47 +01:00
parent 334fecb472
commit 7a9c6b28a9
3 changed files with 10 additions and 13 deletions

View File

@ -56,10 +56,10 @@ const uint8_t *digits[10] = { image_data_icon_digit_0, image_data_icon_digit_1,
//CHANGE HERE ---------------
char *ssid = "Freifunk";
char *pass = "";
char *calendarURL = "https://mail.unitas-network.de/mergedCalendars.json";
char *timeZone = "CET-1CEST,M3.5.0/02,M10.5.0/03";
const char *ssid = "Freifunk";
const char *pass = "";
const char *calendarURL = "";
const char *timeZone = "CET-1CEST,M3.5.0/02,M10.5.0/03";
//Set to 1 to flip the screen 180 degrees
#define ROTATION 3

View File

@ -35,11 +35,10 @@ void Network::begin()
void Network::getTime(int *timeDigits)
{
struct tm timeinfo;
time_t nowSecs = time(nullptr);
setenv("TZ", timeZone, 1);
tzset();
time_t nowSecs = time(nullptr);
localtime_r(&nowSecs, &timeinfo);
// fill in the digits

View File

@ -4,17 +4,15 @@
#include <WiFiClientSecure.h>
// 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 calStart[5][26];
extern char calTitle[5][81];
// Wifi ssid and password
extern char *ssid;
extern char *pass;
extern char *calendarURL;
#ifndef NETWORK_H
#define NETWORK_H