FamilyPlanner/Network.h

39 lines
720 B
C++

#include "Arduino.h"
#include <WiFi.h>
#include <WiFiClientSecure.h>
// To get vars from main file
extern int 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
// All functions defined in Network.cpp
class Network
{
public:
// Functions we can access in main file
void begin();
void getTime(int *timeDigits);
void off();
private:
// Functions called from within our class
void setTime();
void setCalendar();
size_t utf8_to_latin9(char *const output, const char *const input, const size_t length);
};
#endif