Arduino Yun Mini: How to open ateml U32U4 debug serial port?

Hello.

I am new to Arduino. I am using Arduino Yun Mini board, Arduino 1.7.6 IDE. I am trying to enable ateml U32U4 debug serial port but cannot figure out how.

Here is my simple test program:

================================================

void setup() { // put your setup code here, to run once: pinMode(13, OUTPUT);

// Initialize Serial Serial.begin(9600);

while (!Serial); // wait for a serial connection Serial.println("Starter Project"); }

void loop() { // put your main code here, to run repeatedly: digitalWrite(13, HIGH); delay(1000); digitalWrite(13, LOW); delay(1000);

Serial.println("Blink LED");

}

This should be a simple question. If anybody knows, please let me know.

Thanks,

Nick

nickyang:
Hello.

::::SNIP::::

@nickyang,
I don’t own a Yun Mini yet. But if it is like the original Yun.

  • Plug the device into your PC via the mini USB port (on the Yun).
  • Make sure the port on you machine (that the YUN is connected to) is listed in the IDE.
  • Follow the instructions (canned answer) below:

= [Q:] I cannot connect to My Arduino Yún. What do I do? =

First it’s good to know, when Arduino Yun cannot find the AP you have set it for (like your home wifi), it has a script that puts it back into default SSID and AP mode.

Next, you may have already watched this video, but it’s worth watching again. Pay extra attention to the part with the sketches.
Getting started with Arduino Yún - tutorial (6:53)

Then, read these short instructions. We (the volunteer support group) already know these steps by heart, so be familiar with the different reboot methods, and especially the 30+ second wifi reset. Also, not mentioned on that page, if you reset the Wifi/Linux part of the Yun, it will take from 2-8 minutes for the reboot. Lastly on this part, YOU MUST WAIT for the Linux portion to fully boot BEFORE YOU PRESS ANY of the REST buttons.

Resetting the processors (AR9331, WiFi, and 32U4)

’’‘Then start over’’’, plug your Yun into the USB port, run this sketch, and hit the ‘‘Wifi Reset button’’ (for 5-10 seconds).

The ‘‘YunSerialTerminal’’ provides a simplified console access to the Linux part of the Yun. It works via the USB port (the one that powers the Yun - the microUSB). From there you’ll be able to run a few commands to give us a better idea of problems.

Also, be ready with this sketch YunWiFiStatus. This sketch will help us see the status of your home AP. The sketch prints the wifi status to the console every 5 seconds or so. This sketch might seem familiar as it was in that first video link (above).

Let us know how it goes.
Post results from the YunSerialTerminal, if you are still having problems.
Please use markup when posting results.

Jesse

Thanks for your detailed information, Jesse.

Your message reminds me to check USB/serial port. It turns out I need to install windows driver "arduino.inf". Somehow, when I plugged the board to PC at the first time, it didn't mention me the driver.

This link helped me:

https://www.arduino.cc/en/Guide/Windows#toc4

Nick

nickyang: Thanks for your detailed information, Jesse.

Your message reminds me to check USB/serial port. It turns out I need to install windows driver "arduino.inf". Somehow, when I plugged the board to PC at the first time, it didn't mention me the driver.

This link helped me:

https://www.arduino.cc/en/Guide/Windows#toc4

Nick

@nickyang, excellent that you have that working.

One word, be careful - sometimes windows will move the COM port on you. I don't know the behaviour as I do not own a windows machine (anymore). But I have seen people have problems with this.

What will happen is you will be working, then you need to reboot or something, then the COM port shows up in a different COM port NUMBER. All you need to do is change the port number in your IDE and then it works. I know this is a PITA, but maybe someone else has a suggestion.

Best of Luck, Jesse

jessemonroy650: One word, be careful - sometimes windows will move the COM port on you. I don't know the behaviour as I do not own a windows machine (anymore). But I have seen people have problems with this.

What will happen is you will be working, then you need to reboot or something, then the COM port shows up in a different COM port NUMBER. All you need to do is change the port number in your IDE and then it works. I know this is a PITA, but maybe someone else has a suggestion.

It does not change randomly: it may seem that way at times, but there is a pattern. Each time a specific device (unique VID/PID combination) is plugged into a particular USB port, Windows looks to see if it already has a driver installed for that device/port combination: if so, it uses that driver and the same COMx port that was assigned to it. But if that same device is plugged into a different physical USB port, it will get a new driver instance, and a different COMx number. But every time that device is plugged into that same physical port, it will get the same COMx number.

This causes confusion when the same device is plugged into different ports, as the COMx number will be different (but always the same for the particular port.) it's a side effect of the way they handle the ability of having multiple devices of the same type: if a Yun was always assigned the same COMx number regardless of the physical USB port, then you wouldn't be able to plug in two Yun's at the same time, as there would be a conflict since they both have the same COMx number.

It seems to me that it would've made more sense to assign the COMx number to the physical USB port, so that any serial device plugged into it would get that same COMx number, but Microsoft didn't ask my opinion before they implemented it. And that's probably a good thing since that scheme would break down if a device has multiple serial channels: for example, I have a four port RS-232 to USB converter: the first port would get that COMx number, but what COMx number would the other three ports get?