Intel® FPGA University Program
University Program Material, Education Boards, and Laboratory Exercises
1175 Discussions

hello, can anybody show me how to read an image from onchip memory then display on vga monitor. I am using d2-115 board. thanks

rkaib
Beginner
1,063 Views
 
0 Kudos
17 Replies
AnandRaj_S_Intel
Employee
684 Views

Hi,

 

Attached an example of DE-2 try to go through it and implement for d2-115.

 

Also look into example below for d2-115 without on chip ram which can be modified.

https://www.digikey.com/eewiki/pages/viewpage.action?pageId=15925278

 

Regards

Anand

0 Kudos
rkaib
Beginner
683 Views

thank you AnandRs, I have looked into your document and example, but I would like something with nios 2 because I am using onchip memory that I Intialized with an image in .hex but It is not read properly from nios2 before getting displayed in the vga monitor. thanks in advance

0 Kudos
rkaib
Beginner
684 Views

I am getting this mistake message "project elf section bss is not within region onchip_memory2_0'", could you help debug it plz

0 Kudos
AnandRaj_S_Intel
Employee
684 Views

​Hi @rkaib​ ,

 

Memory overflow issue.

 

Increase your onchip ram(onchip_memory2_0) size in QSYS System design.

Which will solve the problem.

 

Let me know if this has helped resolve the issue you are facing or if you need any further assistance.

 

Regards

Anand

0 Kudos
rkaib
Beginner
684 Views

thanks Anand, I have tried to increase the size but still the same problem.

could plz have quick look on it attached.

maybe I am using too much of component because I used an example from university program. I am just looking for reading the image desert.hex from the onchip memory then display in vga.

thanks

0 Kudos
AnandRaj_S_Intel
Employee
684 Views

Hi,

 

  1. Increase your onchip ram(onchip_memory2_0) size in QSYS System design.
  2. Clean the eclipse project -> generate the BSP -> build the project and check

Please upload project, Image are not giving any clue.

 

Regards

Anand

0 Kudos
rkaib
Beginner
684 Views

hi Anand,

I have done the 2 steps of your last post but nothing changed.

attached you can find the project, I hope you can show me how to fix it.

and just remember, all I need is to read the image (here desert.hex) from the onchip memory

then display it on VGA.

the part I am stuck in is reading correctly the image from the memory as different values seem to pop up.

thanks Anand

0 Kudos
AnandRaj_S_Intel
Employee
684 Views

​Have you solved "project elf section bss is not within region onchip_memory2_0"???

0 Kudos
rkaib
Beginner
684 Views

not yet. in the project Ithat I sent you they use an SDRAM, I do not get that message but the data read are nor correct. but if I remove the sdram and use just the on chip memory or even with the sdram and I point in the on chip memory in the link script I get that message again.

the best option for me is to use just the on chip memory, but if it is mandatory I can look into using the sdram.

hope it is clear for you now

0 Kudos
AnandRaj_S_Intel
Employee
684 Views

Okay, thanks for the information.

Let me check and come back.

0 Kudos
AnandRaj_S_Intel
Employee
684 Views

​Hi,

 

I have used onchip ram  in your project, Please check attached.

Create your own eclipse project and check.

Note : Not tested

 Let me know if this has helped resolve the issue you are facing or if you need any further assistance.

 

Regards

Anand

AnandRaj_S_Intel
Employee
684 Views
0 Kudos
rkaib
Beginner
684 Views

hi AnandRS,

thanks for all this effort, sorry for not keeping you updated,

I will try to test it and come back to you as soon as I can,

Regards

0 Kudos
rkaib
Beginner
684 Views

Thank you very much AnandRS for your last post, It definetely helped me a great deal.

I have tested your code and It worked fine but with some minor issues:

1. I changed another .hex image (maube mine was not good),

2.It works exclusively with DE2-115-Computer_time_limited.sof (and not with DE2-115-Computer.sof ),

Neverthless I can manage now.

another problem if you do not mind is in the qualirt of the displayed image in VGA which is bad,

I am using :

alt_up_video_dma_dev* video;

video=alt_up_video_dma_dev("/dev/VGA_Subsystem_VGA_Pixel_DMA");

read RGB image from memory then putting them into img1,img2,img3 respectively .

loop:

alt_up_video_dma_draw(video,img1[i][j]*65536+img2[i][j]*255+img3[i][j]*65536,i,j,1):

end loop

 

any clue?

thanks in advance AnandRS ;

0 Kudos
AnandRaj_S_Intel
Employee
684 Views

Hi,

 

  1. Check hardware connection and monitor.
  2. ​Check timing constrain.
  3. Check how image is read from memory.
  4. Check IP configuration.
  5. Use signal-tap for debugging.

 

The code looks good.

 

We are diverting from actual question Please open new case for new question, which will help other user during forum search.

Thank you for contacting the Support team. We have resolved primary issue and closed your ticket. 

 

Regards

Anand

0 Kudos
rkaib
Beginner
684 Views

ok, I will.

thank you very much Anand, It has been very helpful

regards

0 Kudos
rkaib
Beginner
684 Views

ok, thank you very much Anand, I will

best regards.

0 Kudos
Reply