Searching \ for '[PIC]: Best C programming book for a beginner...' in subject line. ()
Make payments with PayPal - it's fast, free and secure! Help us get a faster server
FAQ page: www.piclist.com/techref/microchip/begin.htm?key=programming
Search entire site for: 'Best C programming book for a beginner...'.

Exact match. Not showing close matches.
PICList Thread
'[PIC]: Best C programming book for a beginner...'
2001\04\11@220120 by Jose S. Samonte Jr.

picon face
Hello everybody! =)
What is really the best, and easiest to understand, book for learning C
programming language?
Is it really OK to program PICs in C language?
Or is it better to program PICs in assembly language?
What is the difference between C and C++?
Could PICs be programmed in C++?

Thank you so much, in advance!
Best regards to all!

____________________________________________________________________
Get free email and a permanent address at http://www.netaddress.com/?N=1

--
http://www.piclist.com hint: To leave the PICList
spam_OUTpiclist-unsubscribe-requestTakeThisOuTspammitvma.mit.edu


2001\04\11@234911 by Bob Blick

face
flavicon
face
>What is really the best, and easiest to understand, book for learning C
>programming language?

For learning, "C for Dummies".
For reference, "The C Programming Language".

>Is it really OK to program PICs in C language?

Yes.

>Or is it better to program PICs in assembly language?

Yes.

>What is the difference between C and C++?

Not gonna touch that one.

>Could PICs be programmed in C++?

Could they? Not really possible unless you created it yourself.

Maybe you should visit Shane Tolmie's web pages and get some sample code,
and go to Htsoft and get PICCLITE, and don't ever use printf() with a PIC.

Cheerful regards,

Bob Blick

--
http://www.piclist.com hint: To leave the PICList
.....piclist-unsubscribe-requestKILLspamspam@spam@mitvma.mit.edu


2001\04\12@074214 by Bob Ammerman

picon face
> >What is the difference between C and C++?

C++ is basically an advanced version of C with object-oriented capabilities.
C is pretty close to being a subset of C++ (tho' there are a few gotchas).

> >Could PICs be programmed in C++?

I know of no compilers for C++ on the PIC. IMNSHO the 18C could support a
variant of C++ called Embedded C++ if someone were to write a compiler for
it.

Bob Ammerman
RAm Systems
(contract development of high performance, high function, low-level
software)

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads


2001\04\12@094021 by Lawrence Lile

flavicon
face
Good questions, Jose!

There are two really highly recommended books on C IMHO.
           1.  K&R (Kernigan and Ritchie??? Can't remember the spelling)
Wrote the original specification, also generally regarded as the best book
on C.  I don't own it.  Everybody raves about it

           2. POWER C from MIX software, 1132 Commerce Dr Richardson, TX
(214)783-6001  is a tutorial, reference book, and C compiler for the DOS PC
rolled into one.  Why use C on your PC?  You'l learn it faster.  You can
compile up tiny little programs and watch them display "Hello World" or
"Helluva World" on your computer display.  It starts at the real basics, and
goes through a good solid tutorial.  US$19.95, cheap.

Remember, C is C, no matter what platform you are on, the differences are
minor.

3.  Then you need C for a PIC.  I use PCB or PCM from CCS
http://www.ccsinfo.com/picc.html   each is about US$100, one does the 12 bit
parts (12C508-16C54) and one does the 14 bit parts (16F84-16F877).  You can
ask three PIClisters and get four opinions about CCS C.  I like it, some
hate it.

YES you can do C on a PIC.  I am actually getting rusty at Assembler because
I only code in C anymore.  Why?  It is way more productive than assembler.
However, all my programs drop into assembler once in a while to do something
tricky or fast.   C is slightly less code efficient than Assembler, but my
time is valuable.

Try coding this one-line of C into assembler:     stuff = SQRT(1 -
EXP(-S/(R*C)) .  Compiled, it's about 2000 lines of PIC assembler code.  See
what I mean about productivity?

C++ is a grandchild of C that is most at home in Windows type environments.
C++ is useless on a PIC because of code bloat.


LEARN ASSEMBLER FIRST.  If you don't know PIC assembler, you don't really
understand PICs yet.  Put off learning C until you can get a PIC to sing and
dance using assembler only.  You will always need assembler.


Lawrence Lile


{Original Message removed}

2001\04\12@112841 by Mike Mansheim

flavicon
face
>> What is really the best, and easiest to understand, book for learning C
>> programming language?

> For learning, "C for Dummies".
> For reference, "The C Programming Language".

I like "The Complete Reference C", by Herbert Schildt as a good mix of
teaching and reference.
Also, you can find all kinds of stuff about C on the web - faqs, tutorials,
etc.  One on-line tutorial I thought was a good intro to C is  from a class
given by a guy named Steve Summit.  It's at:
http://www.eskimo.com/~scs/cclass

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads


2001\04\12@120208 by Bill Westfield

face picon face
   > >What is the difference between C and C++?

   C++ is basically an advanced version of C with object-oriented
   capabilities.  C is pretty close to being a subset of C++

   > >Could PICs be programmed in C++?

   I know of no compilers for C++ on the PIC.


IMNSHO, The practical differences between C++ and C tend to include things
like C++ tending to use large runtime libraries and lots of dynamic memory
allocation; things that tend to be detrimental to small embedded systems.
We have constant arguments here on whether we should allow C++ code into OUR
imbedded systems, due to the possibilities of "code bloat" and "slow
execution" (and this on "systems" with 64M+ of memory and workstation class
CPUs.)  That isn't to say that there's nothing useful in C++, or that it's
not possible to write small efficient code in C++, but the general "style"
of C++ programming doesn't seem very compatible with small microcontrollers.

BillW

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads


2001\04\12@130946 by Neil Bradley

flavicon
face
>     > >What is the difference between C and C++?
>     C++ is basically an advanced version of C with object-oriented
>     capabilities.  C is pretty close to being a subset of C++

No, C++ is a superset of C. In fact, C++ started out its life as a
preprocessor to C. It's funny how so few people know this.

-->Neil

-------------------------------------------------------------------------------
Neil Bradley            Toda su base es pertenece a nosotros. Nadie instÃ
Synthcom Systems, Inc.  ¡lenos la bomba! Muévase, Zig! ICQ #29402898              
--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads


2001\04\12@131734 by Robert Francisco

flavicon
face
I'm a newbie in programming too but I found that C++ Primer by Stanley B.
Lippman, Sam's teachyourself C++ in 24 hours( J . Liberty) and Sam's
TeachYourself MFC in 24 hours by Liberty- seem to be very easy to
understand-especially for me whose native language is not English. The
second book also include a Borland C++ Lite compiler on CD. The MFC is for
pc/win32.

RF
{Original Message removed}

2001\04\12@135456 by David Cary

flavicon
face
Dear Jose S. Samonte Jr.,

Excellent question.

I agree with Lawrence Lile and Mike Mansheim that it's much easier to learn C on
a PC. There are nice tools for single-stepping through your C code, looking at
all the variables and how they change, etc. Most ANSI C programs will compile
and run on any computer, including the PIC. Often I have subroutines that I test
out on a PC before I recompile into my embedded system. And subroutines like CRC
calculation that I don't understand fully -- it's nice to run identical code on
all the various processors I use.

I highly recommend reading the C FAQ
 comp.lang.c Answers to Frequently Asked Questions (FAQ List)
 http://www.faqs.org/faqs/C-faq/faq/
 http://www.eskimo.com/~scs/C-faq/top.html

Although the FAQ is more of a reference than a tutorial, it does have a couple
of immediately relevent answers to the questions:
 What's a good book for learning C?
 Are there any C tutorials or other resources on the net?

Also check out
 [alt.comp.lang.learn.c-c++] - FAQ list
 http://www.faqs.org/faqs/C-faq/learn/
In particular, Mike Mansheim might be interested in what it says about ``a
certain Herbert Schildt''.

I personally found learning PIC assembler interesting,
and learning assembler helps one understand what "really goes on" when your C
program is running. This helps me work within the limited speed and memory of
the PIC. In particular, I've found that the concept of "pointers" is always
wierd to people who have never done assembly-language programming.

But if my goal is just to get something running, I wouldn't bother trying to
become ``fluent'' in PIC assembly or the MPASM macro language. (Since there's
only 40 or so instructions, it shouldn't take more than a day to skim through
it).

Yesterday someone mentioned
 SDCC Pic Port - Is a port of SDCC - Small Device C Compiler to the PIC.
 http://www.dattalo.com/
-- Is this working yet ? Are there any other open-source compilers for the PIC ?

My understanding is that a program called ``cfront'' converts C++ code to plain
C code. Has anyone tried this out ?

--
David Cary

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads


2001\04\12@142924 by Mike Mansheim

flavicon
face
> Also check out
>   [alt.comp.lang.learn.c-c++] - FAQ list
>   http://www.faqs.org/faqs/C-faq/learn/
> In particular, Mike Mansheim might be interested in what it says
> about ``a certain Herbert Schildt''.

That was interesting.  For anyone else curious:  while giving a
bunch of general information about finding suitable C & C++ books,
he says experts specifically recommend avoiding ANY Schildt book.

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads


2001\04\12@144044 by Dale Botkin

flavicon
face
On Thu, 12 Apr 2001, Robert Francisco wrote:

> I'm a newbie in programming too but I found that C++ Primer by Stanley B.
> Lippman, Sam's teachyourself C++ in 24 hours( J . Liberty) and Sam's

Mine is "Teach Yourself C++ in 21 Days"...  24 hours would be quite a
speed reading feat, this sucker makes a good door stop.

Dale
---
The most exciting phrase to hear in science, the one that heralds new
discoveries, is not "Eureka!" (I found it!) but "That's funny ..."
               -- Isaac Asimov

--
http://www.piclist.com hint: PICList Posts must start with ONE topic:
[PIC]:,[SX]:,[AVR]: ->uP ONLY! [EE]:,[OT]: ->Other [BUY]:,[AD]: ->Ads


2001\04\12@210812 by Randy Glenn

picon face
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

There is / was a C++ compiler for PICs and SX chips - Pavel Baranov's
C2C++. He sold the rights to Kanda, who don't seem to have any info
on it on their site.

You can still download a demo from his site -
http://www.geocities.com/SiliconValley/Network/3656/c2c/cpp.html -
you just can't get a registered copy.

- -Randy Glenn

If you have to ship styrofoam, what DO you pack it in?
=================================================
Randy_Glenn-at-tvo.org - PICxpert-at-picxpert.com
PICxpert-at-yahoo.com - PICxpert-at-home.com
           http://www.picxpert.com/
=================================================

- {Original Message removed}

More... (looser matching)
- Last day of these posts
- In 2001 , 2002 only
- Today
- New search...