Hardware Reference
In-Depth Information
Chapter 1
Arduino 1.0.4 Core Changes
If you are writing sketches, creating your own libraries, or making your own Arduino-compatible boards, the
Arduino 1.0.4 changes will affect you. Many of the changes optimize the Arduino IDE for improved workflow and
customization. Changes to the IDE include the removal of unused buttons, and the placement of the Compile and
Upload buttons next to each other. The Arduino IDE is now multilingual; you can pick a custom language for the
editor. These changes are only the visible portions—with these updates, the Arduino team took the opportunity to
make significant and code-breaking changes in order to deliver a more consistent and complete Arduino API.
The core libraries of the Arduino Core API have been overhauled as well. Additional improvements include better
support for making your own Arduino variations and the ability to integrate programmable USB devices with Arduino.
This chapter will go through these changes, what they mean, and how they will affect your code.
The changes break down into the following categories:
Arduino IDE
Sketches
API Core
Core libraries
Variant support for Arduino-derived boards
Changes to the Arduino IDE
The original file extension for Arduino was .pde . This is the Processing application file extension. If you had both
programs installed, Arduino files would be opened in the Processing program. Now, after the updates, Arduino
sketches have their own extension: .ino . Therefore, mysketch.pde is now named mysketch.ino . Double-click the file
name, and Arduino launches. You can change the preferences to support the older PDE extension, but by default,
PDE files simply open. Files will not be renamed to .ino unless you change the setting in the preferences.
The Arduino IDE editor now has line numbers in the lower-left corner, as shown in Figure 1-1 . Compile is the
first button, and the second button is Upload. The lower-right corner shows the selected board and what port it is
connected to. These changes make it possible to quickly debug simple errors by identifying the line of code, verifying
the correct serial port, and establishing whether the board is connected.
 
Search WWH ::




Custom Search