Hello guys! I have a development board of cyclone 2 DE2... It has an SD card input and a VGA output. My screens resolution is 1440-900. It is also a touch screen with 4 outputs(X+ , X- , Y+ , Y-). There are options that I could think of, If you can please tell me the easiest one and if you could how to do it! The first option is to upload pics to my SD card that will be shown directly on the vga screen. What I want is so one picture will be shown that has "links" to other pictures: ------------------------------------ - 1 2 - - - - - - 3 4 - ------------------------------------ ( The links will be determent by the axis of the touch screen: X+, X-, Y+, Y-... like: 15, 30, 40, 55) The number I press is the number of the picture( all I want to know is the concept of how to choose the location and teach the fpga board to know) if I press 1 a picture will be shown. The same for 2, 3 and 4. the pictures can be named like: 1.png, 2.png ... (If they have to be jpeg or a different one please tell me). And if I press the screen again it will come back to the first one. The second option The same idea of the program but I have the program "WinHex" which turns pictures to Hex code. can It be my picture instead the png or the jpeg? If there is an easier way please tell me. Also, please give my tips on how to do it! Thanks for all helpers!
To use files, you will need a file system like FAT. Doing SD-Card + FAT in Hardware without a processor/softcore will be a major pain! So I think your second option is better! I think you can read arbitrary addresses of the SD card over SPI, so reading a "file" is simply a matter of reading from the right address - much easier! The harder part will be getting the data from your PC onto the SD-Card in this plain format without a filesystem... I'm not sure Windows will allow you to do this, I'm thinking Linux + something like dd should work.
Is there a way I can do that program in any way possible? Most important, it cannot be connected to any computer, so linux cant be used...
Also I didnt mention but I HAVE TO use vhdl and not verilog or any other programming language!
Tom B wrote: > Is there a way I can do that program in any way possible? Most > important, it cannot be connected to any computer, so linux cant be > used... Best way would be to use a small 8bit softcore which access your sdcard ... There are plenty of FAT libraries for e.g. AVR and there also is a AVR softcore. And you don't need linux for ... Only task left is how to display content read from the SD-Card on the monitor ...
Can you tell me how does the FAT works? Like, is it just fetching the pictures or will it break them down to every bit and color of each one?
Hey guys! So I was browsing the internet and I have found a program which I can choose a picture and it will break it down to every pixel and its color in hex... How can I save each (long) row of hex code as one picture and to be able to choose between different pictures which will also be long rows of raw code? If I'll be able to do that I have this in the pocket!
Choose the right image format ... TIFF is afaik uncompressed ... BMP also can be stored uncompressed ... Still, there are some headers. Alternatively, you could spend 2h learning a programming language like java and decompress and save your images in raw format on a sdcard sector-wise ... Then you won't have to have FAT or a image decompression algorithm ... But unfortunately, completly without work done by you, there is no solution ;)
I think he could also merge all his hex file into a large text file as a container using hex editor and copy that text in to the formatted sd card.
You don't need to extract - you need to interprete the stream of bytes. And with a known format (like bmp) you know the meaning of each byte in the stream. Greetz J
Just to mentioned I made something similar and know that there is a tool WINHEX Pro, that is able to write raw data streams to sd-cards.
Ok... after I have uploaded the bmp file to the sd card, how can I tranfer it to the vga?
Tom B wrote: > how can I > tranfer it to the vga? Split your task in two: 1. generate VGA signals from display memory 2. read SD card an put data into the display memory Duke
The only thing I donk know Is how to READ the data from the sd card! Can anyone explain it to me?
Tom B wrote: > The only thing I donk know Is how to READ the data from the sd card! > Can anyone explain it to me? You have to implement an SPI-interface for communicating with the sd card, then you have to implement a state machine which uses the interface for reading sectors from the sd card. There are tons of information about sd card and spi-interface ... Do you want me to google you this information? ;-)
I'm glad to be of service ... http://www.dejazzer.com/ee379/lecture_notes/lec12_sd_card.pdf Happy coding!
Please log in before posting. Registration is free and takes only a minute.
Existing account
Do you have a Google/GoogleMail account? No registration required!
Log in with Google account
Log in with Google account
No account? Register here.