pic microcontroller

Thread Starter

sovannarith

Joined Feb 11, 2010
18
Dear All

Could you give me link to video showing the using of pic microcontroller? I'm just a beginner so I think video tutorial will help me.

Thank for helping
 

Tahmid

Joined Jul 2, 2008
343
Hi,
For videos, go to youtube or metacafe and search for PIC microcontrollers or PIC projects or something of that sort.
 

Thread Starter

sovannarith

Joined Feb 11, 2010
18
I know the tallest building in the world starts from the first brick that why I try to do a simple work with pic 16f876 and picket2 programmer I have. Could any one give me some simple code use with these devices. Example code that simple turn led on form a pin.

Thanks
 

Tahmid

Joined Jul 2, 2008
343
Hi sovannarith,
I don't know which language and compiler you use but if you are using mikroBASIC, try this:
Rich (BB code):
program LEDon
main:
   TRISB = 0 'Make PORTB output
   PORTB = 0 'Clear default PORTB values
   PORTB = 1 'Turn RB0 on
   while true 'Wait here forever
   wend
end.
mikroC:
Rich (BB code):
void main(void) {
   TRISB = 0; //Make PORTB output
   PORTB = 0; //Clear PORTB default state
   PORTB = 1; //Turn RB0 on
   while (1); //Wait here forever
}
You should download the datasheet from the Microchip website.

Hope this helps.
Tahmid.
 

spinnaker

Joined Oct 29, 2009
7,830
Sorry, I use MPASM in MPLAB. And could you give me the whole simple could including configuration...

Thank
Configuration depends on your particular PIC.

I suggest you purchase the PICKit 3 and Demo 18f45K22 board combination.

It comes with sample code for that PIC along with lessons.


I would have selected a 5V PIC for a newbie demo board but this is the one that microchip selected for whatever reason. Jut remember that is is 3.3V and be careful when switching from a 5V project.


Also check the link that mik3 posted.

But I like this one better

http://www.mikroe.com/en/books/pic-books/mikroc/


You really need to learn a bit about PICs before running code.
 

russ_hensel

Joined Jan 11, 2009
825
For beginners I strongly suggest that you use a high level language like C, JAL....
There are free compilers for small programs ( and sometimes large ) for most pic chips
See:Microcontrollers for Beginners also follow the link to using C
 
Top