Society of Robots - Robot Forum

Software => Software => Topic started by: TheDarkLord on June 11, 2011, 09:27:15 AM

Title: Programming in C?
Post by: TheDarkLord on June 11, 2011, 09:27:15 AM
Hello everyone!
I'm relatively new to robotics, and I was wondering if any of you could point me towards some quick, learn-the-basics tutorials for C? Preferably tutorials that are robot-oriented.

Thanks in advance,
Vignesh R.
Title: Re: Programming in C?
Post by: waltr on June 11, 2011, 11:51:06 AM
On-line there is The C book:
http://publications.gbdirect.co.uk/c_book/ (http://publications.gbdirect.co.uk/c_book/)

For PIC processors there is the gooligum tutorial:
http://www.gooligum.com.au/tutorials.html (http://www.gooligum.com.au/tutorials.html)
This is more on how to use the C compiler for PICs then the C language.

The standard reference book for all C programming is K&R:
http://www.amazon.com/Programming-Language-2nd-Brian-Kernighan/dp/0131103628 (http://www.amazon.com/Programming-Language-2nd-Brian-Kernighan/dp/0131103628)
This has a fairly good tutorial on the basics of C programming.

Learning C has several parts:
The C language
The compiler and IDE
The target processor (PIC, AVR, ATmega, etc).

Do you have any programming experience?
Any processor experience?

Title: Re: Programming in C?
Post by: TheDarkLord on June 11, 2011, 02:03:20 PM
No, I have almost zero experience with processors. I have however programmed a few simple things in QBASIC several months ago.
Thank you so much for those links, much appreciation. I was wondering if there is a tutorial for Atmel processors similar to the one on PIC ones?
Title: Re: Programming in C?
Post by: newInRobotics on June 11, 2011, 03:33:06 PM
I was wondering if there is a tutorial for Atmel processors similar to the one on PIC ones?
You can find Atmel tutorials in Atmel page - normally where all documentation about certain microcontroller can be found.
Say for ATXMega128A1 (http://www.atmel.com/dyn/products/product_docs.asp?category_id=163&family_id=607&subfamily_id=1965&part_id=4298) a short tutorial, or should I say examples are placed in AVR035: Efficient C Coding for AVR (http://www.atmel.com/dyn/resources/prod_documents/doc1497.pdf) document or in AVR1000: Getting Started Writing C-code for XMEGA (http://www.atmel.com/dyn/resources/prod_documents/doc8075.pdf) document. My point is, that You can find everything related to certain Atmel product in the page of that product.