Storing graphics?

roberts

New member
Hello,

Perhaps this is not the best forum to ask this, however I will try to post anyways since storage of graphics is somewhat still related to lcds.

I have a quick question about storing graphics in external flash memory. I have my own GL which is able to retrieve text, icons or pictures from an 8MEG flash and displays them on either a 1.5 " or 2.0" color LCD. Here's the thing though, when I am using the 1.5" LCD and I display an graphical icon it has to be a certain size. However if I display that same icon on the 2.0" LCD, it has to be slightly bigger. My question is, for us embedded guys that are using microcontrollers (PICS or AVR ...) with limited memory (comparing to today's memory in desktop computers) what are our options to do this.

I was stuck in storing that same icon in two different sizes in flash. Another option would be to store it in flash as the biggest size and according to the size required we palletize the icon to reduce it to any size we need and redisplay it on the LCD.

Is there such a utility or .c file that we can include in our code which resizes (or palletizes) graphics to a certain size so we can then display them.

All feedback is very appreciated.
Rob
Looking for additional LCD resources? Check out our LCD blog for the latest developments in LCD technology.
 

electronnovice

New member
Need help

Hi

I am trying to learn the basics required to build and program an LCD that plays videos. Please help me out by naming the basic parts/components/software I would need. I already know programming so I will be able to write the code once I know all the parts. It sounds like you are already doing this.
Please help or point me to a resource with the info. Much thanks electronnovice
 

roberts

New member
Hello CF support2,

I have breifly looked at the links and it looks good. I have my own LCD display system when it comes to displaying stuff on an LCD. However, I am storing two versions of the same pictures in flash just in different sizes so they can display on different size LCDs. That's my only pet peave right now. I will take a closer look at the links you provided... but from what I can see, they take an image and convert it to code and we must insert that code in our C modules.. is that it???

electronnovice, I was like you at the begining... I couldn't make heads or tails about these LCDs. But with motivation and patience I got there, and so will you. There is two basic ways to get into LCDs. The first is, you get yourself a GL, for example easyGUI and use their dirver and set of libraries to display stuff on the LCD. But this requires you to buy the package (approximately 1000$) and there is yearly fees for upgrades. And then there could be bugs which would be completely out of your control. Furthermore, you would have to deal with the time zone difference..... when I was informing myself I was up at 4 in the morning so I can catch tech support... If I would call in my early morning, it would be a risk as the availability window is approximately 2 hours. Also, if your project has a small potential ... meaning a 100 or 200 peices a year, then I would recommend some off the shelf library. But we are dealing with a huge *potential* thousands a year... so this is why we decided to go lean and mean and build our own GL. Also if you like to use other people's controls that's fine, but if you like to create your own like I do, either way its lots of time to devote.

The second way is to be naive like me and say... "maaaa! I could do this myself". Its been 3 years! and I am still working on it. But hey! mind you, I enjoyed myself building it and I don't have to depend on anyone.
But don't be fooled.... its alot of work!!!!!

If someone tells you that they got to display a picture on an LCD and did it in 1 week..... Yes, I probably believe him, but displaying a picture on a color LCD is the simplest thing ever. .... Its 1 for loop nested in another and the outer one is the rows and the inner the columns and inside the inner there is a data grabber and output logic for every pixel. But to design a complete system where you can display images, *custom controls* such as buttons/icons/text over other images and have transparency on certain controls and then clearing certain parts of a control over an image while maintaining the background data.... hehe! .... Is a lot of vork.

This is my third LCD I used, and you need to fiddle with atleats 2 of them before you to start getting the hang of things. In reference to the OTM2201A (Which is the one I am using currently). LCDs are pretty simple, but nonetheless there are a few key things you *must* know especially if you want to go down the route I took. For example the pixel color depth, the interface data bits(8 or 16), the control signals (RD, WR, RESET, DC REG and CS), Register selection interface (68/80 (MCU), RGB...), Horizontal/Vertical window addresses, Ram start and Ram access and I can't stress enough about the latter two.

Download the spec that crystalfonts offers on their site. You don't need to know every little thing thats on the spec.... but read it anyways. This will prompt you to some interesting questions and I am sure many individuals in this forum will be able to help you. Crystalfontz also has very good tech support.

I can't really hand you out a course right here and then on this forum there is just too much to know for jus one post, but read the spec about electrical characteristics, you can also look at the driver they show in the spec and get familiar how they set it up in respect to the registers also get familiar with the registers ... get familiar with the interfaces (p.35) but like I say do not go overboard and try to learn everything ... for now learn only what I mentioned... just skim through it and you will see you will get the hang of things.

Regards
Rob
 
Last edited:
Top