iMX7 - epdc e-ink and X11

cancel
Showing results for 
Search instead for 
Did you mean: 

iMX7 - epdc e-ink and X11

858 Views
milanvitek
Contributor II

Hello,

I am looking for some help regarding e-ink display. I am using VAR-SOM-MX7 module with iMX7 and ES133UT2 display on Debian Stretch 9.3.

Right now I have it mostly up and running - mxc_epdc_v2_fb_test.out unit test works just fine. Is it possible to somehow configure X11 to be used with this display and refresh it on demand? My ultimate goal is to have our java gui app running on this system and to be able to refresh the screen on demand.

I have this configuration in /usr/share/X11/xorg.conf.d/99-fbdev.conf but I don't really know what to do next or whether this is actually correct.

Thank you.

Section "Monitor"
    Identifier  "Monitor1"

    Mode "1600x1200"
        # D: 0.025 MHz, H: 0.015 kHz, V: 0.012 Hz
        DotClock 0.026
        HTimings 1600 1676 1688 1700
        VTimings 1200 1205 1207 1211
        Flags    "-HSync" "-VSync"
    EndMode
EndSection

Section "Screen"
    Identifier  "Screen1"
    Device      "Kernel Framebuffer Device"
    Monitor     "Monitor1"
EndSection

Section "Device"
    Identifier  "Kernel Framebuffer Device"
    Driver      "fbdev"
    Option      "fbdev" "/dev/fb2"
EndSection

Section "ServerFlags"
    Option "BlankTime"  "0"
    Option "StandbyTime"  "0"
    Option "SuspendTime"  "0"
    Option "OffTime"  "0"
EndSection

Labels (1)
Tags (3)
3 Replies

223 Views
milanvitek
Contributor II

For anyone stumbling upon this. I solved this by digging around in sabre devboard SD card image where I found the mxcfb.h library. Using this I can now build and run the unit tests. Using parts of that code I am now able to refresh my screen on demand (update_to_display function). My java swing app is also running fine so the X11 configs posted above are more or less ok.

One last thing is that I use different fw for the display as the one provided by NXP does not work well. Solution found here:

https://community.nxp.com/thread/457285 

This could use some fine tuning or better fw because in some situations the display suffers from ghosting especially in gray areas. To get nice and clear image I need to do 2 full redraws (black white flashing) which does not look very nice given the refresh rate I will use (30 sec.).

0 Kudos

223 Views
milanvitek
Contributor II

Ok so I tried to mess with the C code. For previous test I used unit test that was prebuild (mxc_epdc_v2_fb_test.out) on SD card that comes with sabre devboard. This works just fine. Display is blanked and shows all kinds of stuff. So I searched for sources of this and found: GitHub - boundarydevices/imx-linux-test 

I am able to build and run this but it does not work:

root@var-som-mx7:/home/user/imx-linux-test/test/mxc_fb_test# make
     Building /mxc_epdc_fb_test.out
mxc_epdc_fb_test.c: In function ‘mxc_epdc_con_fini’:
mxc_epdc_fb_test.c:2182:22: warning: format ‘%s’ expects argument of type ‘char *’, but argument 3 has type ‘int’ [-Wformat=]
    fprintf(stderr, "%s: wait vt %d active failed\n", orig_vt);
                      ^
mxc_epdc_fb_test.c:2182:34: warning: format ‘%d’ expects a matching ‘int’ argument [-Wformat=]
    fprintf(stderr, "%s: wait vt %d active failed\n", orig_vt);
                                  ^
root@var-som-mx7:/home/user/imx-linux-test/test/mxc_fb_test# cd /
root@var-som-mx7:/# ./mxc_epdc_fb_test.out
Opened EPDC fb device /dev/fb2
Set the background to 16-bpp
screen_info.xres_virtual = 1600
screen_info.yres_virtual = 2560
screen_info.bits_per_pixel = 16
Mem-Mapping FB
Set to region update mode
Set waveform modes
Set update scheme - 2
Set pwrdown_delay - 0
Blank screen
Max retries exceeded
Crosshatch updates
Retrying update
Retrying update
Retrying update
Retrying update
Draw crosshatch vertical bar send update failed. retval = -1
Retrying update
Retrying update
Retrying update
Retrying update
Draw crosshatch horizontal bar send update failed. retval = -1
Retrying update
Retrying update
Retrying update

Now I suspect some of the included headers like <linux/mxcfb.h> as the mxcfb.h file was not on my system before and I just got some I found online. The question is where do I find the libraries and all the stuff that was used to build the mxc_epdc_v2_fb_test.out file supplied on the sdcard of sabre dev board?

The system I have on my device is provided by Variscite according to this guide:

Debian Build Release - Variscite Wiki 

0 Kudos

223 Views
weidong_sun
NXP TechSupport
NXP TechSupport

Hello Milan,

     About the question, I asked help from i.MX Expert team, see reply below, please!

---------------------------------------------------------

hi, given that the fbdev library was not modified to fit EPDC. It's need to have change on it. mxc_epdc_v2_fb_test.out can be guidance.

pastedImage_2.png

Have a nice day!

TIC Weidong sun

0 Kudos