arduino-tips-tricks-and-techniques.pdf
(
2487 KB
)
Pobierz
Arduino Tips, Tricks, and Techniques
Created by Ladyada
Last updated on 2013-08-10 10:30:26 AM EDT
Guide Contents
Guide Contents
Arduino UNO FAQ
Arduino Timeline
New USB Chip
More 3.3v power!
UNO R2 and R3
2
4
4
5
12
13
Arduino Libraries
Need Help Installing a Library?
What is a library?
Using Libraries
What's in a library?
It's important to remember!
How to install libraries
15
15
15
15
16
17
18
Bootloader
Bootloader for the Atmega328
"No-Wait" Bootloader
No-Hang Bootloader
Upload Sketches with AVRDUDE
19
19
19
20
21
Upgrade
Introduction
Replace the Chip
Download an Arduino IDE with ATmega328 compatibility
23
23
23
24
3.3V Conversion
Introduction
Replace the Regulator
Replacing the Fuse
25
25
25
28
Arduino Hacks
Bumpers
Free up some RAM
31
31
31
ArduinoISP
© Adafruit Industries
http://learn.adafruit.com/arduino-tips-tricks-and-techniques
33
Page 2 of 39
Introduction
Parts
Assemble
Load the Code
Bonus! Using with AVRdude
33
33
33
36
37
Support Forums
39
© Adafruit Industries
http://learn.adafruit.com/arduino-tips-tricks-and-techniques
Page 3 of 39
Arduino UNO FAQ
There's so many Arduino's out there, it may get a little confusing. We wanted to clarify for
people some of the changes in the latest version.
NB
this is just our opinion and interpretation of some of the decisions made by Arduino. We
aren't associated with Arduino, and don't speak for them! If you have to get an Official
Response to your Arduino question please contact them directly. Thx!
NB2
Still in progress, we're collecting common questions to answer. If you have more
questions, please post them in our
forums (http://adafru.it/forums).
Arduino Timeline
But first…some history! First there was the serial Arduino (what's the name of it?) with RS232
which was not used outside of the Arduino team & friends.
The first popularly manufactured Arduino was called the NG (New Generation, like Star Trek,
yknow?) The NG used the Atmega8 chip running at 16 MHz and an FT232 chip for the USB
interface. The bootloader takes up 2KB of space and runs at 19200 baud.
The next version was the Diecimila. The Diecimila updated the chip from the Atmega8 to the
Atmega168. The great thing here is double the space and memory (16K instead of 8K). It still
ran at 16MHz. The Diecimila also added two extra header pins for 3.3V (from the FTDI chip) and
the reset pin which can be handy when a shield is covering up the Reset button. The bootloader
takes up 2KB of space and runs at 19200 baud. Auto-resetting was also added which makes
life awesomer for everyone.
In 2009, the Duemilanove was released. This one also upgraded the chip again, to the
Atmega328. Yet another doubling of space and memory! Another upgrade is now the power is
automagically switched between USB and DC-jack which removed the previous jumper. This
© Adafruit Industries
http://learn.adafruit.com/arduino-tips-tricks-and-techniques
Page 4 of 39
automagically switched between USB and DC-jack which removed the previous jumper. This
makes it easier and faster to move from programming to standalone and got rid of some
confusion. The bootloader takes up 2KB of space and runs at 57600 baud.
In 2010, we have the Uno! The Uno still uses the 328P chip and the power switcher. It has a
smaller bootloader called OptiBoot (more space for users' projects) that runs at 115K. So even
though the chip is the same, you get another 1.5K of extra flash space that was previously used
by the bootloader. The FTDI chip has also been replaced with a atmega8u2 which allows for
different kinds of USB interfaces. Finally, there's an extra 3.3V regulator (LP2985) for a better
3.3V supply. whew!
New USB Chip
So! All of the older Arduinos (NG, Diecimila and Duemilanove) have used an FTDI chip (the
FT232RL) to convert the TTL serial from the Arduino chip (Atmel ATmega). This allows for
printable debugging, connecting to software like PureData/Max, Processing, Python, etc. etc. It
also allows updating the firmware via the serial bootloader.
The good news about the FT232RL has royalty-free drivers and pretty much just works. The
bad news is that it can -only- act as a USB/Serial port. It can't act like a keyboard, mouse, disk
drive, MIDI device, etc.
The Uno has changed that by exchanging the FT232RL chip with an atmega8u2 chip. There are a
few things that are possible with this new chip but before we discuss that lets make it clear that
by default, this chip acts identically to the FTDI chip that it replaces. It's just a USB-serial port!
One improvement in updating the chip is that, previously, Mac users needed to install FTDI
drivers. The 8u2 imitates a 'generic' CDC serial device. So now, Mac users do not have to install
a driver. Windows users still need to install the .INF file but luckily there are no drivers. This
means there will be fewer problems with new versions of windows. There is no way to have a
serial USB device that doesn't require an INF file in windows, sadly :(
The big thing that is nice about the 8u2 is that
advanced
users can turn it into a different kind
of USB device. For example it can act like a keyboard or mouse. Or a disk driver. Or a MIDI
interface, etc. Right now there are no examples of how to do this, but we hope to post some
© Adafruit Industries
http://learn.adafruit.com/arduino-tips-tricks-and-techniques
Page 5 of 39
Plik z chomika:
MamToCzegoChcesz
Inne pliki z tego folderu:
adafruit-arduino-lesson-9-sensing-light.pdf
(788 KB)
Arduino-sample-code-EZ-COM-MEGA.pdf
(733 KB)
ArduinoTutorials(1).pdf
(1570 KB)
RobotOpen_Lib_v1_1_x.pdf
(62 KB)
adafruit-proto-shield-arduino.pdf
(2555 KB)
Inne foldery tego chomika:
Zgłoś jeśli
naruszono regulamin