CCS C Software and Maintenance Offers
FAQFAQ   FAQForum Help   FAQOfficial CCS Support   SearchSearch  RegisterRegister 

ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

CCS does not monitor this forum on a regular basis.

Please do not post bug reports on this forum. Send them to CCS Technical Support

book for study

 
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion
View previous topic :: View next topic  
Author Message
Flumkin



Joined: 24 Dec 2013
Posts: 5
Location: Coimbatore

View user's profile Send private message

book for study
PostPosted: Tue Dec 24, 2013 1:19 am     Reply with quote

I'm interesting in learning c coding in microcontroller(16f877a) using ccs compiler... please suggest any book....
Ttelmah



Joined: 11 Mar 2010
Posts: 19520

View user's profile Send private message

PostPosted: Tue Dec 24, 2013 1:39 am     Reply with quote

1) Use one of the on-line primers. Cheap!.....
2) Add to this the 'real' C reference work. "The C programming language", by Brian Kernighan and Dennis Ritchie (Prentice-Hall). This was the book that was published to describe C, when it originally launched. This really is the 'key' reference to what is legal in C. Problem is it is a bit 'technical', which is why the primer should come first.
3) Add the data sheet for the chip.
4) Add the CCS manual - there are a few key differences - specific to the PIC hardware and CCS. These are in the manual, but you should really learn basic C coding (on a PC) first.
5) Add the 'readme.txt' with the compiler, and a few other similar notes.

Voila!.

So you work from basic 'how to program in C', through the technicalities of what is legal, through to technicalities of what the chip can do, to to final 'I can program in CCS C'.

Best Wishes
Flumkin



Joined: 24 Dec 2013
Posts: 5
Location: Coimbatore

View user's profile Send private message

Thankyou
PostPosted: Tue Dec 24, 2013 2:30 am     Reply with quote

Thank you for helping...
temtronic



Joined: 01 Jul 2010
Posts: 9229
Location: Greensville,Ontario

View user's profile Send private message

PostPosted: Tue Dec 24, 2013 9:31 am     Reply with quote

also....

Look over the examples that CCS supplies !!! Most were written when the 877 was 'the' chip.You'' find 'drivers' for a lot of peripherals as well as 'how-to-do-it' programs.

hth
jay
gpsmikey



Joined: 16 Nov 2010
Posts: 588
Location: Kirkland, WA

View user's profile Send private message

PostPosted: Tue Dec 24, 2013 9:46 am     Reply with quote

Yes, definitely K&R "The C Programming Language" although recognize that while that book is considered as "the Bible" it will also cure insomnia ! Look at the intro C books at some place like Amazon.com - you can often preview many of the books on the web there and it will give you a chance to see which books work for you - everybody has a different book that just clicks for them. One important thing to understand with the C compiler (not just the CCS one) - they usually don't tell you where the error is in your code. They tell you when they finally realize they are confused which may be quite a few lines down from where the error(s) were Evil or Very Mad Be careful that you understand the difference between "=" and "==" (this is the one that tends to get me). The statement "if (x==2) " will be true if the variable "x" is equal to the value of 2. The statement "if(x=2)" will always be true and will set the variable x to the value of 2. One way around that is to learn to write the conditional as "if (2==x)" - that tests the value of x. If you write it that way and forget one of the "=" signs, then the compiler throws it out as an error (when I write it that way, I find I have fewer holes in my feet).

mikey
_________________
mikey
-- you can't have too many gadgets or too much disk space !
old engineering saying: 1+1 = 3 for sufficiently large values of 1 or small values of 3
newguy



Joined: 24 Jun 2004
Posts: 1908

View user's profile Send private message

PostPosted: Tue Dec 24, 2013 12:01 pm     Reply with quote

http://www.ccsinfo.com/forum/viewtopic.php?p=168473&highlight=book#168473
kender



Joined: 09 Aug 2004
Posts: 768
Location: Silicon Valley

View user's profile Send private message Send e-mail Visit poster's website Yahoo Messenger

PostPosted: Wed Dec 25, 2013 7:57 pm     Reply with quote

newguy wrote:
http://www.ccsinfo.com/forum/viewtopic.php?p=168473&highlight=book#168473


I'll second Embedded C Programming and the Microchip PIC by Barnett, Cox and O'Cull
_________________
Read the label, before opening a can of worms.
Flumkin



Joined: 24 Dec 2013
Posts: 5
Location: Coimbatore

View user's profile Send private message

thanks
PostPosted: Wed Dec 25, 2013 10:12 pm     Reply with quote

thank you friends........hope it will surely help me...... Smile
Display posts from previous:   
Post new topic   Reply to topic    CCS Forum Index -> General CCS C Discussion All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


Powered by phpBB © 2001, 2005 phpBB Group