![]() |
#1 |
Onyx-maniac
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 3,712
Karma: 16193287
Join Date: Feb 2012
Device: Nook NST, Glow2, 3, 4, '21, Kobo Aura2, Poke3, Poke5, Go6
|
![]()
I discovered how to draw to the screen of my Poke3 without anything more than the kernel.
AFAIK, this is not documented anywhere. If it is, I'd certainly like to know. The Freescale (NXP) iMX6 processors have built-in hardware to handle Eink. The Qualcomms do not. They use software. Therefore the usage is different. Short version of how to draw: Open /dev/graphics/fb0 Get finfo & vinfo (exactly like any LCD or Eink) Close it. Open /dev/ebc (this is the software interface, only on Onyx) mmap /dev/ebc with a size of width*height*4 rounded up to 4096 (i.e. 32 bit without stride rounded to pagesize) Doodle on this frame buffer (without stride, i.e, no extra bytes on line ends) You can unmap now if you like Fill a struct mxcfb_update_data (just like iMX6 Eink) ioctl(fd, 0x700c, &update); You can close now if you like This only works with 64 bit executables as the driver ignores 32 bit requests. They made this all sneakier because the driver does not return an error on a bad ioctl code, so no scanning for good codes. (I disassembled the kernel to figure this out.) |
![]() |
![]() |
![]() |
#2 |
Onyx-maniac
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 3,712
Karma: 16193287
Join Date: Feb 2012
Device: Nook NST, Glow2, 3, 4, '21, Kobo Aura2, Poke3, Poke5, Go6
|
There are two frame buffers: /dev/graphics/fb0 & /dev/graphics/fb1
/dev/graphics/fb0 is 1448 (1472 line length) x 1072, 32 bit, 2 buffers /dev/graphics/fb1 is 640 x 480, 32 bit, 2 buffers I wonder what they are needing/doing with a VGA interface? I've got my drawing code working fine, characters, graphics whatever. It shows up on the screen just fine but it never appears in fb0! I can do a screen grab of recovery but it never shows a shred of my doodling that is clearly visible on the screen. |
![]() |
![]() |
Advert | |
|
![]() |
#3 |
Onyx-maniac
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 3,712
Karma: 16193287
Join Date: Feb 2012
Device: Nook NST, Glow2, 3, 4, '21, Kobo Aura2, Poke3, Poke5, Go6
|
I still haven't figured out what all the bufs are doing, but I can do an unconventional screen grab. I'm particularly proud of my "wiggle" which is helpful to see where the text wraps around.
![]() Edit: You want to talk about weird? This is my "unconventional screen grab" of the stock recovery. I can imagine mirrored/rotated/skewed but I've never seen anything like this out of a frame buffer. No, it's not a grab in the middle of some process or animation. It looks like this all the time! Edit^2: Joke's on me. Windows loves translating line endings. Last edited by Renate; 03-28-2022 at 08:28 AM. |
![]() |
![]() |
![]() |
#4 |
Enthusiast
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 43
Karma: 16192
Join Date: May 2017
Location: Hungary
Device: Boyue Likebook P78, Onyx Boox i86HDML+
|
I can't really comment on the topics because my knowledge is far more shallow than this level but keep it up! E-ink focused development has never took off but hey, it's never too late!
|
![]() |
![]() |
![]() |
#5 |
Onyx-maniac
![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() ![]() Posts: 3,712
Karma: 16193287
Join Date: Feb 2012
Device: Nook NST, Glow2, 3, 4, '21, Kobo Aura2, Poke3, Poke5, Go6
|
Actually, a lot of work has been done on this by various people. Here is a library that works on:
Not supported are:
|
![]() |
![]() |
Advert | |
|
![]() |
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
Onyx Boox Max 3 drawing & writing in microsoft word | Astraorion | Onyx Boox | 1 | 06-02-2020 05:31 AM |
Aura Frozen on "Low battery level", impossible to start | sisim | Kobo Reader | 6 | 03-04-2016 11:22 AM |
Drawing to the e-ink screen | sanek_vi | Kindle Developer's Corner | 2 | 05-07-2014 07:00 PM |
Low-level access to Kobo eink panel | giorgio130 | Kobo Developer's Corner | 2 | 01-15-2013 10:56 PM |