Giter Club home page Giter Club logo

lilygo-epd47's Introduction

๐ŸŒŸLilyGo EPD47 ๐ŸŒŸ

Documentation

You can use the T5-4.7 & T5-4.7 Plus Online Documentation to get all information about this project.

Quick Start

  • Install the Arduino IDE. Note: Later instructions may not work if you use Arduino via Flatpak.
  • Install the latest espressif/arduino-esp32 package in the IDE, version >= 1.05
  • Download a zipfile from github using the "Download ZIP" button and install it using the IDE ("Sketch" -> "Include Library" -> "Add .ZIP Library...", OR:
  • Clone this git repository into your sketchbook/libraries folder. For more info, see https://www.arduino.cc/en/Guide/Libraries
  • Choose ESP32 Dev Module for the board
  • Tools -> PSRAM -> Enable
  • ("File" -> "Examples" -> "LilyGoEPD47" -> "demo") in the Arduino IDE
  • Select the correct port and click upload
  • Please refer to Script Instructions for picture and text generation

Required

arduino-esp32 needs to be upgraded to 2.0.3 version to support ESP32-S3.

To upgrade the existing development environment, please refer to the following methods:

$ pwd
/c/Users/lyy/Documents/Arduino
$ cd hardware/espressif/esp32/
$ git checkout 2.0.3
$ git submodule update

Related Projects

FAQ

  1. Which GPIOs are left for free use?

    IO12. If the touch screen is not used, there are also IO12, IO13, IO14 and IO15 which can be used freely. IO0 has been used and cannot be programmed.

  2. How to turn off the blue LED light?

    To turn off the blue LED, you must call epd_poweroff_all(), which will turn off the entire power supply controlled by PWM_EN. Note that it cannot be turned off when powered by USB. It can only be turned off when powered by battery. For details, refer to examples/demo

  3. How to fix afterimages?

    Please upload examples/screen_repair to try to remove afterimages. It is not 100% able to remove afterimages.

lilygo-epd47's People

Contributors

elementw avatar hpsaturn avatar idanov avatar johnwargo avatar lbuque avatar lewisxhe avatar lilygo avatar marsjan155 avatar mmmicky avatar puboy7 avatar windows98pro 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  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  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

lilygo-epd47's Issues

Deep-sleep and button

Is it possible to add documentation or example about having a button awaken the device from deep sleep mode?

My idea: having the device displaying an information refreshed only once an hour (or two). So, it is mostly in deep-sleep mode.
When I click a button, the device awakes, changes its display mode (other information) and refresh.

Disable the blue LED

Is there a way to disable the blue led on the back? I would like to rung the board in deep sleep, but the led stays on even in deep sleep.

Load Image from URL

Hi!
I have a project in mind with the Spotify API. I want to make some kind of music-control. Since I have this E-Paper-Display I thought it would be interesting to display the picture of the song. With the Spotify-API I can already get the URL of the Song-Picture (e.g. https://i.scdn.co/image/ab67616d00001e02255e131abc1410833be95673). But of course I can't download the Song-Pictures of millions of songs to the EPD47. So I have the question: Is there a way to show pictures from an URL?

Thanks in advance
Bastian

BTW: Do we already have a LILYGO-Discord? I think that would be quite helpful

Working with MEMS Microphone - INMP411

I have connected and INMP411microphone to the following pins: BCK=SCK=13 / WS=15, Data=SD=12, Ground=LR , VCC starting from the connector. I am using WIFI to send the data to a server for recording.

I experience a very strong NOISE on this microphone when using on LilyGo-EPD47. Using a Wemos D32 DEV board with same microphone and same settings, the noise is very low.

I have tried several wiring options for the microphone - always with the same result on the EPD :-(

Problem occurs when EPD is enabled or disabled.

I2S Init code used:

  i2s_pin_config_t pin_config = {
            .bck_io_num = 13, //this is BCK pin
            .ws_io_num = 15, // this is LRCK pin
            .data_out_num = I2S_PIN_NO_CHANGE, // this is DATA output pin
            .data_in_num = 12   //DATA IN
    };


     i2s_config_t i2s_config = {
            .mode = (i2s_mode_t) (I2S_MODE_MASTER | I2S_MODE_RX),
            .sample_rate = 16000,
            .bits_per_sample = I2S_BITS_PER_SAMPLE_16BIT,
            .channel_format = I2S_CHANNEL_FMT_ONLY_LEFT, // was I2S_CHANNEL_FMT_RIGHT_LEFT
            .communication_format = i2s_comm_format_t(I2S_COMM_FORMAT_I2S),
            .intr_alloc_flags = ESP_INTR_FLAG_LEVEL1,
            .dma_buf_count = 4,
            .dma_buf_len = 1024,
            .use_apll = false,
            .tx_desc_auto_clear = false,
            .fixed_mclk = 0
    };

Question: Should I use different pins, different wiring?

Thx a lot,

License

Hi, i have mentioned this in vroland/epdiy#44, but just as a reminder:

Please note that the driver and examples (at least the ones written by me) are licensed under the GPLv3 (https://github.com/vroland/epdiy/blob/master/components/epd_driver/LICENSE), which requires that derivatives must be licensed under the same terms.
Currently, this Repo does not contain any licensing information, so please choose a license that is in accordance with the original license.

Regards,
Valentin

Dead (?) Rows

sample

After using my display for the last 24 hours there are two rows of dead(?) pixels as can be seen above.

These artifacts were not displayed yesterday and appears using directly edpiy library's example in plaformIO or with your image display example.

Any idea ? Is it a physical default ? During screen refresh (blackening) the two lines stay white.

Where can I find the Weather Example?

Hello,

a lot of screen dumps show a weather example. May I ask "Where can I find this example?"
I know that epdiy has a weather example, but this dedicated to a different (kindle?) 9.7 " display.
Thanks in advance

BTW, great device with a lot of potential!
:-)

Core 1 Panic: (StoreProhibited). Exception was unhandled.

Hi,

I have a new device T5-4.7, I tried to build the demo example but I got:

Guru Meditation Error: Core  1 panic'ed (StoreProhibited). Exception was unhandled.
Core 1 register dump:
PC      : 0x4000c46c  PS      : 0x00060130  A0      : 0x800d0f10  A1      : 0x3ffb1f70  
A2      : 0x00000000  A3      : 0xffffffff  A4      : 0x0003f480  A5      : 0x00000000  
A6      : 0x00000001  A7      : 0x00003f48  A8      : 0x00000000  A9      : 0x3ffb1f40  
A10     : 0x4008f954  A11     : 0x000001e0  A12     : 0x00000000  A13     : 0x3ffd1cfc  
A14     : 0x00060120  A15     : 0x00000000  SAR     : 0x0000001d  EXCCAUSE: 0x0000001d  
EXCVADDR: 0x00000000  LBEG    : 0x4000c46c  LEND    : 0x4000c477  LCOUNT  : 0x00003f47  

Backtrace: 0x4000c46c:0x3ffb1f70 0x400d0f0d:0x3ffb1f80 0x400d4cfb:0x3ffb1fb0 0x40089195:0x3ffb1fd0

I have the next parameters with PlatformIO (similar to Arduino instructions that you posted here):

platformio]
src_dir = .

[common_env_data]
framework = arduino
upload_speed = 1500000
monitor_speed = 115200
lib_deps =
    Wire
    https://github.com/Xinyuan-LilyGO/LilyGo-EPD47.git
build_flags =
    -DBOARD_HAS_PSRAM

[env:esp32dev]
platform = espressif32
board = esp32dev
framework = ${common_env_data.framework}
upload_speed = ${common_env_data.upload_speed}
monitor_speed = ${common_env_data.monitor_speed}
lib_deps = ${common_env_data.lib_deps}

The build and upload pass ok, but I have this.

Thanks.

Demo's always give compile errors

Unfortunately all efforts to compile any of the examples results in similar compile errors. An example from the demo is....

C:\Users\g7kse\Documents\Arduino\libraries\LilyGo-EPD47\examples\demo\demo.ino: In function 'void setup()':
C:\Users\g7kse\Documents\Arduino\libraries\LilyGo-EPD47\examples\demo\demo.ino:79:21: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
     char *string1 = "โžธ 16 color grayscale  ๐Ÿ˜€ \n";
                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C:\Users\g7kse\Documents\Arduino\libraries\LilyGo-EPD47\examples\demo\demo.ino:80:21: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
     char *string2 = "โžธ Use with 4.7\" EPDs ๐Ÿ˜ \n";
                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C:\Users\g7kse\Documents\Arduino\libraries\LilyGo-EPD47\examples\demo\demo.ino:81:21: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
     char *string3 = "โžธ High-quality font rendering โœŽ๐Ÿ™‹";
                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C:\Users\g7kse\Documents\Arduino\libraries\LilyGo-EPD47\examples\demo\demo.ino:82:21: warning: ISO C++ forbids converting a string constant to 'char*' [-Wwrite-strings]
     char *string4 = "โžธ ~630ms for full frame draw ๐Ÿš€\n";
                     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
C:\Users\g7kse\Documents\Arduino\libraries\LilyGo-EPD47\src\rmt_pulse.c: In function 'rmt_pulse_init':
C:\Users\g7kse\Documents\Arduino\libraries\LilyGo-EPD47\src\rmt_pulse.c:55:5: warning: implicit declaration of function 'rmt_ll_enable_tx_end_interrupt'; did you mean 'xthal_get_interrupt'? [-Wimplicit-function-declaration]
     rmt_ll_enable_tx_end_interrupt(&RMT, row_rmt_config.channel, true);
     ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     xthal_get_interrupt
c:/users/g7kse/appdata/local/arduino15/packages/esp32/tools/xtensa-esp32-elf-gcc/gcc8_4_0-esp-2021r1/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: libraries\LilyGo-EPD47\rmt_pulse.c.o:(.literal.rmt_pulse_init+0x10): undefined reference to `rmt_ll_enable_tx_end_interrupt'
c:/users/g7kse/appdata/local/arduino15/packages/esp32/tools/xtensa-esp32-elf-gcc/gcc8_4_0-esp-2021r1/bin/../lib/gcc/xtensa-esp32-elf/8.4.0/../../../../xtensa-esp32-elf/bin/ld.exe: libraries\LilyGo-EPD47\rmt_pulse.c.o: in function `rmt_pulse_init':
C:\Users\g7kse\Documents\Arduino\libraries\LilyGo-EPD47\src/rmt_pulse.c:55: undefined reference to `rmt_ll_enable_tx_end_interrupt'
collect2.exe: error: ld returned 1 exit status
Multiple libraries were found for "SD.h"
 Used: C:\Users\g7kse\AppData\Local\Arduino15\packages\esp32\hardware\esp32\2.0.0\libraries\SD
 Not used: C:\Program Files (x86)\Arduino\libraries\SD
exit status 1
Error compiling for board ESP32 Dev Module.

Similar 'exit status 1' errors appear on all all examples but other simpler wifi scan esp32 examples do work.

I've used the dev board branch, used different machines, reinstalled arduino ide etc don't know where to go next....any clues?

Touch works right - Making full class with events support

Hi there @lewisxhe
I'm trying to implement the touch for this epaper in my IDF component (For parallel is also based on EPDiy)

I started simply adding this repository as a library and compiled first the grayscale to confirm it works good. Connected the touch like described from Lilygo in a video and compiled touchtest demo adding a single like to print coordinates:

// Just after the getPoint(x, y, 0) call:
Serial.printf("X:%d Y:%d\n", x, y);

All what I get in Serial is this:

X:495 Y:242
X:495 Y:242
X:493 Y:241
X:488 Y:239
readBytes error! -> Mostly happening after pressing one of the buttons
X:0 Y:540
readBytes error!
X:0 Y:540 
// From time to time something like this comes:
X:33 Y:62876 -> Clearly not the right Y value

// From time to time also crashes
Guru Meditation Error: Core  1 panic'ed (LoadStoreError). Exception was unhandled.
Core 1 register dump:
PC      : 0x400d2852  PS      : 0x00060030  A0      : 0x800d1270  A1      : 0x3ffb1f30  
A2      : 0x3ffc05f0  A3      : 0x0000000b  A4      : 0xc6c0a410  A5      : 0x00000000  
A6      : 0x19c8cda5  A7      : 0x40000000  A8      : 0x0004e0cc  A9      : 0x0329c041  
A10     : 0x3ffb1f34  A11     : 0x3ffb1f39  A12     : 0x00000035  A13     : 0x400f1704  
A14     : 0x3ffb1ee0  A15     : 0x00000002  SAR     : 0x0000000f  EXCCAUSE: 0x00000003  
EXCVADDR: 0x40000000  LBEG    : 0x4000c2e0  LEND    : 0x4000c2f6  LCOUNT  : 0x00000000  

Backtrace: 0x400d2852:0x3ffb1f30 0x400d126d:0x3ffb1f80 0x400d65dd:0x3ffb1fb0 0x4008bd49:0x3ffb1fd0

Rebooting...
ets Jul 29 2019 12:21:46

rst:0xc (SW_CPU_RESET),boot:0x13 (SPI_FAST_FLASH_BOOT)
configsip: 0, SPIWP:0xee
clk_drv:0x00,q_drv:0x00,d_drv:0x00,cs0_drv:0x00,hd_drv:0x00,wp_drv:0x00
mode:DIO, clock div:2
load:0x3fff0018,len:4
load:0x3fff001c,len:1044
load:0x40078000,len:8896
load:0x40080400,len:5828
entry 0x400806ac
Started Touchscreen poll (restarted)

X & Y working correcly but not consistently. At some point I get "readBytes error!" and also from time to time it stops for some secods to read the touch signals.

As I side topic I do not understand why Lilygo purchases some touch controller from a provider, but is not able to supply either the Vendor specifications or a proper Technical specs PDF where we developers can properly get informed about the touch events and more. Touch is not only about Tapping and getting X & Y Coordinates, some touch interfaces also have gestures and return different events like Tap, Drag, Press, Release etc.

Second thing I don't understand correctly is why this is not like a standard I2C implementation as we can see for example in this Goodisplay FocalTech component initialization.
Usually when starting communication with I2C, both temperature sensor and other touch components first thing they do is to check that the Vendor ID and Chip ID match. Otherwise might be hitting the wrong component or might be not connecting thus giving you an early warning after I2C is instantiated. And that's what I see on most I2C, but here is simply assuming is like this, can work is no problem but it shows a bit that you are implementing something that you don't understand completely. This lack of information summed to the fact that I cannot even get the Lilygo touch test demo working correctly makes the touch unusable for my intents right now.

If someone can help I will be really happy to get this moving forward and implement this differently using proper Rising edge interrupts instead of looping all the time over, that is first not the right way to do it, and secondly higher CPU intensive if you application does other things other than touch. Touch should be something that runs smooth on the background and is just triggered when TOUCH_INT pin goes HI (This is also uncommon, on other touch interfaces, same as Chip select INT is low when receiving an event) But is ok I'm just interested in getting this to work and getting the full technical information about the controller.

Waveform File

Hi,
Recently, I added support for vendor wavforms to epdiy. These are special files that describe how the display must be driven for accurate grayscale.
This allows to make arbitrary grayscale-to-grayscale transitions, which is not possible with the version of epdiy this library is based on at the moment. There are some other improments as well, especially to the user-facing API. So incorporating them or finding a way to keep this fork more up to date should be discussed in a separate issue.
You have sent me the fitting waveform file via e-Mail already, but it would be nice to have it publicly available for anyone who needs it. That would allow me to add the appropriate header to epdiy directly, which would make it way easier for people to get use out of this file.
So: Could you add the V220_C244_BA5701_ED047TC2U1_TC.wbf waveform file to the repository?

Regards,
Valentin

Multi touch not working

Hello,
I have problem that multi-touch won't work.

I tried:
1:
touch.scanPoint(): Returns 1 while touching (Multi-touch doesn't matter).
2:

for (int i = 0; i < 5; i++) {
  Serial.print(i);
  Serial.print(": ");
  Serial.print(touch.data[i].x);
  Serial.print(" ");
  Serial.print(touch.data[i].y);
  Serial.print(" ");
  Serial.print(touch.data[i].state);
  Serial.print(" ");
  Serial.print(touch.data[i].id);
  Serial.println();
}

Prints:

0: 469 246 6 2
1: 0 0 0 0
2: 0 0 0 0
3: 0 0 0 0
4: 0 0 0 0
0: 469 246 6 2
1: 0 0 0 0
2: 0 0 0 0
3: 0 0 0 0
4: 0 0 0 0
0: 469 246 6 2
1: 0 0 0 0
2: 0 0 0 0
3: 0 0 0 0
4: 0 0 0 0
0: 469 246 6 2
1: 0 0 0 0
2: 0 0 0 0
3: 0 0 0 0
4: 0 0 0 0
0: 469 246 6 2
1: 0 0 0 0
2: 0 0 0 0
3: 0 0 0 0
4: 0 0 0 0

Sometime touch.data[0].id will be 2 while multi-touching
Aliexpress description says Support multi-touch, and I think this is not intended behavior.

Hardware details

Which display is used on this product? Could you give us the exact part number?
Is the schematic available somewhere?

3D printing files

Comes from #2 :
Thanks @markbirss the intention of converting the file to 0-sjk_asm(2).zip was great but it really does not help like this. When importing it to blender or even the Slicer software this comes as a single block piece that looks like a solid mobile device and it's really useless for 3D printing.
Preview:
Screenshot from 2021-01-10 17-38-35

Buttons

Hello, I have tried the test program to use the buttons, IO34 and IO39 works, but IO35 is not.
Is there any special thing with IO35??
I think the other button has problems ... IO0, isnยดt it?

White text on black background

Anyone know how I can get the white color text on black background? All I want to do is that fillRect with Black and then write text with white color.

There are members called

uint8_t fg_color
uint8_t bg_color

But I don't know how should I use it.

Touchscreen not working with battery power

The touchscreen does work fine if the device is powered via USB, however adding a 3.7V battery does not work at all, it is only sending 0, 0 points for touches.

Any idea whats causing this?

Battery 3.7 Volts ??

Hello

My device works almost right when it is connected to electricity using USB. But when it is running with a battery the touch screen doesnยดt respond nor the buttons .... but if I push the reset button it resets, connects to wifi and I can connect to the device using remotedebug library. I use the pitch battery socket version. Is there any problem with the touch device using the batteries ??

Only 1 GPIO for users?

New user here...
Very happy with the EPD47, but now looking to interface to the outside world.

It seems to me that on connector P5 we have IO12, IO13 and on P4 we have IO14, IO15.
Now the touch panel on P2 uses IO13, IO14 and IO15 leaving only IO12 for users. Is this correct?

Regards,
Henk

Molex Connector - source?

Hi not a code issue, but has anyone found a source for the '4pin 2.0 molex 4 p 53015-0410' connectors, nothing found on AliExpress or Digikey.

There are 3 on-board connectors and I'm trying to make a I2C device connection (the LILYGO bme280 board), I want to post some code to show how to read I2C devices.

SCHEMATIC

When you launch new product, the FIRST and MANDATORY thing that must be done is the
SCHEMATIC of the product!
That is why you lose the competition with M5Stack products.

New Epdiy Features

Hi,
as mentioned in a previous issue, epdiy, the driver this library is based on, has made some progress since this repository was created. Notable changes are:

  • A high-level API that makes allows to simply write to a framebuffer and let the driver update the display, no need to know about different update modes / calculating partial updates. (see https://github.com/vroland/epdiy/blob/master/examples/demo/main/main.c)
  • Removed namespace clashes with Adafruit GFX
  • Support for vendor waveforms, allowing arbitrary grayscale-to-grayscale transitions
  • Support the the arduino IDE. Currently, this requires to install a board definition file because of limitations of arduino-esp32, but since this library only supports one board this process could be simplified.
  • The driver can be configured to use significantly less memory at the expense of performance, which is necessary when using wifi and bluetooth together.
  • The documentation has been updated to make things like image and font generation clearer.

Thus, I thought it would make sense to discuss how these changes could be best integrated here, to take advantage of the development effort happening in both places. Maybe this library could wrap epdiy and add device-specific examples and extensions?

MicroPython?

Hi, thanks for such a good project!
Just out of curiosity - how difficult (or feasible) is to port your driver under Micropython (esp32 in particular)?

How to use `epd_draw_frame_1bit()`?

epd_driver.h describes a function called epd_draw_frame_1bit with a signature of:

void IRAM_ATTR epd_draw_frame_1bit(Rect_t area, uint8_t *ptr,
                                   enum DrawMode mode, int time)

Is this a public function? What is the correct way to use it? My application is monochrome so being able to keep a mono canvas and sending that directly would be really useful

Not working with connected battery

Hi there,

I use my for a few weeks and finally decided to switch from USB to battery and it's not working.
I checked voltage on battery and it's all good, 3.7v but once connected board doesn't show any signs of life, no lights, nothing.
Once connected a USB cable it starts to work, blue LED is ON, green is not lighting up.
Once battery is disconnected blue and green LED is ON

How can I troubleshoot this issue?

Thank you
Ihor

How to use IO0 button ?

My question is not directly related to the screen itself (which works very nicely following the examples) but is related to the hardware of the T5-4.7, and more precisely to the buttons.

There is 5 buttons at the top of the board, one is the RST (the one at left with screen in front of you), then they are named IO0, IO35, IO34, IO39 (as seen in the pictures at the back of the box of the boad, that we have at this link ).

I have no problem to use the IO35, IO34, and IO39 (the three buttons at the right), but I am currently not able to find which PIN I must use for the first customisable button (the second one from the left).

When we look at the board, we can see this is the only button without resistors attached to him. Is this button working ? The board description says there is 4 custo buttons.

Copyright infringement G6EJD weather station

I will give you 5-days to remove the weather station code or I will file a GitHub takedown action.

You have taken my code and listed as yours.

This is the second time you have done this, the first time the listing was removed by GitHub.

Faded display

I am using the LilyGo 4.7" ePaper display (https://www.aliexpress.com/item/1005002617525312.html)

When I got the unit, I plugged it in, and it showed the LilyGo demo app. Everything looked great, contrast, and display.

I followed the instructions here to install the demo app.

The app compiled and uploaded successfully. It works well, except that the display is quite faded with poor contrast. I tried the other examples and have the same problem. I don't think the unit is defective since it worked fine before I uploaded the demo.

My setup:
OS: Windows 10
IDE: Arduino IDE v1.8.15 (current as/of 8/22/2021)
Board: ESP32 Dev Module
PSRAM: Enabled
Partition scheme: 16M Flash (2MB APP/12.5 MB FAT)
[I have tried all of the partition schemes, all with the same result)

I have also tried with Arduino IDE 2.0.0-beta.10 and get the same result

image

Tutorial on Fonts and Images

I've tried to create a custom font, with no luck. I've used the fontconvert.py tool and continue to get and error "valueError: code point 166 not found in font stack!".
I've tried to convert a ttf, and a otf. With no luck.
Is there a tutorial somewhere on how to create a font for the T5 4.7"

a tutorial on creating a custom image would also be helpful, thank you.

Screen goes blank when battery is connected

I have a strange issue. When I connect the 18650 battery, screen goes blank however blue LED is on. I've tested if ESP32 getting 3.3v and confirmed that its getting 3.3v.

What could be the issue?

Also can I solder wires to PH connector and use instead? Does anyone know they use different circuitry ?

Battery 18650 charging

Hi, I would to check if the battery is charging. I'm able to check the voltage and to know if the usb cable is connected (voltage > 4,5v), but I don't know how check if the battery is charging. I saw that when charging a red led is lighted up on the board. Please help me. Thanks

Image type?

I'm beginning to make good progress now with the display, but can someone help me with the display image type?

Do we convert BMP or JPG or What and the format needed? especially if colour information is required for the 16-grey levels.

Compilation error: rmt_ll_enable_tx_end_interrupt (in rmt_pulse.c line 55)

Hi and thanks for the awesome software.

I wanted to point out a bug I found while compiling. These are the steps to recreate the bug:

  • Use latest ZIP version of this repo and add it via [Add .zip library] on Arduino IDE
  • Update ESP32 board package from Board Manager from 1.0.6 (previously used) to 2.0.0
  • Try compiling/uploading demo code to ESP32

Compilation does not complete, with the error: no reference to "rmt_ll_enable_tx_end_interrupt" (rmt_pulse.c, line 55)

The snippet in question is:

#if ESP_IDF_VERSION_MAJOR >= 4
    rmt_ll_enable_tx_end_interrupt(&RMT, row_rmt_config.channel, true);
#else
    rmt_set_tx_intr_en(row_rmt_config.channel, true);
#endif

Pullup resistors on the buttons makes them useless for deep sleep

Just hit a major roadblock on a project.

The buttons have pull up resistors which makes them pretty much pointless for deep sleep mode.

esp_sleep_enable_ext1_wakeup has two modes, ESP_EXT1_WAKEUP_ANY_HIGH or ESP_EXT1_WAKEUP_ALL_LOW

You can only work out which pin woke the device using the ESP_EXT1_WAKEUP_ANY_HIGH - unfortunately this mode is not available as the pins are pulled high. So the device wakes up instantly.

I think the only alternative is to write some ULP assembly.

rotate screen

is it possible to rotate the screen, from landscape to portrait?
Thanks

Quick start guide not complete

Hello ๐Ÿ‘‹ I have followed the quick start guide, but when I try to upload the demo example, I get EPS IDF errors:

/home/user/snap/arduino/current/Arduino/libraries/LilyGo-EPD47-master/src/i2s_data_bus.c:5:29: fatal error: esp_idf_version.h: No such file or directory
 #include <esp_idf_version.h>
                             ^
compilation terminated.
exit status 1
Error compiling for board ESP32 Dev Module.

I am using Ubuntu 20.04 and installed the Arduino IDE snap (tried with a non-snap installation and the result is the same). Should I install ESP-IDF too and how to get the demo to work with Arduino IDE?

How do you read the battery voltage?

Looking for a way to get the battery percentage from the board. I looked at the buttons example you posted and I see you defined #define BATT_PIN 36. Can this be used to read the battery voltage?

float voltage = analogRead(36) / 4096.0 * 7.46; seems to come out null. Is there a way without wiring into additional GPIO to check the voltage?

Battery Voltage

Looking for a way to get the battery percentage from the board. I looked at the buttons example you posted and I see you defined #define BATT_PIN 36. Can this be used to read the battery voltage?

float voltage = analogRead(36) / 4096.0 * 7.46; seems to come out null. Is there a way without wiring into additional GPIO to check the voltage?

error compiling arduino

I get this error when compiling in Arduino

sketch\demo.ino.cpp.o:(.literal._Z5setupv+0x6c): undefined reference to writeln' sketch\demo.ino.cpp.o: In function setup()':
C:\Users\Ron\Documents\Arduino\libraries\LilyGo-EPD47-master\examples\demo/demo.ino:72: undefined reference to writeln' C:\Users\Ron\Documents\Arduino\libraries\LilyGo-EPD47-master\examples\demo/demo.ino:86: undefined reference to writeln'
C:\Users\Ron\Documents\Arduino\libraries\LilyGo-EPD47-master\examples\demo/demo.ino:89: undefined reference to writeln' C:\Users\Ron\Documents\Arduino\libraries\LilyGo-EPD47-master\examples\demo/demo.ino:93: undefined reference to writeln'
sketch\demo.ino.cpp.o:C:\Users\Ron\Documents\Arduino\libraries\LilyGo-EPD47-master\examples\demo/demo.ino:95: more undefined references to `writeln' follow
collect2.exe: error: ld returned 1 exit status
Multiple libraries were found for "SD.h"
Used: C:\Users\Ron\Documents\ArduinoData\packages\esp32\hardware\esp32\1.0.5\libraries\SD
Not used: C:\Program Files\WindowsApps\ArduinoLLC.ArduinoIDE_1.8.42.0_x86__mdqgnx93n4wtt\libraries\SD
exit status 1
Error compiling for board ESP32 Dev Module.

ESPNow

Using ESPNow in slave mode works perfectly, except when I try to use the writeln function. It prints one time, then hangs. If I remove the writeln function it continues to print to the console as expected. Any help would be appreciated.

void OnDataRecv(const uint8_t *mac_addr, const uint8_t *data, int data_len) {
char macStr[18];
snprintf(macStr, sizeof(macStr), "%02x:%02x:%02x:%02x:%02x:%02x",
mac_addr[0], mac_addr[1], mac_addr[2], mac_addr[3], mac_addr[4], mac_addr[5]);
Serial.print("Last Packet Recv from: "); Serial.println(macStr);
Serial.print("Last Packet Recv Data: "); Serial.println(*data);
Serial.println("");
writeln((GFXfont *)&OpenSans24B, data, &temp1_cursor_x, &temp1_cursor_y, NULL);
}

epd_draw_pixel not working

i tried using

void epd_draw_pixel(int x, int y, uint8_t color,
                    uint8_t *framebuffer);

from epd_driver.h

i tried it using
epd_draw_pixel(500,200,0,framebuffer);
and
epd_draw_pixel(500,200,255,framebuffer);

both lines didnt work unf.

i am using the touchtest example code where i removed the center text.
a snippet where i added the line
` epd_poweron();
epd_clear();

//Draw Box
epd_draw_rect(600, 450, 120, 60, 0, framebuffer);
cursor_x = 615;
cursor_y = 490;
writeln((GFXfont *)&FiraSans, "Prev", &cursor_x, &cursor_y, framebuffer);

epd_draw_rect(740, 450, 120, 60, 0, framebuffer);
cursor_x = 755;
cursor_y = 490;
writeln((GFXfont *)&FiraSans, "Next", &cursor_x, &cursor_y, framebuffer);

epd_draw_pixel(500,200,0,framebuffer);

Rect_t area = {
    .x = 160,
    .y = 420,
    .width = lilygo_width,
    .height =  lilygo_height
};
epd_copy_to_framebuffer(area, (uint8_t *) lilygo_data, framebuffer);

epd_draw_rect(10, 20, EPD_WIDTH - 20, EPD_HEIGHT / 2 + 80, 0, framebuffer);

epd_draw_grayscale_image(epd_full_screen(), framebuffer);
epd_poweroff();` 

what am i doing something wrong?
could someone correct me please or prive a small snipped?

thanks

Powersave mode for the touchscreen?

At idle, the touchscreen sold with the EPD47 consumes approximately 2 mA. The ESP32, when in deep sleep, consumes power in the range of microamperes; thus making the touchscreen the biggest power consumer on the board.

For wire-powered applications this is acceptable, however when battery-powered from e.g. a 2200 mAh 18650 cell this would drain power in under 1100 h = ~48 days.
Not too short in its own regard, but considering the device will probably be idle most of the time it would be great if the touchscreen power draw could be reduced further.

Removing power from the screen could've been a possibility in certain scenarios but the schematics show it is directly connected to VDD3V3 which can't be disabled through PWR_EN like 3V3 can.

I know the touchscreen controller isn't identified (#2 (comment)), but is there information on how to trigger some sort of powersave mode, or to reduce the idle screen scanning rate?

Ghost image when redrawing screen

Hi,

I am having an issue that when I display some text on the screen the previously displayed one is visible in negative (whiter than the background).

any hints on what could be wrong?

I always write to a fully cleared frame buffer first:

writeln(font, buffer, &x0, &y0, Peripherals::framebuffer);

and then draw the full buffer:

  epd_poweron();
    epd_clear();
    epd_draw_grayscale_image(epd_full_screen(), Peripherals::framebuffer);
    epd_poweroff();
    memset(Peripherals::framebuffer, 0xFF, EPD_WIDTH * EPD_HEIGHT / 2);

See picture below for the issue:

IMG_20210606_120628

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.