开发者

Arduino upload error "stk500_recv(): programmer is not responding" in Fedora

开发者 https://www.devze.com 2023-04-08 19:42 出处:网络
I am attempting to upload the stock Blink sketch using the Arduino IDE in Fedora Core 15 Linux. I get this error:

I am attempting to upload the stock Blink sketch using the Arduino IDE in Fedora Core 15 Linux. I get this error:

avrdude: stk500_recv(): programmer is not responding

To recreate the issue:

  1. Plug in the Arduino Uno board via USB cable
  2. Open the Arduino IDE
  3. Menu FileExamples1. BasicsBlink
  4. Menu ToolsSerial Port → then check the box for /dev/ttyACM0
  5. Menu ToolsBoardArduino Uno
  6. Click the "Play" button to Verify/Compile (this step is successful)
  7. Click the Upload button, to get the error

I tried these same exact steps in Windows XP, and the upload was successful, so I must not have Fedora configured correctly开发者_开发问答.

I followed the Arduino Playground instructions, installing the client using yum and adding my user ID to the groups uucp, lock and dialout.

I did not follow the RXTX fixup -- Link the proper files part of the guide, since the given command did not return any matches: find ~ -name librxtxSerial.so -o -name RXTXcomm.jar | grep -v Download


Before uploading your programme, make sure you selected the right board type, from menu ToolsBoard.


Check if you have any jumpers connected to the digital pins 0 or 1. Those pins have also serial communication functions. And because you are uploading on the Arduino board, using the serial connection provided by the USB cable, you don't want the board's serial port to be engaged in other activities via pins 0 or 1.


In my case, go to menu ToolsProcessor and change to ATMega328P (Old Bootloader). Then the problem is solved.

But make sure that you do the chmod before upload:

sudo chmod a+rw /dev/ttyUSB0


This sounds like it was probably caused by a bug that was present in AVRDUDE at the time. A simple yum update AVRDUDE should now fix it.


For me, changing the cable worked.

I was using Ubuntu 17.04 (Zesty Zapus), Arduino Nano with ATmega28 and a USB cable with ferrite choke (I don’t think ferrite choke was the cause).


The fix that worked for me:

If you have a USBasp programmer (or other type of ICSP programmer) plugged into your Arduino board (but not plugged into your PC), because you just used it to flash the bootloader of your Arduino board, unplug it from the Arduino. Disconnecting the 5V line between the USBasp programmer and the Arduino was enough for me. Now uploading works (with the USBasp programmer lying on the bench with all but the 5V pin still connected to the Arduino).


Arduino Uno R3, Mac OS X v10.8.3 (Mountain Lion), any version of Arduino.app. For me changing the USB cable fix this error.


I believe the instruction in Why I can't upload my programs to the Arduino board? that says

On Linux, the Uno and Mega 2560 show up as devices of the form /dev/ttyACM0

does not always apply. In my Ubuntu 14.10 (Utopic Unicorn) I can see that port in menu ToolsSerial Port, but when selected and trying to upload to the Arduino Nano V3 I get the error

stk500_recv(): programmer is not responding

Changing the Tools -> Serial Port to /dev/ttyUSB0 solves the problem.

I'm guessing that this may be the case in my system where I had an other device at the same USB port before plugging Arduino there. It may be that after restart the situation might be different; I don't know haven't tested. But whatever is the cause, the good news is that the problem can be solved.

You can easily check what is the correct serial port by first checking what ports are available without plugging the Arduino (menu ToolsSerial Port) and then checking again what is the added port after plugging the Arduino in the USB port.


Since this question was posted, a new stable version of Arduino has been released. They are now on 1.0, and it works in Fedora Core Linux 16. It can be downloaded here: http://arduino.cc/en/Main/Software


After hours of searching, the problem has been solved:

Choose menu ToolsProgrammerArduino as ISP


For Windows, I tried doing this

  • In PowerShell, run devcon status usb*. This should show multiple devices similar, one among which would be

    USB\VID_2341&PID_8036&MI_00\6&1D9C3F6B&0&0000
        Name: Arduino Leonardo (COM3)
        Driver is running.
    
  • Then do reg add "HKLM\SYSTEM\ControlSet001\Enum\USB\VID_2341&PID_8036&MI_00\6&1D9C3F6B&0&0000\Device Parameters" /v "PortName" /t REG_SZ /d "COM3" /f.. Double check COM3 is also listed in Device Manager menu of windows.

  • Restart the machine and the Arduino IDE. And try uploading again.

0

精彩评论

暂无评论...
验证码 换一张
取 消