
For example pin1 = MCLR/Vpp/RE3 but I have no idea what that means.
hope you can explain a little to me about this pic 18f4520.
Digg wrote:Ok first of you have quite a bit of confusion about what it is that is going on with this project. I will try to help you to the best of my abilities but I can not teach you everything you will need to do some more research on your own so that this will make more since to you.
Ok first of a rgb led is three leds in one. There are four pins that come out of it. A common cathode or '-' and an anode or '+' for each color: red, green, and blue. You can turn each one on individual or mix them for more colors. For instance you can turn the red and blue leds on you get a purple color.
Your next question is how to expand your design so that you can have more leds than you have pins. This can be done easily with latches. Latches are useful for many things and can be configured in several ways. The best way I can explain this to you is to tell you to think of them as memory. You can write data to them and it will hold those values until you tell it to change them. So with this in mind lets take a generic 8-bit latch. It will have a data bus which will consist of 8 lines, an enable and a clock. We will ignore the clock function of the latch to make things simple. Most enables are active low, which means that the latch is selected when logic '0' is on that pin. So when the latch is enabled whatever is on the data bus is stored in the latch. Whenever logic '1' is returned to the enable whatever was on the data bus is now stored on the latch and will stay there until you change it. I can go more in depth on this but it would be best if you found a good tutorial about exactly how this works.
You also have a problem with your microcontroller idea. A pic is a brand of microcontroller which is very common and easy to use. There is no such thing as an 8-bit it is a description of the microcontroller. It means that it works on 8-bit at a time. I cant think of a good way to explain this to you at this moment.
So lets look at your project...
You want to make an led globe with lets say 16 rgb leds. You have chosen to use a pic MC for the project. The pic I use most is the 18f4520. It has 4 8-bit ports and 1 4-bit port. Each led needs three lines to control it so 16x3=48. You will only have 36 I/O pins so you will need to use latches to expand your design. You then choose to use 6 8-bit latches to do this. You link all the data lines to one data bus. This will only take up one port, or 8 of your I/O pins. Now you need to address each latch to be able to write to it. There are many ways to do this but I will do it the easiest way possible. You will just use another port for this and connect the enables to the first six pins on that port. To write to any latch you drop the enable pin to logic '0' set the data to whatever you want the return it to '1'.
This is not complicated once you understand how all of the pieces fit together. You should really read brads 8x85 pov project as this will be a great help to you. His project is a bit more complicated than the one that I just explained but the circuit diagram is very helpful for an explanation of what i just explained.
I know I left some things out so please feel free to add to explanation.
Hope I was of some help