Break down of the Code Reference.

Hi all. Prepare your eyes for that roll back into head moment, and get ready to post links that will confuse and astound me out of posting again.

I'm new to C++, have an intermediate level of electronics / circuit design knowledge and absolutely bugger all arduino experience. Yup, i'm that "noob" with about enough knowledge to do little more than confuse myself, so please be gentle. Iv'e read all the "read before posting" in all the forum topics and have little patience for the sarcasm and elitist attitudes presented by some, most of which have left me fearful of posting any questions. If you feel you may be one of these types, just don't bother replying.

Now onto the topic at hand : Is there a common sense breakdown of the Code Reference anywhere ?

What do I mean ?

The biggest issue i'm finding as a noob to C++ is the code reference here on the site has no classification for skill level. I have tried finding a tutorial suitable to no avail, as they are either too basic or too extreme. The reference here is a great example, suffering exactly the same problem. It's throwing everything at you all at once without any good real world descriptions that can be followed easily from a learners perspective.

Take the "&" Pointer Access Operand as an example. It even says in it's description that you can code plenty and never need to use it and it's not a beginners topic, yet it's still presented with everything else, ultimately just muddying the waters.

I have no one I can call on to teach me anything related to Arduino or C++ and so am going the self taught route. So the big question is this - does anyone have the patience and time to make a list ( or post a link to where it's already been done ) of the most important and relevant language references to learn for those at various levels of skill or a tutorial set ( with fluent English being used ) that does the same.


Beginners need to focus on learning these first

  • Int
  • For
  • If
  • Arithmetic Operations ( ALL )
  • get a good user friendly basic LCD library

Intermediate users, try these

  • do.....while
  • comparison operators
  • Boolean operators
  • TFT displays

Advanced Users, head melt with these

  • Serial and all it's subcommands
  • Advanced I/O commands
  • Character commands
  • arrays

Masochists, enjoy these

  • writing your own library
  • Stream and it's related functions
  • bit-wise operators

and so on.

Again, if all your going to do is post a "read this" taking me to a page equally as ambiguous and confusing as the base Arduino reference page I'll save you the wasted time, thank you for taking the time to read this post but just don't bother posting a reply.

If you have knowledge of and experience with a decent tutorial set that's not incomplete / that breaks these references into a list of used frequently by many vs rarely used by anyone, that would be of immense help and highly appreciated. We're all new to everything at some point or another, this is my moment.

Thanks in advance people, I can't wait to better understand how to learn C++ with arduino.

A great deal depends on your learning style.

Some people like to learn in a structured way like in school. Other people like to learn by studying examples - and the Arduino IDE comes with a great collection of examples that cover a great deal of what a beginner is likely to need.

In your list above you have "Serial" in your 3rd category. However I would argue that it needs to be at the top of the first category because it is the essential debugging tool that let's you see how your program is behaving.

And haven't you provided the answer to your own comment about the "&" Pointer Access Operand - it says you don't need it so you can skip that part.

I think it is essential to appreciate that you are only a novice programmer once. Assuming it is a subject that interests you then you very quickly move out of that category and it can be very difficult (perhaps impossible) to remember how it was when every part of the process looked like a sheer wall that you had to climb.

You could do other beginners a big favour by keeping track of your own experience and writing an introduction essay while you yourself are still a newbie.


Take the "&" Pointer Access Operand as an example

The '&' operator is the "address-of" operator, or introduces a reference, when used as a unary operator.
When used as a binary operator, it is the bitwise AND operator.

It is never an operand.

Itemised "Things to know" list.
Beginner level:

  1. learn that correct spelling, syntax and punctuation are key to success
  2. learn that words in programming have very precise meanings.
  3. pedantry is a virtue
  4. don't use goto until you are a very advanced programmer.
  5. goto 1)

Take the "&" Pointer Access Operand as an example

The reference stuff here is really just meant as a starting point. Once you get into stuff like that, you should really hit up a C++ tutorial. C++ is the language that the Arduino uses. Just google "C++ tutorial" and start going through one of them.

The only caveat to remember is that most of them are written for people programming a PC, so they'll be using cout where you might use Serial.print. And there won't be any digitalWrite or digitalRead or anything. But the language stuff about memory and arrays and pointers is what you want.

The problem is that it depends what you're doing. I tend to think serial is much more important than displays, for instance, and "for" loops much more difficult than "while" loops.

C at the basic level is a pretty simple language; I'm not sure that too much prioritization within that makes a lot of sense. Libraries and Arduino capabilities are another matter, but much more application-specific.

My hypothetical non-langauge-specific learning order goes something like:

  1. Data and Variables. Including important types of variables (int, long, float)
  2. Math operations and statements. The difference between an assignment and an equation.
  3. Basic input and output.
  4. Introduction to functions/subroutines.
  5. Decision-making: if/then/else, conditional expressions. Boolean values.
  6. Looping
  7. Arrays.
  8. Character arrays. Pointers, as they apply to character arrays.
  9. more I/O.

That's sort of your first-semester programming class. You'll not that it doesn't include anything about "pins" or other fundamental Arduino concepts. You might also notice that Arduino is missing an important thing or two - the "input" capabilities are very limited compared to the output capabilities, and C's concept of strings is ... horrid, compared to most beginning languages.

For better or worse, a good part of the Arduino Philosophy is that you should be able to jump in and start doing stuff WITHOUT going through any particular "education phase." Take an existing example, figure out how it works enough to make the modifications you need, and you're done.