i want to learn how to program a microcontroller...

So im sure we all know how to use a arduino. Its so easy, the arduino enviroment does everything for you! I want to learn how to use a avr or pic. For testing purposes im planning on using it to control relays which will control christmas lights. Can someone point me in the right direction(some tutorials or something) and should i start with a pic or avr? my main concern is the software because i have a mac and no access to windows. The only microcontrollers that ive used are arduino and picaxe.

Thanks :blush:

Have you had a look over at the Playground?

haha nope, ill go look

isnt the playground only about arduino?

Yes, what do you expect on an Arduino forum?

AWOL:
Yes, what do you expect on an Arduino forum?

Cake and or pie. :wink:

well this is the microcontrollers section for "Standalone or alternative microcontrollers"

Doesnt that mean microcontrollers other than arduino?

(some tutorials or something)

http://www.mstracey.btinternet.co.uk/pictutorial/picmain.htm
http://www.winpicprog.co.uk/pic_tutorial.htm
http://www.pages.drexel.edu/~kws23/tutorials/PICTutorial/PICTutorial.html
If you go to Google and type in PIC Tutorial you will get more results.

software because i have a mac and no access to windows

Not sure about the software though since I don't have (or use) a mac.
Hope this helps.

What did they say about the Arduino over at the PIC forum?

im not sure, i never thought they had a pic forum, does microchip have a forum?

Imagine walking into a Ford dealership, and asking about a GM vehicle.

ccdjr106:
So im sure we all know how to use a arduino. Its so easy, the arduino enviroment does everything for you! I want to learn how to use a avr or pic. For testing purposes im planning on using it to control relays which will control christmas lights. Can someone point me in the right direction(some tutorials or something) and should i start with a pic or avr? my main concern is the software because i have a mac and no access to windows. The only microcontrollers that ive used are arduino and picaxe.

Thanks :blush:

Well, Arduino is built around an AVR, so you're already partway there. I got an ICSP programmer and downloaded WinAVR, that's one path you could go down. Or get AVR Studio from Atmel (no experience there, it's another one of those things I'm not getting around to). Also plan on spending considerable time reading the AVR datasheet(s). But that's half the fun!

I mentioned another microcontroller once, think I got away with it.

ccdjr106:
im not sure, i never thought they had a pic forum, does microchip have a forum?

Of course they do:

http://www.microchip.com/forums/Default.aspx?

ccdjr106:
well this is the microcontrollers section for "Standalone or alternative microcontrollers"

Doesnt that mean microcontrollers other than arduino?

Arduino doesn't make microcontroller chips, they just build on several of the Atmel AVR offerings.

http://www.avrfreaks.net/

It depends on how much C you know. I've been making everything I do in Arduino in parallel in straight AVR C. On Linux there is avr-gcc. OS X has CrossPack which is based off of Windows WinAVR.

CrossPack makes it really easy to create a new template with full 'make' and 'make install'. Which uses avr-gcc and avrdude. Everything you do here you can upload right now to your Arduino board.

Take a look at some of my very simple blinking code: https://github.com/jedediahfrey/Arduino/blob/master/C/simpleBlink/main.c
Be warned this isn't as simple as Arduino. You need to sleep with the AVR datasheet for your chip and keep in mind that AVR and Arduino pins do not match. This is the 2560 correlation: http://arduino.cc/en/Hacking/PinMapping2560 You also have to be very up on your C and binary logic.

this is the microcontrollers section for "Standalone or alternative microcontrollers"

Doesnt that mean microcontrollers other than arduino?

Arduino is not a microcontroller. Arduino is an environment and some libraries that run on several different microcontrollers (Mostly Atmel AVRs, but also some ARM an PIC32 chips. Except that they can't call themselves "Arduino." This forum is more about getting the Arduino environment to work for "other" microcontrollers than for helping existing Arduino users graduate beyond the Arduino environment...

You also overestimate the differences between the Arduino environment and "AVR programming." Arduino uses the same C/C++ compiler shipped with (for example) Atmel's AVRStudio, and you can write "real" AVR programs by simply ignoring the Arduino functions and doing things the hard way. Your choice whether you also want to avoid the standard C libraries and/or the C language itself.

Avrfreaks (as previously mentioned) has many tutorials http://smileymicros.com has some tutorials and books and things for AVRs, including some that specifically try to bridge the gap between Arduino and "real microcontroller programming."

Also, see this thread: http://www.arduino.cc/cgi-bin/yabb2/YaBB.pl?num=1257722764