Giter Site home page Giter Site logo

jeffmer / ttgo-t-watch-2020-micropython-os Goto Github PK

View Code? Open in Web Editor NEW
18.0 5.0 5.0 3.54 MB

All micropython watch software for TTGO T-watch 2020 V1, V2 & V3

License: The Unlicense

Python 98.94% Shell 1.06%
ttgo-watch2020 micropython t-watch-2020

ttgo-t-watch-2020-micropython-os's People

Contributors

devnoname120 avatar jeffmer avatar thiswillbeyourgithub avatar

Stargazers

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

Watchers

 avatar  avatar  avatar  avatar  avatar

ttgo-t-watch-2020-micropython-os's Issues

weather app suggestion

Hi, just wanted to talk about a project I love :
simply open a terminal and do curl v2.wttr.in and you get a nice weather report :
image
Customization exist to parse the weather finely and to adapt to any device.

Link to the full project: https://github.com/chubin/wttr.in

I just thought it would be better than the current weather app which is slow to install (needs pictures) and does not contain that many information whil also needing an API key.

Stuck on "Loading..."

Hello,

I followed all of your instructions explicitly - both on Windows (WSL) then on a native Ubuntu box. Both times I just got to the initial 'Loading' screen but nothing is happening beyond that. I have a Version 2 T-watch and I'm sure the configuration file is set up correctly. When I go to the Repl in Thonny I can also see all of the .mpy files there in the correct structure (I think) too.

I willy try running TempOS from the Repl rather than boot.py. But before I do could you please tell me if I may be missing something or where to start to look beyond the Repl/execute TempOS steps please?

With thanks.

Unable to play audio on the Lilygo T-Watch 2020 V3

This is a great project and I really like how easy it is to add custom watch faces, apps and utils.

However, I appear to be unable to play audio on the Lilygo T-Watch 2020 V3 via the MAX98357.

I have tried various options, without succes.
Also when I run misc/play_tone.py, no sound is being produced.

Is this a known issue?
Or is my unit perhaps defective?

Possible mpy-cross / mpy issue?

This project looks exciting, but I'm failing to get it to work on my T-watch.

Installed the firmware successfully, using Thonny as suggested (nb I'm on a Mac). Incidentally, this ends up with a boot.py file visible on the device, with all of the lines commented out.

Edited config.py to add network and OpenWeatherMap keys.

Went to compile the code, realised that the compile.sh points to a local copy of mpy-cross, so edited it:

#CROSS="/home/jeff/pico/micropython/mpy-cross/build/mpy-cross -march=xtensawin"
CROSS="/opt/homebrew/bin/mpy-cross -march=xtensawin"

This then compiles the .mpy files. I have the latest MicroPython 1.19.1 from homebrew installed, but that may not be the same version as the "dirty" / newer build from the firmware binary now on the watch?

Went to install the files, realised I needed to adapt the script to use the correct USB device on my machine, did that, installed - nothing happened. Connected Thonny and noticed that boot.py did not contain the launcher call mentioned in the README; tried to import launcher in the REPL, but got an error about the mpy version being incorrect.

Then, realised that it had not copied over the boot.py file (the line in install.sh is edited out, and anyway, the file already existed); so, cleared the LittleFS, uncommented the line in install.sh, and ran it again. Still no response after a reset.

Now, import launcher in the REPL returns without any obvious change (I'm guessing because boot.py is failing to load it, so at that point, MicroPython already decided that's done).

Any thoughts? I'd love to try this out! How can I help to improve things for anyone else who wants to try it?

OSM Tiles not displaying

Hello,

Unfortunately OSM tiles aren't displaying at all in the app. I have a version 2 T-watch. The app displays that it connects (to a server?) then appears to count something but no data is displayed. Could you please tell me how I can begin to debug this?

With thanks and best wishes.

mpy-cross reports invalid syntax in wifi.py, line 26

mpy-cross reports a syntax error in wifi.py, line 26:

mpy-cross -march=xtensawin ./wifi.py
Traceback (most recent call last):
File "./wifi.py", line 26
SyntaxError: invalid syntax

wifi.py contains an 'else' statement following an 'else' statement.

Looking at the code, lines 26 and 27 need to be removed.

T-watch-2020 V3 not starting

Hi,

I uploaded everything like readme says, but:

`MicroPython v1.22.0-preview.21.g4074f828d.dirty on 2023-10-16; Generic ESP32 module with SPIRAM with ESP32
Type "help()" for more information.

import loader
Traceback (most recent call last):
File "", line 1, in
File "./loader.py", line 2, in
File "./tempos.py", line 3, in
File "./drivers/st7789.py", line 16, in
ValueError: incompatible .mpy file
`

How do you set rtc

Hi,

On my setup running mpremote a0 setrtc seems to only make the watch instantly reboot so I'm looking for straightforward ways to set the actual time automatically after a flash.

Do you have any scripts to share?

Thanks

Proposal : ecosytem harmonization

Hi!

As I said earlier, I'm quite familiar with wasp-os on the Pinetime from Pine64. It's arguably the most successful micropython os on a hackable watch (albeit not that successful, it's quite niche :) ) so I think harmonizing some parts of the code to reduce the cost to port apps between them is not a bad idea.

Wasp-OS has some great features like :

  • a simulator to quickly create apps without having to send them to the watch
  • extensive documentation
  • multiple watch support (all based on the same chip)
  • a neat way to install apps as frozen bytecode or mpy or python (the storage space is way smaller)
  • An app launcher as well as useful widgets (a "top bar" that displays the time and notifications like on android etc)
  • a settings app

You can give it a go right away on your computer by cloning their repo then running make sim in the root. This will launch the simulator.

Before porting my own apps here's what I explored so far:

  1. Out of principle I looked at porting wasp os on the twatch directly. It looks very dooable because AFAIU the main hurdle is getting micropython working and the display is the same as on waspos. But I frankly lack the skills to pull this off and have many more things on my plate so that was mostly out of curiosity.
  2. I looked at adding the simulator to this repo. The code is actually quite simple and clever and it looks way easier than porting the OS. But I also lack the knowledge to understand a good part of the low level of both repo so I also can't pull it off. But frankly this looks easy if someone is interested, it's basically highjacking the PYTHONPATH to load local fake modules like micropython, machine, time etc and displaying in a window using sdl2.
  3. Harmonizing the code architecture. The separation between tempos.py, scheduler.py is not really the same as on waspos so overhauling all of this was too much for too little IMO.
  4. See below

Here's where I'm at now. I think harmonizing the "API" is what yields the most without hurting the authenticity of this repo and allowing to port apps more easily. By that I mean for example renaming the "g" module to "display", renaming the "setInterval" to waspos's alternative etc.

Here would be the tentative roadmap:

  1. renaming the simple stuff like g, setInterval, ticks handling, etc
  2. changing lightly the application life cycle to align more with the one from waspos (i.e. changing app_init by foreground etc)
  3. adding docstrings to all functions.
  4. Harmonizing the widgets API and adding more widgets
  5. adding a central "launcher app" that is triggered when escaping from an app, and allows to swipe to other apps. This would be nicer I believe.

What do you think @jeffmer ? I think it would bring more apps to your OS, increase the visibility to your OS as well as to the twatch (which is incredible but not enough loved!) and be a good thing overall : 2 projects with a common API increase chances of more future watches aligning with this instead of having 3 standards :).

The goal is not to do a major overhaul of the code of course, but just to make it share the same language as waspos.

Can't wait to have your take on this :)

ps : wasp-os is also available on a few other watches, see their great doc

Project name

Hi,

I was wondering what was the name of the project. "TTGO-T-watch-2020-Micropython-OS" is more of a description than a name IMHO :)

Is it tempos? Or does that just mean "temporary os"?

Thanks

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.