And what if you treat Arduino as a language in itself, and not a simplification or jumping point for specifically C++? What about transitioning to C or javascript, or Python, etc.? Is having learned C++ instead of Arduino much different in this case?
And, are the majority of makers that Arduino is targeted to likely to want to transition to something else? If they do, I suspect that they have a high enough interest in programming to make the effort.
And do you think itâs more trouble than it would be explaining to former Python users why their C code doesnât work?
Again, Iâm making the point that Arduino should be treated as a separate language, closely related to, but not identical to, C++ or C. The Arduino Reference talks about the Arduino programming language. It makes no mention of C++.
Arduino marketing department can call it whatever they want. Its C/C++ with a bunch of macros, libraries and a make system. If it were not so, you couldnât use a C compiler to make identical code from the command line.
Directly from Arduino official FAQ on arduino.cc:
"
Can I program the Arduino board in C?
In fact, you already are; the Arduino language is merely a set of C/C++ functions that can be called from your code. Your sketch undergoes minor changes (e.g. automatic generation of function prototypes) and then is passed directly to a C/C++ compiler (avr-g++). All standard C and C++ constructs supported by avr-g++ should work in Arduino. For more details, see the page on the Arduino build process."
From a programmerâs point of view I agree.
If someone is going to be serious about programming hardware they should learn to use the language properly from the start.
I understand the desire to want it to be simple, but (as I mention later on) if they wanted it to be accessible to people who donât actually want to program then they could have made some better choices.
Iâd be more inclined to do that if they had a standalone âArduino Languageâ compiler, but as long as theyâre relying on a poorly written translator itâs like someone thinking putting a paper bag over their head is a good disguise.
If they really wanted to target people who donât actually want to program and just want to get their trinkets whirring then they could have picked any number of languages that are easy to learn, like BASIC or Scratch.
Yes it does:
STRUCTURE
The elements of Arduino (C++) code
Normally Iâm telling people that the code they write for the Arduboy is C++ because they have to use C++ to use the Arduboy2 library, and that C is not a subset of C++.
But this oneâs not quite as clear cut because itâs about the Arduino suite as a whole.
Though for most âsketchesâ it probably would have to be a C++ compiler.
If you carry on that chain it becomes âassembly is just machine code with extra processingâ and then âmachine code is just a bunch of circuitsâ and then âcircuits are just atoms and electricityâ.
Been using Atom and PlatformIO plugin to play around with Pokitto for a few days now on Fedora Linux. I must say even with the few hiccups at the beginning it is much easier for me to work on this from the comfort of a system I already am used to. And with now internet connection