Guide.Troubleshooting History

Hide minor edits - Show changes to markup

December 30, 2011, at 04:39 PM by David A. Mellis -
Changed lines 14-15 from:
  • Then, check that the proper port is selected in the "Tools > Serial Port" menu (if your port doesn't appear, restart the IDE with the board connected to the computer). If you don't seem to have a serial port for your Arduino board, see the following information about drivers.
to:
  • Then, check that the proper port is selected in the Tools > Serial Port menu (if your port doesn't appear, try restarting the IDE with the board connected to the computer). On the Mac, the serial port should be something like /dev/tty.usbmodem621 (for the Uno or Mega 2560) or /dev/tty.usbserial-A02f8e (for older, FTDI-based boards). On Linux, it should be /dev/ttyACM0 or similar (for the Uno or Mega 2560) or /dev/ttyUSB0 or similar (for older boards). On Windows, it will be a COM port but you'll need to check in the Device Manager (under Ports) to see which one. If you don't seem to have a serial port for your Arduino board, see the following information about drivers.
April 28, 2011, at 09:30 PM by David A. Mellis -
Changed lines 20-21 from:

The easiest way to check if the drivers for your board are installed correctly is by opening the Tools > Serial Port menu in the Arduino software with the Arduino board connected to your computer. Additional menu items should appear relative to when you open the menu without the Arduino connected to your computer.

to:

The easiest way to check if the drivers for your board are installed correctly is by opening the Tools > Serial Port menu in the Arduino software with the Arduino board connected to your computer. Additional menu items should appear relative to when you open the menu without the Arduino connected to your computer. Note that it shouldn't matter what name the Arduino board's serial port gets assigned as long as that's the one you pick from the menu.

April 06, 2011, at 10:50 PM by David A. Mellis -
Added lines 30-31:
  • On Windows, if the software is slow to start or crashes on launch, or the Tools menu is slow to open, you may need to disable Bluetooth serial ports or other networked COM ports in the Device Manager. The Arduino software scans all the serial (COM) ports on your computer when it starts and when you open the Tools menu, and these networked ports can sometimes cause large delays or crashes.
February 13, 2011, at 07:38 PM by David A. Mellis -
Changed lines 18-19 from:

Drivers provide a way for software on your computer (i.e. the Arduino software) to talk to hardware you connect to your computer (the Arduino board). In the case of Arduino, the drivers work by providing a virtual serial port (or virtual COM port). The Arduino Uno and Mega 2560 use standard CDC drivers provided by the operating system to communicate with the ATmega8U2 on the board. Other Arduino boards use FTDI drivers to communicate with the FTDI chip on the board (or in the USB-serial convertor).

to:

Drivers provide a way for software on your computer (i.e. the Arduino software) to talk to hardware you connect to your computer (the Arduino board). In the case of Arduino, the drivers work by providing a virtual serial port (or virtual COM port). The Arduino Uno and Mega 2560 use standard drivers (USB CDC) provided by the operating system to communicate with the ATmega8U2 on the board. Other Arduino boards use FTDI drivers to communicate with the FTDI chip on the board (or in the USB-serial convertor).

Changed lines 118-119 from:

Because the RX pin is unconnected, the bootloader on the board may be seeing garbage data coming in, meaning that it never times out and starts your sketch. Try tying the RX pin to ground with a 10K resistor (or connecting it to the TX pin).

to:

Because the RX pin is unconnected, the bootloader on the board may be seeing garbage data coming in, meaning that it never times out and starts your sketch. Try tying the RX pin to ground with a 10K resistor (or connecting RX directly to the TX pin).

Changed lines 127-128 from:

If you're using a USB board, make sure that the jumper (little plastic piece near the USB plug) is on the correct pins. If you're powering the board with an external power supply (plugged into the power plug), the jumper should be on the two pins closest to the power plug. If you're powering the board through the USB, the jumper should be on the two pins closest to the USB plug. This picture shows the arrangment for powering the board from the USB port.

to:

If you're using a Diecimila or older USB board (e.g. NG), make sure that the jumper (little plastic piece near the USB plug) is on the correct pins. If you're powering the board with an external power supply (plugged into the power plug), the jumper should be on the two pins closest to the power plug. If you're powering the board through the USB, the jumper should be on the two pins closest to the USB plug. This picture shows the arrangment for powering the board from the USB port.

February 13, 2011, at 05:06 PM by David A. Mellis -
Changed lines 40-41 from:
  • First make sure your board is on (the green LED is on) and connected to the computer (if it's not, see "what if my board doesn't turn on" above).
to:
  • First make sure your board is on (the green LED is on) and connected to the computer.
Changed lines 44-45 from:
  • Disconnect digital pins 0 and 1 while uploading (they can connected and used after the code has been uploaded).
to:
  • Disconnect digital pins 0 and 1 while uploading as they are shared with serial communication with the computer (they can connected and used after the code has been uploaded).
Added lines 50-51:
  • Try a different USB cable; sometimes they don't work.
February 13, 2011, at 05:04 PM by David A. Mellis -
Added lines 10-15:

Arduino Software

  • Make sure you have the right item selected in the Tools > Board menu. If you have an Arduino Uno, you'll need to choose it. Also, newer Arduino Duemilanove boards come with an ATmega328, while older ones have an ATmega168. To check, read the text on the microcontroller (the larger chip) on your Arduino board. For more information on the board menu items, see the guide to the Arduino environment.

  • Then, check that the proper port is selected in the "Tools > Serial Port" menu (if your port doesn't appear, restart the IDE with the board connected to the computer). If you don't seem to have a serial port for your Arduino board, see the following information about drivers.
Changed lines 18-19 from:
  • On Windows 7 (particularly the 64-bit version), you might need to go into the Device Manager and update the drivers for the Uno or Mega 2560. Just right click on the device (the board should be connected to your computer), and point Windows at the appropriate .inf file again (in the drivers/ directory of the Arduino software).
to:

Drivers provide a way for software on your computer (i.e. the Arduino software) to talk to hardware you connect to your computer (the Arduino board). In the case of Arduino, the drivers work by providing a virtual serial port (or virtual COM port). The Arduino Uno and Mega 2560 use standard CDC drivers provided by the operating system to communicate with the ATmega8U2 on the board. Other Arduino boards use FTDI drivers to communicate with the FTDI chip on the board (or in the USB-serial convertor).

The easiest way to check if the drivers for your board are installed correctly is by opening the Tools > Serial Port menu in the Arduino software with the Arduino board connected to your computer. Additional menu items should appear relative to when you open the menu without the Arduino connected to your computer.

  • On Windows 7 (particularly the 64-bit version), you might need to go into the Device Manager and update the drivers for the Uno or Mega 2560. Just right click on the device (the board should be connected to your computer), and point Windows at the appropriate .inf file again. The .inf is in the drivers/ directory of the Arduino software (not in the FTDI USB Drivers sub-directory of it).
Changed lines 26-31 from:

Arduino Software

  • Then, check that the proper port is selected in the "Tools > Serial Port" menu (if your port doesn't appear, restart the IDE with the board connected to the computer).

  • Make sure you have the right item selected in the Tools > Board menu. If you have an Arduino Uno, you'll need to choose it. Also, newer Arduino Duemilanove boards come with an ATmega328, while older ones have an ATmega168. To check, read the text on the microcontroller (the larger chip) on your Arduino board. For more information on the board menu items, see the guide to the Arduino environment.
to:
  • On Linux, the Uno and Mega 2560 show up as devices of the form /dev/ttyACM0. These are not supported by the standard version of the RXTX library that the Arduino software uses for serial communication. The Arduino software download for Linux includes a version of the RXTX library patched to also search for these /dev/ttyACM* devices. There's also an Ubuntu package (for 11.04) which includes support for these devices. If, however, you're using the RXTX package from your distribution, you may need to symlink from /dev/ttyACM0 to /dev/ttyUSB0 (for example) so that the serial port appears in the Arduino software.
February 13, 2011, at 04:44 PM by David A. Mellis -
Changed lines 8-15 from:

There are a few things that could be wrong.

  • First make sure your board is on (the green LED is on) and connected to the computer (if it's not, see "what if my board doesn't turn on" above).

  • Then, check that the proper port is selected in the "Tools > Serial Port" menu (if your port doesn't appear, restart the IDE with the board connected to the computer).

  • The Arduino Uno and Mega 2560 may have trouble connecting to a Mac through a USB hub. If nothing appears in your "Tools > Serial Port" menu, try plugging the board directly to your computer and restarting the Arduino IDE.
to:

There are many pieces involved in getting a program onto your Arduino board, and if any of them aren't right, the upload can fail. They include: the drivers for the board, the board and serial port selections in the Arduino software, access to the serial port, the physical connection to the board, the firmware on the 8U2 (on the Uno and Mega 2560), the bootloader on the main microcontroller on the board, the microcontroller's fuse settings, and more. Here are some specific suggestions for troubleshooting each of the pieces.

Drivers

Added lines 16-19:

Arduino Software

  • Then, check that the proper port is selected in the "Tools > Serial Port" menu (if your port doesn't appear, restart the IDE with the board connected to the computer).
Changed lines 22-29 from:
  • Disconnect digital pins 0 and 1 while uploading (they can connected and used after the code has been uploaded).

  • Try uploading with nothing connected to the board (apart from the USB cable, of course).

  • Make sure the board isn't touching anything metallic or conductive.

  • Check that you're not running any programs that scan all serial ports, like PDA sync applications, Bluetooth-USB drivers (e.g. BlueSoleil), virtual daemon tools, etc.
to:

Access to the Serial Port

  • Check that you're not running any programs that scan all serial ports, like USB Cellular Wifi Dongle software (e.g. from Sprint or Verizon), PDA sync applications, Bluetooth-USB drivers (e.g. BlueSoleil), virtual daemon tools, etc.
Added lines 30-45:
  • On Linux, you might try running the Arduino software as root, at least temporarily to see if fixes the upload.

Physical Connection

  • First make sure your board is on (the green LED is on) and connected to the computer (if it's not, see "what if my board doesn't turn on" above).

  • The Arduino Uno and Mega 2560 may have trouble connecting to a Mac through a USB hub. If nothing appears in your "Tools > Serial Port" menu, try plugging the board directly to your computer and restarting the Arduino IDE.

  • Disconnect digital pins 0 and 1 while uploading (they can connected and used after the code has been uploaded).

  • Try uploading with nothing connected to the board (apart from the USB cable, of course).

  • Make sure the board isn't touching anything metallic or conductive.

Auto-Reset

Changed lines 54-57 from:
  • Make sure there's a bootloader burned on your Arduino board. To check, connect an LED to pin 13 and reset the board. The LED should blink. If it doesn't, see the Bootloader page for instructions on burning a bootloader to the board.

  • If you have a really ancient Arduino board, you may need to change the baud rate at which sketches are uploaded to 9600 (from the normal 19200). You will have to change the speed in the preferences file directly. See the preferences page for instructions on finding the file. Look for the file in your computer and change the serial.download_rate property to match the one in your board. If you have such a board, it's recommended that you burn the latest bootloader (which works at 19200 baud). This can be done with the 'Tools | Burn Bootloader menu item.
to:

Bootloader

  • Make sure there's a bootloader burned on your Arduino board. To check, reset the board. The built-in L LED (which is connected to pin 13) should blink. If it doesn't, there may not be a bootloader on your board.


January 31, 2011, at 12:08 PM by David A. Mellis -
Added lines 18-19:
  • If you get this error when installing the Uno or Mega 2560 drivers on Windows XP: "The system cannot find the file specified", you might try this suggestion (about adding a "RunOnce" key to "HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion").
October 31, 2010, at 03:37 PM by David A. Mellis -
Changed lines 16-19 from:
  • On Windows 7 (particularly the 64-bit version), you might need to go into the Device Manager and update the drivers for the Uno or Mega 2560. Just right click on the device (the board should be connected to your computer), and point Windows at the same drivers again (in the drivers/ directory of the Arduino software).

  • Make sure you have the right item selected in the Tools > Board menu. In particular, newer Arduino Duemilanove boards come with an ATmega328, while older ones have an ATmega168. To check, read the text on the microcontroller (the larger chip) on your Arduino board. For more information on the board menu items, see the guide to the Arduino environment.
to:
  • On Windows 7 (particularly the 64-bit version), you might need to go into the Device Manager and update the drivers for the Uno or Mega 2560. Just right click on the device (the board should be connected to your computer), and point Windows at the appropriate .inf file again (in the drivers/ directory of the Arduino software).

  • Make sure you have the right item selected in the Tools > Board menu. If you have an Arduino Uno, you'll need to choose it. Also, newer Arduino Duemilanove boards come with an ATmega328, while older ones have an ATmega168. To check, read the text on the microcontroller (the larger chip) on your Arduino board. For more information on the board menu items, see the guide to the Arduino environment.
October 26, 2010, at 07:13 PM by David A. Mellis -
Added lines 16-17:
  • On Windows 7 (particularly the 64-bit version), you might need to go into the Device Manager and update the drivers for the Uno or Mega 2560. Just right click on the device (the board should be connected to your computer), and point Windows at the same drivers again (in the drivers/ directory of the Arduino software).
October 16, 2010, at 09:05 PM by David A. Mellis -
Added lines 14-15:
  • The Arduino Uno and Mega 2560 may have trouble connecting to a Mac through a USB hub. If nothing appears in your "Tools > Serial Port" menu, try plugging the board directly to your computer and restarting the Arduino IDE.
June 13, 2010, at 10:49 PM by David A. Mellis -
Changed lines 74-75 from:

this is what's happening. Look for unusual sequences involving "double-quotes", "single-quotes", \backslashes, comments, etc. In particular the sequence '\"' seems to cause problems; use '"' instead.

to:

or:

	at com.oroinc.text.regex.Perl5Matcher._match(Perl5Matcher.java)
	at com.oroinc.text.regex.Perl5Matcher._match(Perl5Matcher.java)
	at com.oroinc.text.regex.Perl5Matcher._match(Perl5Matcher.java)
	at com.oroinc.text.regex.Perl5Matcher._match(Perl5Matcher.java)
	at com.oroinc.text.regex.Perl5Matcher._match(Perl5Matcher.java)
	at com.oroinc.text.regex.Perl5Matcher._match(Perl5Matcher.java)
	at com.oroinc.text.regex.Perl5Matcher._match(Perl5Matcher.java) 

this is what's happening. Look for unusual sequences involving "double-quotes", "single-quotes", \backslashes, comments, etc. For example, missing quotes can cause problems and so can the sequence '\"' (use '"' instead).

June 06, 2010, at 10:58 PM by David Cuartielles -
Changed lines 1-70 from:
to:
Changed lines 72-166 from:

at com.oroinc.text.regex.Perl5Matcher._pushState(Perl5Matcher.java) @]

esto es lo que está pasando. Puedes buscar secuencias inusuales que supongan "comillas dobles", "comilla simple", las barras invertidas \, comentarios, etc, en particular la secuencia '\ "' parece ser la causa problemas, se recomienda el uso de '"' en su lugar.

# Externalpower

¿Porqué no arranca mi sketch cuando estoy alimentando la tarjeta con una fuente de alimentación externa? (Arduino Diecimila o anterior)

Hay una serie de tarjetas Arduino antiguas (unas 1000) que presentan el problema de tener una versión del bootloader que tiene el pin RX sin conectar la resistencia de pull-up interna. Esto produce que, en ocasiones, el bootloader piense que está recibiendo un nuevo programa, si bien se trata sólo de datos aleatorios. Esto se puede solucionar actualizando el bootloader a la última versión o conectando el pin RX con una resistencia de 10K a tierra.

¿Porqué se congela Arduino cuando intento cargar un programa? (En Windows)?

Esto podría ser causado por un conflicto con el proceso de Logitech LVPrcSrv.exe, que es un programa residente en tu ordenador. Abre el Administrador de tareas y comprueba si este programa se está ejecutando, y si es así, cierra ese proceso antes de intentar subir más datos a la placa [ más información ].

#Alimentación

¿Qué pasa si mi tarjeta no se enciende (el LED verde no se enciende)?

Si estás utilizando una tarjeta USB Diecimila o NG, asegúrate de que el puente (pieza de plástico pequeña cerca del conector USB) es en los pines correctos. Si tienes la certeza que tu placa recibe alimentación al usar una fuente de alimentación externa (conectado a la clavija de red), el puente debe ser más cercano a los dos pines para el cable de alimentación. Si, por el contrario, alimentas tu placa a través del puerto USB, el puente debe estar en los dos pines más cercanos a los conectores USB. Esta foto muestra la disposición para la alimentación de la placa del puerto USB.

Attach: jumper.jpg

# Wrongbootloader

¿Porqué mi Diecimila necesita tanto tiempo (6-8 segundos) para iniciar mi sketch?

Algunas de las placas de Arduino Diecimila (unas 1000) salieron de fábrica accidentalmente con el bootloader Arduino NG, este es un error que en ningún caso debiera manifestarse en placas Arduino posteriores al año 2008. En cualquier caso, tu placa funciona bien, pero requiere hacer reset manual de la placa al subir un sketch y necesita de ese tiempo de espera. Se puede reconocer el bootloader NG porqué el LED en el pin 13 parpadeará tres veces al efectuar presionar el botón de reset en la placa (el bootloader de la Diecimila sólo parpadeará una vez). Puede el bootloader correcto en su Diecimila, consulte la página del bootloader para más detalles.

# Inicio

¿Qué debo hacer si me da un error al lanzar arduino.exe en Windows?

Si obtienes un error al hacer doble click en el ejecutable arduino.exe en Windows, por ejemplo:

@ @ Arduino has encountered a problem and needs to close. @ @

tendrás que poner en marcha Arduino utilizando el archivo run.bat situado en la misma carpeta. Por favor, ten paciencia, el entorno Arduino puede tomar algún tiempo para abrir según la configuración de tu ordenador.

¿Porqué no se ejecuta Arduino en las versiones anteriores de Mac OSX?

Si obtienes un error como este:

 Link (dyld) error: 

dyld: / Applications/arduino-0004/Arduino 04.app/Contents/MacOS/Arduino símbolos Indefinido: 
/ Applications/arduino-0004/librxtxSerial.jnilib undefined referencia a _printf $ LDBL128 espera que esté definido en / usr / lib / libSystem.B.dylib  

es probable que necesites actualizar a Mac OSX 10.3.9 o posterior. Las versiones anteriores tienen versiones incompatibles de algunas librerías del sistema.

¿Qué hago si me da un error "UnsatisfiedLinkError ( librxtxSerial.jnilib native library )" al lanzar Arduino?

Si obtienes un error como este al iniciar Arduino:

@ @ Uncaught exception in main method: java.lang.UnsatisfiedLinkError: Native Library /Users/anu/Desktop/arduino-0002/librxtxSerial.jnilib already loaded in another classloader @ @

es probable que tengas una versión antigua de la biblioteca de comunicaciones en tu ordenador. Busca comm.jar, jcl.jar o en / System / Library / Frameworks / JavaVM.framework / o en los directorios del CLASSPATH o variables de entorno PATH.

¿Qué pasa con el error "No se pudo encontrar la clase principal."?

Si recibe este error al lanzar Arduino:

@ @ JJava Virtual Machine Launcher: Could not find the main class. Program will exit. @ @

asegúrate de que descomprimiste correctamente el contenido del fichero Arduino.zip - en particular, que el directorio lib está dentro del directorio Arduino y contiene el archivo pde.jar.

¿Qué puedo hacer al respecto de conflictos con cygwin en Windows?

Si ya tienes cygwin instalado en tu máquina, podrías obtener un error como este al intentar compilar un sketch en Arduino:

@ @ [main] ? (3512) C:\Dev\arduino-0006\tools\avr\bin\avr-gcc.exe: *** fatal error - C:\Dev\arduino-0006\tools\avr\bin\avr-gcc.exe: *** system shared memory version mismatch detected - 0x75BE0084/0x75BE009C.

This problem is probably due to using incompatible versions of the cygwin DLL.

Search for cygwin1.dll using the Windows Start->Find/Search facility and delete all but the most recent version. The most recent version *should* reside in x:\cygwin\bin, where 'x' is the drive on which you have installed the cygwin distribution. Rebooting is also suggested if you are unable to find another cygwin DLL. @ @

Si es así, primero asegúrate de que no tienes cygwin en ejecución cuando se utiliza Arduino. Si esto no funciona, puedes intentar eliminar las librerías cygwin1.dll del directorio Arduino y cambiarlas por cygwin1.dll de tu instalación existente de cygwin (probablemente en c: \ cygwin \ bin).

¿Porqué tardan el software Arduino y/o el menú Herramientas mucho tiempo en abrir (en Windows)?

Si el software Arduino tarda mucho tiempo en ponerse en marcha y parece bloquearse al intentar abrir el menú Herramientas, existe un conflicto con otro dispositivo en su sistema. El software de Arduino, al arrancar y al abrir el menú Tools, trata de obtener una lista de todos los puertos COM de tu ordenador. Es posible que un puerto COM creado por uno de los dispositivos de tu equipo ralentice este proceso. Echa un vistazo en el Administrador de dispositivos. Intenta desactivar los dispositivos que usan los otros puertos COM (por ejemplo, dispositivos Bluetooth).

# SerialPort

¿Porqué no mi no aparece mi placa en el menú Tools | Serial Port?

Si estás usando una placa USB Arduino, asegúrate de instalar los drivers FTDI (véase el link de instalación para instrucciones). Si estás utilizando un adaptador de USB a serie con una placa serie, asegúrate de instalar los drivers correspondientes.

Asegúrate de que la tarjeta está conectada: el menú del puerto serie se actualiza cada vez que abres la casilla Tools del menú, así que si acabas de desenchufar la placa, no estará en el menú.

Comprueba que no estás ejecutando ningún programa que escanea todos los puertos serie, como aplicaciones de sincronización de PDA, Bluetooth controladores USB (por ejemplo, BlueSoleil), etc

En Windows, el puerto COM asignado a la placa puede ser uno de código muy alto. En ocasiones se recomienda probar a cambiar el número asignado al chip FTDI por uno más bajo. Tal y cómo comenta Zeveland:

"Tuve un montón de puertos virtuales COM creados para Bluetooth por lo que la placa estaba configurada para utilizar COM17. El IDE no fue capaz de encontrarla de modo que suprimí los otros puertos virtuales en el Panel de control (en XP) y trasladó el puerto asignado al chip FTDI de Arduino a otro más bajo, en concreto el COM2. Asegúrate de configurar el IDE de Arduino para utilizar el nuevo puerto y buena suerte. "

En Mac, si tienes una versión antigua de los controladores de FTDI, puede ser necesario borrarlos y reinstalar la última versión. Mas información en esta conversación del foro para instrucciones en cómo proceder (gracias a GCK).

¿Qué pasa si recibo una "gnu.io.PortInUseException" al cargar código o utilizando el monitor de serie (en Mac)?

[@

to:

at com.oroinc.text.regex.Perl5Matcher._pushState(Perl5Matcher.java) @]

this is what's happening. Look for unusual sequences involving "double-quotes", "single-quotes", \backslashes, comments, etc. In particular the sequence '\"' seems to cause problems; use '"' instead.

Why doesn't my sketch start when I'm powering the board with an external power supply? (Arduino Diecimila or earlier)

Because the RX pin is unconnected, the bootloader on the board may be seeing garbage data coming in, meaning that it never times out and starts your sketch. Try tying the RX pin to ground with a 10K resistor (or connecting it to the TX pin).

Why does the Arduino software freeze when I try to upload a program? (on Windows)?

This might be caused by a conflict with the Logitech process 'LVPrcSrv.exe'. Open the Task Manager and see if this program is running, and if so, kill it before attempting the upload. more information

What if my board doesn't turn on (the green power LED doesn't light up)?

If you're using a USB board, make sure that the jumper (little plastic piece near the USB plug) is on the correct pins. If you're powering the board with an external power supply (plugged into the power plug), the jumper should be on the two pins closest to the power plug. If you're powering the board through the USB, the jumper should be on the two pins closest to the USB plug. This picture shows the arrangment for powering the board from the USB port.

Attach:jumper.jpg Δ

(thanks to mrbbp for report and picture)

Why does my Diecimila take such a long time (6-8 seconds) to start my sketch?

Some of the Arduino Diecimila boards were accidently burned with the Arduino NG bootloader. It should work fine, but has a longer delay when the board is reset (because the NG doesn't have an automatic reset, so you have to time the uploads manually). You can recognize the NG bootloader because the LED on pin 13 will blink three times when you reset the board (as compared to once with the Diecimila bootloader). If your Diecimila has the NG bootloader on it, you may need to physically press the reset button on the board before uploading your sketch. You can burn the correct bootloader onto your Diecimila, see the bootloader page for details.

What should I do if I get an error when launching arduino.exe on Windows?

If you get an error when double-clicking the arduino.exe executable on Windows, for example:

Arduino has encountered a problem and needs to close.

you'll need to launch Arduino using the run.bat file. Please be patient, the Arduino environment may take some time to open.

Why won't Arduino run on old versions of Mac OS X?

If you get an error like this:

Link (dyld) error: 

dyld: /Applications/arduino-0004/Arduino 04.app/Contents/MacOS/Arduino Undefined symbols: 
/Applications/arduino-0004/librxtxSerial.jnilib undefined reference to _printf$LDBL128 expected to be defined in /usr/lib/libSystem.B.dylib 

you probably need to upgrade to Max OS X 10.3.9 or later. Older versions have incompatible versions of some system libraries.

Thanks to Gabe462 for the report.

What do I do if I get an UnsatisfiedLinkError error (about native library librxtxSerial.jnilib) when launching Arduino?

If you get an error like this when launching Arduino:

Uncaught exception in main method: java.lang.UnsatisfiedLinkError: Native Library /Users/anu/Desktop/arduino-0002/librxtxSerial.jnilib already loaded in another classloader

you probably have an old version of the communications library lying around. Search for comm.jar or jcl.jar in /System/Library/Frameworks/JavaVM.framework/ or in directories in your CLASSPATH or PATH environment variables. (reported by Anurag Sehgal)

What about the error "Could not find the main class."?

If you get this error when launching Arduino:

Java Virtual Machine Launcher: Could not find the main class. Program will exit.

make sure that you correctly extracted the contents of the Arduino .zip file - in particular that the lib directory is directly inside of the Arduino directory and contains the file pde.jar.

What can I do about cygwin conflicts on Windows?

If you already have cygwin installed on your machine, you might get an error like this when you try to compile a sketch in Arduino:

6 [main] ? (3512) C:\Dev\arduino-0006\tools\avr\bin\avr-gcc.exe: *** fatal error - C:\Dev\arduino-0006\tools\avr\bin\avr-gcc.exe: *** system shared memory version mismatch detected - 0x75BE0084/0x75BE009C.

This problem is probably due to using incompatible versions of the cygwin DLL.

Search for cygwin1.dll using the Windows Start->Find/Search facility and delete all but the most recent version. The most recent version *should* reside in x:\cygwin\bin, where 'x' is the drive on which you have installed the cygwin distribution. Rebooting is also suggested if you are unable to find another cygwin DLL.

If so, first make sure that you don't have cygwin running when you use Arduino. If that doesn't help, you can try deleting cygwin1.dll from the Arduino directory and replacing it with the cygwin1.dll from your existing cygwin install (probably in c:\cygwin\bin).

Thanks to karlcswanson for the suggestion.

Why does do the Arduino software and the Tools menu take a long time to open (on Windows)?

If the Arduino software takes a long time to start up and appears to freeze when you try to open the Tools menu, there by a conflict with another device on your system. The Arduino software, on startup and when you open the Tools menu, tries to get a list of all the COM ports on your computer. It's possible that a COM port created by one of the devices on your computer slows down this process. Take a look in the Device Manager. Try disabling the devices that provide COM ports (e.g. Bluetooth devices).

Why doesn't my board show in the Tools | Serial Port menu ?

If you're using a USB Arduino board, make sure you installed the FTDI drivers (see the Howto for directions). If you're using a USB-to-Serial adapter with a serial board, make sure you installed its drivers.

Make sure that the board is plugged in: the serial port menu refreshes whenever you open the Tools menu, so if you just unplugged the board, it won't be in the menu.

Check that you're not running any programs that scan all serial ports, like PDA sync applications, Bluetooth-USB drivers (e.g. BlueSoleil), virtual daemon tools, etc.

On Windows, the COM port assigned to the board may be too high. From zeveland:

"One little note if you aren't able to export and your USB board is trying to use a high COM port number: try changing the FTDI chip's COM port assignment to a lower one.

"I had a bunch of virtual COM ports set up for Bluetooth so the board was set to use COM17. The IDE wasn't able to find the board so I deleted the other virtual ports in Control Panel (on XP) and moved the FTDI's assignment down to COM2. Make sure to set Arduino to use the new port and good luck."

On the Mac, if you have an old version of the FTDI drivers, you may need to remove them and reinstall the latest version. See this forum thread for directions (thanks to gck).

What if I get a gnu.io.PortInUseException when uploading code or using the serial monitor (on the Mac)?

[@

Changed lines 180-232 from:
 @] 

Esto probablemente significa que el puerto está actualmente en uso por otra aplicación. Por favor, asegúrate de que no estás ejecutando otros programas con acceso al puerto serie o puertos USB de tu placa, como la aplicación de sincronización de PDA, los administradores de dispositivos bluetooth, ciertos servidores de seguridad, etc. Además, ten en cuenta que algunos programas (por ejemplo, Max/MSP o Puredata) mantienen el puerto serie abierto, incluso cuando no los usas - puedes necesitar cerrar todos los parches que usan el puerto serie o salir de la aplicación por completo.

Si obtienes este error con Arduino 0004 o anterior, debieras actualizar a la última versión.

Tengo problemas con los controladores USB FTDI.

Intenta instalar los controladores más recientes de FTDI o ponte en contacto con su grupo de soporte en support1@ftdichip.com.

# Sketchstart

¿Porqué no arraca mi sketch al encender o reiniciar la placa Arduino?

Lo más probable es que alguna aplicación esté enviando datos en serie a tu placa al arrancar. Durante los primeros segundos, el bootloader (que viene pregrabado en tu placa) escucha la llegada de datos desde el ordenador. Después de unos segundos sin comunicación, el bootloader inicia el sketch que ya está en la placa. Si continúa el envío de datos hacia el bootloader, nunca se determinará el final de ejecución del bootloader y tu sketch no arrancará. Tendrás que encontrar una manera de cesar el envío de datos serie a la placa durante el tiempo que esta necesita para arrancar o grabar tu sketch en la placa con un programador externo, que sustituya al bootloader.

¿Porqué mi sketch parece que carga correctamente, pero no hace nada?

Es posible que hayas seleccionado tu placa apropiadamente, pero con la opción de microcontrolador equivocado. Asegúrate de que el microcontrolador corresponde al de tu placa (ya sea Atmega8, ATmega168, ATmega328, o ATmega1280) - el nombre está escrito en el más grande de los chips en la placa.

Comprueba si usas una fuente de alimentación ruidosa. Esto podría causar al chip perder su sketch.

Por otra parte, el sketch puede ser demasiado grande para la tarjeta. Al subir tu sketch, Arduino 0004 y posteriores comprueban si es demasiado grande para el ATmega8, pero basa su cálculo en un bootloader de 1 Kb. Podrías tener bootloaders de mayor tamaño (p.ej. 2 Kb de los 8 Kb disponibles en tu placa). Si empleas placas Arduino oficiales, este problema no se presentará.

Si tienes acceso a un AVR-ISP, AVR-ISP-MKII, el programador de puerto paralelo, o cualquier otro dispositivo externo de programación de chips de la marca Atmel, puedes grabar la última versión del bootloader desde el menú Tools | Burn Bootloader. De lo contrario, puedes determinar en el entorno Arduino la cantidad de espacio disponible para tus programas editando la variable upload.maximum_size en su archivo de preferencias (ver: instrucciones sobre cómo encontrar el archivo?).

# Size

¿Cómo puedo reducir el tamaño de mi sketch?

Los chips ATmega en la placa Arduino son barato, pero tienen limitaciones en el espacio reservado para tus programas: 7Kb para el ATmega8, 14Kb para el ATmega168 y ATmega328, y 124Kb para el ATmega1280 (el resto del espacio es usado por el bootloader).

Por ejemplo, un truco consiste en limitar que librerías usas. Si estás utilizando operaciones en coma flotante, trata de reescribir el código para usar números enteros, lo que debería ahorrar cerca de 2 Kb. Elimine los# include declaraciones en la parte superior de tu programa para eliminar las bibliotecas que no estás usando.

También puedes tratar de hacer tu programa más corto.

En cualquier caso, desde Arduino trabajamos para reducir el tamaño del núcleo de Arduino para dejar más espacio para tus programas.

¿Porqué no puedo obtener un PWM (una salida analógica) cuando llamo analogWrite () en los otros pines que 3, 5, 6, 9, 10 o 11? (Arduino Duemilanove y Diecimila)

El microcontrolador de la placa Arduino Duemilanove (ATmega328) y Diecimila (ATmega168) sólo es compatible con PWM / analogWrite () en los pines determinados. Llamadas analogWrite () en las patas otro dará alto (5 voltios) para valores mayores de 128 y bajo (0 voltios) para valores inferiores a 128. (Nótese que placas Arduino antiguas con Atmega8 sólo trabajan con salida PWM en los pines 9, 10 y 11.)

¿Porqué recibo errores acerca de funciones o tipos no declaradas?

El entorno Arduino intenta generar automáticamente prototipos de sus funciones, de modo que puedas llamarlos a tu gusto en tus programas. Este proceso, sin embargo, no es perfecto, y en ocasiones produce mensajes de error.

Si declaras un tipo personalizado en el código y creas una función que acepte o devuelva valores de ese tipo, obtendrás un error al intentar compilar el sketch. Esto se debe a que el prototipo automático para esa función aparecerá sobre la definición de tipo.

Si declaras una función con un tipo de retorno de dos palabras (por ejemplo, "unsigned int"), el entorno no se dará cuenta de que es una función y no creará un prototipo para ello. Eso significa que debes proporcionar tu propia definición, o colocar la definición de la función por encima de cualquier llamada a la misma.

¿Porqué recibo errores sobre un dispositivo de firma no válida cuando se trata de subir un sketch?

Si obtienes un error como:

[@

to:
 @]

This probably means that the port is actually in use by another application. Please make sure that you're not running other programs that access serial or USB ports, like PDA sync application, bluetooth device managers, certain firewalls, etc. Also, note that some programs (e.g. Max/MSP) keep the serial port open even when not using it - you may to need to close any patches that use the serial port or quit the application entirely.

If you get this error with Arduino 0004 or earlier, or with Processing, you'll need to run the macosx_setup.command, and then restart your computer. Arduino 0004 includes a modified version of this script that all users need to run (even those who ran the one that came with Arduino 0003). You may also need to delete the contents of the /var/spool/uucp directory.

I'm having trouble with the FTDI USB drivers.

Try installing the latest drivers from FTDI or contacting their support at support1@ftdichip.com.

Why doesn't my sketch start when I power up or reset the Arduino board?

Most likely because you are sending serial data to the board when it firsts turns on. During the first few seconds, the bootloader (a program pre-burned onto the chip on the board) listens for the computer to send it a new sketch to be uploaded to the board. After a few seconds without communication, the bootloader will time out and start the sketch that's already on the board. If you continue to send data to the bootloader, it will never time out and your sketch will never start. You'll either need to find a way to stop serial data from arriving for the first few seconds when the board powers (e.g. by enabling the chip that sends the data from within your setup() function) or burn your sketch onto the board with an external programmer, replacing the bootloader.

Why does my sketch appear to upload successfully but not do anything?

You have selected the wrong item from the Tools > Microcontroller menu. Make sure the selected microcontroller corresponds to the one on your board (either ATmega8 or ATmega168) - the name will be written on the largest chip on the board.

Check for a noisy power supply. It's possible this could cause the chip to lose its sketch.

Alternatively, the sketch may be too big for the board. When uploading your sketch, Arduino 0004 checks if it's too big for the ATmega8, but it bases its calculation on a 1 Kb bootloader. You may have a older bootloader that takes up 2 Kb of the 8 Kb of program space (flash) on the ATmega8 instead of the 1 Kb used by the current bootloader. If yours is bigger, only part of the sketch will be uploaded, but the software won't know, and your board will continually reset, pause, reset.

If you have access to an AVR-ISP or parallel port programmer, you can burn the latest version of the bootloader to your board with the Tools | Burn Bootloader menu item. Otherwise, you can tell the Arduino environment the amount of space available for sketches by editing the upload.maximum_size variable in your preferences file (see: instructions on finding the file). Change 7168 to 6144, and the environment should correctly warn you when your sketch is too big.

How can I reduce the size of my sketch?

The ATmega168 chip on the Arduino board is cheap, but it has only 16 Kb of program code, which isn't very much (and 2 Kb is used by the bootloader).

If you're using floating point, try to rewrite your code with integer math, which should save you about 2 Kb. Delete any #include statements at the top of your sketch for libraries that you're not using.

Otherwise, see if you can make your program shorter.

We're always working to reduce the size of the Arduino core to leave more room for your sketches.

Why don't I get a PWM (an analog output) when I call analogWrite() on pins other than 3, 5, 6, 9, 10, or 11?

The microcontroller on the Arduino board (the ATmega168) only supports PWM/analogWrite() on certain pins. Calling analogWrite() on any other pins will give high (5 volts) for values greater than 128 and low (0 volts) for values less than 128. (Older Arduino boards with an ATmega8 only support PWM output on pins 9, 10, and 11.)

Why do I get errors about undeclared functions or undeclared types?

The Arduino environment attempts to automatically generate prototypes for your functions, so that you can order them as you like in your sketch. This process, however, isn't perfect, and sometimes leads to obscure error messages.

If you declare a custom type in your code and create a function that accepts or returns a value of that type, you'll get an error when you try to compile the sketch. This is because the automatically-generated prototype for that function will appear above the type definition.

If you declare a function with a two-word return type (e.g. "unsigned int") the environment will not realize it's a function and will not create a prototype for it. That means you need to provide your own, or place the definition of the function above any calls to it.

Why do I get errors about an invalid device signature when trying to upload a sketch?

If you get an error like:

[@

Changed lines 236-242 from:

@]

puede significar una de dos cosas. Bien seleccionaste la placa equivocada en el menú Tools > Board o no estás usando la versión correcta de avrdude. Arduino utiliza una versión ligeramente modificada de avrdude para subir programas a la placa Arduino. La versión estándar consulta la firma del dispositivo en un modo que el bootloader no es capaz de comprender . Asegúrate de que estás utilizando la versión de avrdude que viene con Arduino (Código Fuente).

Guía Inicio

to:

@]

it can mean one of two things. Either you have the wrong board selected from the Tools > Board menu or you're not using the right version of avrdude. Arduino uses a slightly modified version of avrdude to upload sketches to the Arduino board. The standard version queries for the board's device signature in a way not understood by the bootloader, resulting in this error. Make sure you're using the version of avrdude that comes with Arduino (source code).

Guide Home

June 06, 2010, at 10:55 PM by David Cuartielles -
Changed lines 1-2 from:
to:
Changed line 236 from:

Guide Inicio

to:

Guía Inicio

June 06, 2010, at 10:54 PM by David Cuartielles -
Changed lines 1-68 from:
to:
Changed lines 74-176 from:

at com.oroinc.text.regex.Perl5Matcher._pushState(Perl5Matcher.java) @]

this is what's happening. Look for unusual sequences involving "double-quotes", "single-quotes", \backslashes, comments, etc. In particular the sequence '\"' seems to cause problems; use '"' instead.

Why doesn't my sketch start when I'm powering the board with an external power supply? (Arduino Diecimila or earlier)

Because the RX pin is unconnected, the bootloader on the board may be seeing garbage data coming in, meaning that it never times out and starts your sketch. Try tying the RX pin to ground with a 10K resistor (or connecting it to the TX pin).

Why does the Arduino software freeze when I try to upload a program? (on Windows)?

This might be caused by a conflict with the Logitech process 'LVPrcSrv.exe'. Open the Task Manager and see if this program is running, and if so, kill it before attempting the upload. more information

What if my board doesn't turn on (the green power LED doesn't light up)?

If you're using a USB board, make sure that the jumper (little plastic piece near the USB plug) is on the correct pins. If you're powering the board with an external power supply (plugged into the power plug), the jumper should be on the two pins closest to the power plug. If you're powering the board through the USB, the jumper should be on the two pins closest to the USB plug. This picture shows the arrangment for powering the board from the USB port.

Attach:jumper.jpg Δ

(thanks to mrbbp for report and picture)

Why does my Diecimila take such a long time (6-8 seconds) to start my sketch?

Some of the Arduino Diecimila boards were accidently burned with the Arduino NG bootloader. It should work fine, but has a longer delay when the board is reset (because the NG doesn't have an automatic reset, so you have to time the uploads manually). You can recognize the NG bootloader because the LED on pin 13 will blink three times when you reset the board (as compared to once with the Diecimila bootloader). If your Diecimila has the NG bootloader on it, you may need to physically press the reset button on the board before uploading your sketch. You can burn the correct bootloader onto your Diecimila, see the bootloader page for details.

What should I do if I get an error when launching arduino.exe on Windows?

If you get an error when double-clicking the arduino.exe executable on Windows, for example:

Arduino has encountered a problem and needs to close.

you'll need to launch Arduino using the run.bat file. Please be patient, the Arduino environment may take some time to open.

Why won't Arduino run on old versions of Mac OS X?

If you get an error like this:

Link (dyld) error: 

dyld: /Applications/arduino-0004/Arduino 04.app/Contents/MacOS/Arduino Undefined symbols: 
/Applications/arduino-0004/librxtxSerial.jnilib undefined reference to _printf$LDBL128 expected to be defined in /usr/lib/libSystem.B.dylib 

you probably need to upgrade to Max OS X 10.3.9 or later. Older versions have incompatible versions of some system libraries.

Thanks to Gabe462 for the report.

What do I do if I get an UnsatisfiedLinkError error (about native library librxtxSerial.jnilib) when launching Arduino?

If you get an error like this when launching Arduino:

Uncaught exception in main method: java.lang.UnsatisfiedLinkError: Native Library /Users/anu/Desktop/arduino-0002/librxtxSerial.jnilib already loaded in another classloader

you probably have an old version of the communications library lying around. Search for comm.jar or jcl.jar in /System/Library/Frameworks/JavaVM.framework/ or in directories in your CLASSPATH or PATH environment variables. (reported by Anurag Sehgal)

What about the error "Could not find the main class."?

If you get this error when launching Arduino:

Java Virtual Machine Launcher: Could not find the main class. Program will exit.

make sure that you correctly extracted the contents of the Arduino .zip file - in particular that the lib directory is directly inside of the Arduino directory and contains the file pde.jar.

What can I do about cygwin conflicts on Windows?

If you already have cygwin installed on your machine, you might get an error like this when you try to compile a sketch in Arduino:

6 [main] ? (3512) C:\Dev\arduino-0006\tools\avr\bin\avr-gcc.exe: *** fatal error - C:\Dev\arduino-0006\tools\avr\bin\avr-gcc.exe: *** system shared memory version mismatch detected - 0x75BE0084/0x75BE009C.

This problem is probably due to using incompatible versions of the cygwin DLL.

Search for cygwin1.dll using the Windows Start->Find/Search facility and delete all but the most recent version. The most recent version *should* reside in x:\cygwin\bin, where 'x' is the drive on which you have installed the cygwin distribution. Rebooting is also suggested if you are unable to find another cygwin DLL.

If so, first make sure that you don't have cygwin running when you use Arduino. If that doesn't help, you can try deleting cygwin1.dll from the Arduino directory and replacing it with the cygwin1.dll from your existing cygwin install (probably in c:\cygwin\bin).

Thanks to karlcswanson for the suggestion.

Why does do the Arduino software and the Tools menu take a long time to open (on Windows)?

If the Arduino software takes a long time to start up and appears to freeze when you try to open the Tools menu, there by a conflict with another device on your system. The Arduino software, on startup and when you open the Tools menu, tries to get a list of all the COM ports on your computer. It's possible that a COM port created by one of the devices on your computer slows down this process. Take a look in the Device Manager. Try disabling the devices that provide COM ports (e.g. Bluetooth devices).

Why doesn't my board show in the Tools | Serial Port menu ?

If you're using a USB Arduino board, make sure you installed the FTDI drivers (see the Howto for directions). If you're using a USB-to-Serial adapter with a serial board, make sure you installed its drivers.

Make sure that the board is plugged in: the serial port menu refreshes whenever you open the Tools menu, so if you just unplugged the board, it won't be in the menu.

Check that you're not running any programs that scan all serial ports, like PDA sync applications, Bluetooth-USB drivers (e.g. BlueSoleil), virtual daemon tools, etc.

On Windows, the COM port assigned to the board may be too high. From zeveland:

"One little note if you aren't able to export and your USB board is trying to use a high COM port number: try changing the FTDI chip's COM port assignment to a lower one.

"I had a bunch of virtual COM ports set up for Bluetooth so the board was set to use COM17. The IDE wasn't able to find the board so I deleted the other virtual ports in Control Panel (on XP) and moved the FTDI's assignment down to COM2. Make sure to set Arduino to use the new port and good luck."

On the Mac, if you have an old version of the FTDI drivers, you may need to remove them and reinstall the latest version. See this forum thread for directions (thanks to gck).

What if I get a gnu.io.PortInUseException when uploading code or using the serial monitor (on the Mac)?

[@

to:

at com.oroinc.text.regex.Perl5Matcher._pushState(Perl5Matcher.java) @]

esto es lo que está pasando. Puedes buscar secuencias inusuales que supongan "comillas dobles", "comilla simple", las barras invertidas \, comentarios, etc, en particular la secuencia '\ "' parece ser la causa problemas, se recomienda el uso de '"' en su lugar.

# Externalpower

¿Porqué no arranca mi sketch cuando estoy alimentando la tarjeta con una fuente de alimentación externa? (Arduino Diecimila o anterior)

Hay una serie de tarjetas Arduino antiguas (unas 1000) que presentan el problema de tener una versión del bootloader que tiene el pin RX sin conectar la resistencia de pull-up interna. Esto produce que, en ocasiones, el bootloader piense que está recibiendo un nuevo programa, si bien se trata sólo de datos aleatorios. Esto se puede solucionar actualizando el bootloader a la última versión o conectando el pin RX con una resistencia de 10K a tierra.

¿Porqué se congela Arduino cuando intento cargar un programa? (En Windows)?

Esto podría ser causado por un conflicto con el proceso de Logitech LVPrcSrv.exe, que es un programa residente en tu ordenador. Abre el Administrador de tareas y comprueba si este programa se está ejecutando, y si es así, cierra ese proceso antes de intentar subir más datos a la placa [ más información ].

#Alimentación

¿Qué pasa si mi tarjeta no se enciende (el LED verde no se enciende)?

Si estás utilizando una tarjeta USB Diecimila o NG, asegúrate de que el puente (pieza de plástico pequeña cerca del conector USB) es en los pines correctos. Si tienes la certeza que tu placa recibe alimentación al usar una fuente de alimentación externa (conectado a la clavija de red), el puente debe ser más cercano a los dos pines para el cable de alimentación. Si, por el contrario, alimentas tu placa a través del puerto USB, el puente debe estar en los dos pines más cercanos a los conectores USB. Esta foto muestra la disposición para la alimentación de la placa del puerto USB.

Attach: jumper.jpg

# Wrongbootloader

¿Porqué mi Diecimila necesita tanto tiempo (6-8 segundos) para iniciar mi sketch?

Algunas de las placas de Arduino Diecimila (unas 1000) salieron de fábrica accidentalmente con el bootloader Arduino NG, este es un error que en ningún caso debiera manifestarse en placas Arduino posteriores al año 2008. En cualquier caso, tu placa funciona bien, pero requiere hacer reset manual de la placa al subir un sketch y necesita de ese tiempo de espera. Se puede reconocer el bootloader NG porqué el LED en el pin 13 parpadeará tres veces al efectuar presionar el botón de reset en la placa (el bootloader de la Diecimila sólo parpadeará una vez). Puede el bootloader correcto en su Diecimila, consulte la página del bootloader para más detalles.

# Inicio

¿Qué debo hacer si me da un error al lanzar arduino.exe en Windows?

Si obtienes un error al hacer doble click en el ejecutable arduino.exe en Windows, por ejemplo:

@ @ Arduino has encountered a problem and needs to close. @ @

tendrás que poner en marcha Arduino utilizando el archivo run.bat situado en la misma carpeta. Por favor, ten paciencia, el entorno Arduino puede tomar algún tiempo para abrir según la configuración de tu ordenador.

¿Porqué no se ejecuta Arduino en las versiones anteriores de Mac OSX?

Si obtienes un error como este:

 Link (dyld) error: 

dyld: / Applications/arduino-0004/Arduino 04.app/Contents/MacOS/Arduino símbolos Indefinido: 
/ Applications/arduino-0004/librxtxSerial.jnilib undefined referencia a _printf $ LDBL128 espera que esté definido en / usr / lib / libSystem.B.dylib  

es probable que necesites actualizar a Mac OSX 10.3.9 o posterior. Las versiones anteriores tienen versiones incompatibles de algunas librerías del sistema.

¿Qué hago si me da un error "UnsatisfiedLinkError ( librxtxSerial.jnilib native library )" al lanzar Arduino?

Si obtienes un error como este al iniciar Arduino:

@ @ Uncaught exception in main method: java.lang.UnsatisfiedLinkError: Native Library /Users/anu/Desktop/arduino-0002/librxtxSerial.jnilib already loaded in another classloader @ @

es probable que tengas una versión antigua de la biblioteca de comunicaciones en tu ordenador. Busca comm.jar, jcl.jar o en / System / Library / Frameworks / JavaVM.framework / o en los directorios del CLASSPATH o variables de entorno PATH.

¿Qué pasa con el error "No se pudo encontrar la clase principal."?

Si recibe este error al lanzar Arduino:

@ @ JJava Virtual Machine Launcher: Could not find the main class. Program will exit. @ @

asegúrate de que descomprimiste correctamente el contenido del fichero Arduino.zip - en particular, que el directorio lib está dentro del directorio Arduino y contiene el archivo pde.jar.

¿Qué puedo hacer al respecto de conflictos con cygwin en Windows?

Si ya tienes cygwin instalado en tu máquina, podrías obtener un error como este al intentar compilar un sketch en Arduino:

@ @ [main] ? (3512) C:\Dev\arduino-0006\tools\avr\bin\avr-gcc.exe: *** fatal error - C:\Dev\arduino-0006\tools\avr\bin\avr-gcc.exe: *** system shared memory version mismatch detected - 0x75BE0084/0x75BE009C.

This problem is probably due to using incompatible versions of the cygwin DLL.

Search for cygwin1.dll using the Windows Start->Find/Search facility and delete all but the most recent version. The most recent version *should* reside in x:\cygwin\bin, where 'x' is the drive on which you have installed the cygwin distribution. Rebooting is also suggested if you are unable to find another cygwin DLL. @ @

Si es así, primero asegúrate de que no tienes cygwin en ejecución cuando se utiliza Arduino. Si esto no funciona, puedes intentar eliminar las librerías cygwin1.dll del directorio Arduino y cambiarlas por cygwin1.dll de tu instalación existente de cygwin (probablemente en c: \ cygwin \ bin).

¿Porqué tardan el software Arduino y/o el menú Herramientas mucho tiempo en abrir (en Windows)?

Si el software Arduino tarda mucho tiempo en ponerse en marcha y parece bloquearse al intentar abrir el menú Herramientas, existe un conflicto con otro dispositivo en su sistema. El software de Arduino, al arrancar y al abrir el menú Tools, trata de obtener una lista de todos los puertos COM de tu ordenador. Es posible que un puerto COM creado por uno de los dispositivos de tu equipo ralentice este proceso. Echa un vistazo en el Administrador de dispositivos. Intenta desactivar los dispositivos que usan los otros puertos COM (por ejemplo, dispositivos Bluetooth).

# SerialPort

¿Porqué no mi no aparece mi placa en el menú Tools | Serial Port?

Si estás usando una placa USB Arduino, asegúrate de instalar los drivers FTDI (véase el link de instalación para instrucciones). Si estás utilizando un adaptador de USB a serie con una placa serie, asegúrate de instalar los drivers correspondientes.

Asegúrate de que la tarjeta está conectada: el menú del puerto serie se actualiza cada vez que abres la casilla Tools del menú, así que si acabas de desenchufar la placa, no estará en el menú.

Comprueba que no estás ejecutando ningún programa que escanea todos los puertos serie, como aplicaciones de sincronización de PDA, Bluetooth controladores USB (por ejemplo, BlueSoleil), etc

En Windows, el puerto COM asignado a la placa puede ser uno de código muy alto. En ocasiones se recomienda probar a cambiar el número asignado al chip FTDI por uno más bajo. Tal y cómo comenta Zeveland:

"Tuve un montón de puertos virtuales COM creados para Bluetooth por lo que la placa estaba configurada para utilizar COM17. El IDE no fue capaz de encontrarla de modo que suprimí los otros puertos virtuales en el Panel de control (en XP) y trasladó el puerto asignado al chip FTDI de Arduino a otro más bajo, en concreto el COM2. Asegúrate de configurar el IDE de Arduino para utilizar el nuevo puerto y buena suerte. "

En Mac, si tienes una versión antigua de los controladores de FTDI, puede ser necesario borrarlos y reinstalar la última versión. Mas información en esta conversación del foro para instrucciones en cómo proceder (gracias a GCK).

¿Qué pasa si recibo una "gnu.io.PortInUseException" al cargar código o utilizando el monitor de serie (en Mac)?

[@

Changed lines 174-226 from:
 @]

This probably means that the port is actually in use by another application. Please make sure that you're not running other programs that access serial or USB ports, like PDA sync application, bluetooth device managers, certain firewalls, etc. Also, note that some programs (e.g. Max/MSP) keep the serial port open even when not using it - you may to need to close any patches that use the serial port or quit the application entirely.

If you get this error with Arduino 0004 or earlier, or with Processing, you'll need to run the macosx_setup.command, and then restart your computer. Arduino 0004 includes a modified version of this script that all users need to run (even those who ran the one that came with Arduino 0003). You may also need to delete the contents of the /var/spool/uucp directory.

I'm having trouble with the FTDI USB drivers.

Try installing the latest drivers from FTDI or contacting their support at support1@ftdichip.com.

Why doesn't my sketch start when I power up or reset the Arduino board?

Most likely because you are sending serial data to the board when it firsts turns on. During the first few seconds, the bootloader (a program pre-burned onto the chip on the board) listens for the computer to send it a new sketch to be uploaded to the board. After a few seconds without communication, the bootloader will time out and start the sketch that's already on the board. If you continue to send data to the bootloader, it will never time out and your sketch will never start. You'll either need to find a way to stop serial data from arriving for the first few seconds when the board powers (e.g. by enabling the chip that sends the data from within your setup() function) or burn your sketch onto the board with an external programmer, replacing the bootloader.

Why does my sketch appear to upload successfully but not do anything?

You have selected the wrong item from the Tools > Microcontroller menu. Make sure the selected microcontroller corresponds to the one on your board (either ATmega8 or ATmega168) - the name will be written on the largest chip on the board.

Check for a noisy power supply. It's possible this could cause the chip to lose its sketch.

Alternatively, the sketch may be too big for the board. When uploading your sketch, Arduino 0004 checks if it's too big for the ATmega8, but it bases its calculation on a 1 Kb bootloader. You may have a older bootloader that takes up 2 Kb of the 8 Kb of program space (flash) on the ATmega8 instead of the 1 Kb used by the current bootloader. If yours is bigger, only part of the sketch will be uploaded, but the software won't know, and your board will continually reset, pause, reset.

If you have access to an AVR-ISP or parallel port programmer, you can burn the latest version of the bootloader to your board with the Tools | Burn Bootloader menu item. Otherwise, you can tell the Arduino environment the amount of space available for sketches by editing the upload.maximum_size variable in your preferences file (see: instructions on finding the file). Change 7168 to 6144, and the environment should correctly warn you when your sketch is too big.

How can I reduce the size of my sketch?

The ATmega168 chip on the Arduino board is cheap, but it has only 16 Kb of program code, which isn't very much (and 2 Kb is used by the bootloader).

If you're using floating point, try to rewrite your code with integer math, which should save you about 2 Kb. Delete any #include statements at the top of your sketch for libraries that you're not using.

Otherwise, see if you can make your program shorter.

We're always working to reduce the size of the Arduino core to leave more room for your sketches.

Why don't I get a PWM (an analog output) when I call analogWrite() on pins other than 3, 5, 6, 9, 10, or 11?

The microcontroller on the Arduino board (the ATmega168) only supports PWM/analogWrite() on certain pins. Calling analogWrite() on any other pins will give high (5 volts) for values greater than 128 and low (0 volts) for values less than 128. (Older Arduino boards with an ATmega8 only support PWM output on pins 9, 10, and 11.)

Why do I get errors about undeclared functions or undeclared types?

The Arduino environment attempts to automatically generate prototypes for your functions, so that you can order them as you like in your sketch. This process, however, isn't perfect, and sometimes leads to obscure error messages.

If you declare a custom type in your code and create a function that accepts or returns a value of that type, you'll get an error when you try to compile the sketch. This is because the automatically-generated prototype for that function will appear above the type definition.

If you declare a function with a two-word return type (e.g. "unsigned int") the environment will not realize it's a function and will not create a prototype for it. That means you need to provide your own, or place the definition of the function above any calls to it.

Why do I get errors about an invalid device signature when trying to upload a sketch?

If you get an error like:

[@

to:
 @] 

Esto probablemente significa que el puerto está actualmente en uso por otra aplicación. Por favor, asegúrate de que no estás ejecutando otros programas con acceso al puerto serie o puertos USB de tu placa, como la aplicación de sincronización de PDA, los administradores de dispositivos bluetooth, ciertos servidores de seguridad, etc. Además, ten en cuenta que algunos programas (por ejemplo, Max/MSP o Puredata) mantienen el puerto serie abierto, incluso cuando no los usas - puedes necesitar cerrar todos los parches que usan el puerto serie o salir de la aplicación por completo.

Si obtienes este error con Arduino 0004 o anterior, debieras actualizar a la última versión.

Tengo problemas con los controladores USB FTDI.

Intenta instalar los controladores más recientes de FTDI o ponte en contacto con su grupo de soporte en support1@ftdichip.com.

# Sketchstart

¿Porqué no arraca mi sketch al encender o reiniciar la placa Arduino?

Lo más probable es que alguna aplicación esté enviando datos en serie a tu placa al arrancar. Durante los primeros segundos, el bootloader (que viene pregrabado en tu placa) escucha la llegada de datos desde el ordenador. Después de unos segundos sin comunicación, el bootloader inicia el sketch que ya está en la placa. Si continúa el envío de datos hacia el bootloader, nunca se determinará el final de ejecución del bootloader y tu sketch no arrancará. Tendrás que encontrar una manera de cesar el envío de datos serie a la placa durante el tiempo que esta necesita para arrancar o grabar tu sketch en la placa con un programador externo, que sustituya al bootloader.

¿Porqué mi sketch parece que carga correctamente, pero no hace nada?

Es posible que hayas seleccionado tu placa apropiadamente, pero con la opción de microcontrolador equivocado. Asegúrate de que el microcontrolador corresponde al de tu placa (ya sea Atmega8, ATmega168, ATmega328, o ATmega1280) - el nombre está escrito en el más grande de los chips en la placa.

Comprueba si usas una fuente de alimentación ruidosa. Esto podría causar al chip perder su sketch.

Por otra parte, el sketch puede ser demasiado grande para la tarjeta. Al subir tu sketch, Arduino 0004 y posteriores comprueban si es demasiado grande para el ATmega8, pero basa su cálculo en un bootloader de 1 Kb. Podrías tener bootloaders de mayor tamaño (p.ej. 2 Kb de los 8 Kb disponibles en tu placa). Si empleas placas Arduino oficiales, este problema no se presentará.

Si tienes acceso a un AVR-ISP, AVR-ISP-MKII, el programador de puerto paralelo, o cualquier otro dispositivo externo de programación de chips de la marca Atmel, puedes grabar la última versión del bootloader desde el menú Tools | Burn Bootloader. De lo contrario, puedes determinar en el entorno Arduino la cantidad de espacio disponible para tus programas editando la variable upload.maximum_size en su archivo de preferencias (ver: instrucciones sobre cómo encontrar el archivo?).

# Size

¿Cómo puedo reducir el tamaño de mi sketch?

Los chips ATmega en la placa Arduino son barato, pero tienen limitaciones en el espacio reservado para tus programas: 7Kb para el ATmega8, 14Kb para el ATmega168 y ATmega328, y 124Kb para el ATmega1280 (el resto del espacio es usado por el bootloader).

Por ejemplo, un truco consiste en limitar que librerías usas. Si estás utilizando operaciones en coma flotante, trata de reescribir el código para usar números enteros, lo que debería ahorrar cerca de 2 Kb. Elimine los# include declaraciones en la parte superior de tu programa para eliminar las bibliotecas que no estás usando.

También puedes tratar de hacer tu programa más corto.

En cualquier caso, desde Arduino trabajamos para reducir el tamaño del núcleo de Arduino para dejar más espacio para tus programas.

¿Porqué no puedo obtener un PWM (una salida analógica) cuando llamo analogWrite () en los otros pines que 3, 5, 6, 9, 10 o 11? (Arduino Duemilanove y Diecimila)

El microcontrolador de la placa Arduino Duemilanove (ATmega328) y Diecimila (ATmega168) sólo es compatible con PWM / analogWrite () en los pines determinados. Llamadas analogWrite () en las patas otro dará alto (5 voltios) para valores mayores de 128 y bajo (0 voltios) para valores inferiores a 128. (Nótese que placas Arduino antiguas con Atmega8 sólo trabajan con salida PWM en los pines 9, 10 y 11.)

¿Porqué recibo errores acerca de funciones o tipos no declaradas?

El entorno Arduino intenta generar automáticamente prototipos de sus funciones, de modo que puedas llamarlos a tu gusto en tus programas. Este proceso, sin embargo, no es perfecto, y en ocasiones produce mensajes de error.

Si declaras un tipo personalizado en el código y creas una función que acepte o devuelva valores de ese tipo, obtendrás un error al intentar compilar el sketch. Esto se debe a que el prototipo automático para esa función aparecerá sobre la definición de tipo.

Si declaras una función con un tipo de retorno de dos palabras (por ejemplo, "unsigned int"), el entorno no se dará cuenta de que es una función y no creará un prototipo para ello. Eso significa que debes proporcionar tu propia definición, o colocar la definición de la función por encima de cualquier llamada a la misma.

¿Porqué recibo errores sobre un dispositivo de firma no válida cuando se trata de subir un sketch?

Si obtienes un error como:

[@

Changed lines 230-235 from:

@]

it can mean one of two things. Either you have the wrong board selected from the Tools > Board menu or you're not using the right version of avrdude. Arduino uses a slightly modified version of avrdude to upload sketches to the Arduino board. The standard version queries for the board's device signature in a way not understood by the bootloader, resulting in this error. Make sure you're using the version of avrdude that comes with Arduino (source code).

Guide Home

to:

@]

puede significar una de dos cosas. Bien seleccionaste la placa equivocada en el menú Tools > Board o no estás usando la versión correcta de avrdude. Arduino utiliza una versión ligeramente modificada de avrdude para subir programas a la placa Arduino. La versión estándar consulta la firma del dispositivo en un modo que el bootloader no es capaz de comprender . Asegúrate de que estás utilizando la versión de avrdude que viene con Arduino (Código Fuente).

Guide Inicio

February 24, 2010, at 02:11 PM by David A. Mellis -
Changed lines 48-49 from:
  • The messages displayed when you try to upload with verbose output enabled. To do this, you'll need to set upload.verbose to true in your Arduino preferences file.
to:
  • The messages displayed when you try to upload with verbose output enabled. To do this, hold down the shift key while clicking on the upload button in the toolbar.
January 03, 2010, at 03:40 AM by David A. Mellis -
Added lines 50-53:

Why do I get "Build folder disappeared or could not be written" (Mac OS X)?

Did you drag the Arduino.app out of the disk image (and into, say, your Applications folder)? If not, you won't be able to upload the examples.

November 18, 2009, at 04:37 PM by David A. Mellis -
Added line 59:

November 18, 2009, at 04:36 PM by David A. Mellis -
Changed lines 67-69 from:

at com.oroinc.text.regex.Perl5Matcher._pushState(Perl5Matcher.java) @]

to:

at com.oroinc.text.regex.Perl5Matcher._pushState(Perl5Matcher.java) @]

November 18, 2009, at 04:36 PM by David A. Mellis - adding note about stackoverflow error.
Added lines 59-71:

Why do I get a java.lang.StackOverflowError when I try to compile my program?

The Arduino environment does some preliminary processing on your sketch by manipulating the code using regular expressions. This sometimes gets confused by certain strings of text. If you see an error like:

java.lang.StackOverflowError
at java.util.Vector.addElement(Unknown Source)
at java.util.Stack.push(Unknown Source)
at com.oroinc.text.regex.Perl5Matcher._pushState(Perl5Matcher.java)

this is what's happening. Look for unusual sequences involving "double-quotes", "single-quotes", \backslashes, comments, etc. In particular the sequence '\"' seems to cause problems; use '"' instead.

June 17, 2009, at 10:26 PM by David A. Mellis -
Deleted lines 4-8:

Why doesn't my sketch start when I'm powering the board with an external power supply?

Because the RX pin is unconnected, the bootloader on the board may be seeing garbage data coming in, meaning that it never times out and starts your sketch. Try tying the RX pin to ground with a 10K resistor (or connecting it to the TX pin).

Added lines 50-63:

Why doesn't the Arduino software run after I updated the Java on my Mac?

The latest Java update from Apple attempts to use 64-bit version of native libraries, but the Arduino application comes with a 32 bit version of the RXTX library. If you launch Arduino, you'll get an error like:

Uncaught exception in main method: java.lang.UnsatisfiedLinkError: /Applications/arduino-0016/Arduino 16.app/Contents/Resources/Java/librxtxSerial.jnilib: no suitable image found. Did find: /Applications/arduino-0016/Arduino 16.app/Contents/Resources/Java/librxtxSerial.jnilib: no matching architecture in universal wrapper

To fix this, click on the Arduino application (e.g. Arduino 16.app) in the Finder, and select Get Info from the File menu. In the info panel, click the Open in 32 Bit Mode checkbox. You should then be able to launch Arduino normally.

Why doesn't my sketch start when I'm powering the board with an external power supply? (Arduino Diecimila or earlier)

Because the RX pin is unconnected, the bootloader on the board may be seeing garbage data coming in, meaning that it never times out and starts your sketch. Try tying the RX pin to ground with a 10K resistor (or connecting it to the TX pin).

May 28, 2009, at 02:36 PM by David A. Mellis -
Changed lines 19-20 from:
  • Make sure you have the right item selected in the Tools > Board menu. In particular, newer Arduino Duemilanove boards come with an ATmega328, while older ones have an ATmega168. To check, read the text on the microcontroller (the larger chip) on your Arduino board.
to:
  • Make sure you have the right item selected in the Tools > Board menu. In particular, newer Arduino Duemilanove boards come with an ATmega328, while older ones have an ATmega168. To check, read the text on the microcontroller (the larger chip) on your Arduino board. For more information on the board menu items, see the guide to the Arduino environment.
May 28, 2009, at 02:35 PM by David A. Mellis -
Deleted lines 20-27:
  • Make sure there's a bootloader burned on your Arduino board. To check, connect an LED to pin 13 and reset the board. The LED should blink. If it doesn't, see the Bootloader page for instructions on burning a bootloader to the board.

  • If you have a board that doesn't support auto-reset, be sure that you are resetting the board a couple of seconds before uploading. (The Arduino Diecimila, Duemilanove, and Nano support auto-reset as do the LilyPad, Pro, and Pro Mini with 6-pin programming headers).

  • However, note that some Diecimila were accidently burned with the wrong bootloader and may require you to physically press the reset button before uploading; see this question below.

  • However, on some computers, you may need to press the reset button on the board after you hit the upload button in the Arduino environment. Try different intervals of time between the two, up to 10 seconds or more.
Deleted lines 26-27:
  • If you get this error: [VP 1] Device is not responding correctly. try uploading again (i.e. reset the board and press the download button a second time).
Added lines 33-42:
  • If you have a board that doesn't support auto-reset, be sure that you are resetting the board a couple of seconds before uploading. (The Arduino Diecimila, Duemilanove, and Nano support auto-reset as do the LilyPad, Pro, and Pro Mini with 6-pin programming headers).

  • However, note that some Diecimila were accidently burned with the wrong bootloader and may require you to physically press the reset button before uploading; see this question below.

  • However, on some computers, you may need to press the reset button on the board after you hit the upload button in the Arduino environment. Try different intervals of time between the two, up to 10 seconds or more.

  • If you get this error: [VP 1] Device is not responding correctly. try uploading again (i.e. reset the board and press the download button a second time).

  • Make sure there's a bootloader burned on your Arduino board. To check, connect an LED to pin 13 and reset the board. The LED should blink. If it doesn't, see the Bootloader page for instructions on burning a bootloader to the board.
May 28, 2009, at 02:33 PM by David A. Mellis -
Changed lines 17-22 from:
  • Then, check that the proper port is selected in the "Tools | Serial Port" menu (if your port doesn't appear, restart the IDE with the board connected to the computer).

  • Make sure there's a bootloader burned on the Atmega8 on your Arduino board. To check, connect an LED to pin 13 and reset the board. The LED should blink. If it doesn't, see the Bootloader page for instructions on burning a bootloader to the board.

  • Be sure that you are resetting the board a couple of seconds before uploading (unless you have an Arduino Diecimila).
to:
  • Then, check that the proper port is selected in the "Tools > Serial Port" menu (if your port doesn't appear, restart the IDE with the board connected to the computer).

  • Make sure you have the right item selected in the Tools > Board menu. In particular, newer Arduino Duemilanove boards come with an ATmega328, while older ones have an ATmega168. To check, read the text on the microcontroller (the larger chip) on your Arduino board.

  • Make sure there's a bootloader burned on your Arduino board. To check, connect an LED to pin 13 and reset the board. The LED should blink. If it doesn't, see the Bootloader page for instructions on burning a bootloader to the board.

  • If you have a board that doesn't support auto-reset, be sure that you are resetting the board a couple of seconds before uploading. (The Arduino Diecimila, Duemilanove, and Nano support auto-reset as do the LilyPad, Pro, and Pro Mini with 6-pin programming headers).
December 16, 2008, at 02:24 PM by David A. Mellis -
Changed line 204 from:

@@

to:

[@

Changed lines 207-208 from:
       this check.@@
to:
       this check.

@]

December 16, 2008, at 02:24 PM by David A. Mellis -
Added line 203:
December 16, 2008, at 02:24 PM by David A. Mellis -
Changed lines 203-204 from:

@@avrdude: Yikes! Invalid device signature.

to:

@@ avrdude: Yikes! Invalid device signature.

December 16, 2008, at 02:24 PM by David A. Mellis -
Added lines 200-210:

Why do I get errors about an invalid device signature when trying to upload a sketch?

If you get an error like:

@@avrdude: Yikes! Invalid device signature.

       Double check connections and try again, or use -F to override
       this check.@@

it can mean one of two things. Either you have the wrong board selected from the Tools > Board menu or you're not using the right version of avrdude. Arduino uses a slightly modified version of avrdude to upload sketches to the Arduino board. The standard version queries for the board's device signature in a way not understood by the bootloader, resulting in this error. Make sure you're using the version of avrdude that comes with Arduino (source code).

December 10, 2008, at 01:04 PM by David A. Mellis -
Changed lines 123-124 from:

Why does the Arduino software run really slowly (on Windows)?

to:

Why does do the Arduino software and the Tools menu take a long time to open (on Windows)?

March 31, 2008, at 05:33 PM by David A. Mellis -
Added lines 53-56:

Why does the Arduino software freeze when I try to upload a program? (on Windows)?

This might be caused by a conflict with the Logitech process 'LVPrcSrv.exe'. Open the Task Manager and see if this program is running, and if so, kill it before attempting the upload. more information

January 05, 2008, at 05:06 AM by David A. Mellis - expanding the upload troubleshooting procedure.
Added lines 29-32:
  • Try uploading with nothing connected to the board (apart from the USB cable, of course).

  • Make sure the board isn't touching anything metallic or conductive.
Added lines 43-52:

If it still doesn't work, you can ask for help in the forum. Please include the following information:

  • Your operating system.

  • What kind of board you have. If it's a Mini, LilyPad or other board that requires extra wiring, include a photo of your circuit, if possible.

  • Whether or not you were ever able to upload to the board. If so, what were you doing with the board before / when it stopped working, and what software have you recently added or removed from your computer?

  • The messages displayed when you try to upload with verbose output enabled. To do this, you'll need to set upload.verbose to true in your Arduino preferences file.
November 16, 2007, at 04:07 PM by David A. Mellis - adding some notes about errors caused by the automatic prototype generation.
Added lines 174-181:

Why do I get errors about undeclared functions or undeclared types?

The Arduino environment attempts to automatically generate prototypes for your functions, so that you can order them as you like in your sketch. This process, however, isn't perfect, and sometimes leads to obscure error messages.

If you declare a custom type in your code and create a function that accepts or returns a value of that type, you'll get an error when you try to compile the sketch. This is because the automatically-generated prototype for that function will appear above the type definition.

If you declare a function with a two-word return type (e.g. "unsigned int") the environment will not realize it's a function and will not create a prototype for it. That means you need to provide your own, or place the definition of the function above any calls to it.

October 06, 2007, at 08:14 PM by David A. Mellis -
Added line 159:

September 01, 2007, at 03:49 PM by David A. Mellis -
Changed lines 21-22 from:
  • Be sure that you are resetting the board a couple of seconds before uploading.
to:
  • Be sure that you are resetting the board a couple of seconds before uploading (unless you have an Arduino Diecimila).

  • However, note that some Diecimila were accidently burned with the wrong bootloader and may require you to physically press the reset button before uploading; see this question below.
Added line 48:

Changed lines 51-52 from:

Some of the Arduino Diecimila boards were accidently burned with the Arduino NG bootloader. It should work fine, but has a longer delay when the board is reset (because the NG doesn't have an automatic reset, so you have to time the uploads manually). You can recognize the NG bootloader because the LED on pin 13 will blink three times when you reset the board (as compared to once with the Diecimila bootloader). If your Diecimila has the NG bootloader on it, you may need to physically press the reset button on the board before uploading your sketch.

to:

Some of the Arduino Diecimila boards were accidently burned with the Arduino NG bootloader. It should work fine, but has a longer delay when the board is reset (because the NG doesn't have an automatic reset, so you have to time the uploads manually). You can recognize the NG bootloader because the LED on pin 13 will blink three times when you reset the board (as compared to once with the Diecimila bootloader). If your Diecimila has the NG bootloader on it, you may need to physically press the reset button on the board before uploading your sketch. You can burn the correct bootloader onto your Diecimila, see the bootloader page for details.

September 01, 2007, at 03:43 PM by David A. Mellis - adding note about Diecimila boards with wrong bootloader
Added lines 46-49:

Why does my Diecimila take such a long time (6-8 seconds) to start my sketch?

Some of the Arduino Diecimila boards were accidently burned with the Arduino NG bootloader. It should work fine, but has a longer delay when the board is reset (because the NG doesn't have an automatic reset, so you have to time the uploads manually). You can recognize the NG bootloader because the LED on pin 13 will blink three times when you reset the board (as compared to once with the Diecimila bootloader). If your Diecimila has the NG bootloader on it, you may need to physically press the reset button on the board before uploading your sketch.

August 18, 2007, at 12:15 AM by David A. Mellis - adding a question about Arduino slowness and Tools menu freezing on Windows
Added lines 98-101:

Why does the Arduino software run really slowly (on Windows)?

If the Arduino software takes a long time to start up and appears to freeze when you try to open the Tools menu, there by a conflict with another device on your system. The Arduino software, on startup and when you open the Tools menu, tries to get a list of all the COM ports on your computer. It's possible that a COM port created by one of the devices on your computer slows down this process. Take a look in the Device Manager. Try disabling the devices that provide COM ports (e.g. Bluetooth devices).

July 18, 2007, at 04:19 PM by David A. Mellis -
Changed lines 68-69 from:

What do I do if I get the following error when launching Arduino?

to:

What do I do if I get an UnsatisfiedLinkError error (about native library librxtxSerial.jnilib) when launching Arduino?

If you get an error like this when launching Arduino:

Changed lines 74-77 from:

You probably have an old version of the communications library lying around. Search for comm.jar or jcl.jar in /System/Library/Frameworks/JavaVM.framework/ or in directories in your CLASSPATH or PATH environment variables. (reported by Anurag Sehgal)

What about this error?

to:

you probably have an old version of the communications library lying around. Search for comm.jar or jcl.jar in /System/Library/Frameworks/JavaVM.framework/ or in directories in your CLASSPATH or PATH environment variables. (reported by Anurag Sehgal)

What about the error "Could not find the main class."?

If you get this error when launching Arduino:

Changed lines 82-83 from:

Make sure that you correctly extracted the contents of the Arduino .zip file - in particular that the lib directory is directly inside of the Arduino directory and contains the file pde.jar.

to:

make sure that you correctly extracted the contents of the Arduino .zip file - in particular that the lib directory is directly inside of the Arduino directory and contains the file pde.jar.

Changed lines 115-116 from:

What if I get this error when uploading code or using the serial monitor (on the Mac)?

to:

What if I get a gnu.io.PortInUseException when uploading code or using the serial monitor (on the Mac)?

Changed lines 125-126 from:

You need to run the macosx_setup.command in the Arduino directory, and then restart your computer. Arduino 0004 includes a modified version of this script that all users need to run (even those who ran the one that came with Arduino 0003). You may also need to delete the contents of the /var/spool/uucp directory.

to:

This probably means that the port is actually in use by another application. Please make sure that you're not running other programs that access serial or USB ports, like PDA sync application, bluetooth device managers, certain firewalls, etc. Also, note that some programs (e.g. Max/MSP) keep the serial port open even when not using it - you may to need to close any patches that use the serial port or quit the application entirely.

If you get this error with Arduino 0004 or earlier, or with Processing, you'll need to run the macosx_setup.command, and then restart your computer. Arduino 0004 includes a modified version of this script that all users need to run (even those who ran the one that came with Arduino 0003). You may also need to delete the contents of the /var/spool/uucp directory.

Added lines 142-143:

Check for a noisy power supply. It's possible this could cause the chip to lose its sketch.

July 18, 2007, at 04:12 PM by David A. Mellis -
Added lines 5-36:

Why doesn't my sketch start when I'm powering the board with an external power supply?

Because the RX pin is unconnected, the bootloader on the board may be seeing garbage data coming in, meaning that it never times out and starts your sketch. Try tying the RX pin to ground with a 10K resistor (or connecting it to the TX pin).

Why I can't upload my programs to the Arduino board?

There are a few things that could be wrong.

  • First make sure your board is on (the green LED is on) and connected to the computer (if it's not, see "what if my board doesn't turn on" above).

  • Then, check that the proper port is selected in the "Tools | Serial Port" menu (if your port doesn't appear, restart the IDE with the board connected to the computer).

  • Make sure there's a bootloader burned on the Atmega8 on your Arduino board. To check, connect an LED to pin 13 and reset the board. The LED should blink. If it doesn't, see the Bootloader page for instructions on burning a bootloader to the board.

  • Be sure that you are resetting the board a couple of seconds before uploading.

  • However, on some computers, you may need to press the reset button on the board after you hit the upload button in the Arduino environment. Try different intervals of time between the two, up to 10 seconds or more.

  • Disconnect digital pins 0 and 1 while uploading (they can connected and used after the code has been uploaded).

  • If you get this error: [VP 1] Device is not responding correctly. try uploading again (i.e. reset the board and press the download button a second time).

  • Check that you're not running any programs that scan all serial ports, like PDA sync applications, Bluetooth-USB drivers (e.g. BlueSoleil), virtual daemon tools, etc.

  • Make sure you don't have firewall software that blocks access to the serial port (e.g. ZoneAlarm).

  • You may need to quit Processing, PD, vvvv, etc. if you're using them to read data over the USB or serial connection to the Arduino board.

  • If you have a really ancient Arduino board, you may need to change the baud rate at which sketches are uploaded to 9600 (from the normal 19200). You will have to change the speed in the preferences file directly. See the preferences page for instructions on finding the file. Look for the file in your computer and change the serial.download_rate property to match the one in your board. If you have such a board, it's recommended that you burn the latest bootloader (which works at 19200 baud). This can be done with the 'Tools | Burn Bootloader menu item.
Changed lines 47-48 from:

What do to if I get the following error when launching arduino.exe on Windows?

to:

What should I do if I get an error when launching arduino.exe on Windows?

If you get an error when double-clicking the arduino.exe executable on Windows, for example:

Changed lines 53-54 from:

You'll need to launch Arduino using the run.bat file. Please be patient, the Arduino IDE may take some time to open.

to:

you'll need to launch Arduino using the run.bat file. Please be patient, the Arduino environment may take some time to open.

Deleted lines 110-136:

Why I can't upload my programs to the Arduino board?

There are a few things that could be wrong.

  • First make sure your board is on (the green LED is on) and connected to the computer (if it's not, see "what if my board doesn't turn on" above).

  • Then, check that the proper port is selected in the "Tools | Serial Port" menu (if your port doesn't appear, restart the IDE with the board connected to the computer).

  • Make sure there's a bootloader burned on the Atmega8 on your Arduino board. To check, connect an LED to pin 13 and reset the board. The LED should blink. If it doesn't, see the Bootloader page for instructions on burning a bootloader to the board.

  • Be sure that you are resetting the board a couple of seconds before uploading.

  • However, on some computers, you may need to press the reset button on the board after you hit the upload button in the Arduino environment. Try different intervals of time between the two, up to 10 seconds or more.

  • Disconnect digital pins 0 and 1 while uploading (they can connected and used after the code has been uploaded).

  • If you get this error: [VP 1] Device is not responding correctly. try uploading again (i.e. reset the board and press the download button a second time).

  • Check that you're not running any programs that scan all serial ports, like PDA sync applications, Bluetooth-USB drivers (e.g. BlueSoleil), virtual daemon tools, etc.

  • Make sure you don't have firewall software that blocks access to the serial port (e.g. ZoneAlarm).

  • You may need to quit Processing, PD, vvvv, etc. if you're using them to read data over the USB or serial connection to the Arduino board.

  • If you have a really ancient Arduino board, you may need to change the baud rate at which sketches are uploaded to 9600 (from the normal 19200). You will have to change the speed in the preferences file directly. See the preferences page for instructions on finding the file. Look for the file in your computer and change the serial.download_rate property to match the one in your board. If you have such a board, it's recommended that you burn the latest bootloader (which works at 19200 baud). This can be done with the 'Tools | Burn Bootloader menu item.
Deleted lines 126-130:

Why doesn't my sketch start when I'm powering the board with an external power supply?

Because the RX pin is unconnected, the bootloader on the board may be seeing garbage data coming in, meaning that it never times out and starts your sketch. Try tying the RX pin to ground with a 10K resistor (or connecting it to the TX pin).

July 18, 2007, at 04:08 PM by David A. Mellis - adding table of contents
Added lines 3-4:
Changed lines 6-7 from:

What if my board doesn't turn on (the green power LED doesn't light up)?

to:

What if my board doesn't turn on (the green power LED doesn't light up)?

Changed lines 15-16 from:

What do to if I get the following error when launching arduino.exe on Windows?

to:

What do to if I get the following error when launching arduino.exe on Windows?

Changed lines 21-22 from:

Why won't Arduino run on old versions of Mac OS X?

to:

Why won't Arduino run on old versions of Mac OS X?

Changed lines 34-35 from:

What do I do if I get the following error when launching Arduino?

to:

What do I do if I get the following error when launching Arduino?

Changed lines 40-41 from:

What about this error?

to:

What about this error?

Changed lines 46-47 from:

What can I do about cygwin conflicts on Windows?

to:

What can I do about cygwin conflicts on Windows?

Changed lines 61-62 from:

Why doesn't my board show in the Tools | Serial Port menu ?

to:

Why doesn't my board show in the Tools | Serial Port menu ?

Changed lines 78-79 from:

Why I can't upload my programs to the Arduino board?

to:

Why I can't upload my programs to the Arduino board?

Changed lines 104-105 from:

What if I get this error when uploading code or using the serial monitor (on the Mac)?

to:

What if I get this error when uploading code or using the serial monitor (on the Mac)?

Changed lines 116-117 from:

I'm having trouble with the FTDI USB drivers.

to:

I'm having trouble with the FTDI USB drivers.

Changed lines 121-122 from:

Why doesn't my sketch start when I'm powering the board with an external power supply?

to:

Why doesn't my sketch start when I'm powering the board with an external power supply?

Changed lines 126-127 from:

Why doesn't my sketch start when I power up or reset the Arduino board?

to:

Why doesn't my sketch start when I power up or reset the Arduino board?

Changed lines 130-131 from:

Why does my sketch appear to upload successfully but not do anything?

to:

Why does my sketch appear to upload successfully but not do anything?

Changed lines 138-141 from:

How can I reduce the size of my sketch?

The ATmega8 chip on the Arduino board is cheap, but it has only 8 Kb of program code, which isn't very much (and 1 Kb is used by the bootloader).

to:

How can I reduce the size of my sketch?

The ATmega168 chip on the Arduino board is cheap, but it has only 16 Kb of program code, which isn't very much (and 2 Kb is used by the bootloader).

Changed lines 148-160 from:

Why don't I get a PWM (an analog output) when I call analogWrite() on pins other than 9, 10, or 11?

The microcontroller on the Arduino board (the atmega8) only supports PWM/analogWrite() on certain pins. Calling analogWrite() on any other pins will give high (5 volts) for values greater than 128 and low (0 volts) for values less than 128.

Troubleshooting Old Versions of the Arduino Software

These questions are for reference only, as older versions of the Arduino software are no longer supported. Please download the latest version from the software page?.

Arduino 0005 won't start on Mac OS X.

Check your console log (Applications > Utilities > Console). If you see a message like "unsupported major.minor version 49.0", your Java is too old. Run Software Update to upgrade to the latest version.

to:

Why don't I get a PWM (an analog output) when I call analogWrite() on pins other than 3, 5, 6, 9, 10, or 11?

The microcontroller on the Arduino board (the ATmega168) only supports PWM/analogWrite() on certain pins. Calling analogWrite() on any other pins will give high (5 volts) for values greater than 128 and low (0 volts) for values less than 128. (Older Arduino boards with an ATmega8 only support PWM output on pins 9, 10, and 11.)

May 31, 2007, at 04:12 PM by David A. Mellis -
Changed lines 130-131 from:

The sketch may be too big for the board. When uploading your sketch, Arduino 0004 checks if it's too big for the ATmega8, but it bases its calculation on a 1 Kb bootloader. You may have a older bootloader that takes up 2 Kb of the 8 Kb of program space (flash) on the ATmega8 instead of the 1 Kb used by the current bootloader. If yours is bigger, only part of the sketch will be uploaded, but the software won't know, and your board will continually reset, pause, reset.

to:

You have selected the wrong item from the Tools > Microcontroller menu. Make sure the selected microcontroller corresponds to the one on your board (either ATmega8 or ATmega168) - the name will be written on the largest chip on the board.

Alternatively, the sketch may be too big for the board. When uploading your sketch, Arduino 0004 checks if it's too big for the ATmega8, but it bases its calculation on a 1 Kb bootloader. You may have a older bootloader that takes up 2 Kb of the 8 Kb of program space (flash) on the ATmega8 instead of the 1 Kb used by the current bootloader. If yours is bigger, only part of the sketch will be uploaded, but the software won't know, and your board will continually reset, pause, reset.

May 03, 2007, at 02:14 AM by Paul Badger -
Added lines 155-157:

Guide Home

March 23, 2007, at 11:54 PM by David A. Mellis - adding ftdi question
Added lines 114-117:

I'm having trouble with the FTDI USB drivers.

Try installing the latest drivers from FTDI or contacting their support at support1@ftdichip.com.

February 03, 2007, at 09:22 AM by David A. Mellis - adding note about sketch not starting with external power supply.
Added lines 114-118:

Why doesn't my sketch start when I'm powering the board with an external power supply?

Because the RX pin is unconnected, the bootloader on the board may be seeing garbage data coming in, meaning that it never times out and starts your sketch. Try tying the RX pin to ground with a 10K resistor (or connecting it to the TX pin).

December 23, 2006, at 05:28 AM by David A. Mellis -
Changed line 23 from:

@@Link (dyld) error:

to:

[@Link (dyld) error:

Changed lines 26-27 from:

/Applications/arduino-0004/librxtxSerial.jnilib undefined reference to _printf$LDBL128 expected to be defined in /usr/lib/libSystem.B.dylib @@

to:

/Applications/arduino-0004/librxtxSerial.jnilib undefined reference to _printf$LDBL128 expected to be defined in /usr/lib/libSystem.B.dylib @]

December 23, 2006, at 05:28 AM by David A. Mellis -
Deleted lines 142-147:

The Arduino software won't run on Intel Mac machines.

Arduino 0003 uses a native library for doing serial communication that was only compiled for PPC. You'll need to build your own version of RXTX. See this forum thread for more details.

Arduino 0004 includes a universal version of the RXTX library and should run without modifications on Intel Mac machines. Please report success or failure to the forum.

December 23, 2006, at 05:27 AM by David A. Mellis -
Changed lines 133-134 from:

In new releases of the software, we'll try to make more efficient use of the program space and give an error message if your program is too big.

to:

We're always working to reduce the size of the Arduino core to leave more room for your sketches.

December 23, 2006, at 05:26 AM by David A. Mellis - updating upload troubleshooting suggestions
Changed lines 88-89 from:
  • Also, on the serial boards, be sure that digital pins 0 and 1 are not connected to anything while uploading (they can connected and used after the code has been uploaded).
to:
  • However, on some computers, you may need to press the reset button on the board after you hit the upload button in the Arduino environment. Try different intervals of time between the two, up to 10 seconds or more.

  • Disconnect digital pins 0 and 1 while uploading (they can connected and used after the code has been uploaded).
Deleted lines 99-100:
  • Or (especially on Intel Macs), the bootloader on the Arduino board might time out before the compilation of the new sketch finishes and the upload begins. Here's plaidTortoise's fix: "To get it to work I hold down the reset button, click the Upload button and wait a couple of seconds. Then I release the button and a second or so later both the TX and RX Leds on the board light up and both start flashing. The upload then occurs."
December 23, 2006, at 05:21 AM by David A. Mellis -
Changed lines 100-101 from:
  • You may need change the baud rate at which sketches are uploaded. It should be 9600 for older boards (those with no version numbers) and 19200 for newer boards (MOST OF -but not all- version 2.0 or greater, and most of the Arduino Extreme, which has two red LEDs marked "RX" and "TX"). You will have to change the speed in the preferences file directly. See the preferences page for instructions on finding the file. Look for the file in your computer and change the serial.download_rate property to match the one in your board. Though this is a trick to fix this issue, it is recommended to upgrade the bootloader, the one that downloads always at 19200. This can be done with the 'Tools | Burn Bootloader menu item.
to:
  • If you have a really ancient Arduino board, you may need to change the baud rate at which sketches are uploaded to 9600 (from the normal 19200). You will have to change the speed in the preferences file directly. See the preferences page for instructions on finding the file. Look for the file in your computer and change the serial.download_rate property to match the one in your board. If you have such a board, it's recommended that you burn the latest bootloader (which works at 19200 baud). This can be done with the 'Tools | Burn Bootloader menu item.
December 02, 2006, at 11:26 AM by David A. Mellis -
Changed line 114 from:

to:

December 02, 2006, at 11:25 AM by David A. Mellis -
Deleted lines 12-17:

The Arduino software won't run on Intel Mac machines.

Arduino 0003 uses a native library for doing serial communication that was only compiled for PPC. You'll need to build your own version of RXTX. See this forum thread for more details.

Arduino 0004 includes a universal version of the RXTX library and should run without modifications on Intel Mac machines. Please report success or failure to the forum.

Deleted lines 18-21:

Arduino 0005 won't start on Mac OS X.

Check your console log (Applications > Utilities > Console). If you see a message like "unsupported major.minor version 49.0", your Java is too old. Run Software Update to upgrade to the latest version.

Added lines 138-151:

Troubleshooting Old Versions of the Arduino Software

These questions are for reference only, as older versions of the Arduino software are no longer supported. Please download the latest version from the software page?.

The Arduino software won't run on Intel Mac machines.

Arduino 0003 uses a native library for doing serial communication that was only compiled for PPC. You'll need to build your own version of RXTX. See this forum thread for more details.

Arduino 0004 includes a universal version of the RXTX library and should run without modifications on Intel Mac machines. Please report success or failure to the forum.

Arduino 0005 won't start on Mac OS X.

Check your console log (Applications > Utilities > Console). If you see a message like "unsupported major.minor version 49.0", your Java is too old. Run Software Update to upgrade to the latest version.

December 02, 2006, at 11:22 AM by David A. Mellis -
Added lines 124-128:

Why doesn't my sketch start when I power up or reset the Arduino board?

Most likely because you are sending serial data to the board when it firsts turns on. During the first few seconds, the bootloader (a program pre-burned onto the chip on the board) listens for the computer to send it a new sketch to be uploaded to the board. After a few seconds without communication, the bootloader will time out and start the sketch that's already on the board. If you continue to send data to the bootloader, it will never time out and your sketch will never start. You'll either need to find a way to stop serial data from arriving for the first few seconds when the board powers (e.g. by enabling the chip that sends the data from within your setup() function) or burn your sketch onto the board with an external programmer, replacing the bootloader.

November 17, 2006, at 12:09 AM by David A. Mellis -
Changed lines 94-95 from:
  • Make sure there's a bootloader burned on the Atmega8 on your Arduino board. To check, connect an LED to pin 13 and reset the board. The LED should blink. If it doesn't, see the Bootloader? page for instructions on burning a bootloader to the board.
to:
  • Make sure there's a bootloader burned on the Atmega8 on your Arduino board. To check, connect an LED to pin 13 and reset the board. The LED should blink. If it doesn't, see the Bootloader page for instructions on burning a bootloader to the board.
Changed lines 110-111 from:
  • You may need change the baud rate at which sketches are uploaded. It should be 9600 for older boards (those with no version numbers) and 19200 for newer boards (MOST OF -but not all- version 2.0 or greater, and most of the Arduino Extreme, which has two red LEDs marked "RX" and "TX"). You will have to change the speed in the preferences file directly. See the preferences? page for instructions on finding the file. Look for the file in your computer and change the serial.download_rate property to match the one in your board. Though this is a trick to fix this issue, it is recommended to upgrade the bootloader, the one that downloads always at 19200. This can be done with the 'Tools | Burn Bootloader menu item.
to:
  • You may need change the baud rate at which sketches are uploaded. It should be 9600 for older boards (those with no version numbers) and 19200 for newer boards (MOST OF -but not all- version 2.0 or greater, and most of the Arduino Extreme, which has two red LEDs marked "RX" and "TX"). You will have to change the speed in the preferences file directly. See the preferences page for instructions on finding the file. Look for the file in your computer and change the serial.download_rate property to match the one in your board. Though this is a trick to fix this issue, it is recommended to upgrade the bootloader, the one that downloads always at 19200. This can be done with the 'Tools | Burn Bootloader menu item.
Changed lines 128-129 from:

If you have access to an AVR-ISP or parallel port programmer, you can burn the latest version of the bootloader to your board with the Tools | Burn Bootloader menu item. Otherwise, you can tell the Arduino environment the amount of space available for sketches by editing the upload.maximum_size variable in your preferences file (see: instructions on finding the file?). Change 7168 to 6144, and the environment should correctly warn you when your sketch is too big.

to:

If you have access to an AVR-ISP or parallel port programmer, you can burn the latest version of the bootloader to your board with the Tools | Burn Bootloader menu item. Otherwise, you can tell the Arduino environment the amount of space available for sketches by editing the upload.maximum_size variable in your preferences file (see: instructions on finding the file). Change 7168 to 6144, and the environment should correctly warn you when your sketch is too big.

November 10, 2006, at 08:59 AM by David A. Mellis -
Changed line 58 from:

@@ 6 [main] ? (3512) C:\Dev\arduino-0006\tools\avr\bin\avr-gcc.exe: *** fatal error - C:\Dev\arduino-0006\tools\avr\bin\avr-gcc.exe: *** system shared memory version mismatch detected - 0x75BE0084/0x75BE009C.

to:

6 [main] ? (3512) C:\Dev\arduino-0006\tools\avr\bin\avr-gcc.exe: *** fatal error - C:\Dev\arduino-0006\tools\avr\bin\avr-gcc.exe: *** system shared memory version mismatch detected - 0x75BE0084/0x75BE009C.

Changed line 60 from:

This problem is probably due to using incompatible versions of the cygwin DLL.

to:

This problem is probably due to using incompatible versions of the cygwin DLL.

Changed lines 62-63 from:

Search for cygwin1.dll using the Windows Start->Find/Search facility and delete all but the most recent version. The most recent version *should* reside in x:\cygwin\bin, where 'x' is the drive on which you have installed the cygwin distribution. Rebooting is also suggested if you are unable to find another cygwin DLL.@@

to:

Search for cygwin1.dll using the Windows Start->Find/Search facility and delete all but the most recent version. The most recent version *should* reside in x:\cygwin\bin, where 'x' is the drive on which you have installed the cygwin distribution. Rebooting is also suggested if you are unable to find another cygwin DLL.

November 10, 2006, at 08:58 AM by David A. Mellis -
Added lines 54-67:

What can I do about cygwin conflicts on Windows?

If you already have cygwin installed on your machine, you might get an error like this when you try to compile a sketch in Arduino:

@@ 6 [main] ? (3512) C:\Dev\arduino-0006\tools\avr\bin\avr-gcc.exe: *** fatal error - C:\Dev\arduino-0006\tools\avr\bin\avr-gcc.exe: *** system shared memory version mismatch detected - 0x75BE0084/0x75BE009C.

This problem is probably due to using incompatible versions of the cygwin DLL.

Search for cygwin1.dll using the Windows Start->Find/Search facility and delete all but the most recent version. The most recent version *should* reside in x:\cygwin\bin, where 'x' is the drive on which you have installed the cygwin distribution. Rebooting is also suggested if you are unable to find another cygwin DLL.@@

If so, first make sure that you don't have cygwin running when you use Arduino. If that doesn't help, you can try deleting cygwin1.dll from the Arduino directory and replacing it with the cygwin1.dll from your existing cygwin install (probably in c:\cygwin\bin).

Thanks to karlcswanson for the suggestion.

October 26, 2006, at 10:22 PM by David A. Mellis - creating troubleshooting page from faq questions.
Added lines 1-128:

Arduino Troubleshooting

What if my board doesn't turn on (the green power LED doesn't light up)?

If you're using a USB board, make sure that the jumper (little plastic piece near the USB plug) is on the correct pins. If you're powering the board with an external power supply (plugged into the power plug), the jumper should be on the two pins closest to the power plug. If you're powering the board through the USB, the jumper should be on the two pins closest to the USB plug. This picture shows the arrangment for powering the board from the USB port.

Attach:jumper.jpg Δ

(thanks to mrbbp for report and picture)

The Arduino software won't run on Intel Mac machines.

Arduino 0003 uses a native library for doing serial communication that was only compiled for PPC. You'll need to build your own version of RXTX. See this forum thread for more details.

Arduino 0004 includes a universal version of the RXTX library and should run without modifications on Intel Mac machines. Please report success or failure to the forum.

What do to if I get the following error when launching arduino.exe on Windows?

Arduino has encountered a problem and needs to close.

You'll need to launch Arduino using the run.bat file. Please be patient, the Arduino IDE may take some time to open.

Arduino 0005 won't start on Mac OS X.

Check your console log (Applications > Utilities > Console). If you see a message like "unsupported major.minor version 49.0", your Java is too old. Run Software Update to upgrade to the latest version.

Why won't Arduino run on old versions of Mac OS X?

If you get an error like this:

@@Link (dyld) error:

dyld: /Applications/arduino-0004/Arduino 04.app/Contents/MacOS/Arduino Undefined symbols: /Applications/arduino-0004/librxtxSerial.jnilib undefined reference to _printf$LDBL128 expected to be defined in /usr/lib/libSystem.B.dylib @@

you probably need to upgrade to Max OS X 10.3.9 or later. Older versions have incompatible versions of some system libraries.

Thanks to Gabe462 for the report.

What do I do if I get the following error when launching Arduino?

Uncaught exception in main method: java.lang.UnsatisfiedLinkError: Native Library /Users/anu/Desktop/arduino-0002/librxtxSerial.jnilib already loaded in another classloader

You probably have an old version of the communications library lying around. Search for comm.jar or jcl.jar in /System/Library/Frameworks/JavaVM.framework/ or in directories in your CLASSPATH or PATH environment variables. (reported by Anurag Sehgal)

What about this error?

Java Virtual Machine Launcher: Could not find the main class. Program will exit.

Make sure that you correctly extracted the contents of the Arduino .zip file - in particular that the lib directory is directly inside of the Arduino directory and contains the file pde.jar.

Why doesn't my board show in the Tools | Serial Port menu ?

If you're using a USB Arduino board, make sure you installed the FTDI drivers (see the Howto for directions). If you're using a USB-to-Serial adapter with a serial board, make sure you installed its drivers.

Make sure that the board is plugged in: the serial port menu refreshes whenever you open the Tools menu, so if you just unplugged the board, it won't be in the menu.

Check that you're not running any programs that scan all serial ports, like PDA sync applications, Bluetooth-USB drivers (e.g. BlueSoleil), virtual daemon tools, etc.

On Windows, the COM port assigned to the board may be too high. From zeveland:

"One little note if you aren't able to export and your USB board is trying to use a high COM port number: try changing the FTDI chip's COM port assignment to a lower one.

"I had a bunch of virtual COM ports set up for Bluetooth so the board was set to use COM17. The IDE wasn't able to find the board so I deleted the other virtual ports in Control Panel (on XP) and moved the FTDI's assignment down to COM2. Make sure to set Arduino to use the new port and good luck."

On the Mac, if you have an old version of the FTDI drivers, you may need to remove them and reinstall the latest version. See this forum thread for directions (thanks to gck).

Why I can't upload my programs to the Arduino board?

There are a few things that could be wrong.

  • First make sure your board is on (the green LED is on) and connected to the computer (if it's not, see "what if my board doesn't turn on" above).

  • Then, check that the proper port is selected in the "Tools | Serial Port" menu (if your port doesn't appear, restart the IDE with the board connected to the computer).

  • Make sure there's a bootloader burned on the Atmega8 on your Arduino board. To check, connect an LED to pin 13 and reset the board. The LED should blink. If it doesn't, see the Bootloader? page for instructions on burning a bootloader to the board.

  • Be sure that you are resetting the board a couple of seconds before uploading.

  • Also, on the serial boards, be sure that digital pins 0 and 1 are not connected to anything while uploading (they can connected and used after the code has been uploaded).

  • If you get this error: [VP 1] Device is not responding correctly. try uploading again (i.e. reset the board and press the download button a second time).

  • Check that you're not running any programs that scan all serial ports, like PDA sync applications, Bluetooth-USB drivers (e.g. BlueSoleil), virtual daemon tools, etc.

  • Make sure you don't have firewall software that blocks access to the serial port (e.g. ZoneAlarm).

  • You may need to quit Processing, PD, vvvv, etc. if you're using them to read data over the USB or serial connection to the Arduino board.

  • Or (especially on Intel Macs), the bootloader on the Arduino board might time out before the compilation of the new sketch finishes and the upload begins. Here's plaidTortoise's fix: "To get it to work I hold down the reset button, click the Upload button and wait a couple of seconds. Then I release the button and a second or so later both the TX and RX Leds on the board light up and both start flashing. The upload then occurs."

  • You may need change the baud rate at which sketches are uploaded. It should be 9600 for older boards (those with no version numbers) and 19200 for newer boards (MOST OF -but not all- version 2.0 or greater, and most of the Arduino Extreme, which has two red LEDs marked "RX" and "TX"). You will have to change the speed in the preferences file directly. See the preferences? page for instructions on finding the file. Look for the file in your computer and change the serial.download_rate property to match the one in your board. Though this is a trick to fix this issue, it is recommended to upgrade the bootloader, the one that downloads always at 19200. This can be done with the 'Tools | Burn Bootloader menu item.

What if I get this error when uploading code or using the serial monitor (on the Mac)?

Error inside Serial.<init>() 
gnu.io.PortInUseException: Unknown Application 
     at gnu.io.CommPortIdentifier.open(CommPortIdentifier.java:354) 
     at processing.app.Serial.<init>(Serial.java:127) 
     at processing.app.Serial.<init>(Serial.java:72) 

You need to run the macosx_setup.command in the Arduino directory, and then restart your computer. Arduino 0004 includes a modified version of this script that all users need to run (even those who ran the one that came with Arduino 0003). You may also need to delete the contents of the /var/spool/uucp directory.

Why does my sketch appear to upload successfully but not do anything?

The sketch may be too big for the board. When uploading your sketch, Arduino 0004 checks if it's too big for the ATmega8, but it bases its calculation on a 1 Kb bootloader. You may have a older bootloader that takes up 2 Kb of the 8 Kb of program space (flash) on the ATmega8 instead of the 1 Kb used by the current bootloader. If yours is bigger, only part of the sketch will be uploaded, but the software won't know, and your board will continually reset, pause, reset.

If you have access to an AVR-ISP or parallel port programmer, you can burn the latest version of the bootloader to your board with the Tools | Burn Bootloader menu item. Otherwise, you can tell the Arduino environment the amount of space available for sketches by editing the upload.maximum_size variable in your preferences file (see: instructions on finding the file?). Change 7168 to 6144, and the environment should correctly warn you when your sketch is too big.

How can I reduce the size of my sketch?

The ATmega8 chip on the Arduino board is cheap, but it has only 8 Kb of program code, which isn't very much (and 1 Kb is used by the bootloader).

If you're using floating point, try to rewrite your code with integer math, which should save you about 2 Kb. Delete any #include statements at the top of your sketch for libraries that you're not using.

Otherwise, see if you can make your program shorter.

In new releases of the software, we'll try to make more efficient use of the program space and give an error message if your program is too big.

Why don't I get a PWM (an analog output) when I call analogWrite() on pins other than 9, 10, or 11?

The microcontroller on the Arduino board (the atmega8) only supports PWM/analogWrite() on certain pins. Calling analogWrite() on any other pins will give high (5 volts) for values greater than 128 and low (0 volts) for values less than 128.

Share