6

I am using an Arduino Uno and a Mac and trying to upload my code into the board. I tried uploading the program from different computers(MacBook Air and Pro) and I still have this problem.

How do I fix this? I tried downloading the FTDI driver. I went to the website that they suggested and tried following the instructions. I even followed other posts in Stack Exchange but I still cannot upload the code.

EDIT

Programmer -> AVRISP mkll

I am using a cable to connect to my Mac and I am using the Arduino software. The cable connected between the Arduino USB and Mac USB port.

I tried quitting and relaunching Arduino app. Once it launches I just press the upload button while my USB is plugged in. My available ports in the app are /dev/cu.Bluetooth-Incoming-Port and /dev/cu.Bluetooth-Modem

And this is the error

avrdude: ser_open(): can't open device "/dev/cu.usbmodem1421": No such file or directory
ioctl("TIOCMGET"): Inappropriate ioctl for device
  • Please edit question and add following info: How the Uno is connected to Mac, including name or model number of cable or whatever, and what connects where. The program you used and the commands you entered to upload the code. If you are using arduino ide, what options you selected, eg which port, which programmer, programming mode. URL of "the website they suggested". – James Waldby - jwpat7 Jul 9 '15 at 11:49
  • Better, but please add the other info requested. The problem will be something simple but if people don't know what you have or what you did, then their answers are just guesses. What options did you set? What buttons did you click? What's selected at Tools/Port ? at Tools/Board ? What is each end of the programming cable plugged into? What's the cable? (Eg say if it is a USB A to USB B micro, connected to a USB port on Mac and USB on Uno) – James Waldby - jwpat7 Jul 9 '15 at 12:07
  • Tried running your arduino as a root user? – Michael Jul 9 '15 at 12:08
  • 1
    I think @Majenko is asking if you are using a plain USB cable vs some add-on programmer board. From your latest edit, I assume you use a plain USB cable. I don't know much Mac stuff but it looks to me like port setting is wrong – Bluetooth is totally not relevant to this USB cabled connection. See Getting Started w/ Arduino on Mac OS X which says to use a port like /dev/tty.usbmodem or /dev/tty.usbserial – James Waldby - jwpat7 Jul 9 '15 at 16:20
  • 1
    Did any of the answer help you to resolve your issue? If so, could you mark the answer that helped you the most as "accepted"? – Greenonline Mar 25 '16 at 10:34
6

Plug your Uno into the Mac using a known good USB cable.

Go to the Apple menu -> About This Mac -> More Info -> System Report

Under the USB selection (on the left) please confirm whether or not you see something like this:

Arduino USB in System Report

You can also open a Terminal window and type:

system_profiler SPUSBDataType

Amongst other things you should see:

USB:

    USB High-Speed Bus:

      Host Controller Location: Built-in USB
      Host Controller Driver: AppleUSBEHCI
      PCI Device ID: 0x3b34 
      PCI Revision ID: 0x0006 
      PCI Vendor ID: 0x8086 
      Bus Number: 0xfd 

        Hub:

          Product ID: 0x2514
          Vendor ID: 0x0424  (SMSC)
          Version: 0.03
          Speed: Up to 480 Mb/sec
          Location ID: 0xfd100000 / 2
          Current Available (mA): 500
          Current Required (mA): 2

            Communication Device:

              Product ID: 0x0043
              Vendor ID: 0x2341
              Version: 0.01
              Serial Number: 9314036423335121A0B1
              Speed: Up to 12 Mb/sec
              Manufacturer: Arduino (www.arduino.cc)
              Location ID: 0xfd130000 / 8
              Current Available (mA): 500
              Current Required (mA): 100

Note the "www.arduino.cc" entry.

In your Arduino IDE you should see the Arduino as a tty.usbmodemfd131 (or some similar number).

Arduino Uno USB modem

If you see all that it should work.

If not, please state in what way it differs.

Programmer -> AVRISP mkll

You should not be selecting any programmer. You should be doing an "Upload" (Command-U) not an "Upload using programmer" (Shift+Command+U).

1

I solved this problem. Maybe this post will help others.

I've come across this problem a couple of times. I literally searched for hours for the answer and ended up using several suggestions.

Both scenarios I solved are documented below as 'Scenario A' and 'Scenario B':

====================== Scenario A

Plugged in a new Arduino Uno R3 board, successfully compiled the standard "Blink" sketch. When I tried to upload it to the board, I got this message:

Sketch uses 1,066 bytes (3%) of program storage space. Maximum is 32,256 bytes. Global variables use 9 bytes (0%) of dynamic memory, leaving 2,039 bytes for local variables. Maximum is 2,048 bytes. avrdude: ser_open(): can't open device "COM1": No such file or directory ioctl("TIOCMGET"): Inappropriate ioctl for device Problem uploading to board. See http://www.arduino.cc/en/Guide/Troubleshooting#upload for suggestions.

The Port Options in the IDE (Tools--> Port) only showed /dev/cu.incoming-bluetooth-port

Here's what worked:

  1. Downloaded and Installed the CH340 driver
  2. Removed the FTDI drivers from my mac. Apple recently installed a new utility that prevents removal of what it considers to be critical components.

The process that enforces this rule is called csrutil.

You'll have to disable this process to remove the FTDI driver. Then you'll need to re-enable it when you are done. This required a restart in recovery mode. Here's how to do that:

a.)  power off the mac then hold 'command'+R during the restart until the image of the apple appears.
b.)  when the screen refreshes, click on 'Utilities' menu then 'Terminal.
c.)  type csrutil disable
d.)  Hit enter
e.)  Restart  [Note:  You may be able to execute the next two commands in the terminal before restarting.  I just didn't test it that way.  If the system will allow you to, then by all means run all three commands one after the other THEN restart and you should be on your way.]
  1. remove the FTDI drivers by opening the terminal program again and entering the following command:

       sudo rm -R /System/Library/Extensions/AppleUSBFTDI.kext
    

Type in your password when prompted.

  1. Restore the apple csrutil by following steps a and b above. Task c will be the same EXCEPT you'll type this instead:

    csrutil enable
    

    Then follow steps d and e.

When you restart the arduino IDE, you should see a more comprehensive list of ports besides just the bluetooth port.

====================== Scenario B

This board was an import and clearly not an original Arduino/Genuino. Attempts to load sketches resulted in this lovely error:

    Using Port                    : /dev/cu.usbmodem1421
    Using Programmer              : arduino
    Overriding Baud Rate          : 115200

avrdude: ser_open(): can't open device "/dev/cu.usbmodem1421": No such file or directory ioctl("TIOCMGET"): Inappropriate ioctl for device

There was only one Port listed in the IDE, dev/cu.Bluetooth-Incoming-Port.

It had been a while since Scenario A had occurred and since then I'd installed a few OS updates. Checked the drivers and low and behold, the darned FTDI drivers had RETURNED!!

I repeated the steps in scenario A above but the problem remained.

Then I installed an updated board configuration from arduino and it worked! Testing on the first board I'd used under scenario A were successful as well. Here's what I did:

  1. In the IDE go to Tools-> Boards -> Boards Manager
  2. I installed 'Arduino SAM Boards (32-bits ARM Cortex-M3) by Arduino version 1.6.8
  3. Unplugged and replugged the USB cable into my arduino.
  4. In the IDE go to Tools -> Port. The /dev/cu.usbmodem1421 was listed as a port option. Selected that.
  5. Uploaded my sketch.
  6. Bask in glory of SUCCESS!

I hope this was helpful to you. I spent two days on Scenario A and 3 hours on Scenario B.

  • Warning to future testers, after installing that driver whenever I plug my arduino it freezes my mac and I have to restart – eestein Dec 13 '16 at 19:11
0

I've also had this error message when I've left another serial terminal connected to the same port the Arduino IDE is trying to use.

0

I got this error on my Macintosh system and the problem was that I needed to choose the correct port on the USB. Somehow it had auto-connected to a Bluetooth port which was listed under Tools->Port as /dev/cu.Bluetooth-modem and was my daughter's cell phone. I chose a port labeled /dev/cu/wchusbserialfd... and it worked fine.

-2

I had this problem on a Linux distribution. It was just a permissions issue for me.

sudo ./arduino 

from the Linux Terminal in the Arduino folder worked fine.

  • Do not run Arduino as root - it's unsafe, and likely to leave behind a mess in the form of files which your regulator account cannot clean up. – Chris Stratton Aug 1 '16 at 3:58

Not the answer you're looking for? Browse other questions tagged or ask your own question.