Coder Social home page Coder Social logo

t-qt's People

Contributors

lewisxhe avatar lilygo avatar mmmicky 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  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

t-qt's Issues

Displays everything as reversed.

I bought 2 of these T-QTs and was able to get some sketches loaded and working on both of them. Problem is, everything I install on them runs as a reversed mirror image of the actual code. Any idea how or why this happened and how to fix it?

Waking up on right button - doesn't happen.

I see that the right button puts the device to sleep - which works fine.
However I note that esp_sleep_enable_ext0_wakeup is used to set the wake button to the same right button.
This doesn't work either via a build in Arduino (latest regular build) nor in PlatformIO - the device stays off.

I've no idea where the error is, it doesn't look like it's how it's being used here - perhaps Espressifs own code?
I'm just raising this issue for others to know it's a "known issue" - and not this codes fault.

main.cpp:


void go_to_sleep(void) {
  Serial.println("sleep");
  digitalWrite(PIN_LCD_BL, HIGH);
  gpio_hold_en((gpio_num_t)PIN_LCD_BL);
  digitalWrite(PIN_LCD_RES, LOW);
  esp_sleep_enable_ext0_wakeup((gpio_num_t)PIN_BTN_R, 0);
  esp_light_sleep_start();
}

What pins can wake the device.

The pins labelled RTC compatible.

The left button is GPIO 0, and the right is GPIO 47, so I originally thought it wasn't waking due to GPIO47 not being a RTC pin (and thus unable to wake the device) as shown in the article above.
I swapped the pin numbers in pin_config.h, because GPIO 0 IS connected to the RTC. But this failed to wake the device either.

#define PIN_BTN_L            47
#define PIN_BTN_R            0

Missing lv_conf.h

Hi, I just happened to luckily buy the T-Display-S3 at the same time as the T-QT. The T-Display repo has the lv_conf.h in the lib folder, which is missing from this repo.

Error message was:

**TRUNCATED**libraries/lvgl/src/../src/misc/../lv_conf_internal.h:41:18: fatal error: ../../lv_conf.h: No such file or directory
         #include "../../lv_conf.h"                /*Else assume lv_conf.h is next to the lvgl folder*/

Blank Screen

I can upload the following sketch, and the serial monitor works, but nothing displays on the T-QT screen.

#include <TFT_eSPI.h>
TFT_eSPI tft = TFT_eSPI();

void setup()
{
Serial.begin(115200);
tft.init();
tft.fillScreen(TFT_BLACK);
}

void loop()
{
tft.println("Hello World");
Serial.println("Hello World");
delay(1000);
}

esptool, Linux

I am new to ESP32. I cannot use esptool with T-QT device. I am not sure if this is a bug in the T-QT device or esptool. I use Linux Mint 20.3.

$ esptool version
esptool.py v2.8
2.8
$ esptool flash_id
esptool.py v2.8
Found 1 serial ports
Serial port /dev/ttyACM0
Connecting...
/dev/ttyACM0 failed to connect: Write timeout

A fatal error occurred: Could not connect to an Espressif device on any of the 1 available serial ports.

Connection to the device timeouts. When I reset the device with button on the side, serial port /dev/ttyACM0 disappears for a second and esptool crashes:

$ esptool flash_id
esptool.py v2.8
Found 1 serial ports
Serial port /dev/ttyACM0
Connecting....
Traceback (most recent call last):
  File "/usr/bin/esptool", line 3101, in <module>
    _main()
  File "/usr/bin/esptool", line 3094, in _main
    main()
  File "/usr/bin/esptool", line 2885, in main
    esp = ESPLoader.detect_chip(each_port, initial_baud, args.before, args.trace)
  File "/usr/bin/esptool", line 274, in detect_chip
    detect_port.connect(connect_mode)
  File "/usr/bin/esptool", line 475, in connect
    last_error = self._connect_attempt(mode=mode, esp32r0_delay=False)
  File "/usr/bin/esptool", line 453, in _connect_attempt
    self.flush_input()
  File "/usr/bin/esptool", line 389, in flush_input
    self._port.flushInput()
  File "/usr/lib/python3/dist-packages/serial/serialutil.py", line 584, in flushInput
    self.reset_input_buffer()
  File "/usr/lib/python3/dist-packages/serial/serialposix.py", line 595, in reset_input_buffer
    termios.tcflush(self.fd, termios.TCIFLUSH)
termios.error: (5, 'Input/output error')
Error in sys.excepthook:
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/apport_python_hook.py", line 153, in apport_excepthook
    with os.fdopen(os.open(pr_filename,
FileNotFoundError: [Errno 2] No such file or directory: '/var/crash/_usr_share_esptool_esptool.py.1000.crash'

....

When I use the same procedure on some older devices with UART chip, there is no such issue because that UART is not disconnected during device reset; in most cases it is /dev/ttyUSB0 and even esptool can reset device with RST signal...

Any advice? Do I miss something? Can I use esptool utility with T-QT device?

Programming with PlatformIO

In order to program I have to hold reset, hold IO0, release IO0 and release IO0. Then click on the upload icon in PlatformIO to get it to program.

I have a ESPRESSIF ESP32-S3-DevKitC-1 board and I don't have to touch anything. PlatformIO works using the same code

No CC Resistor

Board connecting to USB-C port directly using USB-C to USB-C cable will not receive power.

A fatal error occurred: No serial data received.

After successfully uploading code to my T-QT board multiple times in the past few weeks, it suddenly stopped receiving uploads with a "No serial data received" error. I uploaded the same code with the same cable to an identical board and it works fine. Did I overwork or break the board? Can I recover from this? Here are the details.

Arduino: 1.8.19 (Linux), Board: "ESP32S3 Dev Module, Disabled, QSPI PSRAM, QIO 80MHz, 4MB (32Mb), Core 1, Core 1, Hardware CDC and JTAG, Enabled, Disabled, Disabled, UART0 / Hardware CDC, Default 4MB with spiffs (1.2MB APP/1.5MB SPIFFS), 240MHz (WiFi), 921600, None, Disabled"

Sketch uses 303305 bytes (23%) of program storage space. Maximum is 1310720 bytes.
Global variables use 20220 bytes (6%) of dynamic memory, leaving 307460 bytes for local variables. Maximum is 327680 bytes.
esptool.py v4.5.1
Serial port /dev/ttyACM0
Connecting...
Chip is ESP32-S3 (revision v0.1)
Features: WiFi, BLE
Crystal is 40MHz
MAC: f4:12:fa:a8:d3:e8
Uploading stub...
Running stub...
Stub running...
Changing baud rate to 921600

A fatal error occurred: No serial data received.
A fatal error occurred: No serial data received.

USB MIDI device

Hi, trying to make a USB MIDI device out of this board, but can't seem to make it appear as one using Control-Surface lib

I'm using the dev core arduino 3.0 choosing ESP32S3_USB-OTG

Also tried this example, compiles and uploads fine, but no USB MIDI device

Any hints?

Battery indicator and USB recognition for T-QT Pro

Hello,

I would like to create a battery indicator that also recognizes if the T-QT Pro is plugged in and charging. I've got the code sample from factory.ino which shows voltage from IO4, but that doesn't help recognize if the board is plugged in or not. It also isn't a great indication of battery percentage left since it's nonlinear.

Does anyone have any example code on how to do this?

Hour hand doesn't move as it should... fix included

If you're finding the hour hand in the factory demo to be a bit wonky... here's the fix.

The hour hand doesn't increment in fractions, so if it's 5 to 3, it looks almost like 5 to 2 because the hour hand hasn't moved on!

The fix shows the hour hand correctly positioned between two numbers for half past the hour:

image

The fix adds on the angle of the minutes scaled to 1/12 of a circle to the angle of the hour hand... which is simply multiplying the minutes by 5.

lvgl_gui.cpp

void update_sensor(lv_timer_t *timer) {
  float volt = (analogRead(PIN_BAT_VOLT) * 2 * 3.3) / 4096;
  char buf[20];
  snprintf(buf, 20, "bat_volt:%.2f V", volt);
  lv_label_set_text(bat_label, buf);

  struct tm timeinfo;
  if (getLocalTime(&timeinfo)) {
    // The line that fixes the hour hand.
    lv_img_set_angle(hour_img, ((timeinfo.tm_hour) * 300 + ((timeinfo.tm_min) * 5)) % 3600);
    lv_img_set_angle(min_img, (timeinfo.tm_min) * 60);

Serial Monitor

How do I get the serial monitor to work with PlatformIO?

Using this simple program:

void setup() {
Serial.begin(9600);
}

void loop() {
Serial.printf("Hello World");
delay(3000);
}

I get this:
--- Terminal on COM13 | 9600 8-N-1
--- Available filters and text transformations: colorize, debug, default, direct, esp32_exception_decoder, hexlify, log2file, nocontrol, printable, send_on_enter, time
--- More details at https://bit.ly/pio-monitor-filters
--- Quit: Ctrl+C | Menu: Ctrl+T | Help: Ctrl+T followed by Ctrl+H
waiting for download

Works okay with ESPRESSIF ESP-S3-DevKitC-1 board.

../../lv_conf.h: No such file or directory

I've just run the "factory" example... and I get this:

        from C:\Users\sarah\Documents\Arduino\sketches\T-QT\factory\factory.ino:5:

c:\users\sarah\documents\arduino\libraries\lvgl\src\lv_conf_internal.h:41:18: fatal error: ../../lv_conf.h: No such file or directory
#include "../../lv_conf.h" /Else assume lv_conf.h is next to the lvgl folder/
^~~~~~~~~~~~~~~~~
compilation terminated.

Stuck with this board

Hi, I'm stucked with this board, any help would be appreciate.

I've just bought 2 of thie tiny display from Ali, I've downloadad this repo and just tried to compile any of the samples to no avail.

To focus in one I've tried to compila and download the Arduino_Life proyect.

I've tried in Arduino Ide and in Platform IO with same results (nothing)

In Arduino IDE I just open the Arduino_Life.ino in samples dir. Select "ESP32S3-DevModule" board, select the proper com port and click upload. Everything goes great compiles, upload but, nothing happens. I've reset the device, power cyclo but nothing

If I try the same with platformio. there is a sligth difference, I've copied the esp-32-s3-qt-pro.json file to my boards dir. Then I compila and upload and sometimes it works, somtimes it stops around 40% of the upload.

can someone give a clue or a a project (easy, just "Hello world..") that runs on this device. I must be doing something real wrong, but I'm stuckedd...

Thx on advenac

What settings for factory example?

With the default settings compilation fails with:

Sketch uses 1379037 bytes (105%) of program storage space. Maximum is 1310720 bytes.
Global variables use 41472 bytes (12%) of dynamic memory, leaving 286208 bytes for local variables. Maximum is 327680 bytes.

With Flash Size of 8MB (64 Mb) and Partition Scheme 8M with spiffs the device just crash reboots.

Circuitpython Support - Requested USB PIDs done - Work In Progress

I'm desperately keen to have this board supported in Circuitpython.
I've gone and added USB PID's after noticing the T-EmbedS3 was recently added espressif/usb-pids#80
I've also defined the pins and done a working build, but no display tested yet so still work in progress.

If anyone has a further along repo or wants to contribute or just follow along then feel free.
Due to the GC9107 not being identical to the ST7789, I've not even begun to play with initialisation and it may just require minor tweaks, but I've included some code duplicated from the adafruit reverse s3 tft board. A clear way forwards is to use russhughes repo's for both the T-QT and T-DisplayS3 display drivers in micropython.

https://github.com/tyeth/circuitpython/tree/add-lilygo_ttgo_t-qt

Might save someone else a little time.

Directly Wired Power 24V - Advice about wiring to 5V/3.3V pin

Can I just chuck 5V +/-5% into the 5V pin? I want to power the T-QT Pro from 24V, so was going to use an AP63205 which seems to fit the bill. I would appreciate any advice in this respect. I am aware the 3.3v model may be more appropriate, and could be put into the 3.3V pin probably safely, but I want 5V for other projects so will buy a few and therefore 5volts is more useful.

display backlight doesent remain OFF when deepSleep

Currently Im executing this piece of code:

if (goToSleep) {
//Serial.println("I need to Sleep");
gfx->displayOff();
digitalWrite(TFT_BL, HIGH); // turn OFF
ledcWrite(pwmLedChannelTFT, 255); // brightness 0 - 255
esp_deep_sleep_start();
}

I noticed that the screen backlight turns off brieftly but when the micro sleeps it turn on again (only Back light) i believe is because of the default state of the pin is LOW, is therea a workaround this issue?

The battery will dryout quickly if the BL cannot turn off.

Bought 3 - 0 work

Can someone tell me what the magic is to get these to work? I am using a Mac and tried multiple USB-C cables. None of the units power up or appear available in PIO.

What is the secret?

Build Filesystem Image fails ...

the factory sketch build is OK, but the filsystem build reports error.
Data directory is there and not empty
any ideas?
Here is my output:

Processing T-QT-Pro-N8 (platform: espressif32; board: esp32-s3-t-qt-pro; framework: arduino)
--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------Verbose mode can be enabled via -v, --verbose option
CONFIGURATION: https://docs.platformio.org/page/boards/espressif32/esp32-s3-t-qt-pro.html
PLATFORM: Espressif 32 (6.3.2) > Espressif ESP32-S3-T-QT (4 MB QD, No PSRAM)
HARDWARE: ESP32S3 240MHz, 320KB RAM, 4MB Flash
DEBUG: Current (esp-builtin) On-board (esp-builtin) External (cmsis-dap, esp-bridge, esp-prog, iot-bus-jtag, jlink, minimodule, olimex-arm-usb-ocd, olimex-arm-usb-ocd-h, olimex-arm-usb-tiny-h, olimex-jtag-tiny, tumpa)
PACKAGES:

  • framework-arduinoespressif32 @ 3.20009.0 (2.0.9)
  • tool-esptoolpy @ 1.40501.0 (4.5.1)
  • tool-mkspiffs @ 2.230.0 (2.30)
  • toolchain-riscv32-esp @ 8.4.0+2021r2-patch5
  • toolchain-xtensa-esp32s3 @ 8.4.0+2021r2-patch5
    Converting LVGL_Factory.ino
    LDF: Library Dependency Finder -> https://bit.ly/configure-pio-ldf
    LDF Modes: Finder ~ chain, Compatibility ~ soft
    Found 37 compatible libraries
    Scanning dependencies...
    Dependency Graph
    |-- lvgl @ 8.3.0-dev
    |-- OneButton @ 2.0.3
    |-- WiFi @ 2.0.0
    |-- TFT_eSPI @ 2.5.23
    Building in release mode
    Building FS image from 'data' directory to .pio\build\T-QT-Pro-N8\spiffs.bin
    error: can't read source directory
    *** [.pio\build\T-QT-Pro-N8\spiffs.bin] Error 1

Qwiic connector's pinout is wrong.

The pinout(and The GPIO numbers printed) of the Qwiic connector are wrong, unlike the connections on the schematic.
According to the ESP32-S3 datasheet, U0TXD and GPIO43 and U0RXD and GPIO44 each share a pin.
On the schematic, pin 3 of the Qwiic connector is connected to U0TXD (GPIO43), but printed as 44 on the board and pinout.
I2C tests using the Qwiic connector also worked fine by setting SDA (3pin) to 43 and SCL (4pin) to 44.

I2S interrupt errors

While other S3 and C3 boards seem to work well with am INMP441 mic, it seems to throw interrupt errors with this specific board, regardless what pins I define.

Battery charger

Hi, I have the device with the buttery charger support but I don't see where I can connect the battery.
There is no dedicated plug.

Battery reading while charging & power off

I have attached an on/off switch. I'm unable to get the battery reading when the device is turned off and charging. Here is the behavior:

  1. Not charging & turned on, IO4 reading is correct.
  2. Charging & turned on, IO4 reading is correct.
  3. Charging & turned OFF, IO4 reading shows full battery.

So it looks like IO4 gives me the charging voltage when turned off, not the battery voltage. I need to get the battery voltage so I can display the device charging.

How can I do this?

LVGL_Factory crashes after color displays with error in LV_timer

hi,

it runs 2 sec, then it crashes with error:

Hello T-QT
Chip: ESP32-S3
ChipRevision: 0
Psram size: 0KB
Flash size: 8192KB
[Error] (9.610, +9610) lv_timer_create: Asserted at expression: new_timer != NULL (Out of memory) (in lv_timer.c line #172)

any Idea why your factory file does not work?????
Thx, M

T-QT PRO circuit and charging IC

Hi,

  1. what charging IC is used in PRO version?
  2. What is the charging current limit? I think it should be set to something like 20-30mA. Otherwise, a small battery will not last long.
  3. Can you update the schematic pdf and provide the printed circuit of the PRO version?

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.