lehrkraefte:blc:informatik:ffprg2-2021:twatch:start

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revision Previous revision
Next revision
Previous revision
Next revision Both sides next revision
lehrkraefte:blc:informatik:ffprg2-2021:twatch:start [2021/06/01 15:40]
Ivo Blöchliger
lehrkraefte:blc:informatik:ffprg2-2021:twatch:start [2021/08/17 14:04]
Ivo Blöchliger
Line 1: Line 1:
-====== TTGO TWatch 2020 ======+====== TTGO TWatch 2020 V3 ====== 
 +===== Setup VSCode ===== 
 +  * [[e24laptops|Setup auf den Linux-Laptops aus dem E24]] 
 +  * [[eigenegeraete|Setup auf eigenen Geräten]] 
 +  * [[schulcomputer|Setup auf den Schulcomptern]] 
 + 
 +===== Links und Resourcen ===== 
 Links: Links:
-  * https://github.com/Xinyuan-LilyGO/TTGO_TWatch_Library+  * Library, die wir verwenden: https://github.com/Xinyuan-LilyGO/TTGO_TWatch_Library (naja, eigentlich ein Klon davon, mit aktuellerer lvgl-Library). 
 + 
 +Weitere nennenswerte Projekte und Resourcen
   * https://github.com/SpectralCascade/FancyWatchOS   * https://github.com/SpectralCascade/FancyWatchOS
   * https://github.com/sharandac/My-TTGO-Watch   * https://github.com/sharandac/My-TTGO-Watch
   * https://twatchbuilder.com/   * https://twatchbuilder.com/
 +  * https://www.freertos.org/index.html
 +
 +Weitere TWatch kaufen, z.B. direkt beim Hersteller LilyGo auf [[https://www.aliexpress.com/item/1005002053650442.html|AliExpress]].
 +
 +===== Minimales T-Watch Projekt =====
 +
 +Am einfachsten importieren Sie folgendes git-Repository: https://github.com/techlabksbg/minimal_twatch.git
 +
 +Dieses enthält auch weitere Branches mit Beispielen.
 +
 +==== Manuelles Setup ====
 +
 +  * Neues PIO-Projekt
 +  * Board: TTGO T-WATCH
 +  * Framework: Arduino
 +  * Ändern Sie die Datei platformio.ini wie folgt ab:
 +<hidden platformio.ini>
 +<code txt>
 +[env]
 +platform = espressif32
 +board = ttgo-t-watch
 +framework = arduino
 +monitor_speed = 115200
 +
 +
 +[env:ttgo-t-watch-linux]
 +upload_port = /dev/ttyUSB0
 +
 +[env:ttgo-t-watch-windows]
 +upload_port = COM4
 +
 +[env:ttgo-t-watch-macos]
 +; On the Mac, set the environment variable PLATFORMIO_UPLOAD_PORT 
 +; to your device port, for example as follows:
 +;
 +;          launchctl setenv PLATFORMIO_UPLOAD_PORT /dev/tty.usbserial-0233D4FC
 +</code>
 +</hidden>
 +  * Und das main.cpp:
 +<hidden main.cpp>
 +<code c++>
 +#include <Arduino.h>
 +
 +void setup() {
 +  Serial.begin(115000);
 +}
 +
 +/**
 + * Open the serial monitor to see the output
 + */
 +void loop() {
 +  Serial.println("Hello world!");
 +  delay(1000);
 +}
 +</code>
 +</hidden>
 +
 +===== Neue App =====
 +  * Neuen git-branch anlegen (z.B. motorapp).
 +  * Im Ordner src/app einen neuen Ordner anlegen (z.B. motorapp), dort drin zwei neue Dateien, motorapp.h und motorapp.cpp
 +  * Icon erstellen: 72x72 Pixel, mit Alpha-Channel, konvertieren auf https://lvgl.io/tools/imageconverter 
 +  * Text-Datei abouticon.txt erstellen, mit Informationen zu den Urhebern der Icons
 +  * App Programmieren. Dazu den Code einer einfachen App kopieren und Anpassen (z.B. die motorApp oder die poweroff app).
 +  * App in launcher.h eintragen.
 +  * Testen
 +  * Committen
 +  * Wiederholen. Pullrequest an mich (mündlich oder auf GitHub).
 +
  • lehrkraefte/blc/informatik/ffprg2-2021/twatch/start.txt
  • Last modified: 2021/08/21 21:20
  • by Ivo Blöchliger