When I try to upload my code onto the Arduino it just gives me the error message: "avrdude: ser_open(): can't open device "/dev/cu.usbmodem14201": No such file or directory Problem uploading to board. See http://www.arduino.cc/en/Guide/Troubleshooting#upload for suggestions."

My Arduino used to function just fine. Now when a plug it in, the lights on the Arduino do not blink like they used to, and the only pins that do anything are the ones to power. It also said something like: Arduino is not optimized for mac os. It seems that the Arduino is taking in the power but not the code. here's the code:

int led = 13; // the pin the LED is connected to
void setup() {
  pinMode(led, OUTPUT); // Declare the LED as an output

void loop() {
  digitalWrite(led, HIGH); // Turn the LED on
  • Is there a power LED? Is that lit? The lights for the serial connection are only going to blink if there is a program on the board that is sending serial data. I would try it on a different computer and see if its the Mac or the arduino causing issues. – Chad G May 3 '19 at 18:37
  • Genuine Arduino or cheap Chinese clone? – Majenko May 3 '19 at 18:48
  • While having your Arduino connected try pushing the reset button and report us if there is anything blinking. – Roberto Lo Giacco May 3 '19 at 19:33
  • Make sure you have a USB cable with data lines - I spent a couple of hours trying to debug a similar problem because of a "Charging Only" cable. – Kevin White May 8 '19 at 16:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.