diff options
| author | Sadeep Madurange <sadeep@asciimx.com> | 2023-10-03 07:31:25 +0800 |
|---|---|---|
| committer | Sadeep Madurange <sadeep@asciimx.com> | 2023-10-03 07:31:25 +0800 |
| commit | 170d30bf548ea2e2196e14e413edf79563500e7f (patch) | |
| tree | 608c08ddd381e60bb54f0ffd6280b2872b1e4040 | |
| parent | 67efb957be76411b9f52cf3c8d2b1dca8abf1f15 (diff) | |
| download | esp32-e-reader-170d30bf548ea2e2196e14e413edf79563500e7f.tar.gz | |
Uncomment draw functions.
| -rw-r--r-- | main/main.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/main/main.c b/main/main.c index 3201f00..a679855 100644 --- a/main/main.c +++ b/main/main.c @@ -115,7 +115,7 @@ static void gpio_task(void* arg) if(xQueueReceive(gpio_evt_queue, &io_num, portMAX_DELAY)) { if (io_num == IO_PAGE_NEXT) { page_num++; - //epd_draw(pages[page_num % PAGE_LEN]); + epd_draw(pages[page_num % PAGE_LEN]); if(!http_get_page(page_num + 2, (char *) pages[(page_num + 1) % PAGE_LEN])) { page_num--; @@ -123,7 +123,7 @@ static void gpio_task(void* arg) } else if (io_num == IO_PAGE_PREV && page_num > 0) { page_num--; - //epd_draw(pages[page_num % PAGE_LEN]); + epd_draw(pages[page_num % PAGE_LEN]); if(!http_get_page(page_num + 1, (char *) pages[(page_num - 1) % PAGE_LEN])) { page_num++; @@ -244,9 +244,9 @@ void app_main(void) wifi_connect(); - //epd_init(); - //epd_clear(); - //delay_ms(500); + epd_init(); + epd_clear(); + delay_ms(500); pages[0] = malloc(sizeof(uint8_t) * PAGE_SIZE); pages[1] = malloc(sizeof(uint8_t) * PAGE_SIZE); @@ -255,7 +255,7 @@ void app_main(void) if (pages[0] && pages[1] && pages[2]) { if (http_get_page(page_num + 1, (char *) pages[page_num % PAGE_LEN])) { - //epd_draw(pages[page_num % PAGE_LEN]); + epd_draw(pages[page_num % PAGE_LEN]); if (!http_get_page(page_num + 2, (char *) pages[(page_num + 1) % PAGE_LEN])) { page_num = -1; |
