This is only a preview of the June 2021 issue of Silicon Chip. You can view 37 of the 112 pages in the full issue, including the advertisments. For full access, purchase the issue for $10.00 or subscribe for access to the latest issues. Items relevant to "Advanced GPS Computer - Part 1":
Articles in this series:
Items relevant to "Recreating Arcade Pong":
Articles in this series:
Items relevant to "PIC Programming Helper":
Items relevant to "Programmable Hybrid Lab Supply with WiFi – Part 2":
Purchase a printed copy of this issue for $10.00. |
The New Arduino IDE 2.0
Review by Tim Blythman
The Arduino boards and software are incredibly popular,
mainly because of the free, powerful and easy-to-use
integrated development environment (IDE) for developing
code. Now there has been a significant revision of the IDE
with the beta release of version 2.0. Here is what you can
expect from it.
I
t was just in March last year that we
took an in-depth look at the Arduino ecosystem (siliconchip.com.au/
Article/12575). That article included
details on the history of the Arduino
software; primarily, the IDE.
Tracing its history back almost 20
years to the Wiring IDE (http://wiring.
org.co/), it has been nearly 10 years
since the official version 1.0 release
of the Arduino IDE.
It is open-source, which means that
it is easy to write libraries, add support
for new boards and even make clones
of existing boards.
Some people have noted that the
Arduino IDE lacks some features that
experienced programmers have come
to expect from other development
environments. These include features
such as debugging, auto-completion
and source code management.
command-line-based Arduino-cli
(command-line interface) and the
Arduino Pro IDE. We understand that
a lot of what has gone into the new IDE
has been informed by those programs.
First look
Opening up the IDE after installation
opens a window as shown in Screen
1. The overall appearance is similar
to older versions, but with a few extra
buttons down the left-hand side and a
new drop-down list near the top.
These extra buttons are to access the
Boards Manager, Library Manager and
the debugging and search functions.
These are features we expect to use
a lot, so it’s handy to have them just
one click away.
The new drop-down selects a board
and port combination. This makes it
easier to work with different projects,
as the board and port can be changed
easily and together, meaning less
chance of getting these mixed up or
changing one and not the other.
At this stage, the debugging function only works with some SAMD and
Mbed boards and requires a separate
debugging probe. So we weren’t able
to test that feature out.
The debugging console and controls
are visible in Screen 2. We also found a
comprehensive list of keyboard shortcuts; they are accessed from the File
→ Advanced → Keyboard Shortcuts
menu item.
The Output window is hidden
by default, so pressing the Verify or
Upload buttons doesn’t immediately
Arduino IDE 2.0
The Arduino IDE 2.0 was released
in February, and not long after that,
we downloaded it and tried it out. If
you don’t wish to switch over fully, it
can run alongside the current version
1.8.13 (and older versions). We downloaded the .zip installer version from
siliconchip.com.au/link/ab85
Note that Arduino IDE 2.0 is still in
the beta stage of development. This
means that it is essentially complete,
but still has some minor bugs and
glitches.
The blog announcement (found at
siliconchip.com.au/link/ab84) indicates that the new version will include
some of the requested features that we
mentioned above.
In the March 2020 article, we
noted that some Arduino software
variants had popped up, such as the
70
Silicon Chip
Screen 1: simply hovering your mouse over a keyword will bring up a tooltip,
pressing F12 will open the file where the keyword is declared.
Australia’s electronics magazine
siliconchip.com.au
Screen 2: the debug controls are shown at left, while the list of keyboard shortcuts is shown in the main editor window.
appear to do anything, which is disconcerting. Once the Output window
appears (when verification completes),
this is less of a problem.
The Boards Manager and Library
Manager now appear as panels in the
Editor window (see Screen 3), rather
than modal windows, meaning that
they don’t block working on sketches.
The Serial Monitor appears as a panel
rather than a separate window too.
The context-sensitive help feature
is also visible in Screen 1. In this
case, it is showing the value of an
enumerated symbol. This makes it
much simpler to follow and troubleshoot code inside sketches. It’s even
possible to right-click on an item in
the code to jump to the library file
which defines it.
Line numbering is turned on by
default, and small arrows allow functions to be collapsed, making it easier
to view and navigate a sketch.
Screen 3: the Library Manager is now
an integral panel and can be toggled
from the block button at left.
Screen 4: auto-completion is activated by the Ctrl-Space key combination; the
results are often very extensive.
siliconchip.com.au
Quirks
One slight problem we ran into was
that opening a new window takes a
few seconds in the IDE 2.0, while it is
practically instantaneous with older
versions. But this is not something
that needs to be done often.
We also noticed that the IDE did
not prompt us to save a changed file
when closing the window, but rather
it appears to save the changes without
prompting.
The auto-complete feature (see
Screen 4) is very comprehensive (for
boards that support it), giving a great
number of options, but we had to use
Ctrl-Space to trigger it, even though
this is not noted in the getting started
guide.
Interestingly, the IDE 2.0 does not
come with any board profiles installed.
This suggests that the Arduino developers no longer favour the older AVR
boards (their profiles came with older
versions of the IDE). Despite this, we
Australia’s electronics magazine
don’t think we’ll see them disappear
any time soon.
In any case, they are easy to install
from the Boards Manager. Otherwise,
the newer version has all the same
features and menu items in much the
same places, meaning that it’s straightforward to transition between the two.
Summary
While we haven’t had a chance to
test-drive the Arduino IDE 2.0’s full
range of features, we’re happy that it
does everything that the older versions
do and more. We’re looking forward to
testing out the debug feature once we
have the hardware required.
We haven’t come across any glitches
in the beta version that have been
show-stoppers, but we expect that
updated versions will quickly follow
that iron out some of the minor quirks
we noted above.
We’re planning to continue using
the Arduino IDE 2.0 to find out what
else it has to offer.
More information on using the new
and improved features of the IDE 2.0
can be found at siliconchip.com.au/
SC
link/ab86
June 2021 71
|