# Tiled Screen

**URL:** <https://forum.arduino.cc/t/tiled-screen/658384>\
**Category:** MKR Vidor 4000\
**Created:** [June 2, 2020, 11:21am UTC](https://forum.arduino.cc/t/tiled-screen/658384 "2020-06-02T11:21:45Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![riccardo\_giacomazzi](https://avatars.discourse-cdn.com/v4/letter/r/6a8cbe/32.png) [@riccardo\_giacomazzi](https://forum.arduino.cc/u/riccardo_giacomazzi)\
**Post date:** [June 2, 2020, 11:21am UTC](https://forum.arduino.cc/t/tiled-screen/658384/1 "2020-06-02T11:21:45Z")

</div>

Hi, if anyone is interested, I have published a library that implements a video controller in Tiled mode: on a resolution of 640x360 pixels a screen of 40x22.5 Tiles of 16x16 pixels each is built.

This allows to have a reasonable speed of updating the screen also passing through the JTAG interface.

You can create a very large virtual screen and view a 640x360 pixel window, with vertical and horizontal scrolling of the single pixel.

The library and the sources can be found on my GitHub: [GitHub - Giako68/TiledScreen: Video Controller Library for Arduino MKR Vidor 4000 -- Tiled Mode](https://github.com/Giako68/TiledScreen)

---

<div class="post-metadata">

**Author:** ![invincing](https://avatars.discourse-cdn.com/v4/letter/i/71c47a/32.png) [@invincing](https://forum.arduino.cc/u/invincing)\
**Post date:** [June 5, 2020, 10:04pm UTC](https://forum.arduino.cc/t/tiled-screen/658384/2 "2020-06-05T22:04:27Z")

</div>

Hey, you just saved me from sending my brand new card back! I was almost certain that the HDMI output was broken at the HW level, but with your sketch I was able to get an image on the screen.

Basically, my issue is similar to this post:  
[https://forum.arduino.cc/index.php?topic=561263.msg3837146#msg3837146](https://forum.arduino.cc/index.php?topic=561263.msg3837146#msg3837146)

The screen is just color noise with the regular HDMI output at 640x480. This is on a monitor with DVI input. With another monitor (HDMI input), the display just says "out of sync".

As I do get correct image with your sketch (on the DVI monitor, the HDMI monitor can't sync to this either), I think I just need to try more monitors in order to get the default 640x480 image size working...

May I ask what you are doing differently with the HDMI signal generation?

---

<div class="post-metadata">

**Author:** ![riccardo\_giacomazzi](https://avatars.discourse-cdn.com/v4/letter/r/6a8cbe/32.png) [@riccardo\_giacomazzi](https://forum.arduino.cc/u/riccardo_giacomazzi)\
**Post date:** [June 6, 2020, 6:36am UTC](https://forum.arduino.cc/t/tiled-screen/658384/3 "2020-06-06T06:36:20Z")

</div>

I chose the 640x360 resolution because, both on an HD Ready panel (1280x720) and on a Full HD panel (1920x1080), the pixels are square and all the same: on an HD Ready a pixel of the image occupies 2x2 pixels of the panel, while on a Full HD it occupies 3x3.

Unfortunately 640x360 is not a "standard" resolution, so some monitors or TVs may not accept it.

To choose the signal settings, I started from my monitor's EDID data for the closest resolution, i.e. 640x480.

If you can get the EDID data of the HDMI monitor, I can try varying the DVI signal settings to see if it accepts it.

The EDID data of my monitor are these:

```cpp
Section "Monitor"
        Identifier "247ELPH"
        ModelName "247ELPH"
        VendorName "PHL"
        # Monitor Manufactured week 1 of 2012
        # EDID version 1.3
        # Digital Display
        DisplaySize 520 290
        Gamma 2.20
        Option "DPMS" "true"
        Horizsync 30-83
        VertRefresh 56-76
        # Maximum pixel clock is 170MHz
        #Not giving standard mode: 1920x1080, 60Hz
        #Not giving standard mode: 1280x1024, 60Hz
        #Not giving standard mode: 1440x900, 75Hz
        #Not giving standard mode: 1440x900, 60Hz
        #Not giving standard mode: 1680x1050, 60Hz

        #Extension block found. Parsing...
        Modeline        "Mode 16" 148.50 1920 2008 2052 2200 1080 1084 1089 1125 +hsync +vsync 
        Modeline        "Mode 0" 148.50 1920 2008 2052 2200 1080 1084 1089 1125 +hsync +vsync 
        Modeline        "Mode 1" 25.200 640 656 752 800 480 490 492 525 -hsync -vsync
        Modeline        "Mode 2" 27.027 720 736 798 858 480 489 495 525 -hsync -vsync
        Modeline        "Mode 3" 27.027 720 736 798 858 480 489 495 525 -hsync -vsync
        Modeline        "Mode 4" 74.250 1920 2008 2052 2200 1080 1082 1087 1125 +hsync +vsync interlace
        Modeline        "Mode 5" 27.027 1440 1478 1602 1716 480 484 487 525 -hsync -vsync interlace
        Modeline        "Mode 6" 27.027 1440 1478 1602 1716 480 484 487 525 -hsync -vsync interlace
        Modeline        "Mode 7" 148.500 1920 2008 2052 2200 1080 1084 1089 1125 +hsync +vsync
        Modeline        "Mode 8" 27.000 720 732 796 864 576 581 586 625 -hsync -vsync
        Modeline        "Mode 9" 27.000 720 732 796 864 576 581 586 625 -hsync -vsync
        Modeline        "Mode 10" 74.250 1280 1720 1760 1980 720 725 730 750 +hsync +vsync
        Modeline        "Mode 11" 74.250 1920 2448 2492 2640 1080 1082 1089 1125 +hsync +vsync interlace
        Modeline        "Mode 12" 27.000 1440 1464 1590 1728 576 578 581 625 -hsync -vsync interlace
        Modeline        "Mode 13" 27.000 1440 1464 1590 1728 576 578 581 625 -hsync -vsync interlace
        Modeline        "Mode 14" 148.500 1920 2448 2492 2640 1080 1084 1089 1125 +hsync +vsync
        Modeline        "Mode 15" 74.250 1280 1390 1420 1650 720 725 730 750 +hsync +vsync
        Modeline        "Mode 17" 27.00 720 736 798 858 480 489 495 525 -hsync -vsync 
        Modeline        "Mode 18" 74.25 1280 1390 1430 1650 720 725 730 750 +hsync +vsync 
        Modeline        "Mode 19" 27.00 720 732 796 864 576 581 586 625 -hsync -vsync 
        Option "PreferredMode" "Mode 16"
EndSection

```

And these are the parameters I use to generate synchronisms:

```cpp
  // -----------------------------------
  // 640x360@60Hz  -- PixClk = 25.200MHz
  // -----------------------------------
  parameter integer H_sync_start = 656;     
  parameter integer H_sync_stop = 751;
  parameter integer H_img_start = 0;
  parameter integer H_img_stop = 639;
  parameter integer H_screen_stop = 799;
  parameter integer H_polarity = 1'b0;
  parameter integer V_sync_start = 361;
  parameter integer V_sync_stop = 364;
  parameter integer V_img_start = 0;
  parameter integer V_img_stop = 359;
  parameter integer V_screen_stop = 449;
  parameter integer V_polarity = 1'b0;

```

---

<div class="post-metadata">

**Author:** ![system](https://dub1.discourse-cdn.com/arduino/user_avatar/forum.arduino.cc/system/32/1140315_2.png) [@system](https://forum.arduino.cc/u/system)\
**Post date:** [May 7, 2021, 11:55am UTC](https://forum.arduino.cc/t/tiled-screen/658384/4 "2021-05-07T11:55:06Z")

</div>


