xinyuan-lilygo / t-qt Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
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?
Hi, I have noticed that a lot of stores offer a "T-QT Pro" version instead of V1.1.
The only difference I could find is this image:
https://ae01.alicdn.com/kf/S24bd6ed3ecd24f09878124b287e865efs.jpg_640x640Q90.jpg_.webp
Is there an updated repository for the Pro version?
What does "support charging" mean? Does it allow LiPo charging?
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
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*/
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);
}
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?
What happened?
We've got the code here, (thanks!) but the device is no longer available. =(
hi,i want to build this under esp-idf
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
Hi,
why is gpio 19 and 20 in pin reference documentation marked as "do not use"?
I would like to pass uart on those pins using usb-c connector, is that a problem?
Board connecting to USB-C port directly using USB-C to USB-C cable will not receive power.
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.
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?
Is the Backlight adjustable? If so could you give a example.
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?
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:
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);
Hi, Arduino ide can not load your boards package :
https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pagespackage_esp32_index.json
This url leads to 400: Invalid request page
What is the correct url?
Thanks
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.
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.
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
How can I change the colors of the clock? Background, hands etc.?
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.
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.
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.
Which pins should be used for I2C , is there any pre-defined ?
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.
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?
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:
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.
can it be used with ESP-IDF?
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.
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.
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:
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?
hi,
any Idea why your factory file does not work?????
Thx, M
Hi,
Thanks.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.