Giter VIP home page Giter VIP logo

t-watch-2020's People

Contributors

federicobusero avatar fra4prg avatar guyou avatar wfdudley avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

t-watch-2020's Issues

Unable to compile: OpenWeatherOneCall: no langCode.h

D:\Documents\Arduino\libraries\OpenWeatherOneCall\src/OpenWeatherOneCall.h:25:22: fatal error: langCode.h: No such file or directory
compilation terminated.
exit status 1
Error compiling for board TTGO T-Watch.

Not strictly an error in your code, but can you compile properly? version of OWOC is 3.0.4

Add License

This is a nice project.
But a LICENSE file is missing, helping people to reuse it while following your own choices.

my_tz.cpp:11:8: error: 'ace_time::BasicZoneManager' is not a template

My device is T-watch-2020 v2.
Unable to compile this project, and prompt an error: my_tz.cpp:11:8: error: 'ace_time::BasicZoneManager' is not a template.

 static BasicZoneManager<CACHE_SIZE> manager(
        ^
my_tz.cpp:12:53: error: no matching function for call to 'ace_time::BasicZoneManager::BasicZoneManager(const uint16_t&, const ace_time::basic::ZoneInfo* const [258])'
     zonedb::kZoneRegistrySize, zonedb::kZoneRegistry);
                                                     ^
In file included from C:\Users\81274664\Documents\Arduino\libraries\AceTime\src/AceTime.h:53:0,
                 from C:\Users\81274664\Documents\Arduino\DudleyWatch\my_tz.cpp:3:
C:\Users\81274664\Documents\Arduino\libraries\AceTime\src/ace_time/ZoneManager.h:224:5: note: candidate: ace_time::BasicZoneManager::BasicZoneManager(uint16_t, const ace_time::basic::ZoneInfo* const*, ace_time::BasicZoneProcessorCacheBase&)
     BasicZoneManager(
     ^
C:\Users\81274664\Documents\Arduino\libraries\AceTime\src/ace_time/ZoneManager.h:224:5: note:   candidate expects 3 arguments, 2 provided
C:\Users\81274664\Documents\Arduino\DudleyWatch\play_sound.cpp: In function 'void beep(int8_t)':
play_sound.cpp:64:20: error: 'TWATCH_DAC_IIS_BCK' was not declared in this scope
     out->SetPinout(TWATCH_DAC_IIS_BCK, TWATCH_DAC_IIS_WS, TWATCH_DAC_IIS_DOUT);
                    ^
play_sound.cpp:64:40: error: 'TWATCH_DAC_IIS_WS' was not declared in this scope
     out->SetPinout(TWATCH_DAC_IIS_BCK, TWATCH_DAC_IIS_WS, TWATCH_DAC_IIS_DOUT);
                                        ^
play_sound.cpp:64:59: error: 'TWATCH_DAC_IIS_DOUT' was not declared in this scope
     out->SetPinout(TWATCH_DAC_IIS_BCK, TWATCH_DAC_IIS_WS, TWATCH_DAC_IIS_DOUT);
                                                           ^
exit status 1
'ace_time::BasicZoneManager' is not a template

Do any process I miss to do?

image

below is my config.h
image

Err for dayOfWeek with Lilygo Skin

Thanks for the hard work, the code works fantastic, watch looks good. Only issue I am having is for the Day of week in the Lilygo skin, it shows Err everyday. Cannot get the day of week showing correctly. Date, month, year shows correctly. Cannot find the issue, thanks.

Unable to connect to Wifi

I modified the my_WiFi.h to look like this:

EXTERN WIFIAP AccessPoints[]
#ifdef WIFIMAIN
= {
{ "Guest123", "ThisIsmypassword1", TZ_EST }, // Home
{ "Not Your A10", "thisismypassword2", TZ_EST }, // my phone hotspot
{ "work-ssid", "password4job", TZ_EST }, // my job's WiFi
{ "friend #1 ssid", "pass#2word", TZ_PST }, // friend one's WiFi
{ "2nd friend SSID", "passwo#4rd", TZ_CST }, // friend two's WiFi
{ "dentist-ssid", "pa#5ssword", TZ_EST }, // my dentist's WiFi
{ "\xE9\x93\xAD\xE5\xBE\xB7\xE7\xBE\x8E\xE5\xAE\xB6" "1-2301", "mingde2301", TZ_CHINA }, // an AirBnB in China, kept as example of non-ASCII chars
{ "friend 3 SSID", "passwor#6d", TZ_EST } // friend three's WiFi
}
#endif

Unfortunately, It never connects to wifi. If I tap on 'weather', it finds all nearby access points, including the ones I configured, but it then freezes at this screen. If I tap on 'delete wifi', I see the pre-configured AP's, but not mine. I then changed the MQTT default password to see if it changed, and it didn't. After making the changes, I saved the file, recompiled, and then uploaded. I'm guessing I'm doing something wrong, or need to somehow wipe the watch before uploading?

UPDATE: I erased the T-Watch 2020 using the Espressif tool, and reflashed. Wifi still doesn't connect, but when I go to the menu option to delete wifi, the watch displays "no wifi data file (acc_pts.txt) found!"

Cannot find the implementation of draw_keyboard

Dear William,

I got your code working on my TTGO watch.
It is really great fun and I am making changes to your code so that the watch looks and works the way I want it.

So far, I have fixed the temperature meter (was in the far left of the screen and is now on the coloured scale).
I also increased the font size of the battery stats.

Now I would like to increase the font size of the menu buttons, but I cannot find the place where these buttons are drawn on the screen. I did find the spot where I can change the labels (which will be needed if I finally succeed to increase the font).
I also found the spot where the calculator buttons are drawn on the screen (there the font size is 4, which is OK).
So my question to you is: where can I find the implementation of the blue button menu?

I found this in the header file, but cannot find the implementation of this function.

void draw_keyboard(uint8_t, const char **, uint8_t, bool, char *);

I found out that the third argument is the font size. But what does the bool do? And could I somehow add pictograms instead of text?

Hope you can help me out, since I do not know where to look further.

Kind regards,

Koen.

AceTime compiling error

Hello!

I have a little problem. I am trying to compile the software in Arduino IDE. I have all the neccesary up to date libraries, but the IDE is giving compiling errors. I am using the IDE version 1.8.13 with the latest ESP32 definitions on Win10. I could not solve this issue on my own. Any help or suggestion would be really appreciated. Thank you in advance. Lazlo

AceTime 1.3.0
custom_lib.a(zone_registry.cpp.o):(.rodata._ZN8ace_time6zonedb13kZoneRegistryE+0x42c): undefined reference to `ace_time::zonedb::kZoneWET'
collect2.exe: error: ld returned 1 exit status
exit status 1
Error compiling to TTGO T-Watch .

Or another error with the AceTime-develop library

custom_lib.a(my_tz.cpp.o):(.literal.startup._GLOBAL__sub_I_tz_opts+0x4): undefined reference to `ace_time::zonedb::kZoneRegistry'
collect2.exe: error: ld returned 1 exit status
exit status 1
Error compiling to TTGO T-Watch .

'MY_LANGUAGE' was not declared in this scope

I got the above error message when I tried to upload the version which I downloaded on 12/23/2020. How can I resolve this?

Error messages log:

Arduino: 1.8.13 (Windows 10), Board: "TTGO T-Watch, Enabled, Default (2 x 6.5 MB app, 3.6 MB SPIFFS), 2000000, None"

In file included from C:\Users\Bill\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.4\cores\esp32/WString.h:29:0,

             from C:\Users\Bill\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.4\cores\esp32/Arduino.h:146,

             from sketch\DudleyWatch.ino.cpp:1:

C:\Users\Bill\Documents\Arduino\DudleyWatch\DudleyWatch.ino: In function 'void setup()':

DudleyWatch:240:44: error: 'MY_LANGUAGE' was not declared in this scope

 strcpy_P(general_config.language, PSTR(MY_LANGUAGE));

                                        ^

C:\Users\Bill\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.4\cores\esp32/pgmspace.h:35:24: note: in definition of macro 'PSTR'

#define PSTR(s) (s)

                    ^

Multiple libraries were found for "WiFi.h"

Used: C:\Users\Bill\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.4\libraries\WiFi

Not used: C:\Program Files (x86)\Arduino\libraries\WiFi

Multiple libraries were found for "SD.h"

Used: C:\Users\Bill\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.4\libraries\SD

Not used: C:\Program Files (x86)\Arduino\libraries\SD

exit status 1

'MY_LANGUAGE' was not declared in this scope

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

Step counter reset issues.

I keep the RTC in GMT, so that changing timezones is easy, and you can even have dual timezones displayed. However,
the step counter clears when the RTC rolls over at midnight. This means that at 8PM in the Eastern US time zone, the step counter resets to 0, when using the LilyGoGui watch.

LVGL "7 segment" font is proportional, not fixed spacing.

In the LilyGoGui watch face, the 7 segment font is rendered proportionally, when it should be fixed width spacing. So times with a "1" in them look stupid. One way to fix would be to write each digit individually, so placement could be controlled accurately.

Clear hour/minute/seconds display area before going to sleep

When i activate clock it is usually shows old time (which was at before sleep) and real time will be shown after delay for redraw (half of second or so). This is quite annoying as i have to remember to wait for the screen redraw.

As hotfix i've added ttgo->tft->fillScreen() right before ttgo->displaySleep() in lowEnergy() function but this clears whole screen which is not needed. I think, better way is to clear only box where hour/minute/seconds are displayed and redraw them first, then all other fields but that will require to implement a function in every skin code.

Searching where to disable wake up on accel

I have 8h of autonomy usng the default firmware , but i can clearly see that the wathc is waking up all the time , even when i don't need to look at time . I'm totally of with having to use the push button to look at the time .

I just can't find where you programmed the waking up on accel ?

Compilation Error: Sketch uses 1839173 bytes (140%) of program storage space.

When I compile I get the following error:

"Arduino: 1.8.13 (Windows 10), Board: "TTGO T1, Default 4MB with spiffs (1.2MB APP/1.5MB SPIFFS), 240MHz (WiFi/BT), QIO, 80MHz, 4MB (32Mb), 921600, None"

Sketch uses 1839173 bytes (140%) of program storage space. Maximum is 1310720 bytes.text section exceeds available space in board

Global variables use 116472 bytes (35%) of dynamic memory, leaving 211208 bytes for local variables. Maximum is 327680 bytes.

Sketch too big; see http://www.arduino.cc/en/Guide/Troubleshooting#size for tips on reducing it.

Error compiling for board TTGO T1."

Has anyone else had the same problem ? and how did you fix it. I would be happy to lose some of the extensive range of features but I don't know where to start doing that.

AppWeather: no longer compiles

sketch\appWeather.cpp.o:(.literal._Z10appWeatherv+0x10): undefined reference to `get_loc_city'
sketch\appWeather.cpp.o:(.literal._Z10appWeatherv+0xd0): undefined reference to `get_city_from_lat_long(char*, char*)'
sketch\appWeather.cpp.o: In function `appWeather()':
sketch/appWeather.cpp:234: undefined reference to `get_city_from_lat_long(char*, char*)'

The Bitcoin app works only once, and subsequent attempts result in a DNS resolution error

when using ntptime , everything work fine , and i can launch it multiple time :

best strength = -36, best ssid = Sighq, tz = 506099284
best channel 11, best mac 1a:f6:cf:fd:97:70
铭德美家1-2301 mingde2301 1467951276
NETGEAR Qin32 Gutsmodernraven47 506099284
found SSID we know: Sighq
Connecting to WiFi network: Sighq
password ######## channel 11 mac ##########
Waiting for WIFI connection...
waiting 2 seconds for wifi connection
WiFi connected! IP address: 192.168.43.239
WiFi connected! IP address: 192.168.43.239
Saturday, November 21 2020 12:25:58
printLocalTime(): UTC = 12:25:58 2020/11/21

when using any others app using wifi : i can do it only once ( ex bitcoin app ) :

tzonestr = 506099284
best strength = -35, best ssid = Sighq, tz = 506099284
best channel 11, best mac 1a:f6:cf:fd:97:70
铭德美家1-2301 mingde2301 1467951276
NETGEAR Qin32 Gutsmodernraven47 506099284
found SSID we know: Sighq
Connecting to WiFi network: Sighq
password ######## channel 11 mac #########
Waiting for WIFI connection...
WiFi connected! IP address: 192.168.43.239
WiFi connected! IP address: 192.168.43.239
WiFi connected! IP address: 192.168.43.239

the next time another time :

Waiting for WIFI connection...
[E][WiFiGeneric.cpp:654] hostByName(): DNS Failed for api.coindesk.com
WiFi connected! IP address: 192.168.43.239
WiFi connected! IP address: 192.168.43.239

The only way to be able to start any wifi app without having this dns error is to start the ntptime before , look like it reset something that the others app don't ..

WiFi.onEvent(WiFiEvent); should only be called once

Each time the app 'NTP Time' or 'Weather' is executed, WiFi.onEvent(WiFiEvent); is executed, but this should only be called once at setup time. If the app NTP time has been opended 10 times, a wifi connection that is created will result in 10x calling the function WiFiEvent, which can be seen on the debug window: you will see 10 times

WiFi connected! IP address: ...

Missing AceTime.h

When I tried to compile, I got an error message. I also got a bunch of Multiple Libraries warnings. I suspect the multiple libraries were due to my trying to install other versions of the watch programs. I can delete the multiple libraries but where do I get the AceTime.h?

Arduino: 1.8.10 (Windows 10), Board: "TTGO T-Watch, Enabled, Default (2 x 6.5 MB app, 3.6 MB SPIFFS), 2000000, None"

DudleyWatch:26:21: error: AceTime.h: No such file or directory

compilation terminated.

Multiple libraries were found for "SPIFFS.h"
Used: C:\Users\Bill\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.4\libraries\SPIFFS
Multiple libraries were found for "WiFi.h"
Used: C:\Users\Bill\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.4\libraries\WiFi
Not used: C:\Program
Multiple libraries were found for "LilyGoWatch.h"
Used: C:\Users\Bill\Documents\Arduino\libraries\TTGO_TWatch_Library-master
Multiple libraries were found for "SPI.h"
Used: C:\Users\Bill\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.4\libraries\SPI
Multiple libraries were found for "Ticker.h"
Used: C:\Users\Bill\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.4\libraries\Ticker
Multiple libraries were found for "Wire.h"
Used: C:\Users\Bill\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.4\libraries\Wire
Multiple libraries were found for "FS.h"
Used: C:\Users\Bill\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.4\libraries\FS
exit status 1
AceTime.h: No such file or directory

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

Having trouble compiling

Getting the following errors when attempting to compile...

Arduino: 1.8.13 (Linux), Board: "TTGO T-Watch, Enabled, Default (2 x 6.5 MB app, 3.6 MB SPIFFS), 2000000, None"

sketch/SPIFF_fns.cpp: In function 'void build_acc_pts_file()':
SPIFF_fns.cpp:189:25: error: 'sizeof_Access_Points' was not declared in this scope
     for(int i = 0 ; i < sizeof_Access_Points ; i++) {
                         ^
sketch/SPIFF_fns.cpp: In function 'int read_acc_pts_file_and_compare_with_SSIDs(WiFiAp*)':
SPIFF_fns.cpp:230:27: error: 'number_of_networks' was not declared in this scope
       for (int i = 0; i < number_of_networks; ++i) {
                           ^
Multiple libraries were found for "WiFi.h"
 Used: /home/XXXX/.arduino15/packages/esp32/hardware/esp32/1.0.4/libraries/WiFi
 Not used: /opt/arduino-1.8.13/libraries/WiFi
Multiple libraries were found for "SD.h"
 Used: /home/XXXX/.arduino15/packages/esp32/hardware/esp32/1.0.4/libraries/SD
 Not used: /opt/arduino-1.8.13/libraries/SD
exit status 1
'sizeof_Access_Points' was not declared in this scope

This report would have more information with
"Show verbose output during compilation"
option enabled in File -> Preferences.

get_location.cpp doesn't compile

sketch\get_location.cpp: In function 'int get_city_from_lat_long(char*, char*)':
get_location.cpp:168:94: error: 'LOCATIONIQ_KEY' was not declared in this scope
   sprintf(url, "https://us1.locationiq.com/v1/reverse.php?key=%s&format=json&lat=%s&lon=%s", LOCATIONIQ_KEY, latitude, longitude);

...

'LOCATIONIQ_KEY' was not declared in this scope

Uploading error.

Hello i have all the same libraries as in your list and that from other sites. I can upload Dan code that this was based off of. however i get a error when trying to upload. Error is below. I never saw any of theses errors before.

Invalid library found in C:\Users\jJcSystems\Documents\Arduino\libraries\TTGO-T-Watch-master: no headers files (.h) found in C:\Users\jJcSystems\Documents\Arduino\libraries\TTGO-T-Watch-master In file included from C:\Users\jJcSystems\Documents\Arduino\libraries\T-watch-2020\DudleyWatch\DudleyWatch.ino:33:0: C:\Users\jJcSystems\Documents\Arduino\libraries\T-watch-2020/DudleyWatch.h:44:8: error: 'RTC_Date' does not name a type EXTERN RTC_Date tnow; ^ C:\Users\jJcSystems\Documents\Arduino\libraries\T-watch-2020/DudleyWatch.h:130:8: error: 'TFT_eSPI' does not name a type EXTERN TFT_eSPI *tft; ^ C:\Users\jJcSystems\Documents\Arduino\libraries\T-watch-2020/DudleyWatch.h:131:8: error: 'AXP20X_Class' does not name a type EXTERN AXP20X_Class *power; ^ C:\Users\jJcSystems\Documents\Arduino\libraries\T-watch-2020/DudleyWatch.h:231:8: error: 'TTGOClass' does not name a type EXTERN TTGOClass *ttgo; ^ C:\Users\jJcSystems\Documents\Arduino\libraries\T-watch-2020\DudleyWatch\DudleyWatch.ino: In function 'void update_step_counter()': DudleyWatch:47:18: error: 'ttgo' was not declared in this scope step_counter = ttgo->bma->getCounter(); ^ C:\Users\jJcSystems\Documents\Arduino\libraries\T-watch-2020\DudleyWatch\DudleyWatch.ino: In function 'void resetStepCounter()': DudleyWatch:51:3: error: 'ttgo' was not declared in this scope ttgo->bma->resetStepCounter(); ^ C:\Users\jJcSystems\Documents\Arduino\libraries\T-watch-2020\DudleyWatch\DudleyWatch.ino: In function 'void bright_check()': DudleyWatch:57:7: error: 'power' was not declared in this scope if (power->isVBUSPlug()) { ^ DudleyWatch:66:5: error: 'ttgo' was not declared in this scope ttgo->setBrightness(screen_brightness); // 0-255 ^ C:\Users\jJcSystems\Documents\Arduino\libraries\T-watch-2020\DudleyWatch\DudleyWatch.ino: In function 'void low_energy()': DudleyWatch:78:9: error: 'ttgo' was not declared in this scope if (ttgo->bl->isOn()) { ^ DudleyWatch:95:53: error: 'AXP202_INT' was not declared in this scope erret = gpio_wakeup_enable ((gpio_num_t)AXP202_INT, GPIO_INTR_LOW_LEVEL); ^ DudleyWatch:99:53: error: 'BMA423_INT1' was not declared in this scope erret = gpio_wakeup_enable ((gpio_num_t)BMA423_INT1, GPIO_INTR_HIGH_LEVEL); ^ DudleyWatch:135:35: error: 'lv_disp_trig_activity' was not declared in this scope lv_disp_trig_activity(NULL); ^ C:\Users\jJcSystems\Documents\Arduino\libraries\T-watch-2020\DudleyWatch\DudleyWatch.ino: In function 'void Serial_timestamp()': DudleyWatch:179:29: error: 'ttgo' was not declared in this scope Serial.printf("%s UTC\n", ttgo->rtc->formatDateTime()); ^ C:\Users\jJcSystems\Documents\Arduino\libraries\T-watch-2020\DudleyWatch\DudleyWatch.ino: In function 'void setup()': DudleyWatch:213:16: error: 'EEPROM_SIZE' was not declared in this scope EEPROM.begin(EEPROM_SIZE); ^ DudleyWatch:253:3: error: 'ttgo' was not declared in this scope ttgo = TTGOClass::getWatch(); ^ DudleyWatch:253:10: error: 'TTGOClass' has not been declared ttgo = TTGOClass::getWatch(); ^ DudleyWatch:255:3: error: 'tft' was not declared in this scope tft = ttgo->tft; // just a shorthand for ttgo->tft ^ DudleyWatch:256:3: error: 'power' was not declared in this scope power = ttgo->power; // just a shorthand for ttgo->power ^ DudleyWatch:258:19: error: 'TFT_BLACK' was not declared in this scope tft->fillScreen(TFT_BLACK); ^ DudleyWatch:259:21: error: 'TFT_YELLOW' was not declared in this scope tft->setTextColor(TFT_YELLOW, TFT_BLACK); // Note: the new fonts do not draw the background colour ^ DudleyWatch:264:21: error: 'AXP202_BATT_VOL_ADC1' was not declared in this scope power->adc1Enable(AXP202_BATT_VOL_ADC1 | AXP202_BATT_CUR_ADC1 | AXP202_VBUS_VOL_ADC1 | AXP202_VBUS_CUR_ADC1, AXP202_ON); ^ DudleyWatch:264:44: error: 'AXP202_BATT_CUR_ADC1' was not declared in this scope power->adc1Enable(AXP202_BATT_VOL_ADC1 | AXP202_BATT_CUR_ADC1 | AXP202_VBUS_VOL_ADC1 | AXP202_VBUS_CUR_ADC1, AXP202_ON); ^ DudleyWatch:264:67: error: 'AXP202_VBUS_VOL_ADC1' was not declared in this scope power->adc1Enable(AXP202_BATT_VOL_ADC1 | AXP202_BATT_CUR_ADC1 | AXP202_VBUS_VOL_ADC1 | AXP202_VBUS_CUR_ADC1, AXP202_ON); ^ DudleyWatch:264:90: error: 'AXP202_VBUS_CUR_ADC1' was not declared in this scope power->adc1Enable(AXP202_BATT_VOL_ADC1 | AXP202_BATT_CUR_ADC1 | AXP202_VBUS_VOL_ADC1 | AXP202_VBUS_CUR_ADC1, AXP202_ON); ^ DudleyWatch:264:112: error: 'AXP202_ON' was not declared in this scope power->adc1Enable(AXP202_BATT_VOL_ADC1 | AXP202_BATT_CUR_ADC1 | AXP202_VBUS_VOL_ADC1 | AXP202_VBUS_CUR_ADC1, AXP202_ON); ^ DudleyWatch:265:20: error: 'AXP202_VBUS_REMOVED_IRQ' was not declared in this scope power->enableIRQ(AXP202_VBUS_REMOVED_IRQ | AXP202_VBUS_CONNECT_IRQ | AXP202_CHARGING_FINISHED_IRQ, AXP202_ON); ^ DudleyWatch:265:46: error: 'AXP202_VBUS_CONNECT_IRQ' was not declared in this scope power->enableIRQ(AXP202_VBUS_REMOVED_IRQ | AXP202_VBUS_CONNECT_IRQ | AXP202_CHARGING_FINISHED_IRQ, AXP202_ON); ^ DudleyWatch:265:72: error: 'AXP202_CHARGING_FINISHED_IRQ' was not declared in this scope power->enableIRQ(AXP202_VBUS_REMOVED_IRQ | AXP202_VBUS_CONNECT_IRQ | AXP202_CHARGING_FINISHED_IRQ, AXP202_ON); ^ DudleyWatch:269:25: error: 'AXP202_EXTEN' was not declared in this scope power->setPowerOutPut(AXP202_EXTEN, AXP202_OFF); ^ DudleyWatch:269:39: error: 'AXP202_OFF' was not declared in this scope power->setPowerOutPut(AXP202_EXTEN, AXP202_OFF); ^ DudleyWatch:270:25: error: 'AXP202_DCDC2' was not declared in this scope power->setPowerOutPut(AXP202_DCDC2, AXP202_OFF); ^ DudleyWatch:271:25: error: 'AXP202_LDO3' was not declared in this scope power->setPowerOutPut(AXP202_LDO3, AXP202_OFF); // audio device ^ DudleyWatch:272:25: error: 'AXP202_LDO4' was not declared in this scope power->setPowerOutPut(AXP202_LDO4, AXP202_OFF); ^ DudleyWatch:283:11: error: 'BMA423_INT1' was not declared in this scope pinMode(BMA423_INT1, INPUT); ^ DudleyWatch:304:11: error: 'AXP202_INT' was not declared in this scope pinMode(AXP202_INT, INPUT); ^ C:\Users\jJcSystems\Documents\Arduino\libraries\T-watch-2020\DudleyWatch\DudleyWatch.ino: In function 'void loop()': DudleyWatch:392:12: error: 'ttgo' was not declared in this scope rlst = ttgo->bma->readInterrupt(); ^ DudleyWatch:397:2: error: 'power' was not declared in this scope power->readIRQ(); ^ DudleyWatch:425:12: error: 'ttgo' was not declared in this scope rlst = ttgo->bma->readInterrupt(); ^ DudleyWatch:428:8: error: 'ttgo' was not declared in this scope if (ttgo->bma->isStepCounter()) { ^ DudleyWatch:434:2: error: 'power' was not declared in this scope power->readIRQ(); ^ DudleyWatch:539:7: error: 'ttgo' was not declared in this scope ttgo->tft->fillScreen(TFT_BLACK); ^ DudleyWatch:539:29: error: 'TFT_BLACK' was not declared in this scope ttgo->tft->fillScreen(TFT_BLACK); ^ DudleyWatch:540:7: error: 'tft' was not declared in this scope tft->setTextSize(1); ^ Multiple libraries were found for "WiFi.h" Used: C:\Users\jJcSystems\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.4\libraries\WiFi Not used: C:\Program Files (x86)\Arduino\libraries\WiFi Multiple libraries were found for "SD.h" Used: C:\Users\jJcSystems\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.4\libraries\SD Not used: C:\Program Files (x86)\Arduino\libraries\SD Multiple libraries were found for "Ethernet.h" Used: C:\Users\jJcSystems\Documents\Arduino\libraries\Ethernet Not used: C:\Program Files (x86)\Arduino\libraries\Ethernet exit status 1 'ttgo' was not declared in this scope

Joseph

unable to push a new branch

modfiles.zip
Hello Bill,

first of all thank you for this great project.
It’s the best T-Watch I found so far.

I made some additions to the stop watch and I would appreciate if you could merge this into your project.
Please apologise, I'm new to Github and it was a nightmare to configure everything but I still get an error when I try to push my branch: "remote:Permission to wfdudley/T-watch-2020.git denied to Fra4prg..."
I don't know: Isn't it allowed to submit a branch to a foreign project?
How else could I submit my proposal?
I added my changed/added files here as modfiles.zip. All changes are marked with the comment // Fra4prg:

Description of my changes:
Added "Smart Sound" option ("HeliTimer")
"Smart Sound" enables you to hear the number of minutes without having to look on the display.
The idea behind this is that human brain can identify the number of 3 beeps as triple without counting them even if they are very short and fast.
So up to 3 beeps are played slowly and preceeding triples are faster.
For every 10 minutes a sweep sound is preceeding.
A new top left button switches modes between [no sound] - [vibration + sound] - [only sound]

Some examples to show the sequence:
Minute 1: C5
Minute 2: C5-E5
Minute 3: C5-E5-G5
Minute 4: triple - C5
Minute 5: triple - C5-E5
...
Minute 9: triple - triple - C5-E5-G5
Minute 10: sweep
...
Minute 18: sweep - triple - triple - C5-E5
and so on...

As you can see this works well for short times up to 10 minutes then it gets weird...
The idea came up when I was flying model helicopters where I had to control the flight time due to small batteries and must not loose visual contact to my heli model.
So I made a small Arduino based timer called HeliTimer.
But this function fits perfect to the T-watch :-)

Got my first issue

Hello i have i have tried to follow everything you wrote to the letter. however i get this error.

`In file included from C:\Users\jJcSystems\Documents\Arduino\libraries\AceTime-develop\src/AceTime.h:20:0,
from C:\Users\jJcSystems\Documents\Arduino\libraries\T-watch-2020-master\DudleyWatch\DudleyWatch.ino:26:
C:\Users\jJcSystems\Documents\Arduino\libraries\AceTime-develop\src/ace_time/common/compat.h:78:25: fatal error: AceCommon.h: No such file or directory
compilation terminated.

Multiple libraries were found for "WiFi.h"
Used: C:\Users\jJcSystems\AppData\Local\Arduino15\packages\esp32\hardware\esp32\1.0.4\libraries\WiFi
Not used: C:\Users\jJcSystems\Desktop\Bakup\12-24-2020\Desktop\arduino-1.8.3\libraries\WiFi
exit status 1
Error compiling for board TTGO T-Watch.`

Joseph

appWeather.cpp units

Hi,
As I am using centigrade I noticed a few issues with the weather app module.
Formatting and units mostly.

Just a few lines to change to correct this so listing them below:

378
-	tft->printf("%.0f %c hi %.0f lo",
+	tft->printf("%.0f %c hi %.0f %c lo",

381
-	  OWOC.forecast[0].temperatureLow
+	  OWOC.forecast[0].temperatureLow,temp_unit

435
-	  tft->printf("%.0f F hi", OWOC.forecast[fo].temperatureHigh);
+	  tft->printf("%.0f %c hi", OWOC.forecast[fo].temperatureHigh,temp_unit);

438
-	  tft->printf("%.0f F lo", OWOC.forecast[fo].temperatureLow);
+	  tft->printf("%.0f %c lo", OWOC.forecast[fo].temperatureLow, temp_unit);

525
-	  tft->printf("%.0f F hi", OWOC.forecast[fo].temperatureHigh);
+	  tft->printf("%.0f %c hi", OWOC.forecast[fo].temperatureHigh, temp_unit);
 
528	
-	  tft->printf("%.0f F lo", OWOC.forecast[fo].temperatureLow);
+	  tft->printf("%.0f %c lo", OWOC.forecast[fo].temperatureLow, temp_unit);

Unable to compile RTC_INT undefined

There are a lot of mentions of RTC_INT in the code, but it's not defined anywhere. Which gpio is it?

exit status 1
'RTC_INT' was not declared in this scope
  attachInterrupt(RTC_INT, [] {
      rtcIrq = 1;
      BaseType_t xHigherPriorityTaskWoken = pdFALSE;
      EventBits_t  bits = xEventGroupGetBitsFromISR(isr_group);
      if (bits & WATCH_FLAG_SLEEP_MODE)
      {
	  //! For quick wake up, use the group flag
	  xEventGroupSetBitsFromISR(isr_group, WATCH_FLAG_SLEEP_EXIT | WATCH_FLAG_AXP_IRQ, &xHigherPriorityTaskWoken);
      } else
      {
	  uint8_t data = Q_EVENT_AXP_INT;
	  xQueueSendFromISR(g_event_queue_handle, &data, &xHigherPriorityTaskWoken);
      }
      if (xHigherPriorityTaskWoken)
      {
	  portYIELD_FROM_ISR ();
      }
  }, FALLING);```

Gestures are broken & other things

Hi, maybe I've gotten something very wrong here, but this project doesn't seem to work to me. I was able to build and flash using the Arduino IDE after changing the name of the folder to "DudleyWatch" and installing the following libraries:

https://github.com/Xinyuan-LilyGO/TTGO_TWatch_Library
https://github.com/bxparks/AceTime
https://github.com/Bodmer/TFT_eSPI
https://github.com/bxparks/AceCommon
https://github.com/bblanchon/ArduinoJson
https://github.com/arduino-libraries/Ethernet
https://github.com/knolleary/pubsubclient/
https://github.com/earlephilhower/ESP8266Audio

That's where my problems started. None of the given gestures seem to work for me. I seem to have access to only two things:
(1) the MQTT app (which is proceeded by a "scan networks" page which does seem able to connect to my wifi), accessed by swiping in any direction on the home screen
(2) the settings app, accessed by CCW rotation

I can't seem to launch the app select screen reliably - most of the time, it opens the MQTT app instead. I was able to bring it up once, but have not been able to repeat. Also, fonts seem to be messed up on the display - non-half-height lines overlap with each other. My timezone info seems to be ignored (assumes I'm in Perth). Finally, the time did not seem to sync from NTP the one time I was able to run the NTP sync app.

Am I just bad at swiping? :P

Edit: here's the output of a two fast near-vertical swipes down with DEBUG_GESTURES 1

i = 100, p = 252
max_lrud[] = 110, 120, 1, 239
pts_lrud[] = 232, 1, 2, 233
x0 = 120, x = 110, xdir = -10
y0 = 1, y = 239, ydir = 238, amax = 238
maybe a circle
max_order[4] = 1, 2, 0, 3
dir_order = RULDRULD
found CCW CIRCLE
ccw circle

i = 100, p = 427
max_lrud[] = 99, 104, 5, 239
pts_lrud[] = 0, 407, 2, 408
x0 = 99, x = 104, xdir = 5
y0 = 5, y = 239, ydir = 234, amax = 234
maybe a circle
max_order[4] = 0, 2, 1, 3
dir_order = LURDLURD
found CW CIRCLE
cw circle

here's a slow vertical swipe down (which is not recognized at all?):

i = 100, p = 1356
max_lrud[] = 134, 149, 11, 239
pts_lrud[] = 0, 1336, 2, 1337
x0 = 134, x = 149, xdir = 15
y0 = 11, y = 239, ydir = 228, amax = 228
maybe a circle
max_order[4] = 0, 2, 2, 2
dir_order = LUUULUUU

here's what it looks like when I try to draw a CW circle (up, right, down, left):

i = 100, p = 1339
max_lrud[] = 37, 201, 69, 207
pts_lrud[] = 1321, 887, 471, 3
x0 = 75, x = 37, xdir = -38
y0 = 207, y = 195, ydir = -12, amax = 38
maybe a circle
max_order[4] = 3, 2, 1, 1
dir_order = DURRDURR

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.