User Tools

Site Tools

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
gen7_troubleshooting [2016/01/31 18:18] – [Testing Serial Communications] Traumfluggen7_troubleshooting [2018/05/27 16:10] (current) – external edit (unknown user)
Line 24: Line 24:
 How this works? Well, the character is sent out over USB, converted to serial, sent on the serial transmit line, fed right back into the serial receive line by this wire bridge and then goes all the way back via serial and USB into your terminal window. If this works, serial communications works. How this works? Well, the character is sent out over USB, converted to serial, sent on the serial transmit line, fed right back into the serial receive line by this wire bridge and then goes all the way back via serial and USB into your terminal window. If this works, serial communications works.
  
 +===== Resource Busy =====
 +
 +==== Symptom ====
 +
 +When trying to connect to a Gen7 with a Debian/Ubuntu system, it says this:
 +
 +  stty: /dev/ttyACM0: Device or resource busy
 +
 +==== Cause ====
 +
 +/dev/ttyACM0 is a serial device and as such, Modem Manager assumes it to be a connected modem and tries to establish a network connection as soon as it appears, occupying the device.
 +
 +==== First Solution ====
 +
 +Most simple solution is to simply wait for a minute. Modem Manager gives up after a while, freeing the device.
 +
 +==== Second Solution ====
 +
 +Also a solution is to uninstall Modem Manager:
 +
 +  sudo apt-get purge modemmanager
 +
 +As no other package depends on Modem Manager, this works flawlessly. You loose the ability to make a network connection via a modem, of course.
 +
 +==== Third Solution ====
 +
 +The most sophisticated way is to instruct Modem Manager to try on all serial devices, but not on the Gen7. This is a bit more complicated. Googling around I found several sets of instructions, only one of them looks reasonable:
 +
 +[[http://www.at91.com/linux4sam/bin/view/Linux4SAM/SoftwareTools#Device_or_resource_busy_dev_ttyA|AT91]] writes:
 +
 +  sudo vi /lib/udev/rules.d/10-atmel-usb-device-blacklist.rules
 +
 +Then insert the following lines:
 +
 +  # Atmel CDC interfaces: Not handled by ModemManager
 +  # SEGGER console interface
 +  ATTRS{idVendor}=="1366", ENV{ID_MM_DEVICE_IGNORE}="1"
 +  # SAM-BA CDC interface with SAM-BA monitor
 +  ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="6124", ENV{ID_MM_DEVICE_IGNORE}="1"
 +  # Atmel EDBG CDC interface
 +  ATTRS{idVendor}=="03eb", ATTRS{idProduct}=="2111", ENV{ID_MM_DEVICE_IGNORE}="1"
 +
 +Finally restart udev:
 +
 +  sudo service udev restart
 +  udev stop/waiting
 +  udev start/running, process 9299
 +
 +**RepRap DIY note**: this wasn't tested and the vendorIDs above need to match the Gen7. Also, doing it this way will cause a conflict next time the //udev// package is upgraded. As //udev// allows to override distribution files it'd probably be better to copy that file to ///etc/udev/rules.d//, which causes the one in ///lib/udev/rules.d// to be ignored. Then to edit the copy.
gen7_troubleshooting.1454260680.txt.gz · Last modified: 2018/05/27 16:10 (external edit)