cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
DuyLionTran
Observer
Observer
946 Views
Registered: ‎08-11-2020

Petalinux HDMI TX on Arty Z7

Jump to solution

Hello everyone,

I am able to run the Arty HDMI out demo using Xilinx toolchain v2020.1

https://github.com/Digilent/Arty-Z7-20-hdmi-out/tree/v2020.1

Now I want to integrate the HDMI into Linux driver (treat it like a default display output) but I don't find any tutorial about it. Any one has experience with it can give me some advices or show me where to start?

Thanks and best regards,

Duy

Tags (3)
0 Kudos
1 Solution

Accepted Solutions
DuyLionTran
Observer
Observer
580 Views
Registered: ‎08-11-2020

Hi @toblerone90 @watari ,

I was able to make it. There are several steps to follow:

1. Develop the driver for the dvi2rgb encoder. This one is a little tricky if you use the Xilinx toolchain v2020.1 and later. You can see this thread for the encoder driver: https://forums.xilinx.com/t5/Video-and-Audio/Bug-report-on-DRM-CRTC-DMA-engine-driver/td-p/1141378

2. Develop the driver for the axi_dynclk.

3. Develop the software framebuffer or you can implement the framebuffer IP in the block design.

I already pushed my code here as the reference, please use git-lfs to clone or you can just download it: https://github.com/DuyTrandeLion/PYNQ-Z1

Here is the prebuilt image, can run on both PYNQ-Z1 board or Arty Z7 20: https://drive.google.com/drive/folders/1-ekihuuoOUflDFoXWLwHhOEAwr9tylMD?usp=sharing

Thanks and best regards,

Duy Tran

View solution in original post

11 Replies
toblerone90
Visitor
Visitor
730 Views
Registered: ‎05-15-2018

Hi Duy,

I am currently working on the same topic - but did not get it running yet on petalinux 2020.1 / 2019.1. Did you manage to get it running?

My approach is to use the digilent sample project for petalinux, which is based on 2017.4 and the digilent kernel. But as this kernel is quite old it is not compatible with > 2019.1 toolchain. So I decided to integrate the digilent dynclk and hdmi encoder drivers as kernel modules into the official xilinx kernel. But at the moment without luck as the drm driver is returning an error during  "load is defered & will be called again!".

Regards

Martin

 

0 Kudos
watari
Professor
Professor
681 Views
Registered: ‎06-16-2013

Hi @DuyLionTran 

 

First of all, this IP is for DVI. It's different HDMI.

BTW, you can refer the followings to understand Linux DRM.

And you have to do porting DRM driver or describe DRM driver.

 

https://xilinx-wiki.atlassian.net/wiki/spaces/A/pages/18842136/Xilinx+DRM+KMS+HDMI-Tx+Driver

https://xilinx-wiki.atlassian.net/wiki/spaces/A/pages/18842520/Xilinx+DRM+KMS+driver

https://github.com/Xilinx/hdmi-modules

https://www.kernel.org/doc/html/v4.11/gpu/drm-internals.html

 

Would you try it ?

 

Best regards,

DuyLionTran
Observer
Observer
639 Views
Registered: ‎08-11-2020

Hi @toblerone90,

Unfortunately I have not managed to make it work yet. It got stuck during kernel boot. I am investigating the Digilent uboot and kernel because I suspect there are somethings customized there. So far no result on this.

Digilent seems not supporting the repo anymore.

Thanks and best regards,

Duy Tran

0 Kudos
DuyLionTran
Observer
Observer
638 Views
Registered: ‎08-11-2020

Hi @watari ,

Thanks for the reply. I don't mind taking time to study and follow it.

Best regards,

Duy Tran

0 Kudos
DuyLionTran
Observer
Observer
581 Views
Registered: ‎08-11-2020

Hi @toblerone90 @watari ,

I was able to make it. There are several steps to follow:

1. Develop the driver for the dvi2rgb encoder. This one is a little tricky if you use the Xilinx toolchain v2020.1 and later. You can see this thread for the encoder driver: https://forums.xilinx.com/t5/Video-and-Audio/Bug-report-on-DRM-CRTC-DMA-engine-driver/td-p/1141378

2. Develop the driver for the axi_dynclk.

3. Develop the software framebuffer or you can implement the framebuffer IP in the block design.

I already pushed my code here as the reference, please use git-lfs to clone or you can just download it: https://github.com/DuyTrandeLion/PYNQ-Z1

Here is the prebuilt image, can run on both PYNQ-Z1 board or Arty Z7 20: https://drive.google.com/drive/folders/1-ekihuuoOUflDFoXWLwHhOEAwr9tylMD?usp=sharing

Thanks and best regards,

Duy Tran

View solution in original post

toblerone90
Visitor
Visitor
561 Views
Registered: ‎05-15-2018

Hi DuyLionTran,

 

thanks a lot! I will dig into your sources as reference and will try to make it work on my platform and will come back with a feedback.

Best Regards

Martin

0 Kudos
DuyLionTran
Observer
Observer
536 Views
Registered: ‎08-11-2020

Hi @toblerone90 ,

Please let me know if I can help, looking forward to hearing from you.

I just updated my reply, adding the prebuilt image.

Thanks and best regards,

Duy Tran

0 Kudos
toblerone90
Visitor
Visitor
452 Views
Registered: ‎05-15-2018

Hi Duy,

as I first step I downloaded your binaries and booted the board. Can you please advise how to test the HDMI output port? I have connected a monitor but nothing is displayed. Do you have any console command for me to enter to test the output?

Thanks and regards

toblerone90

 

0 Kudos
DuyLionTran
Observer
Observer
419 Views
Registered: ‎08-11-2020

Hi @toblerone90 ,

The screen is automatically up when you power and boot the board, there is nothing to config. Can you share the boot log?

Thanks and best regards,

Duy

0 Kudos
toblerone90
Visitor
Visitor
375 Views
Registered: ‎05-15-2018

Hi Duy,

it was my bad - I noticed that I need to run the board from EXT4 filesystem -  I didn't noticed this first as there was my old filesystem present on the sd card

Thanks a lot - I can now see the desktop screen after booting. In your binaries, did you include the vdmafb and axidynckl modules into the source code or as KLM?

Unfortunately I need to make it running under 2020.1 (all my projects are based on that revision) so there is a bit work to do now for me - but with having your 2020.2 project as reference this should be doable. I will return once I have made some progress.

Best Regards

toblerone90

0 Kudos
DuyLionTran
Observer
Observer
360 Views
Registered: ‎08-11-2020

Hi @toblerone90 ,

Glad that you can run the binaries.

I suggest you re-clone the repo because there are some minor modifications. You can find the source code in project-spec/meta-user/recipes-modules.

However, I also suggest you to go the recipes-kernel to read the pynqz1-dev.patch file to understand more.

Please let me know if I can help. I hope you finish your project soon.

Best Regards,

Duy TRan

0 Kudos