I'm aware of different ways to load Arduino on an Atmega, have not tried it yet and probably will (have some on the way) but ultimately, I'd like to learn how to program them directly in their native language (C I think? or C++? I'm hoping C++). From the reading I did, I need to buy a programmer, such as a USBtinyISP and connect it to the proper pins of the MCU as per instructions and USB into the computer. There are ways to use a parallel or serial port but rather not rely on that as it's harder and harder to find computers that have those ports.
Then a program like avr-gcc is used to compile the code into a binary, then avrdude is used to load it on the chip. Am I on the right path here?
One thing I have not found though is actual programming tutorials. Like, showing how the framework works. How do you set pin parameters, general syntax, that kind of thing. Just looking for a good resource to get started.
Also, I'm open to other MCU platforms too, but ultimately I want to use a platform that will be easy to expand on and can use in actual projects that I may potentially decide to market at some point, so it also has to be a platform that would allow me to do that (Ex: no need to buy expensive license or anything of that sort). I know there's PIC too, have not read up much on those yet.
Hey! I'm assuming you're another beginner like me!
Most microcontrollers are programmed in C, although some do C++ (I think AVR does? I'm not sure. Either way, most programmers use C because it's more intuitive for the types of things you'll be doing with an MCU). If you've worked with Arduino before, you're in luck - because the Arduino language is essentially C with a couple of libraries added on.
Regarding compiling and all, the manufacturer will provide their own IDE. For AVR It's Atmel Studio. Go into that, hit compile then load and everything should be handled for you. At least usually. I have an XMEGA Xplained-A3BU board, which uses a bootloader (USB). So when I compile the binary in Atmel Studio I have to load it in a piece of software called FLIP and flash the board through that.
Hardware wise, the best way to do it is by getting an existing dev board. The one I have is fantastic, but a little expensive (was AUD$40).
Pin parameters, general syntax etc. should be given in tutorials and the datasheet. For AVR, they're sorted into "ports" of length 8 bit. Each port is a struct with a byte for pin direction, output data, input data, output configuration, interrupts etc. All explained under the "I/O ports" section of the manual.
If you want to save a bit of cash but still get acquainted with a "proper" MCU architecture, I
strongly recommend Cypress's PSoC.
Fantastic support, the best (free!) IDE I've ever used (it has this circuit layout thing that's fantastic), quite simple to use, some of the most versatile hardware on the market (It actually has a tiny little CPLD-esque thing on chip!), the dev boards cost as little as US$4 and come with a USB programmer. A little bit easier than AVR, too.
PSoC 4 chips are relatively cheap if you plan to go to market - about as much as a PIC32MX or XMEGA A4U, however they don't do USB.
And a single comment on PIC, because I've not used them much: the official starter kits are absolutely woeful.
No matter which way you go, though, good on you for getting away from Arduino.
There are so many far, far better options out there.
EDIT: One other thing! If you're going to get a PSoC4 board, get the 4200. The 4100 has no programmable digital and the 4000 lacks an ADC and DAC as well (or something similar - either way the 4100 and 4000 are only for people who plan to develop commercial applications on lower end chips).