I'm trying to dig in and learn C. My end goal is to head more toward AVR programming and hardware so I downloaded AtmelStudio.
I'm working through a C primer book and wondering how to write console programs in AtmelStudio? All the project types seem to be AVR/ARM focused (makes sense) and require me to pick a Device.
Can I use AtmelStudio for just compiling simple programs and running them in a cmd window?
For programs intended to run in a Windows console window, may I suggest using MinGW? That's a port of the GCC C/C++/etc. compilers used by Atmel Studio, and the Code::Blocks IDE makes a nice match for that under Windows. I usually don't recommend software bundles, but there's a handy binary download codeblocks.org with a stable Code::Blocks and a recent stable MinGW.
As for using AtmelStudio to compile programs to run in a "cmd" window, the compilers used will will be some sort of cross-compiler for a CPU and OS that is not what you are running on. Unless you have an emulator for that target platform that runs in Windows console, then I think you're out of luck. Embedded systems typically don't have keyboard or console devices, so real programs won't have a classical Unix-style main()
function. You still can write and test functions that don't do console I/O or system calls. Properly coded, those will recompile without changes to run in either environment.