From 170029672a2bd4d3a9cbf72d2e640beb94e7d138 Mon Sep 17 00:00:00 2001 From: "Alexandre J. Raymond" Date: Tue, 3 May 2022 21:32:11 -0400 Subject: [PATCH 1/3] Fix missing defines breaking compilation --- src/config.h | 42 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 42 insertions(+) diff --git a/src/config.h b/src/config.h index 6529486..78b6e4c 100644 --- a/src/config.h +++ b/src/config.h @@ -1,6 +1,48 @@ #ifndef CONFIG_H #define CONFIG_H +//pins +#define MENU_BTN_PIN 26 +#define BACK_BTN_PIN 25 +#define DOWN_BTN_PIN 4 +#define DISPLAY_CS 5 +#define DISPLAY_RES 9 +#define DISPLAY_DC 10 +#define DISPLAY_BUSY 19 +#define ACC_INT_1_PIN 14 +#define ACC_INT_2_PIN 12 +#define VIB_MOTOR_PIN 13 +#define RTC_INT_PIN 27 + + +#if !defined(ARDUINO_WATCHY_V10) && !defined(ARDUINO_WATCHY_V15) && !defined(ARDUINO_WATCHY_V20) + #warning Hardware revision is not defined at the project level. Using hard-coded value + #define ARDUINO_WATCHY_V20 +#endif + +#if defined (ARDUINO_WATCHY_V10) + #define UP_BTN_PIN 32 + #define BATT_ADC_PIN 33 + #define UP_BTN_MASK GPIO_SEL_32 + #define RTC_TYPE 1 //DS3231 +#elif defined (ARDUINO_WATCHY_V15) + #define UP_BTN_PIN 32 + #define BATT_ADC_PIN 35 + #define UP_BTN_MASK GPIO_SEL_32 + #define RTC_TYPE 2 //PCF8563 +#elif defined (ARDUINO_WATCHY_V20) + #define UP_BTN_PIN 35 + #define BATT_ADC_PIN 34 + #define UP_BTN_MASK GPIO_SEL_35 + #define RTC_TYPE 2 //PCF8563 +#endif + +#define MENU_BTN_MASK GPIO_SEL_26 +#define BACK_BTN_MASK GPIO_SEL_25 +#define DOWN_BTN_MASK GPIO_SEL_4 +#define ACC_INT_MASK GPIO_SEL_14 +#define BTN_PIN_MASK MENU_BTN_MASK|BACK_BTN_MASK|UP_BTN_MASK|DOWN_BTN_MASK + //display #define DISPLAY_WIDTH 200 #define DISPLAY_HEIGHT 200 From 715a0e1bd3216cf500e45223415bfca6dc6bdee3 Mon Sep 17 00:00:00 2001 From: sqfmi Date: Fri, 6 May 2022 23:58:07 -0400 Subject: [PATCH 2/3] fix include order --- library.json | 2 +- library.properties | 2 +- src/Watchy.h | 18 +++++++++--------- 3 files changed, 11 insertions(+), 11 deletions(-) diff --git a/library.json b/library.json index be4de92..efe21cf 100644 --- a/library.json +++ b/library.json @@ -1,6 +1,6 @@ { "name": "Watchy", - "version": "1.4.0", + "version": "1.4.1", "description": "Watchy - An Open Source E-Paper Watch by SQFMI", "authors": [ { diff --git a/library.properties b/library.properties index 56da205..5b2d87a 100644 --- a/library.properties +++ b/library.properties @@ -1,5 +1,5 @@ name=Watchy -version=1.4.0 +version=1.4.1 author=SQFMI maintainer=SQFMI sentence=Watchy - An Open Source E-Paper Watch by SQFMI diff --git a/src/Watchy.h b/src/Watchy.h index 4233b49..43fa9ae 100644 --- a/src/Watchy.h +++ b/src/Watchy.h @@ -1,20 +1,20 @@ #ifndef WATCHY_H #define WATCHY_H -#include "BLE.h" -#include "DSEG7_Classic_Bold_53.h" -#include "WatchyRTC.h" -#include "bma.h" -#include "config.h" #include -#include -#include -#include +#include #include #include -#include #include +#include +#include #include +#include +#include "DSEG7_Classic_Bold_53.h" +#include "WatchyRTC.h" +#include "BLE.h" +#include "bma.h" +#include "config.h" typedef struct weatherData { int8_t temperature; From 3e3a8859a94755cc0b7d2de5f189a3de7ccb62e7 Mon Sep 17 00:00:00 2001 From: SQFMI Date: Sat, 7 May 2022 00:06:06 -0400 Subject: [PATCH 3/3] Update README.md --- README.md | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/README.md b/README.md index 2a862a0..ccaa9da 100644 --- a/README.md +++ b/README.md @@ -15,9 +15,8 @@ Visit [**https://watchy.sqfmi.com**](https://watchy.sqfmi.com) for documentation 2. Install this library (search for **Watchy** in the library manager), and any other dependencies when prompted 3. Check out the examples under ```Examples``` -> ```Watchy``` 4. Compile & Upload with these board settings: - * Board: "Watchy" + * Board: "ESP32 Dev Module" * Partition Scheme: "Huge App" - * Board Revision: "Watchy v2.0" (if purchased in 2022) * All Other Settings: leave to default You may also have to install the [CP2104 USB to Serial drivers](https://www.silabs.com/products/development-tools/software/usb-to-uart-bridge-vcp-drivers) if the port is not automatically detected.