I tried to post all the code but it will not fit on the page.
Can you tell me where to put the declare?
/* ESP32 Weather Display using an EPD 4.2" Display, obtains data from Open Weather Map, decodes the weather data and then displays it.
####################################################################################################################################
This software, the ideas and concepts is Copyright (c) David Bird 2019. All rights to this software are reserved.
Any redistribution or reproduction of any part or all of the contents in any form is prohibited other than the following:
1. You may print or download to a local hard disk extracts for your personal and non-commercial use only.
2. You may copy the content to individual third parties for their personal use, but only if you acknowledge the author David Bird as the source of the material.
3. You may not, except with my express written permission, distribute or commercially exploit the content.
4. You may not transmit it or store it in any other website or other form of electronic retrieval system for commercial purposes.
The above copyright ('as annotated') notice and this permission notice shall be included in all copies or substantial portions of the Software and where the
software use is visible to an end-user.
THE SOFTWARE IS PROVIDED "AS IS" FOR PRIVATE USE ONLY, IT IS NOT FOR COMMERCIAL USE IN WHOLE OR PART OR CONCEPT. FOR PERSONAL USE IT IS SUPPLIED WITHOUT WARRANTY
OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHOR OR COPYRIGHT HOLDER BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
See more at http://www.dsbird.org.uk
*/
#include <Arduino.h>
#include "owm_credentials.h" // See 'owm_credentials' tab and enter your OWM API key and set the Wifi SSID and PASSWORD
#include "Sys_Variables.h"
#include "Void_S.h"
#include "Wx_Icons.h" // Weather Icons
#include <ArduinoJson.h> // https://github.com/bblanchon/ArduinoJson
#include <WiFi.h> // Built-in
#include "time.h" // Built-in
#include <SPI.h> // Built-in
#define ENABLE_GxEPD2_display 0
#include <GxEPD2_BW.h>
#include <GxEPD2_3C.h>
#include <Fonts/FreeMonoBold12pt7b.h>
#include "epaper_fonts.h"
**enum alignment {LEFT, RIGHT, CENTER};**
void addmoon (int x, int y, int scale);
int StartWiFi();
void SetupTime();
bool obtain_wx_data(String RequestType);
void StopWiFi();
void DisplayWeatherInfo();
void DisplaySystemStatus(int x, int y);
void begin_sleep();
void DisplayHeadingSection();
void DisplayTempSection(int x, int y);
void DisplayWxPerson(int x, int y, String IconName);
void DisplayWxIcon(int x, int y, String IconName, bool LargeSize);
void DisplayMainWeatherSection(int x, int y);
void DisplayForecastSection(int x, int y);
void DisplayAstronomySection(int x, int y);
void DisplayWindSection(int x, int y, float angle, float windspeed, int Cradius);
void drawString(int x, int y, String text, alignment align);
void drawStringMaxWidth(int x, int y, int text_width, String text, alignment align);
String TitleCase(String text);
String WindDegToDirection(float winddirection);
int JulianDate(int d, int m, int y);
void MostlySunny(int x, int y, bool LargeSize, String IconName);
void Cloudy(int x, int y, bool LargeSize, String IconName);
void ChanceRain(int x, int y, bool LargeSize, String IconName);
void Rain(int x, int y, bool LargeSize, String IconName);
void Tstorms(int x, int y, bool LargeSize, String IconName);
void Haze(int x, int y, bool LargeSize, String IconName);
void Fog(int x, int y, bool LargeSize, String IconName);
void Nodata(int x, int y, bool LargeSize);
bool DecodeWeather(String json, String Type);
void Convert_Readings_to_Imperial();
void UpdateLocalTime();
void ExpectRain(int x, int y, bool LargeSize, String IconName);
void Sunny(int x, int y, bool LargeSize, String IconName);
void MostlyCloudy(int x, int y, bool LargeSize, String IconName);
void DisplayRSSI(int x, int y);
void DisplayBattery(int x, int y);
void Snow(int x, int y, bool LargeSize, String IconName);
void DrawMoon(int x, int y, int dd, int mm, int yy, String hemisphere);
String MoonPhase(int d, int m, int y, String hemisphere);
void arrow(int x, int y, int asize, float aangle, int pwidth, int plength);
String ConvertUnixTime(int unix_time);
void DisplayForecastWeather(int x, int y, int index);
#define SCREEN_WIDTH 400.0 // Set for landscape mode, don't remove the decimal place!
#define SCREEN_HEIGHT 300.0 // Not used but included for completeness
**enum alignment {LEFT, RIGHT, CENTER};**
// pins_arduino.h, e.g. LOLIN32 LITE
static const uint8_t EPD_BUSY = 4;
static const uint8_t EPD_SS = 5;
static const uint8_t EPD_RST = 16;
static const uint8_t EPD_DC = 17;
static const uint8_t EPD_SCK = 18;
static const uint8_t EPD_MISO = 19; // Master-In Slave-Out not used, as no data from display
static const uint8_t EPD_MOSI = 23;