There should be an additional USB device listed. With the original Arduino boards you might directly get the board name, like „Arduino Leonard“. With the cheaper models it maybe just say „USB Device 2.0“. For the official Arduino boards with the FT232 chips you need the FTDI Driver. Those drivers are officially signed by Apple too. There hasn't been an FTDI on an Arduino for many years. If you have a cheap Chinese clone then you probably want the CG340G drivers (and good luck with those). Genuine Arduino boards use a CDC/ACM interface, and all modern operating systems have those drivers built in. – Majenko ♦ May 28 '17 at 10:38.
So I bought some Arduino Nano (https://www.arduino.cc/en/Main/ArduinoBoardNano) over Amazon lately and was amazed that I got 5 boards for only ~15 EUR by some chinese retailer. When I finally found some time and wanted to start programming with the Nano modules I couldn’t manage to connect them to the Arduino IDE.
If connected via USB you normally have to make the USB connection first, start the Arduino IDE and finally have to select the model and mainly the port over the Tools menu. I did so on my OSX 10.11 ( El Capitan ), but the Nano module didn’t show up on the ports list. Only /dev/cu.Bluetooth-Incoming-Port was listed.
After some days of random Google researches and several driver installations without fixing the problem, I finally found out that there are two main USB to UART converter chips used which need different drivers.
Official boards use FT232 some chinese boards use a CH340 Chip
First have a look at the USB modules on your board and read if it says something like „CH34*“ or „FT232“. You could with the chip on the backside of the Arduino board like this:
First of all be sure that your board is still working and is detected at the USB Port. So go by „Apple Logo top left“ > „About This Mac“ > „System Report“ > „Hardware / USB„. Try this once without the Arduino board connected and once with the board connected. There should be an additional USB device listed. With the original Arduino boards you might directly get the board name, like „Arduino Leonard“. With the cheaper models it maybe just say „USB Device 2.0“.
For the official Arduino boards with the FT232 chips you need the FTDI Driver. Those drivers are officially signed by Apple too. No further problems to be expected. Do the following steps:
- Download the drivers ( Version 2.3 and later ) from here: http://www.ftdichip.com/Drivers/VCP.htm
- Install the downloaded .pkg file
- restart the computer
- You should find a new port listed within the Arduino IDE, like /dev/tty.usbserial-xxxxxxxx
For other boards using the CH34x chip you need those drivers. The problem here is, that they are currently not signed by Apple ( and probably will never ). So we have to switch of the security mode. This is of course officially not recommended. WARNING: This will not work with OSX 10.12 (macOS / OSX Sierra). For macOS 10.12 or later you could use the following solution. Please do not do this with those versions as this will stop the boot process and you have to unset this via recovery mode.
For OSX 10.9 – 10.11. you could do the following steps:
- Download the drivers from here: http://www.wch.cn/downfile/178
- Install the downloaded .pkg file
- restart the computer
- run the following command within the terminal
sudo nvram boot-args='kext-dev-mode=1'
- after confirming this with your admin password, restart the computer
- You should find a new port listed within the Arduino IDE, like /dev/cu.wchusbserial1d10
If you want to remove those drivers later remove all file like „FTDIUSBSerialDriver.kext“ or „usbserial.kext“ from the /Library/Extensions directory.
cheers.
Sebastian
Sebastian
The first time using a new microcontroller is what I call funstrating, especially if you don’t have clear instructions. We’ve done the hard work of figuring out the NodeMCU drivers and NodeMCU Arduino IDE setup for you. Read on for the two steps that have to be done only once. More helpful info at the end, too.
Installing NodeMCU drivers for USB
This part of the instructions are written for Windows. They’re very similar for OSX and Linux.
Mostly these days devices download and install drivers on their own, automagically. Unfortunately as of writing this post when I plug a brand new NodeMCU into a new Windows 10 installation with a micro USB cable I get a warning message that says “USB Device Not Recognized – Device Descriptor Request Failed”.
Windows doesn’t know how to talk to the USB driver on the NodeMCU so it can’t figure out that the board is a NodeMCU and proceed normally. You’ll need to download the official driver and install it yourself.
The official NodeMCU drivers are here.
Download and extract the files, then run the Windows 10 installer. NodeMCU should now appear as a COM port on your Windows 10 computer.
Please post OSX-specific instructions them in the comments below.
Upgrade Arduino Boards Manager
We’re almost done! This next bit is pretty easy. Arduino has a list of possible microcontrollers (boards) that it can support if you ask it to add support. This does two useful things: it keeps the download smaller for them (less $) and it means new users are not swamped with lots of options they may never use. We need to add NodeMCU to the list of possible microcontrollers and then tell Arduion “Please download and install support for NodeMCU.”
Fire up Arduino IDE and go to File > Preferences.
In the field that says “Additional Boards Manager URLs” add “http://arduino.esp8266.com/stable/package_esp8266com_index.json” and hit OK. Now your Arduino IDE knows that NodeMCU boards exist.
go to Tools > Boards > Boards Manager
Arduino Driver Download
There are a lot of boards here! In the search field type “esp8266”, which is the name of the Wifi module at the heart of the NodeMCU.
You can see in my copy I’ve already installed the plugin. Click once anywhere on the description text. A button labelled “install” will appear nearby. The location is inconsistent, and IMHO the button should always be visible if the plugin has not been installed. Click it and the installation process will begin. As of this writing it has to download ~150mb of data. Once it’s done, close the Boards Manager.
To back to Tools > Boards and you will find the list is now quite a bit longer.
Choose your flavor of NodeMCU (probably 1.0 ESP-12E Module) and start coding.
NodeMCU example sketches
Arduino Driver Mac High Sierra
Examples for any given board type should appear under File > Examples. Examples are tailored to the type of board that you have currently selected. If you don’t see any NodeMCU or ESP examples, double check that you have Tools > Boards > [your NodeMCU flavor] selected. One time I changed board type to UNO and all my NodeMCU examples vanished. So confusing!
Final thoughts
- Sketch upload time is long compared to UNO or Mega. Still worth it!
- When using digitalWrite(), use digitalWrite(D0) instead of digitalWrite(0) and so on. Pin mapping on the NodeMCU is weird.
- Wifi sketches need the SSID and password of your local Wifi network in order to connect. In the top of most sketches you’ll find a field “….” that should be replaced with your wifi SSID and/or wifi password.
See Also
[products skus=’ELEC-0108, ELEC-0041, ELEC-0111′]